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]

Re: 'gcc -V' no longer works properly between 2.95 and older versions


I found the same problem earlier with egcs-1.1.X.  Workaround I used was
editting specs of earlier compiler versions to avoid giving bad options 
(-V 2.7.2.3 or similar) to GAS. It was long time ago and I have not used
gcc-2.7.2.3 or gcc-2.8.1 so long as I don't exactly remeber (I used egcs-1.1.X
for some time and now gcc-2.95)

Andris

On Fri, 13 Aug 1999, Michael Deutschmann wrote:
> I've recently installed gcc-2.95.  I've discovered that 'gcc -V 2.8.1' or
> `gcc -V 2.7.2.3' does not work, although I do have those compilers
> properly installed.  A `script' dump of my attempt follows. 
> 
> My guess (considering the warning) is that you've gone and changed the 
> specs format in a backwardly-incompatible way.  This is a no-no, as it 
> makes the manual lie:
> 
> (from invoke.texi)
> # The only way that the driver program depends on the target machine is
> # in the parsing and handling of special machine-specific options.
> # However, this is controlled by a file which is found, along with the
> # other executables, in the directory for the specified version and
> # target machine.  As a result, a single installed driver program adapts
> # to any specified target machine and compiler version.
> 
> ---- Michael Deutschmann <michael@talamasca.wkpowerlink.com>
> 
> Script started on Thu Aug 12 21:42:58 1999
> bash-2.03$ echo 'int main(void) {return 0;}' > null.c
> bash-2.03$ gcc -V 2.7.2.3 null.c -c -onull.o
> gcc: Warning: use of obsolete %[ operator in specs
> GNU assembler version 2.9.5 (i386-pc-linux-gnu) using BFD version 2.9.5.0.4
> Assembler messages:
> Error: Can't open 2.7.2.3 for reading.
> 2.7.2.3: No such file or directory
> bash-2.03$ gcc -v -V 2.7.2.3 null.c -c -onull.o
> Reading specs from /usr/lib/gcc-lib/i386-pc-linux-gnu/2.7.2.3/specs
> gcc driver version 2.95 19990728 (release) executing gcc version 2.7.2.3
> gcc: Warning: use of obsolete %[ operator in specs
>  /usr/lib/gcc-lib/i386-pc-linux-gnu/2.7.2.3/cpp -lang-c -v -D__GNUC__=2 -D__GNUC_MINOR__=7 -D__ELF__ -Dunix -Di386 -Dlinux -D__ELF__ -D__unix__ -D__i386__ -D__linux__ -D__unix -D__i386 -D__linux -Asystem(unix) -Asystem(posix) -Acpu(i386) -Amachine(i386) n
> ull.c /tmp/cc0nYo2T.i
> GNU CPP version 2.7.2.3 (i386 Linux/ELF)
> #include "..." search starts here:
> #include <...> search starts here:
>  /usr/local/include
>  /usr/i386-pc-linux-gnu/include
>  /usr/lib/gcc-lib/i386-pc-linux-gnu/2.7.2.3/include
>  /usr/include
> End of search list.
>  /usr/lib/gcc-lib/i386-pc-linux-gnu/2.7.2.3/cc1 /tmp/cc0nYo2T.i -quiet -dumpbase null.c -version -o /tmp/cc6HZSIH.s
> GNU C version 2.7.2.3 (i386 Linux/ELF) compiled by GNU C version 2.8.1.
>  as -V 2.7.2.3 -Qy -onull.o /tmp/cc6HZSIH.s
> GNU assembler version 2.9.5 (i386-pc-linux-gnu) using BFD version 2.9.5.0.4
> Assembler messages:
> Error: Can't open 2.7.2.3 for reading.
> 2.7.2.3: No such file or directory
> bash-2.03$ exit
> exit
> 
> Script done on Thu Aug 12 21:44:12 1999


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