[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
non gcc compilation of src/complain.o fails due to missing macro
From: |
a whited sepulchre |
Subject: |
non gcc compilation of src/complain.o fails due to missing macro |
Date: |
Wed, 3 Oct 2001 11:03:05 -0700 (PDT) |
Hi,
this bug prevents normal compilation on non gcc systems due to a
missing macro in complain.h - the macro is taken from lib/error.h to
build the following output:
-----
> src/bison --version
bison (GNU Bison) 1.29
Copyright 1984, 1986, 1989, 1992, 2000, 2001 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-----
with the macro, the build completes ok, the gnu context diff is simply:
-----
> /usr/local/gnu/diff -c complain.h $BUILDROOT/bison-1.29/src/complain.h
*** complain.h Tue Nov 7 08:28:46 2000
--- /home/ameko/build/bison-1.29/src/complain.h Wed Oct 3 13:54:15 2001
***************
*** 19,24 ****
--- 19,37 ----
#ifndef COMPLAIN_H_
#define COMPLAIN_H_ 1
+ #ifndef __attribute__
+ /* This feature is available in gcc versions 2.5 and later. */
+ # if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || __STRICT_ANSI__
+ # define __attribute__(Spec) /* empty */
+ # endif
+ /* The __-protected variants of `format' and `printf' attributes
+ are accepted by gcc versions 2.6.4 (effectively 2.7) and later. */
+ # if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7)
+ # define __format__ format
+ # define __printf__ printf
+ # endif
+ #endif
+
#ifdef __cplusplus
extern "C" {
#endif
-----
enjoy.
--
ameko
- non gcc compilation of src/complain.o fails due to missing macro,
a whited sepulchre <=