summaryrefslogtreecommitdiffstats
path: root/openpower/package/hostboot-p8/0010-Use-std-gnu-03-for-host-g-invocations.patch
diff options
context:
space:
mode:
authorStewart Smith <stewart@linux.vnet.ibm.com>2017-02-17 14:57:57 +1100
committerStewart Smith <stewart@linux.ibm.com>2018-05-02 00:29:03 -0500
commit03671c06d119a673e14d290f0785deb148cd83fd (patch)
tree30e1b74673ba040cff3cffa937a0b16fb5808b77 /openpower/package/hostboot-p8/0010-Use-std-gnu-03-for-host-g-invocations.patch
parent9307e07318cbdfb104118bf4dca1c174a3e8368b (diff)
downloadblackbird-op-build-03671c06d119a673e14d290f0785deb148cd83fd.tar.gz
blackbird-op-build-03671c06d119a673e14d290f0785deb148cd83fd.zip
Split P8 and P9 Hostboot and OCC packages
This was causing a couple of issues: 1) increased complexity in build files 2) It breaks the pkg-version patch detection/checksum 3) Failing to apply patches to would silently fail The split makes this a bit easier and requires less custom code. We keep the P9 hostboot/occ named hostboot/occ, so that day-to-day, nobody notices a difference. The only difference you'll notice is if doing POWER8 hostboot/occ development, as the package name will be 'hostboot-p8' or 'occ-p8'. Fixes: https://github.com/open-power/op-build/issues/876 Fixes: https://github.com/open-power/op-build/issues/1194 Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'openpower/package/hostboot-p8/0010-Use-std-gnu-03-for-host-g-invocations.patch')
-rw-r--r--openpower/package/hostboot-p8/0010-Use-std-gnu-03-for-host-g-invocations.patch69
1 files changed, 69 insertions, 0 deletions
diff --git a/openpower/package/hostboot-p8/0010-Use-std-gnu-03-for-host-g-invocations.patch b/openpower/package/hostboot-p8/0010-Use-std-gnu-03-for-host-g-invocations.patch
new file mode 100644
index 00000000..a9cef3f6
--- /dev/null
+++ b/openpower/package/hostboot-p8/0010-Use-std-gnu-03-for-host-g-invocations.patch
@@ -0,0 +1,69 @@
+From 9852975319c864b47759cc8d7814bf6f9f0f1f4c Mon Sep 17 00:00:00 2001
+From: Stewart Smith <stewart@linux.vnet.ibm.com>
+Date: Thu, 3 Nov 2016 14:36:19 +1100
+Subject: [PATCH 10/10] Use -std=gnu++03 for host g++ invocations
+
+Seeing as the ancient GCC on RHEL6 doesn't actually support -std=gnu++03
+we have to go through some hoops to detect it (we use the same magic
+Make as we use in skiboot to do the same)
+
+Change-Id: I338560ae2ebdac842c8055c07519d542564c3923
+Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
+---
+ src/usr/hwpf/makefile | 16 ++++++++++++----
+ 1 file changed, 12 insertions(+), 4 deletions(-)
+
+diff --git a/src/usr/hwpf/makefile b/src/usr/hwpf/makefile
+index 8d0bb72..ee8cf13 100644
+--- a/src/usr/hwpf/makefile
++++ b/src/usr/hwpf/makefile
+@@ -5,7 +5,7 @@
+ #
+ # OpenPOWER HostBoot Project
+ #
+-# Contributors Listed Below - COPYRIGHT 2011,2015
++# Contributors Listed Below - COPYRIGHT 2011,2016
+ # [+] International Business Machines Corp.
+ #
+ #
+@@ -402,18 +402,26 @@ $(call GENTARGET, ${IF_CMP_FLEX_TARGET}) : \
+ $(C2) " FLEX $(notdir $<)"
+ $(C1)flex -o$@ $^
+
++try = $(shell set -e; if ($(1)) >/dev/null 2>&1; \
++ then echo "$(2)"; \
++ else echo "$(3)"; fi )
++
++try-cflag = $(call try,$(1) $(2) -x c -c /dev/null -o /dev/null,$(2))
++HOSTCFLAGS:=-O3
++HOSTCFLAGS+=$(call try-cflag,$(HOST_PREFIX)g++,-std=gnu++03)
++
+ $(GENDIR)/$(IF_CMP_SUBDIR)/%.host.o: \
+ ifcompiler/%.C $(IF_COMPILER_H_FILES) \
+ $(GENDIR)/$(IF_CMP_YACC_H_TARGET)
+ $(C2) " CXX $(notdir $<)"
+- $(C1)$(CCACHE) $(HOST_PREFIX)g++ -O3 $< -I ifcompiler -I $(GENDIR) \
++ $(C1)$(CCACHE) $(HOST_PREFIX)g++ $(HOSTCFLAGS) $< -I ifcompiler -I $(GENDIR) \
+ -I $(GENDIR)/$(IF_CMP_SUBDIR) \
+ -I $(ROOTPATH)/src/include/usr/hwpf/hwp -c -o $@
+
+ $(GENDIR)/$(IF_CMP_YACC_C_TARGET:.c=.host.o): \
+ $(GENDIR)/$(IF_CMP_YACC_C_TARGET) $(IF_COMPILER_H_FILES)
+ $(C2) " CXX $(notdir $<)"
+- $(C1)$(CCACHE) $(HOST_PREFIX)g++ -O3 $< -I ifcompiler -I $(GENDIR) \
++ $(C1)$(CCACHE) $(HOST_PREFIX)g++ $(HOSTCFLAGS) $< -I ifcompiler -I $(GENDIR) \
+ -I $(GENDIR)/$(IF_CMP_SUBDIR) \
+ -I $(ROOTPATH)/src/include/usr/hwpf/hwp -c -o $@
+
+@@ -421,7 +429,7 @@ $(GENDIR)/$(IF_CMP_FLEX_TARGET:.c=.host.o): \
+ $(GENDIR)/$(IF_CMP_FLEX_TARGET) $(IF_COMPILER_H_FILES) \
+ $(GENDIR)/$(IF_CMP_YACC_H_TARGET)
+ $(C2) " CXX $(notdir $<)"
+- $(C1)$(CCACHE) $(HOST_PREFIX)g++ -O3 -DHOSTBOOT_COMPILE $< -I ifcompiler -I $(GENDIR) \
++ $(C1)$(CCACHE) $(HOST_PREFIX)g++ $(HOSTCFLAGS) -DHOSTBOOT_COMPILE $< -I ifcompiler -I $(GENDIR) \
+ -I $(GENDIR)/$(IF_CMP_SUBDIR) \
+ -I $(ROOTPATH)/src/include/usr/hwpf/hwp -c -o $@
+
+--
+2.7.4
+
OpenPOWER on IntegriCloud