summaryrefslogtreecommitdiff
path: root/package/binutils
diff options
context:
space:
mode:
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>2016-07-05 11:46:59 +0200
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2016-07-05 15:04:29 +0200
commitde4b45d5e70dd5d2431b0f44aeda60b033ecff11 (patch)
treedc26ac9d7d30b4bb819bca7f9a3af61fed87d5fb /package/binutils
parentc30bd14901e35303bfaeba65441d8bfadd206abf (diff)
binutils: fix build of 2.26 when makeinfo is not available
The 2.26 binutils tarball has incorrect timestamps for the .info files, so binutils build system tries to regenerate them with makeinfo. In order to avoid depending on host-texinfo, we simply touch the .info files so that their timestamp is newer than the corresponding source files. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Reviewed-by: Romain Naour <romain.naour@gmail.com> Tested-by: Romain Naour <romain.naour@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/binutils')
-rw-r--r--package/binutils/binutils.mk11
1 files changed, 11 insertions, 0 deletions
diff --git a/package/binutils/binutils.mk b/package/binutils/binutils.mk
index 33aaf85fb..50a353118 100644
--- a/package/binutils/binutils.mk
+++ b/package/binutils/binutils.mk
@@ -33,6 +33,17 @@ BINUTILS_DEPENDENCIES += host-flex host-bison host-texinfo
HOST_BINUTILS_DEPENDENCIES += host-flex host-bison host-texinfo
endif
+# The .info files in the 2.26 tarball have an incorrect timestamp, so
+# binutils tries to re-generate them. In order to avoid the dependency
+# on host-texinfo, we simply update the timestamps.
+ifeq ($(BR2_BINUTILS_VERSION_2_26_X),y)
+define BINUTILS_FIXUP_INFO_TIMESTAMPS
+ find $(@D) -name '*.info' -exec touch {} \;
+endef
+BINUTILS_POST_PATCH_HOOKS += BINUTILS_FIXUP_INFO_TIMESTAMPS
+HOST_BINUTILS_POST_PATCH_HOOKS += BINUTILS_FIXUP_INFO_TIMESTAMPS
+endif
+
# When binutils sources are fetched from the binutils-gdb repository,
# they also contain the gdb sources, but gdb shouldn't be built, so we
# disable it.