3 echo "Generating device properties"
4 rm -f generate
-props.sh
5 wget https
://github.com
/Anbox
-halium/anbox
-halium/raw
/lineage
-17.1
/scripts
/generate
-props.sh
6 chmod +x generate
-props.sh
9 echo "Asking for root access"
16 # remove LD_LIBRARY_PATH from /etc/environment to make life easier
17 if ! grep -q "#LD_LIBRARY_PATH" /etc/environment; then
18 sed -i -e "s/^LD_LIBRARY_PATH/#LD_LIBRARY_PATH/" /etc/environment
21 echo "Installing packages"
23 apt install -y qtwayland5 qml-module-qtwayland-compositor
24 rm anbox-sensors_0.1.0_arm64.deb
25 wget https://github.com/Anbox-halium/anbox-sensors/releases/download/v0.1.0/anbox-sensors_0.1.0_arm64.deb
26 dpkg -i anbox-sensors_0.1.0_arm64.deb
28 echo "Geting anbox images"
29 if [ -f anbox_arm64_system.img ]; then
30 mv anbox_arm64_system.img anbox_arm64_system.img.bak
31 mv anbox_arm64_vendor.img anbox_arm64_vendor.img.bak
33 rm -f latest-raw-images.zip
34 wget https://build.lolinet.com/file/lineage/anbox_arm64/latest-raw-images.zip
35 unzip latest-raw-images.zip
37 echo "Geting latest runner script"
38 rm -f run-container.sh
39 wget https://github.com/Anbox-halium/anbox-halium/raw/lineage-17.1/scripts/run-container.sh
40 chmod +x run-container.sh
41 rm -f stop-container.sh
42 wget https://github.com/Anbox-halium/anbox-halium/raw/lineage-17.1/scripts/stop-container.sh
43 chmod +x stop-container.sh
45 if [ -f anbox.prop ]; then
46 mv anbox.prop anbox.prop.bak
48 if grep -q "anbox.display_height" anbox.prop.bak; then
49 grep "anbox.display_height" anbox.prop.bak >> anbox.prop
51 echo "NOTE: Edit /home/anbox/anbox.prop based on your device screen resolution"
52 echo "anbox.display_height=1920" >> anbox.prop
54 if grep -q "anbox.display_width" anbox.prop.bak; then
55 grep "anbox.display_width" anbox.prop.bak >> anbox.prop
57 echo "NOTE: Edit /home/anbox/anbox.prop based on your device screen resolution"
58 echo "anbox.display_width=1080" >> anbox.prop
60 echo "${GRALLOC_PROP}" >> anbox.prop
61 echo "${EGL_PROP}" >> anbox.prop
62 echo "${MEDIA_PROFILES_PROP}" >> anbox.prop
63 echo "${CCODEC_PROP}" >> anbox.prop
64 echo "${EXT_LIB_PROP}" >> anbox.prop
65 echo "${VULKAN_PROP}" >> anbox.prop
66 echo "${DPI_PROP}" >> anbox.prop
67 echo "${GLES_VER_PROP}" >> anbox.prop
68 echo "${XDG_PROP}" >> anbox.prop
69 echo "${WAYLAND_DISP_PROP}" >> anbox.prop
70 echo "${PULSE_PROP}" >> anbox.prop
72 echo "Geting latest lxc config"
73 mkdir /var/lib/lxc/anbox
76 wget https://github.com/Anbox-halium/anbox-halium/raw/lineage-17.1/lxc-configs/config
78 if ! grep -q "module-native-protocol-unix auth-anonymous=1" /etc/pulse/touch-android9.pa; then
79 echo "Pulseaudio config patching"
80 sed -i "s/module-native-protocol-unix/module-native-protocol-unix auth-anonymous=1/" /etc/pulse/touch-android9.pa
83 if [ ! -f /etc/gbinder.d/anbox.conf ]; then
84 echo "Adding gbinder config"
87 wget https://github.com/Anbox-halium/anbox-halium/raw/lineage-17.1/gbinder/anbox.conf
92 echo "Going back to phablet user"
96 echo "Installing anbox launcher"
97 rm anbox.rudiimmer_1.0_all.click
98 wget https
://build.lolinet.com
/file
/lineage
/anbox_arm
64/anbox.rudiimmer_1.0_all.click
99 pkcon
install-local anbox.rudiimmer_1.0_all.click
--allow-untrusted
101 echo "Restarting Pulseaudio service"
102 initctl
--user stop pulseaudio
103 initctl
--user start pulseaudio
105 echo "Installing Finished!"
106 echo "Run anbox container with \"sudo /home/anbox/run-container.sh\" on terminal"
107 echo "Stop anbox container with \"sudo /home/anbox/stop-container.sh\" on terminal"