Subject: Re: Setting include path for building pkg
To: Jonathan <>
From: Jeremy C. Reed <>
List: tech-pkg
Date: 04/12/2004 18:34:11
> gcc -g -O2       -I/usr/X11R6/include    -I/usr/X11R6/include
> -I../appFrame   -I../appUtil    -I../bitmap     -I../ind
> -I../include                      -c sioCopyPasteMotif.c
> In file included from ../appFrame/sioXprop.h:7,
>                  from sioCopyPasteMotif.c:11:
> ../appFrame/appGuiBase.h:34: Xm/Xm.h: No such file or directory

>  The problem is that it is looking for Xm/Xm.h in /usr/X11R6/include but
> the location of Xm.Xm.h is really in
> /usr/pkg/include/Xm/Xm.h

Make sure you have a motif buildlinked, like:
.include "../../mk/"
at end of Makefile.

At build time, it should use something like work/.buildlink/include/Xm/
whatever. Make sure that the link is there.

(Later, you may want to also try replacing USE_BUILDLINK2 with
USE_BUILDLINK3 and switching all the buildlink2.m to too.)

> Where in the do I append the additional search paths? I
> remember Jeremy Reed showed me that the fix for the Xlibs was to add
>  -Wl -R/usr/X11R6/lib to the X_LIBS=@X_LIBS@ line like so:
> X_LIBS=@X_LIBS@ -Wl -R/usr/X11R6/lib

That was for at run time.

> Where do I add the path /usr/pkg/include/Xm/Xm.h in the ?

I don't think that is needed. The problem is that it may have been
buildlinked wrong. Look in your work/.buildlink directory.

   Jeremy C. Reed