public inbox for gdb-testers@sourceware.org help / color / mirror / Atom feed
From: sergiodj+buildbot@sergiodj.net To: gdb-testers@sourceware.org Subject: [binutils-gdb] Replace YY_NULL with YY_NULLPTR in LANG-exp.c Date: Thu, 03 Nov 2016 17:04:00 -0000 [thread overview] Message-ID: <722bcb33bf0383487c1af0e7d401e30301e94e2b@gdb-build> (raw) *** TEST RESULTS FOR COMMIT 722bcb33bf0383487c1af0e7d401e30301e94e2b *** Author: Yao Qi <yao.qi@linaro.org> Branch: master Commit: 722bcb33bf0383487c1af0e7d401e30301e94e2b Replace YY_NULL with YY_NULLPTR in LANG-exp.c As we require c++11, GDB fails to build if bison is not new enough. I see the following error on the system (fedora 19) that bison is 2.6.4, g++ -std=gnu++11 .... \ -c -o ada-exp.o -MT ada-exp.o -MMD -MP -MF .deps/ada-exp.Tpo 'if test -f ada-exp.c; then echo ada-exp.c; else echo ../../binutils-gdb/gdb/ada-exp.c; fi` In file included from ../../binutils-gdb/gdb/ada-exp.y:731:0: ada-lex.c:113:0: error: "YY_NULL" redefined [-Werror] #define YY_NULL 0 ^ ada-exp.c:158:0: note: this is the location of the previous definition # define YY_NULL nullptr ^ cc1plus: all warnings being treated as errors make: *** [ada-exp.o] Error 1 Both ada-exp.c and ada-lex.c has macro YY_NULL, like this, $ cat 1.c # ifndef YY_NULL # if defined __cplusplus && 201103L <= __cplusplus # define YY_NULL nullptr # else # define YY_NULL 0 # endif # endif #define YY_NULL 0 as we can see, YY_NULL is defined differently (nullptr vs 0) $ g++ -std=c++11 -Wall 1.c -c 1.c:9:0: warning: "YY_NULL" redefined #define YY_NULL 0 ^ 1.c:3:0: note: this is the location of the previous definition # define YY_NULL nullptr ^ $ g++ -Wall 1.c -c bison renames YY_NULL to YY_NULLPTR in 2013 Nov, https://lists.gnu.org/archive/html/bison-patches/2013-11/msg00002.html and bison released later than 2013 Nov have this patch. Bison 3.0.2, released on 2013 Dec, is OK. The fix is to replace YY_NULL with YY_NULLPTR via sed. With old bison, YY_NULL becomes YY_NULLPTR; with new bison, YY_NULLPTR becomes YY_NULLPTRPTR, gdb: 2016-11-03 Yao Qi <yao.qi@linaro.org> * Makefile.in (.y.c): Replace YY_NULL with YY_NULLPTR.
next reply other threads:[~2016-11-03 16:59 UTC|newest] Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top 2016-11-03 17:04 sergiodj+buildbot [this message] 2016-11-03 17:10 ` *** COMPILATION FAILED *** Failures on Debian-i686-native-extended-gdbserver, branch master *** BREAKAGE *** sergiodj+buildbot 2016-11-03 17:10 ` *** COMPILATION FAILED *** Failures on Debian-i686, " sergiodj+buildbot 2016-11-04 1:42 ` *** COMPILATION FAILED *** Failures on Fedora-i686, " sergiodj+buildbot 2016-11-04 6:22 ` Failures on Debian-s390x-native-extended-gdbserver-m64, branch master sergiodj+buildbot 2016-11-10 10:44 ` Failures on Fedora-ppc64be-cc-with-index, " sergiodj+buildbot 2016-11-10 10:44 ` Failures on Fedora-ppc64be-m64, " sergiodj+buildbot 2016-11-10 10:44 ` Failures on Fedora-ppc64be-native-gdbserver-m64, " sergiodj+buildbot 2016-11-10 10:45 ` Failures on Fedora-ppc64be-native-extended-gdbserver-m64, " sergiodj+buildbot 2016-11-10 13:27 ` Failures on Fedora-ppc64le-native-extended-gdbserver-m64, " sergiodj+buildbot 2016-11-10 13:27 ` Failures on Fedora-ppc64le-cc-with-index, " sergiodj+buildbot 2016-11-10 13:27 ` Failures on Fedora-ppc64le-m64, " sergiodj+buildbot 2016-11-10 13:28 ` Failures on Fedora-ppc64le-native-gdbserver-m64, " sergiodj+buildbot
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=722bcb33bf0383487c1af0e7d401e30301e94e2b@gdb-build \ --to=sergiodj+buildbot@sergiodj.net \ --cc=gdb-testers@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).