public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: John Tang Boyland <boyland@cs.uwm.edu>
To: nobody@gcc.gnu.org
Cc: gcc-prs@gcc.gnu.org,
Subject: Re: c++/8477: autoconf script chooses wrong value for  gcc_gxx_include_path
Date: Mon, 13 Jan 2003 03:26:00 -0000	[thread overview]
Message-ID: <20030113032602.20436.qmail@sources.redhat.com> (raw)

The following reply was made to PR c++/8477; it has been noted by GNATS.

>From boyland@cs.uwm.edu  Mon Jan 13 01:09:12 2003
From: John Tang Boyland <boyland@cs.uwm.edu>
To: ian.grant@cl.cam.ac.uk, gcc-gnats@gcc.gnu.org, gcc-prs@gcc.gnu.org,
   gcc-bugs@gcc.gnu.org, nobody@gcc.gnu.org
Cc:  
Subject: Re: c++/8477: autoconf script chooses wrong value for 
 gcc_gxx_include_path
Date: Sun, 12 Jan 2003 21:24:41 -0600

 I have a similar problem (except not with autoconf, since
 I just use the release 3.2.1 source.)  'make install' installs
 g++ header files in $(profix)/common/c++/3.2.1/ but then g++
 looks for the files not using prefix.  It seems to do something
 strange related to where the executable is.  I show two runs of g++:
 one from a symbolic link in /usr/new/bin (and /usr/new/lib/lib-gcc
 points 
 to $(exec-prefix)/lib/gcc-lib) and one directly using the full path
 without any symbolic links.  In both cases the files aren't found:
 
 Run #1: (with symbolic links)
 
 % /usr/new/bin/g++ --verbose hello.cc
 Reading specs from
 /usr/new/bin/../lib/gcc-lib/sparc-sun-solaris2.8/3.2.1/specs
 Configured with: ../src/configure
 --prefix=/afs/cs.uwm.edu/package/gcc/gcc-3.2.1/common
 --exec-prefix=/afs/cs.uwm.edu/package/gcc/gcc-3.2.1/sun4x_58
 --enable-languages=c,c++ --disable-nls
 Thread model: posix
 gcc version 3.2.1
  /usr/new/bin/../lib/gcc-lib/sparc-sun-solaris2.8/3.2.1/cc1plus -v
 -iprefix /usr/new/bin/../lib/gcc-lib/sparc-sun-solaris2.8/3.2.1/
 -D__GNUC__=3 -D__GNUC_MINOR__=2 -D__GNUC_PATCHLEVEL__=1
 -D__GXX_ABI_VERSION=102 -Dsparc -Dsun -Dunix -D__svr4__ -D__SVR4
 -D__PRAGMA_REDEFINE_EXTNAME -D__sparc__ -D__sun__ -D__unix__ -D__svr4__
 -D__SVR4 -D__PRAGMA_REDEFINE_EXTNAME -D__sparc -D__sun -D__unix
 -Asystem=unix -Asystem=svr4 -D__NO_INLINE__ -D__STDC_HOSTED__=1
 -D_XOPEN_SOURCE=500 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1
 -D__EXTENSIONS__ -D__SIZE_TYPE__=unsigned int -D__PTRDIFF_TYPE__=int
 -D__WCHAR_TYPE__=long int -D__WINT_TYPE__=long int -D__GCC_NEW_VARARGS__
 -Acpu=sparc -Amachine=sparc hello.cc -D__GNUG__=3 -D__DEPRECATED
 -D__EXCEPTIONS -quiet -dumpbase hello.cc -version -o
 /var/tmp//ccSYZafr.s
 GNU CPP version 3.2.1 (cpplib) (sparc ELF)
 GNU C++ version 3.2.1 (sparc-sun-solaris2.8)
         compiled by GNU C version 3.2.1.
 ignoring nonexistent directory
 "/usr/new/lib/gcc-lib/../../../../../../../../include/c++/3.2.1"
 ignoring nonexistent directory
 "/usr/new/lib/gcc-lib/../../../../../../../../include/c++/3.2.1/sparc-sun-solaris2.8"
 ignoring nonexistent directory
 "/usr/new/lib/gcc-lib/../../../../../../../../include/c++/3.2.1/backward"
 ignoring nonexistent directory
 "/usr/new/lib/gcc-lib/../../../../../../../sparc-sun-solaris2.8/include"
 ignoring nonexistent directory "/include/c++/3.2.1"
 ignoring nonexistent directory "/include/c++/3.2.1/sparc-sun-solaris2.8"
 ignoring nonexistent directory "/include/c++/3.2.1/backward"
 ignoring nonexistent directory "/afs/sparc-sun-solaris2.8/include"
 ignoring duplicate directory
 "/afs/cs.uwm.edu/package/gcc/gcc-3.2.1/sun4x_58/lib/gcc-lib/sparc-sun-solaris2.8/3.2.1/include"
 #include "..." search starts here:
 #include <...> search starts here:
  /usr/new/lib/gcc-lib/sparc-sun-solaris2.8/3.2.1/include
  /usr/local/include
  /afs/cs.uwm.edu/package/gcc/gcc-3.2.1/common/include
  /usr/include
 End of search list.
 hello.cc:1:20: iostream: No such file or directory
 hello.cc: In function `int main()':
 hello.cc:5: `cout' undeclared in namespace `std'
 hello.cc:5: `endl' undeclared in namespace `std'
 
 (2) run without symbolic links:
 
 % /afs/cs.uwm.edu/package/gcc/gcc-3.2.1/sun4x_58/bin/g++ --verbose
 hello.cc
 Reading specs from
 /afs/cs.uwm.edu/package/gcc/gcc-3.2.1/sun4x_58/lib/gcc-lib/sparc-sun-solaris2.8/3.2.1/specs
 Configured with: ../src/configure
 --prefix=/afs/cs.uwm.edu/package/gcc/gcc-3.2.1/common
 --exec-prefix=/afs/cs.uwm.edu/package/gcc/gcc-3.2.1/sun4x_58
 --enable-languages=c,c++ --disable-nls
 Thread model: posix
 gcc version 3.2.1
 
 /afs/cs.uwm.edu/package/gcc/gcc-3.2.1/sun4x_58/lib/gcc-lib/sparc-sun-solaris2.8/3.2.1/cc1plus
 -v -D__GNUC__=3 -D__GNUC_MINOR__=2 -D__GNUC_PATCHLEVEL__=1
 -D__GXX_ABI_VERSION=102 -Dsparc -Dsun -Dunix -D__svr4__ -D__SVR4
 -D__PRAGMA_REDEFINE_EXTNAME -D__sparc__ -D__sun__ -D__unix__ -D__svr4__
 -D__SVR4 -D__PRAGMA_REDEFINE_EXTNAME -D__sparc -D__sun -D__unix
 -Asystem=unix -Asystem=svr4 -D__NO_INLINE__ -D__STDC_HOSTED__=1
 -D_XOPEN_SOURCE=500 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1
 -D__EXTENSIONS__ -D__SIZE_TYPE__=unsigned int -D__PTRDIFF_TYPE__=int
 -D__WCHAR_TYPE__=long int -D__WINT_TYPE__=long int -D__GCC_NEW_VARARGS__
 -Acpu=sparc -Amachine=sparc hello.cc -D__GNUG__=3 -D__DEPRECATED
 -D__EXCEPTIONS -quiet -dumpbase hello.cc -version -o
 /var/tmp//ccHTgJY7.s
 GNU CPP version 3.2.1 (cpplib) (sparc ELF)
 GNU C++ version 3.2.1 (sparc-sun-solaris2.8)
         compiled by GNU C version 3.2.1.
 ignoring nonexistent directory "/include/c++/3.2.1"
 ignoring nonexistent directory "/include/c++/3.2.1/sparc-sun-solaris2.8"
 ignoring nonexistent directory "/include/c++/3.2.1/backward"
 ignoring nonexistent directory "/afs/sparc-sun-solaris2.8/include"
 #include "..." search starts here:
 #include <...> search starts here:
  /usr/local/include
  /afs/cs.uwm.edu/package/gcc/gcc-3.2.1/common/include
 
 /afs/cs.uwm.edu/package/gcc/gcc-3.2.1/sun4x_58/lib/gcc-lib/sparc-sun-solaris2.8/3.2.1/include
  /usr/include
 End of search list.
 hello.cc:1:20: iostream: No such file or directory
 hello.cc: In function `int main()':
 hello.cc:5: `cout' undeclared in namespace `std'
 hello.cc:5: `endl' undeclared in namespace `std'
 
 
 My current "fix" is to edit the binaries in emacs to put in the correct
 paths.
 But I wonder why g++ tries to do tricky things with ../../ working
 backwards from
 gcc-lib rather than just use the same place that things were installed.
 
 John
 
 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=8477


             reply	other threads:[~2003-01-13  3:26 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-13  3:26 John Tang Boyland [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-05-12 11:28 steven
2003-01-08  2:42 bangerth
2002-11-06 14:46 Phil Edwards
2002-11-06  5:06 ian.grant

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030113032602.20436.qmail@sources.redhat.com \
    --to=boyland@cs.uwm.edu \
    --cc=gcc-prs@gcc.gnu.org \
    --cc=nobody@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).