reduce portfile

Mark Brethen mark.brethen at gmail.com
Sun Jan 22 06:26:57 PST 2012


On Jan 22, 2012, at 8:01 AM, Mark Brethen wrote:

> 
> On Jan 20, 2012, at 3:30 AM, Arthur Norman wrote:
> 
>> to investigate further why your test scripts are failing. I believe macports isn't providing all the necessary libraries.
>>> 
>>> I'm not sure what you mean by forcing -lX11 -lXext, but you should be 
>> linking to the macports X11 libs (i.e. those in the /opt/local/... path).
>>> 
>> What I mean is that when it set CFLAGS, LIBS etc in its customised way it had not put -lX11 into LIBS and so I need to. This is all to do with just what it expects me to set up via my configure script and what it will insist on having its own settings for. Somewhere there may be a lengthy explanation on their web-site of what they do and require and expect, and why they do it that way! But at present it seems that they expect me to put in -lX11 but not -L/usr/X11R6/lib while on native xcode I need to put in both.
> 
> I don't think you should do this. For instance, in the config.log for CSL I found:
> 
> configure:6574: checking Xlib.h presence
> configure:6574: /Developer/usr/bin/clang -E -I/opt/local/include -I/usr/X11R6/include  -I/usr/X11R6/include  conftest.c
> conftest.c:33:10: fatal error: 'Xlib.h' file not found
> #include <Xlib.h>
>         ^
> 1 error generated.
> 
> But MacPorts puts the X11 LIBS in /opt/local/include/X11 and Xlib.h is in that directory. Now, if you look in the portfile I have listed port:xorg-libX11 under depends_lib. If its not passing that path to the config/makefile then we need to find out why?
> 
> Can someone on the dev-list please verify?
> 
> 
> 
> Mark
> 
> 
> 
> 

Correction: this was in the fox config.log, not the CSL config.log. Here's another example from that log file:

configure:7021: /Developer/usr/bin/clang -c -pipe -O2 -arch x86_64 -msse2 -isysroot /Developer/SDKs/MacOSX10.7.sdk  -I/opt/local/include -I/usr/X11R6/include  -I/usr/X11R6/include  conftest.c >&5
In file included from conftest.c:38:
/opt/local/include/X11/extensions/XShm.h:41:5: error: unknown type name 'Bool'; did you mean '_Bool'?
   Bool send_event;        /* true if this came frome a SendEvent request */
   ^
/opt/local/include/X11/extensions/XShm.h:42:5: error: unknown type name 'Display'
   Display *display;       /* Display the event was read from */
   ^
/opt/local/include/X11/extensions/XShm.h:43:5: error: unknown type name 'Drawable'
   Drawable drawable;      /* drawable of request */
   ^
/opt/local/include/X11/extensions/XShm.h:54:5: error: unknown type name 'Bool'; did you mean '_Bool'?
   Bool readOnly;      /* how the server should attach it */
   ^
/opt/local/include/X11/extensions/XShm.h:59:1: error: unknown type name 'Bool'; did you mean '_Bool'?
Bool XShmQueryExtension(
^
/opt/local/include/X11/extensions/XShm.h:60:5: error: unknown type name 'Display'
   Display*            /* dpy */
   ^
/opt/local/include/X11/extensions/XShm.h:64:5: error: unknown type name 'Display'
   Display*            /* dpy */
   ^
/opt/local/include/X11/extensions/XShm.h:67:1: error: unknown type name 'Bool'; did you mean '_Bool'?
Bool XShmQueryVersion(
^
/opt/local/include/X11/extensions/XShm.h:68:5: error: unknown type name 'Display'
   Display*            /* dpy */,
   ^
/opt/local/include/X11/extensions/XShm.h:71:5: error: unknown type name 'Bool'; did you mean '_Bool'?
   Bool*               /* sharedPixmaps */
   ^
/opt/local/include/X11/extensions/XShm.h:75:5: error: unknown type name 'Display'
   Display*            /* dpy */
   ^
/opt/local/include/X11/extensions/XShm.h:78:1: error: unknown type name 'Bool'; did you mean '_Bool'?
Bool XShmAttach(
^
/opt/local/include/X11/extensions/XShm.h:79:5: error: unknown type name 'Display'
   Display*            /* dpy */,
   ^
/opt/local/include/X11/extensions/XShm.h:83:1: error: unknown type name 'Bool'; did you mean '_Bool'?
Bool XShmDetach(
^
/opt/local/include/X11/extensions/XShm.h:84:5: error: unknown type name 'Display'
   Display*            /* dpy */,
   ^
/opt/local/include/X11/extensions/XShm.h:88:1: error: unknown type name 'Bool'; did you mean '_Bool'?
Bool XShmPutImage(
^
/opt/local/include/X11/extensions/XShm.h:89:5: error: unknown type name 'Display'
   Display*            /* dpy */,
   ^
/opt/local/include/X11/extensions/XShm.h:90:5: warning: type specifier missing, defaults to 'int' [-Wimplicit-int]
   Drawable            /* d */,
   ^~~~~~~~
/opt/local/include/X11/extensions/XShm.h:91:5: warning: type specifier missing, defaults to 'int' [-Wimplicit-int]
   GC                  /* gc */,
   ^~
/opt/local/include/X11/extensions/XShm.h:92:5: error: unknown type name 'XImage'
   XImage*             /* image */,
   ^
/opt/local/include/X11/extensions/XShm.h:99:5: warning: type specifier missing, defaults to 'int' [-Wimplicit-int]
   Bool                /* send_event */
   ^~~~
/opt/local/include/X11/extensions/XShm.h:102:1: error: unknown type name 'Bool'; did you mean '_Bool'?
Bool XShmGetImage(
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
3 warnings and 20 errors generated.

Mark






More information about the macports-dev mailing list