package/openmpi: fix build failure due to Gcc Bug 68485
authorGiulio Benetti <giulio.benetti@micronovasrl.com>
Thu, 30 May 2019 13:23:41 +0000 (15:23 +0200)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Fri, 31 May 2019 20:52:57 +0000 (22:52 +0200)
Package openmpi manifests Microblaze Gcc Bug 68485 resulting in a build
failure due to an Internal Compiler Error.

As done for other packages in Buildroot work around this Gcc Bug by
setting optimization to -O0 if BR2_TOOLCHAIN_HAS_GCC_BUG_68485=y.

Fixes:
http://autobuild.buildroot.net/results/8f3/8f334427e7475154d69469f8ee4efab6df80e403/

Signed-off-by: Giulio Benetti <giulio.benetti@micronovasrl.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/openmpi/openmpi.mk

index 8d9eafd6310ff5348f42343e0124d7d36e3ebfc9..b682e6e74e33456270239c261c58f131a1e5d4f4 100644 (file)
@@ -38,4 +38,12 @@ else
 OPENMPI_CONF_OPTS += --enable-mpi-fortran=no
 endif
 
+OPENMPI_CFLAGS = $(TARGET_CFLAGS)
+
+ifeq ($(BR2_TOOLCHAIN_HAS_GCC_BUG_68485),y)
+OPENMPI_CFLAGS += -O0
+endif
+
+OPENMPI_CONF_ENV = CFLAGS="$(OPENMPI_CFLAGS)"
+
 $(eval $(autotools-package))