anbox / anbox-modules

Anbox kernel modules
327 stars 224 forks source link

Help for 20.04 #83

Open Kushagra-Srivastava opened 3 years ago

Kushagra-Srivastava commented 3 years ago

Is there just any way i can use anbox on 20.04? When I run sudo apt-get install dkms i get this error

sudo apt install dkms

Reading package lists... Done
Building dependency tree       
Reading state information... Done
dkms is already the newest version (2.8.1-5ubuntu2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up anbox-modules-dkms (13) ...
Removing old anbox-1 DKMS files...

------------------------------
Deleting module version: 1
completely from the DKMS tree.
------------------------------
Done.
Loading new anbox-1 DKMS files...
Building for 5.11.0-27-generic
Building initial module for 5.11.0-27-generic
ERROR: Cannot create report: [Errno 17] File exists: '/var/crash/anbox-modules-d
kms.0.crash'
Error! Bad return status for module build on kernel: 5.11.0-27-generic (x86_64)
Consult /var/lib/dkms/anbox/1/build/make.log for more information.
dpkg: error processing package anbox-modules-dkms (--configure):
 installed anbox-modules-dkms package post-installation script subprocess return
ed error exit status 10
Errors were encountered while processing:
 anbox-modules-dkms
E: Sub-process /usr/bin/dpkg returned an error code (1)

when i run sudo apt install linux-headers-generic anbox-modules-dkms , it give me this error

sudo apt install linux-headers-generic anbox-modules-dkms
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package anbox-modules-dkms is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'anbox-modules-dkms' has no installation candidate

And when i run ls -1 /dev/{ashmem,binder} It gives me this--

ls -1 /dev/{ashmem,binder}
ls: cannot access '/dev/binder': No such file or directory
**/dev/ashmem**

And whin i run this--sudo add-apt-repository ppa:morphis/anbox-support it give me this--

Reading package lists... Done
E: The repository 'http://ppa.launchpad.net/morphis/anbox-support/ubuntu focal Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

and by running snap info anbox it gives this--

snap info anbox
name:      anbox
summary:   Android in a Box
publisher: Simon Fels (morphis)
store-url: https://snapcraft.io/anbox
contact:   https://anbox.io
license:   unset
description: |
  Runtime for Android applications which runs a full Android system
  in a container using Linux namespaces (user, ipc, net, mount) to
  separate the Android system fully from the host.

  You can find further details in our documentation at
  https://github.com/anbox/anbox/blob/master/README.md
commands:
  - anbox
  - anbox.android-settings
  - anbox.appmgr
  - anbox.collect-bug-info
  - anbox.shell
services:
  anbox.container-manager: simple, enabled, active
snap-id:      Nr9K6UJaIOD8wHpDEQl16nabFFt9LLEQ
tracking:     latest/beta
refresh-date: today at 15:58 IST
channels:
  latest/stable:    --                                   
  latest/candidate: --                                   
  latest/beta:      4-56c25f1     2020-01-02 (186) 391MB devmode
  latest/edge:      4+gitrad377ff 2021-05-27 (213) 405MB devmode
installed:          4-56c25f1                (186) 391MB devmode
goisneto commented 2 years ago

try this -> https://github.com/anbox/anbox-modules/issues/84#issuecomment-953320510

SoulInfernoDE commented 2 years ago

Do not try to compile the modules for newer kernels as it is not possible anymore. Instead you need to compile THE KERNEL itself with the modules options enabled in the config file as the modules had been migrated to the newer kernels but some code had been removed that prevents you from building/using the modules standalone for security reasons.

You can look at my tutorial/notice i wrote down to address the issue for myself or use my precompiled kernels (with the android config options pre-enabled) if you are using a ubuntu distribution. https://github.com/anbox/anbox-modules/issues/75#issuecomment-794079944