[ccan] autodata problem

PICCA Frédéric-Emmanuel frederic-emmanuel.picca at synchrotron-soleil.fr
Fri Mar 15 23:13:40 EST 2013


> Hmm, I never thought of trying to use autodata in a shared library!

:)

> When I try it here (32 bit x86 Ubuntu), I get:

I am using a Debian x86 32 bit unstable.

I tryed with your patch but the problem is still triggered

/usr/bin/g-ir-scanner  --add-include-path=. --add-include-path=. --warn-all --namespace=Hkl --nsversion=5.0 --libtool="/bin/sh ../libtool" --pkg=gobject-2.0  --pkg-export=hkl-5.0  --library=libhkl.la --warn-all --c-include='hkl.h'   -I.. -I.. -I/usr/include -I/usr/include/glib-2.0 -I/usr/lib/i386-linux-gnu/glib-2.0/include    hkl-error.h hkl-vector.h hkl-matrix.h hkl-quaternion.h hkl-unit.h hkl-interval.h hkl-parameter.h hkl-axis.h hkl-source.h hkl-geometry.h hkl-geometry-factory.h hkl-detector.h hkl-detector-factory.h hkl-lattice.h hkl-sample.h hkl-pseudoaxis.h hkl-pseudoaxis-factory.h hkl-binding-private.h hkl-types.h hkl-error.c hkl-vector.c hkl-matrix.c hkl-quaternion.c hkl-unit.c hkl-interval.c hkl-parameter.c hkl-axis.c hkl-source.c hkl-geometry.c hkl-geometry-factory.c hkl-detector.c hkl-detector-factory.c hkl-lattice.c hkl-sample.c hkl-pseudoaxis.c hkl-pseudoaxis-factory.c hkl-binding.c hkl-types.c hkl-type-builtins.c hkl-type-builtins.h /usr/bin/g-ir-scanner libhkl.la Makefile --output Hkl-5.0.gir
hkl-pseudoaxis.h:37: Warning: Hkl: symbol='darray_mode': Unknown namespace for identifier 'darray_mode'
hkl-pseudoaxis.h:38: Warning: Hkl: symbol='darray_parameter': Unknown namespace for identifier 'darray_parameter'
hkl-pseudoaxis.h:39: Warning: Hkl: symbol='darray_engine': Unknown namespace for identifier 'darray_engine'
g-ir-scanner: compile: gcc -Wall -pthread -I/usr/include/glib-2.0 -I/usr/lib/i386-linux-gnu/glib-2.0/include -I.. -I.. -I/usr/include -I/usr/include/glib-2.0 -I/usr/lib/i386-linux-gnu/glib-2.0/include -I/usr/include/glib-2.0 -I/usr/lib/i386-linux-gnu/glib-2.0/include -c -o /home/picca/Projets/hkl/hkl/tmp-introspectHRsltY/Hkl-5.0.o /home/picca/Projets/hkl/hkl/tmp-introspectHRsltY/Hkl-5.0.c
g-ir-scanner: link: /bin/sh ../libtool --mode=link --tag=CC gcc -o /home/picca/Projets/hkl/hkl/tmp-introspectHRsltY/Hkl-5.0 -export-dynamic /home/picca/Projets/hkl/hkl/tmp-introspectHRsltY/Hkl-5.0.o -L. libhkl.la -pthread -Wl,--export-dynamic -lgio-2.0 -lgthread-2.0 -lgmodule-2.0 -lrt -lgobject-2.0 -lglib-2.0
libtool: link: gcc -o /home/picca/Projets/hkl/hkl/tmp-introspectHRsltY/.libs/Hkl-5.0 /home/picca/Projets/hkl/hkl/tmp-introspectHRsltY/Hkl-5.0.o -pthread -Wl,--export-dynamic -Wl,--export-dynamic  -L. ./.libs/libhkl.so -lgio-2.0 -lgthread-2.0 -lgmodule-2.0 -lrt -lgobject-2.0 -lglib-2.0 -pthread
./.libs/libhkl.so: undefined reference to `__stop_xautodata_geometries'
./.libs/libhkl.so: undefined reference to `__start_xautodata_geometries'
collect2: error: ld returned 1 exit status


I am wondering if this section trick requiered a special CFLAGS or LDFLAGS ?

I can sent you my project if you want to reproduce the problem ?

Cheers

Frederic


More information about the ccan mailing list