[strongSwan] Vstr shared library build failure on ICS for Strongswan

mrunal upadhyay mrunalu1 at gmail.com
Thu May 3 00:25:02 CEST 2012


Dear Experts,

Sorry for unnecessary flooding of the same message.

Based on the steps mentioned at the below link, I started with Vstr
library building on the ICS workspace.

http://wiki.strongswan.org/projects/strongswan/wiki/Android

1. Downloaded and extracted droid-gcc
tmurakam-droid-wrapper-v1.0.4-5-g04eb4dc package 2. Ran make install.
( It installed the necessary droid-gcc and droid-ld in /usr/local/bin
directory) 3. Downloaded and extracted the vstr-1.0.15.tar.bz2 package
from download.strongswan.org site.
4. Changed the DROID_ROOT and optionally DROID_TARGET and INSTALLDIR
path locations appropriately in vstr.build 5. Ran the below steps:
	cd vstr-1.0.15
	patch -p1 < ../vstr.patch
	. ../vstr.build
6. I could see the libvstr.a, include files and Android.mk files
getting created in the android/external/strongswan-support directory.
7. However, I am not able to make the libvstr module. I get the
following error  when I try to make libvstr module as a shared
library:


Build Error Snippet:
--------------------------

Commands:
source build/envsetup.sh
lunch "product_name"
make libvstr

Output:

target Prebuilt: libvstr-static
(out/target/product/product/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a)
target SharedLib: libvstr
(out/target/product/product/obj/SHARED_LIBRARIES/libvstr_intermediates/LINKED/libvstr.so)
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(assert_loop.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(fix.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_add.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_add_fmt.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_add_netstr.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_cache.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_cmp.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_cntl.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_conv.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_cstr.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_data.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_del.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_dup.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_export.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_fmt.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_inline.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_mov.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_parse.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_parse_netstr.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_ref.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_sc.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_sc_posix.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_sect.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_spn.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_split.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_srch.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_srch_case.o):
incompatible target
prebuilt/linux-x86/toolchain/arm-linux-androideabi-4.4.x/bin/../lib/gcc/arm-linux-androideabi/4.4.3/../../../../arm-linux-androideabi/bin/ld:
error: out/target/product/ics/obj/STATIC_LIBRARIES/libvstr-static_intermediates/libvstr-static.a(vstr_sub.o):
incompatible target
collect2: ld returned 1 exit status
make: *** [out/target/product/ics/obj/SHARED_LIBRARIES/libvstr_intermediates/LINKED/libvstr.so]
Error 1

It would be great if anyone has come across this error and can help in
tackling this build error problem where as mentioned in the Makefile,
we are trying to create a Shared Library from the Static Library
libvstr.a

Once the above build error is resolved, I will check on building the
strongswan source in android/external/strongswan-4.6.2 directory.


-- 
Cheers,
Mrunal




More information about the Users mailing list