mirror of
https://github.com/openwrt/openwrt.git
synced 2026-10-12 06:57:57 +04:00
Configure stage without a cache against a warm cache: mtools 3.34 s -> 0.28 s gengetopt 4.39 s -> 2.13 s fakeroot 10.97 s -> 8.73 s xz 4.32 s -> 2.17 s libressl 3.07 s -> 1.46 s flex 12.32 s -> 10.98 s expat 2.74 s -> 1.52 s bc 1.34 s -> 0.38 s dosfstools 3.13 s -> 2.54 s libtool 2.86 s -> 2.29 s mtd-utils 4.06 s -> 3.56 s flex, fakeroot, dosfstools and mtd-utils run autoreconf in the same stage, and the cache does not reach that part. Each of the eleven configures the same way with a warm cache as it does without one: the check configures three times, without a cache, with a cold cache and with a warm cache, and every generated file of the first and the last run is identical. A static scan of each configure script found no cache check that changes CFLAGS, CPPFLAGS, LDFLAGS or LIBS without restoring it. patchelf, mklibs and automake pass the same check but gain less than half a second, so they stay out. make world after make tools/clean now takes 121 s against 177 s with cold caches. Signed-off-by: John Crispin <john@phrozen.org>
68 lines
1.5 KiB
Makefile
68 lines
1.5 KiB
Makefile
#
|
|
# Copyright (C) 2008-2015 OpenWrt.org
|
|
#
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
# See /LICENSE for more information.
|
|
#
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
PKG_NAME:=libtool
|
|
PKG_CPE_ID:=cpe:/a:gnu:libtool
|
|
PKG_VERSION:=2.5.4
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|
PKG_SOURCE_URL:=@GNU/$(PKG_NAME)
|
|
PKG_HASH:=da8ebb2ce4dcf46b90098daf962cffa68f4b4f62ea60f798d0ef12929ede6adf
|
|
|
|
HOST_BUILD_PARALLEL:=1
|
|
HOST_CONFIGURE_CACHE:=1
|
|
|
|
include $(INCLUDE_DIR)/host-build.mk
|
|
|
|
export GNULIB_SRCDIR:=$(HOST_GNULIB_SRCDIR)
|
|
|
|
HOST_CONFIGURE_VARS += \
|
|
lt_cv_sys_dlsearch_path=""
|
|
|
|
HOST_MAKE_FLAGS += \
|
|
am__CONFIG_DISTCLEAN_FILES= \
|
|
CONFIG_STATUS_DEPENDENCIES=
|
|
|
|
define Host/Bootstrap
|
|
( \
|
|
cd $(HOST_BUILD_DIR); \
|
|
$(AM_TOOL_PATHS) \
|
|
./bootstrap \
|
|
--copy \
|
|
--force \
|
|
--skip-git \
|
|
--skip-po \
|
|
--gnulib-srcdir=$(GNULIB_SRCDIR) \
|
|
)
|
|
endef
|
|
|
|
define Host/Prepare
|
|
$(call Host/Prepare/Default)
|
|
$(call Host/Uninstall)
|
|
$(if $(QUILT),,$(call Host/Bootstrap))
|
|
endef
|
|
|
|
define Host/Configure
|
|
$(if $(QUILT),$(call Host/Bootstrap))
|
|
$(call Host/Configure/Default)
|
|
$(call Host/Uninstall)
|
|
endef
|
|
|
|
define Host/Install
|
|
$(call Host/Compile/Default,install)
|
|
$(SED) 's,\(hardcode_into_libs\)=yes,\1=no,g' $(STAGING_DIR_HOST)/bin/libtool
|
|
endef
|
|
|
|
define Host/Uninstall
|
|
-$(call Host/Compile/Default,uninstall)
|
|
-$(call Host/Compile/Default,maintainer-clean) # Clean bootstrap files from the release
|
|
(cd $(STAGING_DIR_HOST)/share/aclocal/ && rm -f libtool.m4 ltdl.m4 lt~obsolete.m4 ltoptions.m4 ltsugar.m4 ltversion.m4)
|
|
endef
|
|
|
|
$(eval $(call HostBuild))
|