summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
Diffstat (limited to 'mk')
-rw-r--r--mk/build.mk31
-rw-r--r--mk/buildhlp.mk5
-rw-r--r--mk/host-bottom.mk39
-rw-r--r--mk/host.mk5
4 files changed, 41 insertions, 39 deletions
diff --git a/mk/build.mk b/mk/build.mk
index f784c99db..b44247005 100644
--- a/mk/build.mk
+++ b/mk/build.mk
@@ -18,13 +18,9 @@ DEFCONFIG= ADK_DEBUG=n \
ADK_SIMPLE_NETWORK_CONFIG=n \
ADK_USE_CCACHE=n \
ADK_TOOLCHAIN_GDB=n \
- ADK_PACKAGE_LIBAU=n \
ADK_PACKAGE_E2FSCK_STATIC=n \
- ADK_PACKAGE_AUFS2_UTIL=n \
ADK_PACKAGE_KEXECINIT=n \
ADK_PACKAGE_INSTALLER=n \
- ADK_PACKAGE_CXXTOOLS_DEV=n \
- ADK_PACKAGE_XORG_SERVER_DEV=n \
ADK_PACKAGE_LM_SENSORS_DETECT=n \
ADK_PACKAGE_PACEMAKER=n \
ADK_PACKAGE_PACEMAKER_MGMTD=n \
@@ -37,20 +33,14 @@ DEFCONFIG= ADK_DEBUG=n \
ADK_PACKAGE_GRUB=n \
ADK_PACKAGE_BASE_FILES=y \
ADK_PACKAGE_CRYPTINIT=n \
- ADK_PACKAGE_HEIMDAL_SERVER=n \
- ADK_PACKAGE_LIBHEIMDAL=n \
ADK_PACKAGE_PAM=n \
- ADK_PACKAGE_PYTHON=n \
ADK_PACKAGE_VIRTINST=n \
ADK_PACKAGE_URLGRABBER=n \
ADK_PACKAGE_PERL=n \
ADK_PACKAGE_LIBSSP=n \
- ADK_PKG_DESKTOP=n \
- ADK_PKG_LAPTOP=n \
+ ADK_PKG_XORG=n \
ADK_PKG_MPDBOX=n \
ADK_PKG_DEVELOPMENT=n \
- ADK_PKG_VPN_CLIENT=n \
- ADK_PKG_VPN_SERVER=n \
ADK_TOOLCHAIN_GCC_JAVA=n \
ADK_TOOLCHAIN_GCC_OBJC=n \
ADK_TOOLCHAIN_GCC_USE_SSP=n \
@@ -569,8 +559,9 @@ bulktoolchain:
$(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then touch .exit;fi; \
rm .config; \
) 2>&1 | tee $(TOPDIR)/bin/toolchain_$${arch}_$${libc}/build.log; \
- if [ -f .exit ];then echo "Bulk build failed!"; rm .exit; exit 1;fi \
+ if [ -f .exit ];then break;fi \
done <${TOPDIR}/target/tarch.lst ;\
+ if [ -f .exit ];then echo "Bulk build failed!"; rm .exit; exit 1;fi \
done
# build all target architecture, target systems and libc combinations
@@ -584,12 +575,14 @@ bulk:
echo === building $$arch $$system $$libc on $$(date); \
$(GMAKE) prereq && \
$(GMAKE) ARCH=$$arch SYSTEM=$$system LIBC=$$libc FS=archive defconfig; \
- $(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then touch .exit;fi; \
+ $(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then touch .exit; exit 1;fi; \
rm .config; \
) 2>&1 | tee $(TOPDIR)/bin/$${system}_$${arch}_$$libc/build.log; \
+ if [ -f .exit ]; then break;fi \
done; \
- if [ -f .exit ];then echo "Bulk build failed!"; rm .exit; exit 1;fi \
+ if [ -f .exit ]; then break;fi \
done <${TOPDIR}/target/arch.lst ;\
+ if [ -f .exit ];then echo "Bulk build failed!"; rm .exit; exit 1;fi \
done
bulkall:
@@ -602,12 +595,14 @@ bulkall:
echo === building $$arch $$system $$libc on $$(date); \
$(GMAKE) prereq && \
$(GMAKE) ARCH=$$arch SYSTEM=$$system LIBC=$$libc FS=archive allconfig; \
- $(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then touch .exit;fi; \
+ $(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then touch .exit; exit 1;fi; \
rm .config; \
) 2>&1 | tee $(TOPDIR)/bin/$${system}_$${arch}_$$libc/build.log; \
+ if [ -f .exit ]; then break;fi \
done; \
- if [ -f .exit ];then echo "Bulk build failed!"; rm .exit; exit 1;fi \
+ if [ -f .exit ]; then break;fi \
done <${TOPDIR}/target/arch.lst ;\
+ if [ -f .exit ];then echo "Bulk build failed!"; rm .exit; exit 1;fi \
done
bulkallmod:
@@ -623,9 +618,11 @@ bulkallmod:
$(GMAKE) VERBOSE=1 all; if [ $$? -ne 0 ]; then echo $$system-$$libc >.exit; exit 1;fi; \
rm .config; \
) 2>&1 | tee $(TOPDIR)/bin/$${system}_$${arch}_$$libc/build.log; \
+ if [ -f .exit ]; then break;fi \
done; \
- if [ -f .exit ];then echo "Bulk build failed!"; cat .exit;rm .exit; exit 1;fi \
+ if [ -f .exit ]; then break;fi \
done <${TOPDIR}/target/arch.lst ;\
+ if [ -f .exit ];then echo "Bulk build failed!"; cat .exit;rm .exit; exit 1;fi \
done
${TOPDIR}/bin/tools/pkgmaker: $(TOPDIR)/tools/adk/pkgmaker.c $(TOPDIR)/tools/adk/sortfile.c $(TOPDIR)/tools/adk/strmap.c
diff --git a/mk/buildhlp.mk b/mk/buildhlp.mk
index 41f09d946..79014ac4b 100644
--- a/mk/buildhlp.mk
+++ b/mk/buildhlp.mk
@@ -93,8 +93,9 @@ ifeq ($(strip ${_IN_PACKAGE})$(strip ${_IN_CVTC}),1)
else
@$(MAKE) -s V=0 prepare WRKDIR=${WRKDIR}.orig PREVENT_PATCH=: NO_CHECKSUM=1
endif
- @-test -r ${WRKDIR}/.autoreconf_done && \
- (cd ${WRKDIR}.orig/${PKG_NAME}-${PKG_VERSION}; \
+ @-test ! -r ${WRKDIR}/.autoreconf_done || \
+ (wrkdist=$(WRKDIST) dir=$${wrkdist#$(WRKDIR)}; \
+ cd ${WRKDIR}.orig$${dir}; \
env ${AUTOTOOL_ENV} autoreconf -if) $(MAKE_TRACE)
@rm -rf ${WRKDIR}.orig/${PKG_NAME}-${PKG_VERSION}/autom4te.cache
@# restore config.sub/config.guess
diff --git a/mk/host-bottom.mk b/mk/host-bottom.mk
index 327883a95..83eb22b0e 100644
--- a/mk/host-bottom.mk
+++ b/mk/host-bottom.mk
@@ -20,36 +20,35 @@ ${_HOST_CONFIGURE_COOKIE}: ${_HOST_PATCH_COOKIE}
${CP} ${SCRIPT_DIR}/config.guess $$i; \
fi; \
done;
-ifneq ($(filter auto,${HOST_STYLE}),)
+ifeq ($(strip ${HOST_STYLE}),)
cd ${WRKBUILD}; rm -f config.{cache,status}; \
env ${HOST_CONFIGURE_ENV} \
${BASH} ${WRKSRC}/${CONFIGURE_PROG} \
--program-prefix= \
--program-suffix= \
- --prefix=${STAGING_HOST_DIR}/usr \
- --bindir=${STAGING_HOST_DIR}/usr/bin \
- --datadir=${STAGING_HOST_DIR}/usr/share \
- --mandir=${STAGING_HOST_DIR}/usr/share/man \
- --libexecdir=${STAGING_HOST_DIR}/usr/libexec \
- --sysconfdir=${STAGING_HOST_DIR}/etc \
+ --prefix=/usr \
+ --bindir=/usr/bin \
+ --datadir=/usr/share \
+ --mandir=/usr/share/man \
+ --libexecdir=/usr/libexec \
+ --localstatedir=/var \
+ --sysconfdir=/etc \
--disable-dependency-tracking \
--disable-libtool-lock \
--disable-nls \
${HOST_CONFIGURE_ARGS} $(MAKE_TRACE)
-
else
cd ${WRKBUILD}; rm -f config.{cache,status}; \
env ${HOST_CONFIGURE_ENV} \
${BASH} ${WRKSRC}/${CONFIGURE_PROG} \
--program-prefix= \
--program-suffix= \
- --prefix=/usr \
- --bindir=/usr/bin \
- --datadir=/usr/share \
- --mandir=/usr/share/man \
- --libexecdir=/usr/libexec \
- --localstatedir=/var \
- --sysconfdir=/etc \
+ --prefix=${STAGING_HOST_DIR}/usr \
+ --bindir=${STAGING_HOST_DIR}/usr/bin \
+ --datadir=${STAGING_HOST_DIR}/usr/share \
+ --mandir=${STAGING_HOST_DIR}/usr/share/man \
+ --libexecdir=${STAGING_HOST_DIR}/usr/libexec \
+ --sysconfdir=${STAGING_HOST_DIR}/etc \
--disable-dependency-tracking \
--disable-libtool-lock \
--disable-nls \
@@ -68,20 +67,20 @@ hpkg-install: ${ALL_HOSTINST}
host-install:
${_HOST_FAKE_COOKIE}: ${_HOST_BUILD_COOKIE}
@$(CMD_TRACE) "host installing... "
-ifneq ($(filter auto,${HOST_STYLE}),)
- cd ${WRKBUILD} && env ${HOST_MAKE_ENV} ${MAKE} -f ${MAKE_FILE} \
- DESTDIR='' ${HOST_FAKE_FLAGS} ${HOST_INSTALL_TARGET} $(MAKE_TRACE)
-else
+ifeq ($(strip ${HOST_STYLE}),)
cd ${WRKBUILD} && env ${HOST_MAKE_ENV} ${MAKE} -f ${MAKE_FILE} \
DESTDIR='${HOST_WRKINST}' ${HOST_FAKE_FLAGS} ${HOST_INSTALL_TARGET} $(MAKE_TRACE)
env ${HOST_MAKE_ENV} ${MAKE} hpkg-install $(MAKE_TRACE)
+else
+ cd ${WRKBUILD} && env ${HOST_MAKE_ENV} ${MAKE} -f ${MAKE_FILE} \
+ DESTDIR='' ${HOST_FAKE_FLAGS} ${HOST_INSTALL_TARGET} $(MAKE_TRACE)
endif
rm -rf ${WRKBUILD} ${WRKDIST} ${WRKSRC}
exec ${MAKE} host-extract $(MAKE_TRACE)
mkdir -p ${HOST_WRKINST}
- touch $@
# avoid rebuild
touch ${_HOST_BUILD_COOKIE} ${_HOST_CONFIGURE_COOKIE}
+ touch $@
${_HOST_COOKIE}:
exec ${MAKE} hostpackage
diff --git a/mk/host.mk b/mk/host.mk
index 855adf0d1..619ec140e 100644
--- a/mk/host.mk
+++ b/mk/host.mk
@@ -20,6 +20,11 @@ HOST_FAKE_FLAGS?=
HOST_ALL_TARGET?= all
HOST_INSTALL_TARGET?= install
+HOST_MAKE_ENV+= PATH='${TARGET_PATH}' \
+ CFLAGS='$(strip ${CFLAGS_FOR_BUILD})' \
+ CXXFLAGS='$(strip ${CXXFLAGS_FOR_BUILD})' \
+ CPPFLAGS='$(strip ${CPPFLAGS_FOR_BUILD})' \
+ LDFLAGS='$(strip ${LDFLAGS_FOR_BUILD})'
HOST_MAKE_FLAGS+= ${HOST_XAKE_FLAGS} V=1
HOST_FAKE_FLAGS+= ${HOST_XAKE_FLAGS}