summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Kemper2017-12-05 20:05:53 +0000
committerSebastian Kemper2017-12-05 20:12:12 +0000
commit22ac754cc39d692a163d299ce8d8f21abcb11c29 (patch)
treefd06f02dc0fb96744fbb8ebf7096cd7a57b9dca7
parent6c8eaf8f01f8fa819d83ba638819eb0bd9225362 (diff)
downloadtelephony-22ac754cc39d692a163d299ce8d8f21abcb11c29.tar.gz
asterisk-13.x: workaround for build failure
On the buildbots (and locally, too) the x86 builds currently fail. It's visible that the Asterisk build system attempts to build menuselect a second time, which fails because it follows the standard recipes in its Makefiles. The first build of menuselect on the other hand only works because the OpenWrt package sets up the build properly. The second build attempt happens because the menuselect CFLAGS category is setup to delete a stamp file when anything in it changes. On x86 -march=native is available, so the OpenWrt package disables that via menuselect, hence this item in the category is changed and the stamp file automatically removed. The missing stamp file triggers a rebuild of menuselect (which is not required for OpenWrt's intents and purposes). Another item in the CFLAGS category with which the package can have the same issue is LOW_MEMORY, but that is not enabled (changed) by default. Work around this problem by recreating the stamp file after the menuselect calls. Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
-rw-r--r--net/asterisk-13.x/Makefile7
1 files changed, 7 insertions, 0 deletions
diff --git a/net/asterisk-13.x/Makefile b/net/asterisk-13.x/Makefile
index a8376f8..78a9194 100644
--- a/net/asterisk-13.x/Makefile
+++ b/net/asterisk-13.x/Makefile
@@ -413,6 +413,13 @@ define Build/Compile
--disable BUILD_NATIVE \
$(if $(CONFIG_ASTERISK13_LOW_MEMORY),--enable LOW_MEMORY) \
menuselect.makeopts
+ # Hack:
+ # When changing anything in MENUSELECT_CFLAGS the file ".lastclean"
+ # gets deleted. E.g. when compiling on x86 for x86 "--disable
+ # BUILD_NATIVE" changes MENUSELECT_CFLAGS and the file gets removed.
+ # But that will result in a rebuild attempt of menuselect which will
+ # likely fail. Prevent that by recreating ".lastclean".
+ $(CP) "$(PKG_BUILD_DIR)/.cleancount" "$(PKG_BUILD_DIR)/.lastclean"
$(call Build/Compile/Default,all install samples)
endef