Message ID | 20210930193451.gacunhy24jqyqxau@lug-owl.de |
---|---|
State | Committed |
Commit | 5b4bf54a00be17e49433582c237724ac4e653608 |
Headers |
Return-Path: <gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 0956F3857C53 for <patchwork@sourceware.org>; Thu, 30 Sep 2021 19:35:44 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from lug-owl.de (lug-owl.de [IPv6:2a03:4000:10:469::]) by sourceware.org (Postfix) with ESMTP id EF2483858001 for <gcc-patches@gcc.gnu.org>; Thu, 30 Sep 2021 19:34:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org EF2483858001 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=lug-owl.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=lug-owl.de Received: by lug-owl.de (Postfix, from userid 1001) id 5F22C41EF1; Thu, 30 Sep 2021 21:34:51 +0200 (CEST) Date: Thu, 30 Sep 2021 21:34:51 +0200 From: Jan-Benedict Glaw <jbglaw@lug-owl.de> To: Sebastien Bourdeauducq <sebastien@milkymist.org>, gcc-patches@gcc.gnu.org Subject: [LM32] Fix '"LINK_GCC_C_SEQUENCE_SPEC" redefined' warning Message-ID: <20210930193451.gacunhy24jqyqxau@lug-owl.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="gbuwv5wak2hsvyle" Content-Disposition: inline X-Operating-System: Linux chamaeleon 5.8.0-0.bpo.2-amd64 X-gpg-fingerprint: 250D 3BCF 7127 0D8C A444 A961 1DBD 5E75 8399 E1BB X-gpg-key: wwwkeys.de.pgp.net X-Echelon-Enable: howto poison arsenous mail psychological biological nuclear warfare test the bombastical terror of flooding the spy listeners explosion sex drugs and rock'n'roll X-TKUeV: howto poison arsenous mail psychological biological nuclear warfare test the bombastical terror of flooding the spy listeners explosion sex drugs and rock'n'roll X-message-flag: Please send plain text messages only. Do not send HTML emails. Thank you. User-Agent: NeoMutt/20170113 (1.7.2) X-Spam-Status: No, score=-9.4 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_STATUS, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Sender: "Gcc-patches" <gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org> |
Series |
[LM32] Fix '"LINK_GCC_C_SEQUENCE_SPEC" redefined' warning
|
|
Commit Message
Jan-Benedict Glaw
Sept. 30, 2021, 7:34 p.m. UTC
Hi! When configuring GCC for --target=lm32-uclinux --enable-werror-always, it breaks here: [all 2021-09-30 08:55:55] /usr/lib/gcc-snapshot/bin/g++ -c -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wno-error=format-diag -Wmissing-format-attribute -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Werror -fno-common -DHAVE_CONFIG_H -DGENERATOR_FILE -I. -Ibuild -I../../gcc/gcc -I../../gcc/gcc/build -I../../gcc/gcc/../include -I../../gcc/gcc/../libcpp/include \ [all 2021-09-30 08:55:55] -o build/genpreds.o ../../gcc/gcc/genpreds.c [all 2021-09-30 08:55:55] In file included from ./tm.h:29, [all 2021-09-30 08:55:55] from ../../gcc/gcc/genpreds.c:26: [all 2021-09-30 08:55:55] ../../gcc/gcc/config/lm32/uclinux-elf.h:70: error: "LINK_GCC_C_SEQUENCE_SPEC" redefined [-Werror] [all 2021-09-30 08:55:55] 70 | #define LINK_GCC_C_SEQUENCE_SPEC \ [all 2021-09-30 08:55:55] | [all 2021-09-30 08:55:55] In file included from ./tm.h:27, [all 2021-09-30 08:55:55] from ../../gcc/gcc/genpreds.c:26: [all 2021-09-30 08:55:55] ../../gcc/gcc/config/gnu-user.h:117: note: this is the location of the previous definition [all 2021-09-30 08:55:55] 117 | #define LINK_GCC_C_SEQUENCE_SPEC GNU_USER_TARGET_LINK_GCC_C_SEQUENCE_SPEC [all 2021-09-30 08:55:55] | [all 2021-09-30 08:55:58] cc1plus: all warnings being treated as errors [all 2021-09-30 08:55:58] make[1]: *** [Makefile:2825: build/genpreds.o] Error 1 Easy fix, just undefine LINK_GCC_C_SEQUENCE_SPEC beforehand: gcc/ChangeLog: * config/lm32/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): Undefine before redefinition. Ok for trunk? Thanks, Jan-Benedict --
Comments
Hi, On Thu, 2021-09-30 21:34:51 +0200, Jan-Benedict Glaw <jbglaw@lug-owl.de> wrote: > gcc/ChangeLog: > > * config/lm32/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): > Undefine before redefinition. > > diff --git a/gcc/config/lm32/uclinux-elf.h b/gcc/config/lm32/uclinux-elf.h > index 370df4c55dd..5b638fa5db2 100644 > --- a/gcc/config/lm32/uclinux-elf.h > +++ b/gcc/config/lm32/uclinux-elf.h > @@ -67,6 +67,7 @@ > > #define TARGET_OS_CPP_BUILTINS() GNU_USER_TARGET_OS_CPP_BUILTINS() > > +#undef LINK_GCC_C_SEQUENCE_SPEC > #define LINK_GCC_C_SEQUENCE_SPEC \ > "%{static|static-pie:--start-group} %G %{!nolibc:%L} \ > %{static|static-pie:--end-group}%{!static:%{!static-pie:%G}}" > > Ok for trunk? ...and a ping for this patch. Thanks, Jan-Benedict --
On 10/5/2021 8:46 AM, Jan-Benedict Glaw wrote: > Hi, > > On Thu, 2021-09-30 21:34:51 +0200, Jan-Benedict Glaw <jbglaw@lug-owl.de> wrote: >> gcc/ChangeLog: >> >> * config/lm32/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): >> Undefine before redefinition. >> >> diff --git a/gcc/config/lm32/uclinux-elf.h b/gcc/config/lm32/uclinux-elf.h >> index 370df4c55dd..5b638fa5db2 100644 >> --- a/gcc/config/lm32/uclinux-elf.h >> +++ b/gcc/config/lm32/uclinux-elf.h >> @@ -67,6 +67,7 @@ >> >> #define TARGET_OS_CPP_BUILTINS() GNU_USER_TARGET_OS_CPP_BUILTINS() >> >> +#undef LINK_GCC_C_SEQUENCE_SPEC >> #define LINK_GCC_C_SEQUENCE_SPEC \ >> "%{static|static-pie:--start-group} %G %{!nolibc:%L} \ >> %{static|static-pie:--end-group}%{!static:%{!static-pie:%G}}" >> >> Ok for trunk? > ...and a ping for this patch. OK jeff
diff --git a/gcc/config/lm32/uclinux-elf.h b/gcc/config/lm32/uclinux-elf.h index 370df4c55dd..5b638fa5db2 100644 --- a/gcc/config/lm32/uclinux-elf.h +++ b/gcc/config/lm32/uclinux-elf.h @@ -67,6 +67,7 @@ #define TARGET_OS_CPP_BUILTINS() GNU_USER_TARGET_OS_CPP_BUILTINS() +#undef LINK_GCC_C_SEQUENCE_SPEC #define LINK_GCC_C_SEQUENCE_SPEC \ "%{static|static-pie:--start-group} %G %{!nolibc:%L} \ %{static|static-pie:--end-group}%{!static:%{!static-pie:%G}}"