I'm trying to make an application similar to ics-openconnect. As you know it is based on openconnect, so I first tried to compile it for Android, and here are the problems that I faced:
First, the NDK path and version in the Makefile
varies from mine, so I change it to my android-ndk-r25c
. Then I try to make the file and I get the following error:
/path/to/ndk/android-ndk-r25c/build/tools/make-standalone-toolchain.sh: not found
which is true. In the previous versions of ndk this file existed(I tested it with ndk 16), but in version 25, there is just make_standalone_toolchain.py
file. So in the Makefile
I change line 83 :
$(TOOLCHAIN_BUILT):
$(NDK)/build/tools/make-standalone-toolchain.sh $(TOOLCHAIN_OPTS) || \
$(NDK)/build/tools/make-standalone-toolchain.sh \
$(TOOLCHAIN_OPTS) --system=linux-x86_64
touch $@
to this:
$(TOOLCHAIN_BUILT):
python $(NDK)/build/tools/make_standalone_toolchain.py $(TOOLCHAIN_OPTS) || \
python $(NDK)/build/tools/make_standalone_toolchain.py \
$(TOOLCHAIN_OPTS) --system=linux-x86_64
touch $@
And also made some changes to download and check the hash of these libraries with these versions:
libxml2-2.11.4
gmp-6.2.1
nettle-3.9
gnutls-3.7.9
stoken-0.92
oath-toolkit-2.6.7
lz4-1.9.4
Then I make the application but I get this error:
configure: WARNING: *** LIBIDN2 was not found. You will not be able to use IDN2008 support
checking for nettle_get_secp_192r1 in -lhogweed... no
checking for nettle_rsa_sec_decrypt... no
configure: error: Nettle lacks the required rsa_sec_decrypt function
make: *** [Makefile:231: arm-linux-androideabi/gnutls/Makefile] Error 1