summaryrefslogtreecommitdiffstats
path: root/meta-phosphor
diff options
context:
space:
mode:
authorJames Feist <james.feist@linux.intel.com>2018-11-20 11:29:16 -0800
committerBrad Bishop <bradleyb@fuzziesquirrel.com>2018-12-18 17:51:37 +0000
commit03bea90cdfa31cb77d58e69ebe8a8989b34a5208 (patch)
tree79c4746c93259bf760b267bcb5e68d004caf36c8 /meta-phosphor
parenta5ec2d98e9559542d40c63af8f4849a5696f9622 (diff)
downloadtalos-openbmc-03bea90cdfa31cb77d58e69ebe8a8989b34a5208.tar.gz
talos-openbmc-03bea90cdfa31cb77d58e69ebe8a8989b34a5208.zip
meta-phosphor: Create obmc-autotools to update AR and RANLIB
Many recipes are turning on -flto which causes issues with the linker when dealing with libraries. It was suggested here http://stackoverflow.com/questions/25878407/how-can-i-use-lto-with-static-libraries#comment67660913_25878408 to use the gcc wrappers to deal with this problem. Create flto-automake class as this seems like something that could be globally applied if needed. Tested-by: phosphor-pid-control began to build, saw no new build issues. (From meta-phosphor rev: ae3f085053fa2de4783d6f35a6b5f998743a130a) Change-Id: I3f682cf0fb70e266b544badb0223fa89306332db Signed-off-by: James Feist <james.feist@linux.intel.com> Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Diffstat (limited to 'meta-phosphor')
-rw-r--r--meta-phosphor/classes/flto-automake.bbclass6
-rw-r--r--meta-phosphor/recipes-phosphor/fans/phosphor-pid-control_git.bb2
2 files changed, 7 insertions, 1 deletions
diff --git a/meta-phosphor/classes/flto-automake.bbclass b/meta-phosphor/classes/flto-automake.bbclass
new file mode 100644
index 000000000..517bd5ea5
--- /dev/null
+++ b/meta-phosphor/classes/flto-automake.bbclass
@@ -0,0 +1,6 @@
+inherit autotools
+
+# use gcc equivalents of AR and RANLIB
+# to use -flto with shared libs
+PACKAGECONFIG_CONFARGS += " AR=${TARGET_PREFIX}gcc-ar \
+ RANLIB=${TARGET_PREFIX}gcc-ranlib"
diff --git a/meta-phosphor/recipes-phosphor/fans/phosphor-pid-control_git.bb b/meta-phosphor/recipes-phosphor/fans/phosphor-pid-control_git.bb
index ef0b5436a..8293c6137 100644
--- a/meta-phosphor/recipes-phosphor/fans/phosphor-pid-control_git.bb
+++ b/meta-phosphor/recipes-phosphor/fans/phosphor-pid-control_git.bb
@@ -6,7 +6,7 @@ PV = "0.1+git${SRCPV}"
LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://LICENSE;md5=86d3f3a95c324c9479bd8986968f4327"
-inherit autotools pkgconfig
+inherit flto-automake pkgconfig
inherit pythonnative
inherit phosphor-pid-control
OpenPOWER on IntegriCloud