linker - Linking failing for PCRE when using Android NDK stand-alone toolchain -



linker - Linking failing for PCRE when using Android NDK stand-alone toolchain -

people have been able build pcre (or subset of) copying source files , creating appropriate andriod.mk. want similar, using android stand-alone toolchain , using configure , create process. have had success building other useful libraries using same flow, running issue pcre. specifically, late in create flow getting error:

undefined reference to__dso_handle' .libs/pcre_stringpiece.o

when doing this,

/bin/bash ./libtool --tag=cxx --mode=link arm-linux-androideabi-g++ -o2 -version-info 0:0:0 -o libpcrecpp.la -rpath /usr/local/lib pcrecpp.lo pcre_scanner.lo pcre_stringpiece.lo libpcre.la libtool: link: arm-linux-androideabi-g++ -fpic -dpic -shared -nostdlib .libs/pcrecpp.o .libs/pcre_scanner.o .libs/pcre_stringpiece.o -wl,-rpath -wl,/home/corbin/applications/pcre-8.21/.libs ./.libs/libpcre.so -l/home/corbin/my-android-toolchain-mod/bin/../lib/gcc/arm-linux-androideabi/4.7.0 -l/home/corbin/my-android-toolchain-mod/bin/../lib/gcc -l/home/corbin/my-android-toolchain-mod/bin/../lib/gcc/arm-linux-androideabi/4.7.0/../../../../arm-linux-androideabi/lib -l/home/corbin/my-android-toolchain-mod/bin/../sysroot/usr/lib -lstdc++ -lm -lc -ldl -lgcc -o2 -wl,-soname -wl,libpcrecpp.so.0 -o .libs/libpcrecpp.so.0.0.0 .libs/pcrecpp.o: in function `_global__sub_i_pcrecpp.cc': pcrecpp.cc:(.text.startup+0x94): undefined reference `__dso_handle' .libs/pcre_stringpiece.o: in function `_global__sub_i_pcre_stringpiece.cc': pcre_stringpiece.cc:(.text.startup+0x40): undefined reference `__dso_handle' collect2: error: ld returned 1 exit status make[1]: *** [libpcrecpp.la] error 1 make[1]: leaving directory `/home/corbin/applications/pcre-8.21'

any thoughts on problem , solution is? read various things similar problems, unhelpful or wasn't clear if related same problem.

update 1: have found problem not occur when utilize default stand-alone toolchain. happens when utilize modified 1 described here: http://specificimpulses.blogspot.com/2011/10/android-fortran-step-by-step-part-2.html need utilize 1 building other libraries include fortran (and have done so) , want utilize same toolchain builds. so, need rebuild toolchain different options?

looks -fno-use-cxa-atexit acceptable workaround.

android linker android-ndk

Comments

Popular posts from this blog

How do I check if an insert was successful with MySQLdb in Python? -

delphi - blogger via idHTTP : error 400 bad request -

postgresql - ERROR: operator is not unique: unknown + unknown -