From a94d74d9c875b4a1c07945bf9af282221d0178b3 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Sun, 13 Dec 2015 17:18:40 +0100 Subject: rework prereq check The new prereq check is completely implemented in POSIX shell in scripts/prereq.sh. It combines the old features from Makefile, scan-tools.sh, scan-pkgs.sh, reloc.sh and some wrappers for tools. The big benefit is to have all portability stuff in one place. Furthermore we can compile GNU make and bash on the fly, for systems lacking the required tools. All changes on the host are detected on the fly, no make prereq required anymore. The build process is separated in following three phases: 1. small wrapper Makefile is used for BSD make or GNU make 2. prereq.sh is called, doing all checking, calling Makefile.adk 3. old logic in Makefile.adk or mk/build.mk is used Tested successfully on Linux, MacOS X, Cygwin, FreeBSD, OpenBSD and NetBSD. An old depmaker bug was fixed, only optional host tools are compiled. For example, even when a host provides xz, a local xz was compiled in the past, because other packages had a build dependency on it. Signed-off-by: Waldemar Brodkorb --- package/pkgconf/Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'package/pkgconf/Makefile') diff --git a/package/pkgconf/Makefile b/package/pkgconf/Makefile index 0d0e123e6..47c2b7b78 100644 --- a/package/pkgconf/Makefile +++ b/package/pkgconf/Makefile @@ -9,6 +9,7 @@ PKG_RELEASE:= 1 PKG_HASH:= 8f5f48e52ddef0c3cbffe93f32d5148041e0030b8798b49b0b5fe72f4968d7ec PKG_DESCR:= smart pkg-config replacement PKG_SECTION:= dev/tools +HOST_BUILDDEP:= sed-host PKG_URL:= https://github.com/pkgconf/pkgconf PKG_SITES:= http://rabbit.dereferenced.org/~nenolod/distfiles/ @@ -23,9 +24,9 @@ $(eval $(call PKG_template,PKGCONF,pkgconf,$(PKG_VERSION)-${PKG_RELEASE},${PKG_D hostpost-install: $(CP) ./files/pkg-config $(STAGING_HOST_DIR)/usr/bin ifeq ($(ADK_TARGET_USE_STATIC_LIBS),y) - $(SED) "s#@@OPTS@@#--static#" $(STAGING_HOST_DIR)/usr/bin/pkg-config + PATH="$(HOST_PATH)" $(SED) "s#@@OPTS@@#--static#" $(STAGING_HOST_DIR)/usr/bin/pkg-config else - $(SED) "s#@@OPTS@@##" $(STAGING_HOST_DIR)/usr/bin/pkg-config + PATH="$(HOST_PATH)" $(SED) "s#@@OPTS@@##" $(STAGING_HOST_DIR)/usr/bin/pkg-config endif (cd $(STAGING_HOST_DIR)/usr/bin && ln -sf pkg-config $(GNU_TARGET_NAME)-pkg-config) -- cgit v1.2.3