You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-user@axis.apache.org by Erik Sallmann - iNTENCE automotive electronics <e....@intence.de> on 2010/09/07 10:07:29 UTC

Cross Compiling Axis2 for ARM

Hi,

when I try to cross compile Axis2/c for arm7 (IGEPv2 Plattform) with the angstrom sdk (which seems to be a OE generated toolchain) I get this:


make[4]: Leaving directory `/home/jdoe/axis2c-src-1.6.0/neethi/src'
Making all in test
make[4]: Entering directory `/home/jdoe/axis2c-src-1.6.0/neethi/test'
arm-none-linux-gnueabi-gcc -DHAVE_CONFIG_H -I. -I.. -I../include -I ../../util/include -I ../../axiom/include -I ../../include   -g -O2 -pthread -g -O2 -D_LARGEFILE64_SOURCE -ansi -Wall -Werror -Wno-implicit-function-declaration  -MT test.o -MD -MP -MF .deps/test.Tpo -c -o test.o test.c
mv -f .deps/test.Tpo .deps/test.Po
/bin/sh ../libtool --tag=CC   --mode=link arm-none-linux-gnueabi-gcc -g -O2 -pthread -g -O2 -D_LARGEFILE64_SOURCE -ansi -Wall -Werror -Wno-implicit-function-declaration   -lpthread -o test test.o ../src/libneethi.la ../../axiom/src/om/libaxis2_axiom.la ../../util/src/libaxutil.la ../src/libneethi.la -ldl
mkdir .libs
arm-none-linux-gnueabi-gcc -g -O2 -pthread -g -O2 -D_LARGEFILE64_SOURCE -ansi -Wall -Werror -Wno-implicit-function-declaration -o .libs/test test.o  -lpthread ../../axiom/src/om/.libs/libaxis2_axiom.so ../../util/src/.libs/libaxutil.so ../src/.libs/libneethi.so -ldl  -Wl,--rpath -Wl,/usr/local/axis2c/lib
/usr/local/poky/eabi-glibc/arm/lib/gcc/arm-none-linux-gnueabi/4.3.2/../../../../arm-none-linux-gnueabi/bin/ld: warning: libaxis2_parser.so.0, needed by ../../axiom/src/om/.libs/libaxis2_axiom.so, not found (try using -rpath or -rpath-link)
test.o: In function `load_policy_array':
/home/jdoe/axis2c-src-1.6.0/neethi/test/test.c:185: undefined reference to `axiom_xml_reader_create_for_file'
/home/jdoe/axis2c-src-1.6.0/neethi/test/test.c:198: undefined reference to `axiom_xml_reader_free'
test.o: In function `om_node_serialize':
/home/jdoe/axis2c-src-1.6.0/neethi/test/test.c:143: undefined reference to `axiom_xml_writer_create_for_memory'
/home/jdoe/axis2c-src-1.6.0/neethi/test/test.c:158: undefined reference to `axiom_xml_writer_get_xml'
test.o: In function `main':
/home/jdoe/axis2c-src-1.6.0/neethi/test/test.c:32: undefined reference to `axiom_xml_reader_create_for_file'
/home/jdoe/axis2c-src-1.6.0/neethi/test/test.c:45: undefined reference to `axiom_xml_reader_free'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_attribute_prefix_by_number'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_value'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_attribute_count'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_raw'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_attribute_with_namespace'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_attribute_with_namespace_prefix'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_dtd'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_processing_instruction'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_attribute_namespace_by_number'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_namespace_prefix_by_number'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_namespace'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_empty_element'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_comment'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_attribute_value_by_number'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_end_element'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_next'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_attribute_name_by_number'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_start_document_with_version_encoding'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_start_element_with_namespace'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_processing_instruction_data'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_pi_data'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_pi_target'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_dtd'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_create_for_memory'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_attribute'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_namespace_count'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_start_element_with_namespace_prefix'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_start_element'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_xml_free'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_empty_element_with_namespace_prefix'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_namespace_uri_by_number'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_prefix'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_set_prefix'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_characters'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_reader_get_name'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_write_empty_element_with_namespace'
../../axiom/src/om/.libs/libaxis2_axiom.so: undefined reference to `axiom_xml_writer_free'
collect2: ld returned 1 exit status
make[4]: *** [test] Error 1
make[4]: Leaving directory `/home/jdoe/axis2c-src-1.6.0/neethi/test'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/jdoe/axis2c-src-1.6.0/neethi'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/jdoe/axis2c-src-1.6.0/neethi'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/jdoe/axis2c-src-1.6.0'
make: *** [all] Error 2


Adding "-rpath /home/jdoe/axis2c-src-1.6.0/axiom/src/parser/libxml2/.libs" to the LDFLAGS into the Makefile in neethi/test resolved the Problem for me.
I've noticed that "--rpath" is used several times. I'm not sure whether that's correct because I didn't find any hints about setting flags with two hyphens and whether it's meant to be "-rpath".

Kind regards

Erik