app-emulation/anbox: treeclean
Signed-off-by: Alfred Wingate <parona@protonmail.com>
This commit is contained in:
parent
4d109b9f7f
commit
a51c23293b
@ -1,2 +0,0 @@
|
||||
DIST anbox-20211020.tar.gz 1025857 BLAKE2B e5c7d9d17751ecd5d52ef6db1f48c0a3a3b0398dd3e0cfce974e5743bcd58c1dc4e72a6eac719fc4a56f297917da56340bf45cda247c31f45c0001420e0188c1 SHA512 9092a212b6662b84becf86c96a001090187763003a3c16d4fd4d7b4d31cc6bb92be240cbba1593b89e39637cb43da19f8f91567a578c7626709addb96be16809
|
||||
DIST cpu_features-b9593c8b395318bb2bc42683a94f962564cc4664.tar.gz 55211 BLAKE2B b49714863cbebfde09e6ab99f31d9aaace367d84df9ecb12989fffc1326c9c60cfa14d917e490332c2a0b2a3fe267b6327b719652afba9bfa1654fc2564408b8 SHA512 8c12b50741e2979a32b69c788934bee0d00811b7662006c8b493e98d5efeada67ed59460be40c234b2d3bafd85671cb1a1d7c1a6ee535a7fc1cc6ac56a754576
|
@ -1,145 +0,0 @@
|
||||
# Copyright 2020-2022 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit linux-info systemd cmake
|
||||
|
||||
DESCRIPTION="Container-based approach to boot a full Android system"
|
||||
HOMEPAGE="https://anbox.io/"
|
||||
|
||||
if [[ "${PV}" == "99999999" ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/anbox/anbox.git"
|
||||
EGIT_SUBMODULES=( 'external/cpu_features' )
|
||||
else
|
||||
COMMIT="84f0268012cbe322ad858d76613f4182074510ac" # 20.10.2021
|
||||
EXTCOMMIT="b9593c8b395318bb2bc42683a94f962564cc4664"
|
||||
SRC_URI="
|
||||
https://github.com/anbox/anbox/archive/${COMMIT}.tar.gz -> ${P}.tar.gz
|
||||
https://github.com/google/cpu_features/archive/${EXTCOMMIT}.tar.gz -> cpu_features-${EXTCOMMIT}.tar.gz
|
||||
"
|
||||
S="${WORKDIR}/${PN}-${COMMIT}"
|
||||
KEYWORDS="~amd64"
|
||||
fi
|
||||
|
||||
LICENSE="GPL-3"
|
||||
SLOT="0"
|
||||
IUSE="X wayland systemd"
|
||||
|
||||
DEPEND="
|
||||
>=app-containers/lxc-3.0.0
|
||||
dev-cpp/properties-cpp
|
||||
dev-cpp/sdbus-c++
|
||||
dev-cpp/gtest
|
||||
dev-libs/boost[threads(+)]
|
||||
dev-libs/expat
|
||||
dev-libs/protobuf
|
||||
media-libs/libsdl2
|
||||
media-libs/glm
|
||||
media-libs/mesa[egl(+),gles2]
|
||||
media-libs/sdl2-image
|
||||
sys-apps/dbus
|
||||
sys-fs/fuse:3
|
||||
sys-libs/libcap
|
||||
|| (
|
||||
sys-apps/systemd
|
||||
sys-auth/elogind
|
||||
)
|
||||
"
|
||||
RDEPEND="${DEPEND}"
|
||||
BDEPEND="virtual/pkgconfig"
|
||||
|
||||
CONFIG_CHECK="
|
||||
~ANDROID_BINDERFS
|
||||
~ANDROID_BINDER_IPC
|
||||
~ASHMEM
|
||||
~BLK_DEV_LOOP
|
||||
~FUSE_FS
|
||||
~SQUASHFS
|
||||
~SQUASHFS_XZ
|
||||
~SQUASHFS_XATTR
|
||||
~TMPFS_XATTR
|
||||
"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/lxc.patch"
|
||||
"${FILESDIR}/no_bundled_sdbus-r1.patch"
|
||||
)
|
||||
|
||||
pkg_pretend() {
|
||||
if use !systemd; then
|
||||
# Needed for anbox-bridge.sh
|
||||
CONFIG_CHECK="
|
||||
~NETFILTER_XT_MATCH_COMMENT
|
||||
~NETFILTER_XT_TARGET_CHECKSUM
|
||||
"
|
||||
check_extra_config
|
||||
fi
|
||||
# Check if ANDROID_BINDER_DEVICES has binder string specicied in it
|
||||
if ! linux_config_exists && grep -qE '(CONFIG_ANDROID_BINDER_DEVICES=*[^h][^w]binder)' "${KERNEL_DIR}"/.config; then
|
||||
eerror " CONFIG_ANDROID_BINDER_DEVICES does not contain string 'binder'"
|
||||
fi
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
cp "${FILESDIR}/FindGMock.cmake" "${S}/cmake" || die
|
||||
|
||||
if [[ "${PV}" != "99999999" ]]; then
|
||||
mv "${WORKDIR}"/cpu_features-"${EXTCOMMIT}"/* "${S}"/external/cpu_features || die
|
||||
fi
|
||||
|
||||
if use !systemd; then
|
||||
eapply "${FILESDIR}"/remove_systemd_dependency-r1.patch
|
||||
fi
|
||||
|
||||
cmake_src_prepare
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
local mycmakeargs=(
|
||||
-DCMAKE_BUILD_TYPE=Release
|
||||
-DENABLE_X11=$(usex X)
|
||||
-DENABLE_WAYLAND=$(usex wayland)
|
||||
-DBUILD_SHARED_LIBS=OFF
|
||||
)
|
||||
if [[ "${PV}" != "99999999" ]]; then
|
||||
mycmakeargs+=(-DANBOX_VERSION="${PV} (${COMMIT})")
|
||||
fi
|
||||
|
||||
cmake_src_configure
|
||||
}
|
||||
|
||||
src_install() {
|
||||
cmake_src_install
|
||||
|
||||
newbin "${FILESDIR}"/anbox-launch.sh anbox-launch
|
||||
|
||||
if use systemd; then
|
||||
systemd_dounit "${FILESDIR}"/anbox-{container-manager.service,bridge.net{dev,work}}
|
||||
systemd_douserunit "${FILESDIR}"/anbox-session-manager.service
|
||||
else
|
||||
exeinto /usr/share/anbox
|
||||
doexe scripts/anbox-bridge.sh
|
||||
newinitd "${FILESDIR}"/anbox-container-manager-r1.initd anbox-container-manager
|
||||
newconfd "${FILESDIR}"/anbox-container-manager.confd anbox-container-manager
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
einfo "Anbox requires a specially made android image installed to /usr/share/anbox/android.img. "
|
||||
einfo "You can either download it prebuilt from upstream:"
|
||||
einfo " https://build.anbox.io/android-images/"
|
||||
einfo "or to build it manually according to instructions:"
|
||||
einfo " https://github.com/anbox/anbox/blob/master/docs/build-android.md"
|
||||
einfo ""
|
||||
einfo "How to get it running:"
|
||||
einfo "First start the anbox-container-manager daemon"
|
||||
if use systemd; then
|
||||
einfo "# systemctl start anbox-container-manager"
|
||||
else
|
||||
einfo "# rc-service anbox-container-manager start"
|
||||
fi
|
||||
einfo "Then you can access the image"
|
||||
einfo "$ anbox-launch"
|
||||
}
|
@ -1,145 +0,0 @@
|
||||
# Copyright 2020-2022 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit linux-info systemd cmake
|
||||
|
||||
DESCRIPTION="Container-based approach to boot a full Android system"
|
||||
HOMEPAGE="https://anbox.io/"
|
||||
|
||||
if [[ "${PV}" == "99999999" ]]; then
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://github.com/anbox/anbox.git"
|
||||
EGIT_SUBMODULES=( 'external/cpu_features' )
|
||||
else
|
||||
COMMIT="84f0268012cbe322ad858d76613f4182074510ac" # 20.10.2021
|
||||
EXTCOMMIT="b9593c8b395318bb2bc42683a94f962564cc4664"
|
||||
SRC_URI="
|
||||
https://github.com/anbox/anbox/archive/${COMMIT}.tar.gz -> ${P}.tar.gz
|
||||
https://github.com/google/cpu_features/archive/${EXTCOMMIT}.tar.gz -> cpu_features-${EXTCOMMIT}.tar.gz
|
||||
"
|
||||
S="${WORKDIR}/${PN}-${COMMIT}"
|
||||
KEYWORDS="~amd64"
|
||||
fi
|
||||
|
||||
LICENSE="GPL-3"
|
||||
SLOT="0"
|
||||
IUSE="X wayland systemd"
|
||||
|
||||
DEPEND="
|
||||
>=app-containers/lxc-3.0.0
|
||||
dev-cpp/properties-cpp
|
||||
dev-cpp/sdbus-c++
|
||||
dev-cpp/gtest
|
||||
dev-libs/boost[threads(+)]
|
||||
dev-libs/expat
|
||||
dev-libs/protobuf
|
||||
media-libs/libsdl2
|
||||
media-libs/glm
|
||||
media-libs/mesa[egl(+),gles2]
|
||||
media-libs/sdl2-image
|
||||
sys-apps/dbus
|
||||
sys-fs/fuse:3
|
||||
sys-libs/libcap
|
||||
|| (
|
||||
sys-apps/systemd
|
||||
sys-auth/elogind
|
||||
)
|
||||
"
|
||||
RDEPEND="${DEPEND}"
|
||||
BDEPEND="virtual/pkgconfig"
|
||||
|
||||
CONFIG_CHECK="
|
||||
~ANDROID_BINDERFS
|
||||
~ANDROID_BINDER_IPC
|
||||
~ASHMEM
|
||||
~BLK_DEV_LOOP
|
||||
~FUSE_FS
|
||||
~SQUASHFS
|
||||
~SQUASHFS_XZ
|
||||
~SQUASHFS_XATTR
|
||||
~TMPFS_XATTR
|
||||
"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/lxc.patch"
|
||||
"${FILESDIR}/no_bundled_sdbus-r1.patch"
|
||||
)
|
||||
|
||||
pkg_pretend() {
|
||||
if use !systemd; then
|
||||
# Needed for anbox-bridge.sh
|
||||
CONFIG_CHECK="
|
||||
~NETFILTER_XT_MATCH_COMMENT
|
||||
~NETFILTER_XT_TARGET_CHECKSUM
|
||||
"
|
||||
check_extra_config
|
||||
fi
|
||||
# Check if ANDROID_BINDER_DEVICES has binder string specicied in it
|
||||
if ! linux_config_exists && grep -qE '(CONFIG_ANDROID_BINDER_DEVICES=*[^h][^w]binder)' "${KERNEL_DIR}"/.config; then
|
||||
eerror " CONFIG_ANDROID_BINDER_DEVICES does not contain string 'binder'"
|
||||
fi
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
cp "${FILESDIR}/FindGMock.cmake" "${S}/cmake" || die
|
||||
|
||||
if [[ "${PV}" != "99999999" ]]; then
|
||||
mv "${WORKDIR}"/cpu_features-"${EXTCOMMIT}"/* "${S}"/external/cpu_features || die
|
||||
fi
|
||||
|
||||
if use !systemd; then
|
||||
eapply "${FILESDIR}"/remove_systemd_dependency-r1.patch
|
||||
fi
|
||||
|
||||
cmake_src_prepare
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
local mycmakeargs=(
|
||||
-DCMAKE_BUILD_TYPE=Release
|
||||
-DENABLE_X11=$(usex X)
|
||||
-DENABLE_WAYLAND=$(usex wayland)
|
||||
-DBUILD_SHARED_LIBS=OFF
|
||||
)
|
||||
if [[ "${PV}" != "99999999" ]]; then
|
||||
mycmakeargs+=(-DANBOX_VERSION="${PV} (${COMMIT})")
|
||||
fi
|
||||
|
||||
cmake_src_configure
|
||||
}
|
||||
|
||||
src_install() {
|
||||
cmake_src_install
|
||||
|
||||
newbin "${FILESDIR}"/anbox-launch.sh anbox-launch
|
||||
|
||||
if use systemd; then
|
||||
systemd_dounit "${FILESDIR}"/anbox-{container-manager.service,bridge.net{dev,work}}
|
||||
systemd_douserunit "${FILESDIR}"/anbox-session-manager.service
|
||||
else
|
||||
exeinto /usr/share/anbox
|
||||
doexe scripts/anbox-bridge.sh
|
||||
newinitd "${FILESDIR}"/anbox-container-manager-r1.initd anbox-container-manager
|
||||
newconfd "${FILESDIR}"/anbox-container-manager.confd anbox-container-manager
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
einfo "Anbox requires a specially made android image installed to /usr/share/anbox/android.img. "
|
||||
einfo "You can either download it prebuilt from upstream:"
|
||||
einfo " https://build.anbox.io/android-images/"
|
||||
einfo "or to build it manually according to instructions:"
|
||||
einfo " https://github.com/anbox/anbox/blob/master/docs/build-android.md"
|
||||
einfo ""
|
||||
einfo "How to get it running:"
|
||||
einfo "First start the anbox-container-manager daemon"
|
||||
if use systemd; then
|
||||
einfo "# systemctl start anbox-container-manager"
|
||||
else
|
||||
einfo "# rc-service anbox-container-manager start"
|
||||
fi
|
||||
einfo "Then you can access the image"
|
||||
einfo "$ anbox-launch"
|
||||
}
|
@ -1,102 +0,0 @@
|
||||
# Copyright (C) 2014 Canonical Ltd
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Lesser General Public License version 3 as
|
||||
# published by the Free Software Foundation.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU Lesser General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Lesser General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# Build with system gmock and embedded gtest
|
||||
#
|
||||
# Usage:
|
||||
#
|
||||
# find_package(GMock)
|
||||
#
|
||||
# ...
|
||||
#
|
||||
# target_link_libraries(
|
||||
# my-target
|
||||
# ${GTEST_BOTH_LIBRARIES}
|
||||
# )
|
||||
#
|
||||
# NOTE: Due to the way this package finder is implemented, do not attempt
|
||||
# to find the GMock package more than once.
|
||||
|
||||
find_package(Threads)
|
||||
|
||||
pkg_check_modules(GTEST gtest )
|
||||
pkg_check_modules(GTEST_MAIN gtest_main)
|
||||
pkg_check_modules(GMOCK gmock )
|
||||
pkg_check_modules(GMOCK_MAIN gmock_main)
|
||||
|
||||
if (NOT (GTEST_FOUND AND GTEST_MAIN_FOUND AND GMOCK_FOUND AND GMOCK_MAIN_FOUND))
|
||||
|
||||
if (EXISTS "/usr/src/googletest")
|
||||
# As of version 1.8.0
|
||||
set(GMOCK_SOURCE_DIR "/usr/src/googletest/googlemock" CACHE PATH "gmock source directory")
|
||||
set(GMOCK_INCLUDE_DIRS "${GMOCK_SOURCE_DIR}/include" CACHE PATH "gmock source include directory")
|
||||
set(GTEST_INCLUDE_DIRS "/usr/src/googletest/googletest/include" CACHE PATH "gtest source include directory")
|
||||
else()
|
||||
set(GMOCK_SOURCE_DIR "/usr/src/gmock" CACHE PATH "gmock source directory")
|
||||
set(GMOCK_INCLUDE_DIRS "/usr/include" CACHE PATH "gmock source include directory")
|
||||
set(GTEST_INCLUDE_DIRS "/usr/include" CACHE PATH "gtest source include directory")
|
||||
endif()
|
||||
|
||||
# We add -g so we get debug info for the gtest stack frames with gdb.
|
||||
# The warnings are suppressed so we get a noise-free build for gtest and gmock if the caller
|
||||
# has these warnings enabled.
|
||||
set(findgmock_cxx_flags "${CMAKE_CXX_FLAGS} -g -Wno-old-style-cast -Wno-missing-field-initializers -Wno-ctor-dtor-privacy -Wno-switch-default")
|
||||
|
||||
set(findgmock_bin_dir "${CMAKE_CURRENT_BINARY_DIR}/gmock")
|
||||
set(findgmock_gtest_lib "${findgmock_bin_dir}/lib/libgtest.a")
|
||||
set(findgmock_gtest_main_lib "${findgmock_bin_dir}/lib/libgtest_main.a")
|
||||
set(findgmock_gmock_lib "${findgmock_bin_dir}/lib/libgmock.a")
|
||||
set(findgmock_gmock_main_lib "${findgmock_bin_dir}/lib/libgmock_main.a")
|
||||
|
||||
include(ExternalProject)
|
||||
ExternalProject_Add(GMock SOURCE_DIR "${GMOCK_SOURCE_DIR}"
|
||||
BINARY_DIR "${findgmock_bin_dir}"
|
||||
BUILD_BYPRODUCTS "${findgmock_gtest_lib}"
|
||||
"${findgmock_gtest_main_lib}"
|
||||
"${findgmock_gmock_lib}"
|
||||
"${findgmock_gmock_main_lib}"
|
||||
INSTALL_COMMAND ""
|
||||
CMAKE_ARGS "-DCMAKE_CXX_FLAGS=${findgmock_cxx_flags}")
|
||||
|
||||
add_library(gtest INTERFACE)
|
||||
target_include_directories(gtest INTERFACE ${GTEST_INCLUDE_DIRS})
|
||||
target_link_libraries(gtest INTERFACE ${findgmock_gtest_lib} ${CMAKE_THREAD_LIBS_INIT})
|
||||
add_dependencies(gtest GMock)
|
||||
|
||||
add_library(gtest_main INTERFACE)
|
||||
target_include_directories(gtest_main INTERFACE ${GTEST_INCLUDE_DIRS})
|
||||
target_link_libraries(gtest_main INTERFACE ${findgmock_gtest_main_lib} gtest)
|
||||
|
||||
add_library(gmock INTERFACE)
|
||||
target_include_directories(gmock INTERFACE ${GMOCK_INCLUDE_DIRS})
|
||||
target_link_libraries(gmock INTERFACE ${findgmock_gmock_lib} gtest)
|
||||
|
||||
add_library(gmock_main INTERFACE)
|
||||
target_include_directories(gmock_main INTERFACE ${GMOCK_INCLUDE_DIRS})
|
||||
target_link_libraries(gmock_main INTERFACE ${findgmock_gmock_main_lib} gmock gtest_main)
|
||||
|
||||
set(GTEST_LIBRARIES gtest)
|
||||
set(GTEST_MAIN_LIBRARIES gtest_main)
|
||||
set(GMOCK_LIBRARIES gmock gmock_main)
|
||||
|
||||
unset(findgmock_cxx_flags)
|
||||
unset(findgmock_bin_dir)
|
||||
unset(findgmock_gtest_lib)
|
||||
unset(findgmock_gtest_main_lib)
|
||||
unset(findgmock_gmock_lib)
|
||||
unset(findgmock_gmock_main_lib)
|
||||
|
||||
endif()
|
||||
|
||||
set(GTEST_BOTH_LIBRARIES ${GTEST_LIBRARIES} ${GTEST_MAIN_LIBRARIES})
|
@ -1,3 +0,0 @@
|
||||
[NetDev]
|
||||
Name=anbox0
|
||||
Kind=bridge
|
@ -1,7 +0,0 @@
|
||||
[Match]
|
||||
Name=anbox0
|
||||
Driver=bridge
|
||||
|
||||
[Network]
|
||||
Address=192.168.250.1/24
|
||||
IPMasquerade=yes
|
@ -1,46 +0,0 @@
|
||||
#!/sbin/openrc-run
|
||||
|
||||
supervisor=supervise-daemon
|
||||
|
||||
name="Anbox container manager"
|
||||
ANDROID_IMAGE="${ANDROID_IMAGE:-"/usr/share/andbox/android.img"}"
|
||||
DATA_PATH="${DATA_PATH:-"/var/lib/anbox"}"
|
||||
command=/usr/bin/anbox
|
||||
command_args="container-manager --daemon --privileged --data-path=${DATA_PATH} --android-image=${ANDROID_IMAGE}"
|
||||
|
||||
depend() {
|
||||
need localmount sysfs cgroups fuse
|
||||
use net
|
||||
after firewall
|
||||
}
|
||||
|
||||
start_pre() {
|
||||
# that's all you need to avoid the lxc dependency
|
||||
checkpath --directory /usr/lib/lxc
|
||||
checkpath --directory /usr/lib/lxc/rootfs
|
||||
|
||||
modprobe loop
|
||||
modprobe tun
|
||||
modprobe binder_linux
|
||||
|
||||
if ! [[ -d /dev/binderfs ]] && grep -vq "binder on /dev/binderfs"; then
|
||||
mkdir /dev/binderfs
|
||||
mount -t binder binder /dev/binderfs
|
||||
fi
|
||||
|
||||
if ip link show anbox0 >/dev/null 2>&1; then
|
||||
ewarn "anbox0 network interface already exists"
|
||||
else
|
||||
ebegin "Creating anbox0 network interface"
|
||||
/usr/share/anbox/anbox-bridge.sh start
|
||||
eend $?
|
||||
fi
|
||||
}
|
||||
|
||||
stop_post() {
|
||||
if ip link show anbox0 >/dev/null 2>&1; then
|
||||
ebegin "Removing anbox0 network interface"
|
||||
/usr/share/anbox/anbox-bridge.sh stop
|
||||
eend $?
|
||||
fi
|
||||
}
|
@ -1,4 +0,0 @@
|
||||
# /etc/conf.d/anbox-container-manager: config file for /etc/init.d/anbox-container-manager
|
||||
|
||||
DATA_PATH="/var/lib/anbox"
|
||||
ANDROID_IMAGE="/usr/share/anbox/android.img"
|
@ -1,43 +0,0 @@
|
||||
#!/sbin/openrc-run
|
||||
|
||||
supervisor=supervise-daemon
|
||||
|
||||
name="Anbox container manager"
|
||||
command=/usr/bin/anbox
|
||||
command_args="container-manager --daemon --privileged --data-path=/var/lib/anbox --android-image=/usr/share/anbox/android.img"
|
||||
|
||||
depend() {
|
||||
need localmount sysfs cgroups fuse
|
||||
use net
|
||||
after firewall
|
||||
}
|
||||
|
||||
start_pre() {
|
||||
# that's all you need to avoid the lxc dependency
|
||||
checkpath --directory /usr/lib/lxc
|
||||
checkpath --directory /usr/lib/lxc/rootfs
|
||||
|
||||
modprobe loop
|
||||
modprobe tun
|
||||
|
||||
if ! [[ -d /dev/binderfs ]]; then
|
||||
mkdir /dev/binderfs
|
||||
mount -t binder binder /dev/binderfs
|
||||
fi
|
||||
|
||||
if ip link show anbox0 >/dev/null 2>&1; then
|
||||
ewarn "anbox0 network interface already exists"
|
||||
else
|
||||
ebegin "Creating anbox0 network interface"
|
||||
/usr/share/anbox/anbox-bridge.sh start
|
||||
eend $?
|
||||
fi
|
||||
}
|
||||
|
||||
stop_post() {
|
||||
if ip link show anbox0 >/dev/null 2>&1; then
|
||||
ebegin "Removing anbox0 network interface"
|
||||
/usr/share/anbox/anbox-bridge.sh stop
|
||||
eend $?
|
||||
fi
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
[Unit]
|
||||
Description=Anbox Container Manager
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/anbox container-manager --daemon --privileged --data-path=/var/lib/anbox
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
@ -1,23 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# https://gitlab.com/postmarketOS/pmaports/-/issues/479
|
||||
# EGL_PLATFORM=wayland is broken on desktop as
|
||||
# Anbox require PBuffer support but Wayland EGL
|
||||
# doesn't provide it. Unsetting this value
|
||||
# unbreaks Anbox on e.g. Plasma Mobile.
|
||||
if [ "$EGL_PLATFORM" = wayland ]; then
|
||||
export EGL_PLATFORM
|
||||
unset EGL_PLATFORM
|
||||
fi
|
||||
|
||||
# This breaks Anbox display if EGL_PLATFORM is not
|
||||
# set to wayland. Since EGL_PLATFORM is never set
|
||||
# to wayland, let's unset SDL_VIDEODRIVER if it is.
|
||||
if [ "$SDL_VIDEODRIVER" = wayland ]; then
|
||||
export SDL_VIDEODRIVER
|
||||
unset SDL_VIDEODRIVER
|
||||
fi
|
||||
|
||||
# We let Anbox autostart the session manager as this
|
||||
# provides a splash-screen
|
||||
anbox launch --package=org.anbox.appmgr --component=org.anbox.appmgr.AppViewActivity
|
@ -1,8 +0,0 @@
|
||||
[Unit]
|
||||
Description=Anbox Session Manager
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/anbox session-manager
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
@ -1,8 +0,0 @@
|
||||
# Sample conf.d file for alpine linux
|
||||
|
||||
#
|
||||
# Specify daemon options here.
|
||||
#
|
||||
|
||||
sample_opts=""
|
||||
sample_user=""
|
@ -1,16 +0,0 @@
|
||||
https://github.com/anbox/anbox/pull/1827
|
||||
--- a/src/anbox/container/lxc_container.cpp
|
||||
+++ b/src/anbox/container/lxc_container.cpp
|
||||
@@ -343,8 +343,10 @@ void LxcContainer::start(const Configuration &configuration) {
|
||||
set_config_item(lxc_config_tty_max_key, "0");
|
||||
set_config_item(lxc_config_uts_name_key, "anbox");
|
||||
|
||||
- set_config_item("lxc.group.devices.deny", "");
|
||||
- set_config_item("lxc.group.devices.allow", "");
|
||||
+ set_config_item("lxc.cgroup.devices.deny", "");
|
||||
+ set_config_item("lxc.cgroup.devices.allow", "");
|
||||
+ set_config_item("lxc.cgroup2.devices.deny", "");
|
||||
+ set_config_item("lxc.cgroup2.devices.allow", "");
|
||||
|
||||
// We can't move bind-mounts, so don't use /dev/lxc/
|
||||
set_config_item(lxc_config_tty_dir_key, "");
|
@ -1,50 +0,0 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 713df49..1e8b462 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -59,6 +59,7 @@ set(CMAKE_INCLUDE_CURRENT_DIR ON)
|
||||
find_package(Boost COMPONENTS filesystem log serialization system thread program_options)
|
||||
find_package(PkgConfig)
|
||||
find_package(Threads)
|
||||
+find_package(SDBus-C++ REQUIRED)
|
||||
find_package(EGL REQUIRED)
|
||||
find_package(GLESv2 REQUIRED)
|
||||
find_package(Protobuf REQUIRED)
|
||||
diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt
|
||||
index f677aa0..265a2eb 100644
|
||||
--- a/external/CMakeLists.txt
|
||||
+++ b/external/CMakeLists.txt
|
||||
@@ -6,12 +6,3 @@ add_subdirectory(backward-cpp)
|
||||
set(BUILD_TESTING OFF)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-error")
|
||||
add_subdirectory(cpu_features EXCLUDE_FROM_ALL)
|
||||
-include(ExternalProject)
|
||||
-ExternalProject_Add(sdbus-cpp
|
||||
- PREFIX sdbus-cpp
|
||||
- SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/sdbus-cpp"
|
||||
- INSTALL_COMMAND ""
|
||||
- CMAKE_CACHE_ARGS
|
||||
- -DBUILD_CODE_GEN:BOOL=ON
|
||||
- -DBUILD_SHARED_LIBS:BOOL=OFF
|
||||
-)
|
||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
||||
index 796b881..a19da1b 100644
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -26,7 +26,6 @@ include_directories(
|
||||
${CMAKE_SOURCE_DIR}/external/android-emugl/host/libs/renderControl_dec
|
||||
${CMAKE_BINARY_DIR}/external/android-emugl/host/libs/renderControl_dec
|
||||
${CMAKE_SOURCE_DIR}/external/cpu_features/include
|
||||
- ${CMAKE_SOURCE_DIR}/external/sdbus-cpp/include
|
||||
)
|
||||
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DBINDERFS_PATH=\"\\\"${BINDERFS_PATH}\\\"\"")
|
||||
@@ -59,7 +58,7 @@ add_library(anbox-protobuf
|
||||
target_link_libraries(anbox-protobuf
|
||||
${PROTOBUF_LITE_LIBRARIES})
|
||||
|
||||
-set(XML2CPP ${CMAKE_BINARY_DIR}/external/sdbus-cpp/src/sdbus-cpp-build/tools/sdbus-c++-xml2cpp)
|
||||
+set(XML2CPP sdbus-c++-xml2cpp)
|
||||
|
||||
macro(DBusServer BaseName)
|
||||
add_custom_command(
|
@ -1,38 +0,0 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 713df49..8ef4633 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -68,7 +68,6 @@ pkg_check_modules(SDL2_IMAGE SDL2_image REQUIRED)
|
||||
pkg_check_modules(DBUS dbus-1 REQUIRED)
|
||||
pkg_check_modules(LXC lxc REQUIRED)
|
||||
pkg_check_modules(PROPERTIES_CPP properties-cpp REQUIRED)
|
||||
-pkg_check_modules(LIBSYSTEMD libsystemd REQUIRED)
|
||||
pkg_check_modules(LIBCAP libcap REQUIRED)
|
||||
|
||||
message(STATUS "LXC version: ${LXC_VERSION}")
|
||||
diff --git a/src/anbox/cmds/launch.h b/src/anbox/cmds/launch.h
|
||||
index 5238982..2d388f5 100644
|
||||
--- a/src/anbox/cmds/launch.h
|
||||
+++ b/src/anbox/cmds/launch.h
|
||||
@@ -21,7 +21,7 @@
|
||||
#include <functional>
|
||||
#include <iostream>
|
||||
#include <memory>
|
||||
-#include <systemd/sd-bus.h>
|
||||
+#include <elogind/systemd/sd-bus.h>
|
||||
|
||||
#include "anbox/android/intent.h"
|
||||
#include "anbox/wm/stack.h"
|
||||
diff --git a/src/anbox/dbus/bus.h b/src/anbox/dbus/bus.h
|
||||
index 40b3d94..e798b4b 100644
|
||||
--- a/src/anbox/dbus/bus.h
|
||||
+++ b/src/anbox/dbus/bus.h
|
||||
@@ -25,7 +25,7 @@
|
||||
#include <mutex>
|
||||
#include <thread>
|
||||
|
||||
-#include <systemd/sd-bus.h>
|
||||
+#include <elogind/systemd/sd-bus.h>
|
||||
|
||||
namespace anbox::dbus {
|
||||
class Bus : public DoNotCopyOrMove {
|
@ -1,11 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer type="person">
|
||||
<email>parona@protonmail.com</email>
|
||||
<name>Alfred Wingate</name>
|
||||
</maintainer>
|
||||
<upstream>
|
||||
<remote-id type="github">anbox/anbox</remote-id>
|
||||
</upstream>
|
||||
</pkgmetadata>
|
@ -2,11 +2,6 @@
|
||||
# Uses php-7 which has been removed from tree
|
||||
www-apps/icecoder
|
||||
|
||||
# Alfred Wingate <parona@protonmail.com> (2023-09-07)
|
||||
# Deprecated.
|
||||
# https://github.com/anbox/anbox#important---hi-there-
|
||||
app-emulation/anbox
|
||||
|
||||
# Alfred Wingate <parona@protonmail.com> (2023-08-31)
|
||||
# Indiscriminate mask of packages with NonsolvableDepsInStable
|
||||
# Fix or remove
|
||||
|
Loading…
Reference in New Issue
Block a user