can not compile shadowsocks/badvpn fork


#1

I want to build this repo for android devices

I follow the guide in


And execute following commands

cmake .. -DBUILD_NOTHING_BY_DEFAULT=1 -DBUILD_TUN2SOCKS=1 -DCMAKE_SYSTEM_NAME=Android
make install

I used CMAKE_SYSTEM_NAME flag for targeting android devices as mentioned in cmake documents
https://cmake.org/cmake/help/latest/manual/cmake-toolchains.7.html#cross-compiling-for-android

I am using NDK Revision 18b (January 2019) downloaded from:
https://developer.android.com/ndk/downloads/older_releases.html

after run make install I got these errors:

[ 42%] Building C object system/CMakeFiles/system.dir/BSignal.c.o
In file included from /home/smart/Downloads/badvpn/system/BSignal.c:34:
/home/smart/Downloads/badvpn/system/BUnixSignal.h:38:2: error: Unknown signal
      backend or too many signal backends
#error Unknown signal backend or too many signal backends
 ^
In file included from /home/smart/Downloads/badvpn/system/BSignal.c:34:
In file included from /home/smart/Downloads/badvpn/system/BUnixSignal.h:45:
In file included from /home/smart/Downloads/badvpn/system/BReactor.h:6:
/home/smart/Downloads/badvpn/system/BReactor_badvpn.h:39:2: error: Unknown event
      backend or too many event backends
#error Unknown event backend or too many event backends
 ^
2 errors generated.
make[2]: *** [system/CMakeFiles/system.dir/build.make:76: system/CMakeFiles/system.dir/BSignal.c.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:147: system/CMakeFiles/system.dir/all] Error 2
make: *** [Makefile:130: all] Error 2

the error is:

Unknown event backend or too many event backends


#2

Take a look at shadowsocks-android for example.