]> git.ipfire.org Git - ipfire-2.x.git/commitdiff
toolchain: fix build with gcc<8 on builder.
authorArne Fitzenreiter <arne_f@ipfire.org>
Thu, 24 Sep 2020 05:36:01 +0000 (07:36 +0200)
committerArne Fitzenreiter <arne_f@ipfire.org>
Thu, 24 Sep 2020 05:36:01 +0000 (07:36 +0200)
gcc-7 not support -fcf-protection so filter it from CFLAGS.
also filter -mtune in first pass because it should optimized for the
actual host.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
lfs/binutils
lfs/ccache
lfs/gcc
lfs/glibc

index 334adad25891459f58e4c62cb58daaced4c0118b..6db2e990f07e1269e804ffe2dec331272d2352d3 100644 (file)
@@ -51,6 +51,8 @@ ifeq "$(PASS)" "1"
   CFLAGS := $(patsubst -mfloat-abi=%,,$(CFLAGS))
   CFLAGS := $(patsubst -mindirect-branch=%,,$(CFLAGS))
   CFLAGS := $(patsubst -mfunction-return=%,,$(CFLAGS))
+  CFLAGS := $(patsubst -fstack-clash-protection,,$(CFLAGS))
+  CFLAGS := $(patsubst -fcf-protection,,$(CFLAGS))
 
   TARGET = $(DIR_INFO)/$(THISAPP)-tools1
   EXTRA_CONFIG = \
index 94d7bd149e5383c76186993d699ab3531dbd6e6f..1361f3ed07a58783845db13eeab713c3b5de2cc3 100644 (file)
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2018  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2020  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -34,10 +34,13 @@ TARGET     = $(DIR_INFO)/$(THISAPP)-pass$(PASS)
 
 ifeq "$(PASS)" "1"
        CFLAGS := $(patsubst -march=%,,$(CFLAGS))
+       CFLAGS := $(patsubst -mtune=%,,$(CFLAGS))
        CFLAGS := $(patsubst -mfpu=%,,$(CFLAGS))
        CFLAGS := $(patsubst -mfloat-abi=%,,$(CFLAGS))
        CFLAGS := $(patsubst -mindirect-branch=%,,$(CFLAGS))
        CFLAGS := $(patsubst -mfunction-return=%,,$(CFLAGS))
+       CFLAGS := $(patsubst -fstack-clash-protection,,$(CFLAGS))
+       CFLAGS := $(patsubst -fcf-protection,,$(CFLAGS))
 endif
 
 ###############################################################################
diff --git a/lfs/gcc b/lfs/gcc
index 7cbc8e9e84e112063ebeab553220a3964a7a5371..3aa147ce813247da7cc0af876064ca13c67165ae 100644 (file)
--- a/lfs/gcc
+++ b/lfs/gcc
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2018  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2020  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -44,6 +44,8 @@ CFLAGS    := $(filter-out -fexceptions,$(CFLAGS))
 ifeq "$(PASS)" "1"
 CFLAGS    := $(patsubst -mindirect-branch=%,,$(CFLAGS))
 CFLAGS    := $(patsubst -mfunction-return=%,,$(CFLAGS))
+CFLAGS    := $(patsubst -fstack-clash-protection,,$(CFLAGS))
+CFLAGS    := $(patsubst -fcf-protection,,$(CFLAGS))
 endif
 
 CXXFLAGS  := $(CFLAGS)
index 802c372a904bf283fe2d3bd26b220d058b7fa2fe..281c290dcd2b7d92d14138ff57cc45c8c60351b2 100644 (file)
--- a/lfs/glibc
+++ b/lfs/glibc
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2018  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2020  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #