summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2014-03-19 20:54:03 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2014-03-19 20:54:03 +0100
commitbcd130f15376964f63bd9f88c24d30ae3cb14432 (patch)
treee5baf8881985f5ef25dff77f4906d7df7b4597b9 /mk
parentefe4bb828100c6f13f0f51dd756aa7ed321ed184 (diff)
use separate WRKDIR for host packages to avoid rebuild problems in wrong order, findstring idea from tg
Diffstat (limited to 'mk')
-rw-r--r--mk/host-bottom.mk7
-rw-r--r--mk/host.mk9
2 files changed, 8 insertions, 8 deletions
diff --git a/mk/host-bottom.mk b/mk/host-bottom.mk
index 23d5652ba..19b43b081 100644
--- a/mk/host-bottom.mk
+++ b/mk/host-bottom.mk
@@ -79,6 +79,7 @@ hpkg-install: ${ALL_HOSTINST}
host-install:
${_HOST_FAKE_COOKIE}: ${_HOST_BUILD_COOKIE}
@$(CMD_TRACE) "host installing... "
+ @mkdir -p ${HOST_WRKINST}
ifneq (${HOST_STYLE},manual)
ifeq ($(strip ${HOST_STYLE}),)
cd ${WRKBUILD} && env ${HOST_MAKE_ENV} ${MAKE} -f ${MAKE_FILE} \
@@ -92,12 +93,6 @@ else
env ${HOST_MAKE_ENV} ${MAKE} hpkg-install $(MAKE_TRACE)
endif
env ${HOST_MAKE_ENV} ${MAKE} hostpost-install $(MAKE_TRACE)
- rm -rf ${WRKBUILD} ${WRKDIST} ${WRKSRC}
- exec ${MAKE} host-extract $(MAKE_TRACE)
- mkdir -p ${HOST_WRKINST}
- # avoid rebuild
- @touch ${_HOST_CONFIGURE_COOKIE}
- @touch ${_HOST_BUILD_COOKIE}
@touch $@
${_HOST_COOKIE}:
diff --git a/mk/host.mk b/mk/host.mk
index aa88bab44..ce41a7d7d 100644
--- a/mk/host.mk
+++ b/mk/host.mk
@@ -1,6 +1,11 @@
# This file is part of the OpenADK project. OpenADK is copyrighted
# material, please see the LICENCE file in the top-level directory.
+# This is where all package operation is done in
+ifneq (,$(findstring hostpackage,$(MAKECMDGOALS)))
+WRKDIR?= ${WRKDIR_BASE}/w-${PKG_NAME}-${PKG_VERSION}-${PKG_RELEASE}-host
+endif
+
HOST_CONFIGURE_ENV+= AUTOM4TE=${STAGING_HOST_DIR}/usr/bin/autom4te \
CONFIG_SHELL='$(strip ${SHELL})' \
PKG_CONFIG_LIBDIR='${STAGING_HOST_DIR}/usr/lib/pkgconfig' \
@@ -30,7 +35,7 @@ HOST_MAKE_ENV+= PATH='${HOST_PATH}' \
HOST_MAKE_FLAGS+= ${HOST_XAKE_FLAGS} V=1
HOST_FAKE_FLAGS+= ${HOST_XAKE_FLAGS}
-HOST_WRKINST= ${WRKDIR}/host
+HOST_WRKINST= ${WRKDIR}/fake
_HOST_EXTRACT_COOKIE= ${WRKDIST}/.extract_done
_HOST_PATCH_COOKIE= ${WRKDIST}/.prepared
@@ -54,7 +59,7 @@ hostfake: ${_HOST_FAKE_COOKIE}
define HOST_template
ALL_PKGOPTS+= $(1)
PKGNAME_$(1)= $(2)
-HOSTDIR_$(1)= $(WRKDIR)/host
+HOSTDIR_$(1)= $(WRKDIR)/fake
ALL_HOSTDIRS+= $${HOSTDIR_$(1)}
ALL_HOSTINST+= $(2)-hostinstall