Christian Weisgerber <na...@mips.inka.de> writes: > Jeremie Courreges-Anglas: > >> > imlib2-config and pkg-config imlib2 don't agree: >> >> I think that "-L/usr/local/lib -L/usr/X11R6/lib -lImlib2" and >> "-I/usr/local/include -I/usr/X11R6/include" should be enough. > > Yes to "-I/usr/local/include -I/usr/X11R6/include". > > However, in "-L/usr/local/lib -L/usr/X11R6/lib -lImlib2" the X11R6 path > is useless. It should be either just > > -L/usr/local/lib -lImlib2
I'm not sure I understand, afaik it would be enough if /usr/X11R6/lib was in the default search path of ld(1). ritchie /tmp$ cc main.c -L/usr/local/lib -lImlib2 /usr/local/lib/libImlib2.so.6.0: warning: warning: strcpy() is almost always misused, please use strlcpy() /usr/local/lib/libImlib2.so.6.0: warning: warning: sprintf() is often misused, please use snprintf() /usr/bin/ld: warning: libfreetype.so.27.0, needed by /usr/local/lib/libImlib2.so.6.0, not found (try using -rpath or -rpath-link) /usr/bin/ld: warning: libXext.so.13.0, needed by /usr/local/lib/libImlib2.so.6.0, not found (try using -rpath or -rpath-link) /usr/bin/ld: warning: libX11.so.16.1, needed by /usr/local/lib/libImlib2.so.6.0, not found (try using -rpath or -rpath-link) /usr/bin/ld: warning: libxcb.so.4.0, needed by /usr/local/lib/libImlib2.so.6.0, not found (try using -rpath or -rpath-link) /usr/local/lib/libImlib2.so.6.0: undefined reference to `XFreePixmap' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XShmDetach' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XShmGetImage' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XSync' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Init_FreeType' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Load_Glyph' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Done_Face' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XGetVisualInfo' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Get_Kerning' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Get_Char_Index' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XCreateImage' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XSetForeground' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XGetWindowAttributes' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Get_Glyph' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XFreeGC' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XCopyArea' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Set_Pixel_Sizes' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XUngrabServer' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Select_Charmap' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XGetImage' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Glyph_To_Bitmap' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XFree' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XFreeColors' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XSetErrorHandler' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XShapeGetRectangles' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Set_Char_Size' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XShmCreateImage' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XShmPutImage' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XShmAttach' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XGrabServer' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XTranslateCoordinates' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XQueryColors' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_Done_Glyph' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XAllocColor' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XShmQueryExtension' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XGetGeometry' /usr/local/lib/libImlib2.so.6.0: undefined reference to `FT_New_Face' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XFillRectangle' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XVisualIDFromVisual' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XPutImage' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XCreatePixmap' /usr/local/lib/libImlib2.so.6.0: undefined reference to `XCreateGC' collect2: ld returned 1 exit status ritchie /tmp$ cc main.c -L/usr/local/lib -L/usr/X11R6/lib -lImlib2 /usr/local/lib/libImlib2.so.6.0: warning: warning: strcpy() is almost always misused, please use strlcpy() /usr/local/lib/libImlib2.so.6.0: warning: warning: sprintf() is often misused, please use snprintf() /usr/X11R6/lib/libfreetype.so.27.0: warning: warning: strcat() is almost always misused, please use strlcat() > > or > > -L/usr/local/lib -L/usr/X11R6/lib -lImlib2 -lfreetype -lz -lm -lXext -lX11 > > For imlib2.pc, something like > > Libs: -L${libdir} -lImlib2 > Libs.private: -L${X11BASE}/lib -lfreetype -lz -lm -lXext -lX11 > Cflags: -I${includedir} -I${X11BASE}/include > > may make sense. But then again, we have stopped listing interlibrary > dependencies... We're not supposed to need them any more so I think that maintaining them on a general basis would be a bad idea. -- jca | PGP : 0x1524E7EE / 5135 92C1 AD36 5293 2BDF DDCC 0DFA 74AE 1524 E7EE