Delivered-To: lablgtk at yquem.inria.fr Date: Sun, 24 Aug 2008 21:53:03 +0200 From: Philippe Strauss To: LablGTK Message-ID: <20080824195303.GA12733 at whitechalk.dfinet.ch> MIME-Version: 1.0 Content-Disposition: inline Subject: [Lablgtk] OSX specific: compiling lablgtk against native (quartz based) gtk Content-Type: text/plain; charset=iso-8859-1 Content-Length: 4374 Hello lablgtk users, It's specific to the mac. I would like to get lablgtk (latest rev.) linked against imendio's OSX native gtk port (not requiring X-Window (xquartz) but using gdk primitives rendering directly to quartz). I was able to install imendio gtk without any problem (easy step), gtkglarea-1.99 was more difficult but it seems to work now. (I need gtkglarea in my software experiments). I'm using lablgtk-2.10.1, configured using the following: PKG_CONFIG_PATH=/opt/gtk-osx/lib/pkgconfig:/opt/gtk-osx/share/pkgconfig:/usr/lib/pkgconfig \ ./configure --with-libdir=/opt/godi/lib-custom OCaml is 3.10.2 of current godi, OSX 10.5.4. the build chokes on: --- ... ocamlc.opt -c -ccopt '-DG_DISABLE_ASSERT -DG_DISABLE_CAST_CHECKS -I/opt/gtk-osx/include/gtk-2.0 -I/opt/gtk-osx/lib/gtk-2.0/include -I/opt/gtk-osx/include/atk-1.0 -I/opt/gtk-osx/include/cairo -I/opt/gtk-osx/include/pango-1.0 -I/opt/gtk-osx/include/glib-2.0 -I/opt/gtk-osx/lib/glib-2.0/include -I/opt/gtk-osx/include/libpng12 -I/opt/gtk-osx/include/pixman-1 -I/opt/gtk-osx/include/gtkgl-2.0 -I/usr/include/libxml2 -I/opt/local/include/libglade-2.0 -I/opt/local/include/librsvg-2 -imacros ml_domain.h -O ' ml_rsvg.c ocamlmklib -verbose -o lablrsvg ml_rsvg.o -L/opt/gtk-osx/lib -L/opt/local/lib -lrsvg-2 -lgdk_pixbuf-2.0 -lcairo -lz -lgobject-2.0 -lgmodule-2.0 -lglib-2.0 -lintl -liconv -lpng12 -lpixman-1 + gcc -bundle -flat_namespace -undefined suppress -o ./dlllablrsvg.so ml_rsvg.o -L/opt/godi/lib -L/opt/gtk-osx/lib -L/opt/local/lib -lrsvg-2 -lgdk_pixbuf-2.0 -lcairo -lz -lgobject-2.0 -lgmodule-2.0 -lglib-2.0 -lintl -liconv -lpng12 -lpixman-1 ld: warning, duplicate dylib /opt/local/lib/libz.1.dylib ld: warning, duplicate dylib /opt/local/lib/libiconv.2.dylib ld: warning, duplicate dylib /opt/gtk-osx/lib/libgdk_pixbuf-2.0.0.dylib ld: warning, duplicate dylib /opt/gtk-osx/lib/libcairo.2.dylib ld: warning, duplicate dylib /opt/gtk-osx/lib/libpng12.0.dylib ld: warning, duplicate dylib /opt/gtk-osx/lib/libpixman-1.0.dylib ld: warning, duplicate dylib /opt/gtk-osx/lib/libgobject-2.0.0.dylib ld: warning, duplicate dylib /opt/gtk-osx/lib/libgmodule-2.0.0.dylib ld: warning, duplicate dylib /opt/gtk-osx/lib/libglib-2.0.0.dylib ld: warning, duplicate dylib /opt/gtk-osx/lib/libintl.8.dylib ld: warning, duplicate dylib /opt/local/lib/libxml2.2.dylib + ar rc ./liblablrsvg.a ml_rsvg.o; ranlib ./liblablrsvg.a ocamlc.opt -I +lablGL -w s -c rsvg.mli ocamlc.opt -I +lablGL -w s -c rsvg.ml ocamlmklib -verbose -o lablrsvg -oc lablrsvg rsvg.cmo -L/opt/gtk-osx/lib -L/opt/local/lib -lrsvg-2 -lgdk_pixbuf-2.0 -lcairo -lz -lgobject-2.0 -lgmodule-2.0 -lglib-2.0 -lintl -liconv -lpng12 -lpixman-1 + /opt/godi/bin/ocamlc -a -o lablrsvg.cma rsvg.cmo -dllib -llablrsvg -cclib -llablrsvg -ccopt -L/opt/godi/lib -ccopt -L/opt/gtk-osx/lib -ccopt -L/opt/local/lib -cclib -lrsvg-2 -cclib -lgdk_pixbuf-2.0 -cclib -lcairo -cclib -lz -cclib -lgobject-2.0 -cclib -lgmodule-2.0 -cclib -lglib-2.0 -cclib -lintl -cclib -liconv -cclib -lpng12 -cclib -lpixman-1 ocamlc.opt -I +lablGL -w s -c -thread gtkThread.mli ocamlc.opt -I +lablGL -w s -c -thread gtkThread.ml ocamlc.opt -I +lablGL -w s -c gtkThInit.ml ocamlmktop -I +lablGL -thread -o lablgtktop unix.cma threads.cma lablgl.cma \ -I . lablgtk.cma lablgtkgl.cma lablglade.cma lablrsvg.cma gtkThread.cmo Error on dynamically loaded library: ./dlllablgtkgl2.so: Symbol not found: _GDK_DISPLAY Referenced from: /opt/gtk-osx/lib/libgtkgl-2.0.1.dylib Expected in: flat namespace make[1]: *** [lablgtktop] Error 2 make: *** [all] Error 2 --- Using nm, I can see that in /opt/gtk-osx/lib/libgdk-quartz-2.0.dylib, there is a __gdk_display symbol, but no _gdk_display. (! one or two underscores). (macports gdk, x11 based): /opt/local/lib/libgdk-x11-2.0.dylib: 000800d8 D _gdk_display (immendio's gtk, jhbuild): /opt/gtk-osx/lib/libgdk-quartz-2.0.dylib: 00071100 d __gdk_display where is the problem? is it a feature of non-x11 but quartz based gdk? I've looked at the source, but actually cannot tell myself if the gdk_display function is specific to x11, it seems not but I may be wrong. Should I direct my request to the gtk-devel mailing list? TIA. -- Philippe Strauss http://philou.ch _______________________________________________ Lablgtk mailing list Lablgtk@yquem.inria.fr http://yquem.inria.fr/cgi-bin/mailman/listinfo/lablgtk