[OpenWrt-Devel] [PATCH] tools: add autoconf-archive

Karel Kočí citrisin at gmail.com
Wed Apr 29 06:47:58 EDT 2020

Some autotools based build systems are using autoconf-archive scripts
and are expecting them to almost always be available. This is not
required for regular releases as tar balls generated for releases
commonly have existing configure script. This is rather intended to be
used with autotools.mk's autoreconf and in cases it is not always
possible to get release tar ball.

Including this adds little to no overhead in terms of build time as
those are just m4 scripts copied to an appropriate location.

Signed-off-by: Karel Kočí <karel.koci at nic.cz>
 tools/Makefile                  |  2 +-
 tools/autoconf-archive/Makefile | 28 ++++++++++++++++++++++++++++
 2 files changed, 29 insertions(+), 1 deletion(-)
 create mode 100644 tools/autoconf-archive/Makefile

diff --git a/tools/Makefile b/tools/Makefile
index 02556d4b83..aaaef95046 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -22,7 +22,7 @@ ifneq ($(CONFIG_SDK)$(CONFIG_PACKAGE_kmod-b43)$(CONFIG_PACKAGE_b43legacy-firmwar
 tools-$(BUILD_TOOLCHAIN) += gmp mpfr mpc libelf expat
-tools-y += m4 libtool autoconf automake flex bison pkgconf mklibs zlib
+tools-y += m4 libtool autoconf autoconf-archive automake flex bison pkgconf mklibs zlib
 tools-y += sstrip make-ext4fs e2fsprogs mtd-utils mkimage
 tools-y += firmware-utils patch-image quilt padjffs2
 tools-y += mm-macros missing-macros cmake bc findutils gengetopt patchelf
diff --git a/tools/autoconf-archive/Makefile b/tools/autoconf-archive/Makefile
new file mode 100644
index 0000000000..b3d729f41d
--- /dev/null
+++ b/tools/autoconf-archive/Makefile
@@ -0,0 +1,28 @@
+include $(TOPDIR)/rules.mk
+include $(INCLUDE_DIR)/host-build.mk
+	--datarootdir=$(STAGING_DIR_HOST)/share
+define Host/Compile
+	export SHELL="$(BASH)"; $(MAKE) -C $(HOST_BUILD_DIR)
+define Host/Install
+	export SHELL="$(BASH)"; $(MAKE) -C $(HOST_BUILD_DIR) install
+define Host/Clean
+	-export SHELL="$(BASH)"; $(MAKE) -C $(HOST_BUILD_DIR) uninstall
+	$(call Host/Clean/Default)
+$(eval $(call HostBuild))

openwrt-devel mailing list
openwrt-devel at lists.openwrt.org

More information about the openwrt-devel mailing list