This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: gcc 2.95.2 can't find X11 includes


Thanks, Fred,

I'm an idiot!  I had two windows open, one on the host on which
I was trying to do the build, another on another host.  The host
on which I was trying to do the gcc build doesn't have HP's ANSIC
compiler and development bundle, and therefore doesn't have the
X11 includes installed.  I was doing the find to check the paths
of the missing includes in the other window, on a host which has
the development bundle installed and thus also has the includes
for X11.

Thanks, again, for helping me see my mistake.

Doug

<fheitka@attglobal.net> wrote:
> 
> In <3AFC15E1.7D77BF3@kohlmansystems.com>, on 05/11/01
>    at 11:40 AM, Doug Wyatt <dwyatt@kohlmansystems.com> said:
> 
> >I guess I wasn't too clear on this... to my understanding either
> >-I/usr/include or -I/usr/include/X11R6 should work because Xproto.h, for
> >example, is in these two locations:
> 
> Hmmmm?  There is only one file: Xproto.h?  There should be
> a mess of .h files for X.   But if the X11 headers directory is linked to
> /usr/include/ your gcc installation should find them.
> 
> I know though sometimes on Suns for example, the X11 headers
> might be in /opt/dt (can't remember the actual directory.).
> I mean they will be somewhere with the Common Desktop Environment stuff.
> Does your HP use CDE?
> 
> Have you tried doing this from root level:
> find . -name 'X11' -type d -print

> Fred
> 
> >-r--r--r-- 1 bin bin 56454 Sep 26 1996 /usr/include/X11/Xproto.h
> >-r--r--r-- 1 bin bin 56454 Sep 26 1996 /usr/include/X11R6/X11/Xproto.h
> 
> >The first is actually a symlink to the second:
> >  lrwxr-xr-x 1 root sys 31 Jul 15  1997 /usr/include/X11/Xproto.h ->
> >     /usr/include/X11R6/X11/Xproto.h
> 
> >The list shown after "#include <...> search starts here:" contains
> >/usr/include (a default), where <X11/Xproto.h> should have been found.
> >This search list doesn't show /usr/include/X11R6, which it should to my
> >mind since I had -I/usr/include/X11R6 in XINCLUDES and this value clearly
> >made it onto the gcc command line generated by the makefile.
> 
> >"Frederick V. Heitkamp" <heitkamp@pc1.attglobal.net> wrote:
> >>
> >> My X11 includes are in /usr/X11R6/include/X11
> >> which means to you that you probably need
> >> -I/usr/include/X11R6/include.
> >> The gcc -I directive needs to point to the directory
> >> that has the directory X11 in it.  Alternatively
> >> you can make a link from /usr/include/X11 to
> >> /usr/include/X11R6/include/X11.  Anyway you need to
> >> take a good look at your X installations directory
> >> structure to see where the problem is.
> >>
> >> Fred
> >>
> >> On Fri, May 11, 2001 at 04:10:22AM -0500 or thereabouts, Doug Wyatt wrote
> >>> Hi,
> >>>
> >>> I'm trying to build GhostScript on HP-UX with gcc 2.95.2 and
> >>> I've run into a compile problem that looks like gcc isn't
> >>> actually searching the include directories.  Probably I'm
> >>> just being dense (I haven't done much source compiling in
> >>> the last few years), but perhaps some kind soul could point
> >>> out something I'm missing.
> >>>
> >>> The following is an excerpt from the make output:
> >>>
> >>> gcc -v `cat ./obj/cc.tr`  -O2 -Wall -Wstrict-prototypes
> >>>     -Wmissing-declarations     -Wmissing-prototypes -Wtraditional
> >>>     -fno-builtin -fno-common -I./obj -I./src
> >>>     -I/usr/include/X11R6 -o ./obj/gdevx.o -c ./src/gdevx.c
> >>> Reading specs from
> >>>     /usr/local/gcc/lib/gcc-lib/hppa1.1-hp-hpux10.20/2.95.2/specs
> >>> gcc version 2.95.2 19991024 (release)
> >>>  /usr/local/gcc/lib/gcc-lib/hppa1.1-hp-hpux10.20/2.95.2/cpp -lang-c -v
> >>>     -I./obj -I./src -I/usr/include/X11R6 -D__GNUC__=2 -D__GNUC_MINOR__=95
> >>>     -Dhppa -Dhp9000s800 -D__hp9000s800 -Dhp9k8 -DPWB -Dhpux -Dunix
> >>>     -D__hppa__ -D__hp9000s800__ -D__hp9000s800 -D__hp9k8__ -D__PWB__
> >>>     -D__hpux__ -D__unix__ -D__hppa -D__hp9000s800 -D__hp9k8 -D__PWB
> >>>     -D__hpux -D__unix -Asystem(unix) -Asystem(hpux) -Acpu(hppa)
> >>>     -Amachine(hppa) -D__OPTIMIZE__ -Wcast-qual -Wwrite-strings -Wall
> >>>      -Wstrict-prototypes -Wmissing-declarations
> >>>     -Wmissing-prototypes -Wtraditional -D__hp9000s700 -D_PA_RISC1_1
> >>>     -D_HPUX_SOURCE -D_HIUX_SOURCE -D__STDC_EXT__ ./src/gdevx.c
> >>>     /var/tmp/cca7xlpe.i
> >>> GNU CPP version 2.95.2 19991024 (release) (hppa)
> >>> #include "..." search starts here:
> >>> #include <...> search starts here:
> >>>  obj
> >>>  src
> >>>  /usr/local/include
> >>>  /usr/local/gcc/lib/gcc-lib/hppa1.1-hp-hpux10.20/2.95.2/../../../\
> >>> ../hppa1.1-hp-hpux10.20/include
> >>>  /usr/local/gcc/lib/gcc-lib/hppa1.1-hp-hpux10.20/2.95.2/include
> >>>  /usr/include
> >>> End of search list.
> >>> The following default directories have been omitted from the search path:
> >>>  /usr/local/gcc/lib/gcc-lib/hppa1.1-hp-hpux10.20/2.95.2/../../../\
> >>> ../include/g++-3
> >>> End of omitted list.
> >>> In file included from ./src/gdevx.c:24:
> >>> src/x_.h:135: X11/Xlib.h: No such file or directory
> >>> src/x_.h:136: X11/Xproto.h: No such file or directory
> >>> src/x_.h:137: X11/Xatom.h: No such file or directory
> >>> src/x_.h:138: X11/Xutil.h: No such file or directory
> >>> src/x_.h:139: X11/Intrinsic.h: No such file or directory
> >>> src/x_.h:140: X11/StringDefs.h: No such file or directory
> >>> src/x_.h:141: X11/Shell.h: No such file or directory
> >>> gmake: *** [obj/gdevx.o] Error 1
> >>>
> >>>
> >>> I've verified that these include files exist both in /usr/include/X11R6
> >>> and in /usr/include and the two copies are identical.  The files are
> >>> referenced as, for example,
> >>>
> >>> #  include <X11/Xlib.h>
> >>>
> >>> I don't know if it makes any difference, but gcc was built on an HP9000
> >>> 700 series and I'm running this compile on an HP 800 series server.
> >>>
> >>> Can anyone give me a clue?  I'm not subscribed to the list, so please
> >>> cc: me in any replies, though I will monitor the archive.
> >>>
> 
> >Thanks,
> >Doug Wyatt
> 
> OS/2!! OS/2!!
> --
> -----------------------------------------------------------
> fheitka@attglobal.net
> -----------------------------------------------------------


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]