[Vala] glade, symbol not found.
- From: Sam Liddicott <sam liddicott com>
- To: vala-list gnome org
- Subject: [Vala] glade, symbol not found.
- Date: Mon, 16 Jun 2008 16:11:11 +0100
I've imported the vala glade example from the wiki into a project build
using vala-gen-project.
I in configure.ac I had to add:
GLADE_REQUIRED=2.6.0
and
libglade-2.0 >= $GLADE_REQUIRED
to
PKG_CHECK_MODULES(PHONEUI, glib-2.0 >= $GLIB_REQUIRED gobject-2.0 >=
$GLIB_REQUIRED gtk+-2.0 >= $GTK_REQUIRED)
It builds fine now, but when I run the application, the connect_signals
fails:
sam lazarus:~/projects/vala/phoneui$ ./phoneui
Symbol not found: activate => glade_phone_ui_on_bHelloWorld_clicked
sam lazarus:~/projects/vala/phoneui$ nm -s ./phoneui | grep
glade_phone_ui_on_bHelloWorld_clicked
080491b0 T glade_phone_ui_on_bHelloWorld_clicked
However if I build in one step using a command line based on the glade
example:
$ valac --pkg gtk+-2.0 --pkg libglade-2.0 --pkg gmodule-2.0 -o demo
mainwindow.vala -X "-Wl,--export-dynamic -rdynamic"
then it works fine; also:
sam lazarus:~/projects/vala/phoneui/src$ nm -s ./demo | grep
glade_phone_ui_on_bHelloWorld_clicked
08048ea4 T glade_phone_ui_on_bHelloWorld_clicked
...so the symbol seems just as valid...
I guess the:
"-Wl,--export-dynamic -rdynamic"
has something to do with it, if I add it to the build line, like this:
sam lazarus:~/projects/vala/phoneui$ gcc -g -O2 -Wl,--export-dynamic
-rdynamic -o phoneui src/mainwindow.o /usr/lib/libglade-2.0.so
/usr/lib/libgtk-x11-2.0.so /usr/lib/libxml2.so
/usr/lib/libgdk-x11-2.0.so /usr/lib/libatk-1.0.so
/usr/lib/libgdk_pixbuf-2.0.so -lm /usr/lib/libpangocairo-1.0.so
/usr/lib/libpango-1.0.so /usr/lib/libcairo.so /usr/lib/libgobject-2.0.so
/usr/lib/libgmodule-2.0.so -ldl /usr/lib/libglib-2.0.so
then it works, so it should probably mean a changed needed in
vala-gen-project to put this as C flags configure.ac or Makefile.am or
something (I guess).
I've not managed to work out where.
Sam
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]