[OE-core] [oe-core][PATCH 1/1] libtool: allow for use of reproducible_build bbclass

Joe Slater joe.slater at windriver.com
Thu Jul 11 20:27:39 UTC 2019


In a reproducible build environment, do not put the build host
name into libtool.

Signed-off-by: Joe Slater <joe.slater at windriver.com>
---
 .../libtool/libtool/reproducible_build.patch       | 29 ++++++++++++++++++++++
 meta/recipes-devtools/libtool/libtool_2.4.6.bb     |  2 +-
 2 files changed, 30 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-devtools/libtool/libtool/reproducible_build.patch

diff --git a/meta/recipes-devtools/libtool/libtool/reproducible_build.patch b/meta/recipes-devtools/libtool/libtool/reproducible_build.patch
new file mode 100644
index 0000000..c770c24
--- /dev/null
+++ b/meta/recipes-devtools/libtool/libtool/reproducible_build.patch
@@ -0,0 +1,29 @@
+libtool: allow for reproducible build
+
+If we are in a reproducible build environment, do not put the build host
+name into libtool.
+
+Upstream-Status: Inappropriate [embedded specific]
+
+Signed-off-by: Joe Slater <joe.slater at windriver.com>
+
+--- a/m4/libtool.m4
++++ b/m4/libtool.m4
+@@ -728,7 +728,17 @@ _LT_CONFIG_SAVE_COMMANDS([
+     cat <<_LT_EOF >> "$cfgfile"
+ #! $SHELL
+ # Generated automatically by $as_me ($PACKAGE) $VERSION
++_LT_EOF
++    if test -n "${SOURCE_DATE_EPOCH}"; then
++        cat <<_LT_EOF >> "$cfgfile"
++# Libtool was configured for a reproducible build: ${SOURCE_DATE_EPOCH}
++_LT_EOF
++    else
++        cat <<_LT_EOF >> "$cfgfile"
+ # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
++_LT_EOF
++    fi
++    cat <<_LT_EOF >> "$cfgfile"
+ # NOTE: Changes made to this file will be lost: look at ltmain.sh.
+ 
+ # Provide generalized library-building support services.
diff --git a/meta/recipes-devtools/libtool/libtool_2.4.6.bb b/meta/recipes-devtools/libtool/libtool_2.4.6.bb
index f5fdd00..a67d6dd 100644
--- a/meta/recipes-devtools/libtool/libtool_2.4.6.bb
+++ b/meta/recipes-devtools/libtool/libtool_2.4.6.bb
@@ -1,6 +1,6 @@
 require libtool-${PV}.inc
 
-SRC_URI += "file://multilib.patch"
+SRC_URI += "file://multilib.patch file://reproducible_build.patch"
 
 RDEPENDS_${PN} += "bash"
 
-- 
2.7.4



More information about the Openembedded-core mailing list