Re: Undefined X11 symbols for architecture x86_64 (on Lion)
Re: Undefined X11 symbols for architecture x86_64 (on Lion)
- Subject: Re: Undefined X11 symbols for architecture x86_64 (on Lion)
- From: Jeremy Huddleston <email@hidden>
- Date: Sat, 6 Aug 2011 03:42:30 -0700
You need to link against libX11
On Aug 6, 2011, at 3:01 AM, Philippe Strauss wrote:
> Hello X11 OSX users,
>
> I'm trying to build gtkglarea-2.0.1, having latest gtk+ already (by homebrew), and the build die in the following way:
>
<snip />
> libtool: link: gcc -dynamiclib -o .libs/libgtkgl-2.0.1.dylib .libs/gdkgl.o .libs/gtkglarea.o -L/usr/local/Cellar/gtk+/2.24.5/lib -L/usr/local/Cellar/atk/2.0.1/lib -L/usr/local/Cellar/gdk-pixbuf/2.23.5/lib -L/usr/local/Cellar/glib/2.28.7/lib -L/usr/local/Cellar/pango/1.28.4/lib -L/usr/local/Cellar/gettext/0.18.1.1/lib -L/usr/X11/lib -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lpangocairo-1.0 -lgdk_pixbuf-2.0 -lm -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgthread-2.0 -lgmodule-2.0 -lglib-2.0 -lintl -lGLU -lGL -install_name /usr/local/lib/libgtkgl-2.0.1.dylib -compatibility_version 2 -current_version 2.1 -Wl,-single_module
>
<snip />
>
>
> philou@bookpro-wlan:~/src/gtkglarea-2.0.1$ file /usr/X11/lib/libX11.6.3.0.dylib
> /usr/X11/lib/libX11.6.3.0.dylib: Mach-O universal binary with 2 architectures
> /usr/X11/lib/libX11.6.3.0.dylib (for architecture x86_64): Mach-O 64-bit dynamically linked shared library x86_64
> /usr/X11/lib/libX11.6.3.0.dylib (for architecture i386): Mach-O dynamically linked shared library i386
>
>
> philou@bookpro-wlan:~/src/gtkglarea-2.0.1$ nm -arch x86_64 /usr/X11/lib/libX11.6.3.0.dylib | grep _XVisualIDFromVisual000000000001333e T _XVisualIDFromVisual
Yes. That is where those symbols are located. You should be linking against libX11, but you're not. You need an -lX11 in your link line.
---
Jeremy Huddleston
Rebuild Sudan
- Board of Directors
- http://www.rebuildsudan.org
Berkeley Foundation for Opportunities in Information Technology
- Advisory Board
- http://www.bfoit.org
_______________________________________________
Do not post admin requests to the list. They will be ignored.
X11-users mailing list (email@hidden)
This email sent to email@hidden