This is the mail archive of the gcc-bugs@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]
Other format: [Raw text]

[Bug driver/48306] presence of gcc subdir with . in PATH causes breakdown


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48306

--- Comment #2 from karl at freefriends dot org 2011-03-28 21:51:03 UTC ---
For both gcc 4.5.2 and 4.6.0, I configured it from the original source on
ftp.gnu.org, using --prefix=/usr/local/gnu --enable-languages=c,c++, no other
arguments.  "make install" to install.

Here is the gcc -v output.  I note that cpp is not even being executed.

$ gcc -v hello.c                                                            
Using built-in specs.                                                           
COLLECT_GCC=gcc                                                                 
Target: i686-pc-linux-gnu                                                       
Configured with: ../gcc-4.6.0/configure --prefix=/usr/local/gnu
--enable-langua\
ges=c,c++                                                                       
Thread model: posix                                                             
gcc version 4.6.0 (GCC)                                                         
COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=pentiumpro'                   
 cc1 -quiet -v -iprefix /tmp/../lib/gcc/i686-pc-linux-gnu/4.6.0/ hello.c
-quiet\
 -dumpbase hello.c -mtune=generic -march=pentiumpro -auxbase hello -version -o
\
/dev/shm/cc34H39x.s                                                             
gcc: error trying to exec 'cc1': execvp: No such file or directory

The /tmp/../lib seems like a clear indication it is finding the empty /tmp/gcc
directory.

I thought it might be something in my environment causing the failure, but even
running with env -i, I get the same error.  It is puzzling that you do not see
it.  I can't think of what else would be specific to my installation.

$ mkdir /tmp/gcc
$ env -i PATH=/tmp:/usr/local/gnu/bin gcc hello.c
gcc: error trying to exec 'cc1': execvp: No such file or directory

(the gcc -v output from this env -i run is the same as above.)

Thanks,
karl


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