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]

tradtradcpp0, cpp spec bugs, and use of '|'


I was compiling some NetBSD kernel code, which used to compile
properly with gcc 2.95.2.  in the process, I noticed that the flags

My new compiler is from the head of the CVS trunk as of "2000-10-10
0:00 UTC".

"-traditional -traditional-cpp" no longer work together as they used
to.  Output from new and old compilers (with -v, foo.s is a one-line
input file).


There are two specific behaviours which are 'interesting' to me:

(1) probably simple to fix: -traditional-cpp is now called an
unrecognized option, when given to gcc.  (Not quite sure where the
right place to fix this one would be...)

(2) when provided with those two options, the driver ends up trying to
invoke tradtradcpp0.  amusingly, if you add -ftraditional, it tries
tradtradtradcpp0, etc...  8-)


This would seem to be an issue with the use of '|' in the
trad_capable_cpp spec:

	%{traditional|ftraditional|traditional-cpp:trad}cpp0

from reading the documentation and code, '|' in this case doesn't mean
"one or the other" it means "for each of those specified, output the
bits after the colon."  meaning, one of those flags -> trad.  2 ->
tradtrad.  3-> tradtradtrad.

I don't know if there's an easy way to fix this one at all... but i do
note that additional uses of '|' with this apparently bogus intent
have been added since then
(e.g. http://gcc.gnu.org/cgi-bin/cvsweb.cgi/egcs/gcc/gcc.c.diff?r1=1.168&r2=1.169).


any ideas?


chris

(p.s. is it really the intent to provide no output file for 0-length
input?  I've not checked later versions of the compiler than
2000-10-10... but that oen doesn't provide any output for 0-length
input.)

==============

Old compiler (2.95.2):

89 [highland] tmp % /usr/local/sbtools-mips64-sb1sim/bin/mips64-sb1sim-gcc -E -v -traditional -traditional-cpp -x assembler-with-cpp -o foo.a foo.s
Reading specs from /usr/local/sbtools-mips64-sb1sim-1.3.10/lib/gcc-lib/mips64-sb1sim/2.95.2/specs
gcc version 2.95.2 19991024 (release)
 /usr/local/sbtools-mips64-sb1sim-1.3.10/lib/gcc-lib/mips64-sb1sim/2.95.2/cpp -lang-asm -v -$ -Dmips -DMIPSEB -DR4000 -D_mips -D_MIPSEB -D_R4000 -D__mips__ -D__MIPSEB__ -D__R4000__ -D___mips__ -D_MIPSEB -D_R4000 -D__mips -D__MIPSEB -D__R4000 -D___mips -D__ASSEMBLER__ -traditional -traditional -D__LANGUAGE_ASSEMBLY -D_LANGUAGE_ASSEMBLY -DLANGUAGE_ASSEMBLY -D__SIZE_TYPE__=unsigned int -D__SSIZE_TYPE__=int -D__PTRDIFF_TYPE__=int -D__long32 -U__mips -D__mips=3 -D__mips64 foo.s -o foo.a
GNU CPP version 2.95.2 19991024 (release) [AL 1.1, MM 40] BSD Mips
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/sbtools-mips64-sb1sim-1.3.10/lib/gcc-lib/mips64-sb1sim/2.95.2/include
 /usr/local/sbtools-mips64-sb1sim-1.3.10/lib/gcc-lib/mips64-sb1sim/2.95.2/../../../../mips64-sb1sim/sys-include
 /usr/local/sbtools-mips64-sb1sim-1.3.10/lib/gcc-lib/mips64-sb1sim/2.95.2/../../../../mips64-sb1sim/include
End of search list.
The following default directories have been omitted from the search path:
 /usr/local/sbtools-mips64-sb1sim-1.3.10/lib/gcc-lib/mips64-sb1sim/2.95.2/../../../../include/g++-3
End of omitted list.


New compiler (head of the CVS trunk as of "2000-10-10 0:00 UTC":

93 [highland] tmp % /usr/local/sbtools-mips64-sb1sim-1.4.9/bin/mips64-sb1sim-gcc -E -v -traditional -traditional-cpp -x assembler-with-cpp -o foo.a foo.s
Reading specs from /usr/local/sbtools-mips64-sb1sim-1.4.9/lib/gcc-lib/mips64-sb1sim/2.97/specs
mips64-sb1sim-gcc: unrecognized option `-traditional-cpp'
Configured with:  --target=mips64-sb1sim --prefix=/usr/local/sbtools-mips64-sb1sim-1.4.9 --disable-nls --with-gnu-as --with-gnu-ld
gcc version 2.97 20001009 (experimental)
 tradtradcpp0 -lang-asm -v -D__GNUC__=2 -D__GNUC_MINOR__=97 -D__GNUC_PATCHLEVEL__=0 -Dmips -DMIPSEB -DR4000 -D_mips -D_MIPSEB -D_R4000 -D__mips__ -D__MIPSEB__ -D__R4000__ -D__mips__ -D_MIPSEB -D_R4000 -D__mips -D__MIPSEB -D__R4000 -D__mips -D__STDC_HOSTED__=1 -D__LANGUAGE_ASSEMBLY -D_LANGUAGE_ASSEMBLY -DLANGUAGE_ASSEMBLY -D__SIZE_TYPE__=unsigned int -D__SSIZE_TYPE__=int -D__PTRDIFF_TYPE__=int -D__long32 -U__mips -D__mips=3 -D__mips64 foo.s -o foo.a
mips64-sb1sim-gcc: installation problem, cannot exec `tradtradcpp0': No such file or directory



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