Cant install Anbox-git

I’ve been trying to install anbox. Im on a kernel that works with the dkms pakages. I’ve been installling it through the software gui. cmake cant make it heres the cmake error log

Change Dir: /var/tmp/pamac-build-roluxio767/anbox-git/src/anbox/build/CMakeFiles/CMakeTmp

Run Build Command(s):/usr/bin/make cmTC_3f26d/fast && /usr/bin/make  -f CMakeFiles/cmTC_3f26d.dir/build.make CMakeFiles/cmTC_3f26d.dir/build
make[1]: Entering directory '/var/tmp/pamac-build-roluxio767/anbox-git/src/anbox/build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_3f26d.dir/src.c.o
/usr/bin/cc   -D_FORTIFY_SOURCE=2 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt -Wall -pedantic -Wno-error=pedantic -Wno-variadic-macros -Wextra -fPIC -pedantic -Wno-error=pedantic -Wall -Wextra -Wcast-align -Wcast-qual -Wformat -Wredundant-decls -Wswitch-default -Werror -Wno-error=deprecated-declarations -DCMAKE_HAVE_LIBC_PTHREAD -o CMakeFiles/cmTC_3f26d.dir/src.c.o -c /var/tmp/pamac-build-roluxio767/anbox-git/src/anbox/build/CMakeFiles/CMakeTmp/src.c
Linking C executable cmTC_3f26d
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_3f26d.dir/link.txt --verbose=1
/usr/bin/cc -D_FORTIFY_SOURCE=2 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt -Wall -pedantic -Wno-error=pedantic -Wno-variadic-macros -Wextra -fPIC -pedantic -Wno-error=pedantic -Wall -Wextra -Wcast-align -Wcast-qual -Wformat -Wredundant-decls -Wswitch-default -Werror -Wno-error=deprecated-declarations -DCMAKE_HAVE_LIBC_PTHREAD -Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now  -rdynamic CMakeFiles/cmTC_3f26d.dir/src.c.o -o cmTC_3f26d 
/usr/bin/ld: CMakeFiles/cmTC_3f26d.dir/src.c.o: in function `main':
src.c:(.text.startup+0x24): undefined reference to `pthread_create'
/usr/bin/ld: src.c:(.text.startup+0x2e): undefined reference to `pthread_detach'
/usr/bin/ld: src.c:(.text.startup+0x38): undefined reference to `pthread_cancel'
/usr/bin/ld: src.c:(.text.startup+0x44): undefined reference to `pthread_join'
collect2: error: ld returned 1 exit status
make[1]: *** [CMakeFiles/cmTC_3f26d.dir/build.make:106: cmTC_3f26d] Error 1
make[1]: Leaving directory '/var/tmp/pamac-build-roluxio767/anbox-git/src/anbox/build/CMakeFiles/CMakeTmp'
make: *** [Makefile:140: cmTC_3f26d/fast] Error 2


Source file was:
#include <pthread.h>

void* test_func(void* data)
{
  return data;
}

int main(void)
{
  pthread_t thread;
  pthread_create(&thread, NULL, test_func, NULL);
  pthread_detach(thread);
  pthread_cancel(thread);
  pthread_join(thread, NULL);
  pthread_atfork(NULL, NULL, NULL);
  pthread_exit(NULL);

  return 0;
}

Determining if the function pthread_create exists in the pthreads failed with the following output:
Change Dir: /var/tmp/pamac-build-roluxio767/anbox-git/src/anbox/build/CMakeFiles/CMakeTmp

Run Build Command(s):/usr/bin/make cmTC_a49f4/fast && /usr/bin/make  -f CMakeFiles/cmTC_a49f4.dir/build.make CMakeFiles/cmTC_a49f4.dir/build
make[1]: Entering directory '/var/tmp/pamac-build-roluxio767/anbox-git/src/anbox/build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_a49f4.dir/CheckFunctionExists.c.o
/usr/bin/cc   -D_FORTIFY_SOURCE=2 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt -Wall -pedantic -Wno-error=pedantic -Wno-variadic-macros -Wextra -fPIC -pedantic -Wno-error=pedantic -Wall -Wextra -Wcast-align -Wcast-qual -Wformat -Wredundant-decls -Wswitch-default -Werror -Wno-error=deprecated-declarations -DCHECK_FUNCTION_EXISTS=pthread_create -o CMakeFiles/cmTC_a49f4.dir/CheckFunctionExists.c.o -c /usr/share/cmake-3.18/Modules/CheckFunctionExists.c
Linking C executable cmTC_a49f4
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_a49f4.dir/link.txt --verbose=1
/usr/bin/cc -D_FORTIFY_SOURCE=2 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt -Wall -pedantic -Wno-error=pedantic -Wno-variadic-macros -Wextra -fPIC -pedantic -Wno-error=pedantic -Wall -Wextra -Wcast-align -Wcast-qual -Wformat -Wredundant-decls -Wswitch-default -Werror -Wno-error=deprecated-declarations -DCHECK_FUNCTION_EXISTS=pthread_create -Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now  -rdynamic CMakeFiles/cmTC_a49f4.dir/CheckFunctionExists.c.o -o cmTC_a49f4  -lpthreads 
/usr/bin/ld: cannot find -lpthreads
collect2: error: ld returned 1 exit status
make[1]: *** [CMakeFiles/cmTC_a49f4.dir/build.make:106: cmTC_a49f4] Error 1
make[1]: Leaving directory '/var/tmp/pamac-build-roluxio767/anbox-git/src/anbox/build/CMakeFiles/CMakeTmp'
make: *** [Makefile:140: cmTC_a49f4/fast] Error 2 `````

Please surround your output with the </> button, ```, or <code>. It’s very difficult to read as it is.

Will do

FYI, 5.7.19-2 (Last release, now EOL) & 5.8.5-2 in the unstable branch have support for the Anbox kernel modules. You can thank @nightmare-2021.

1 Like