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]

(fixed) Gcc PPC header file problem


Hello!

	I am writing to report what I believe is a bug in the recent Gcc
distribution.

	I am running gcc 2.95.2 1991024 (release/franzo) on a G4 power pc
platform.  This machine is running PPC Linux/2000.

	I was building ssh-2.1.0 when I encountered a compile-time error
saying a macro was missing.  I tracked it down to the file 'va-ppc.h'
which was located in:
/usr/lib/gcc-lib/ppc-redhat-linux/2.95.2/include/va-ppc.h

	The error was triggered by the file:
ssh-secure-shell-2.1.0-noncommercial/lib/sshcrypt/genpkcs.c
	This piece of source code handles all the vararg stuff for ssh.

	I apologize for not submitting my change in a patch form -- I
modified my original va-ppc.h file and didn't save a backup.  The
offending entry is on line 102.  Here's my new version from line 99 to
line 106.  My only change was to copy the va_arg define from the
non-optimized case to the optimized one.  The original, unedited line is
prefixed with a double-slash:

   avoid calling it for now.  */

#ifdef __OPTIMIZE__
// extern void __va_arg_type_violation(void) __attribute__((__noreturn__));
#define __va_arg_type_violation()
#else
#define __va_arg_type_violation()
#endif

	The ssh code was being compiled with '-O3', so I'm sure that the
'extern void' line was the problem.  I replaced it with a copy of the
#define for the non-optimized case, and everything works perfectly fine.

	I appoligize for not submitting the entire source that generated
the compile error, but I don't see any convient way of doing that, and I
don't think it should be necessary anyway.  Don't hesitate to contact me
about any questions or concerns with what I've said here.

- John Frear
<jsf8471@ksu.edu>

NO SOLICITING!


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