diff options
author | Waldemar Brodkorb <wbx@openadk.org> | 2013-10-24 14:59:22 +0200 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2013-10-24 14:59:22 +0200 |
commit | d1ee3be7f4b966174d673876f961b44e37b4c85a (patch) | |
tree | d1dca9d3273dcf9eae0a72355b101bce1f1c9060 /mk/host.mk | |
parent | f082cffba0eac8316ec58164ee215e75c8a364ed (diff) |
add host build infrastructure; convert file, ncurses, glib and ruby to it. remove unneeded hacks for openldap and mesalib
Diffstat (limited to 'mk/host.mk')
-rw-r--r-- | mk/host.mk | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/mk/host.mk b/mk/host.mk new file mode 100644 index 000000000..f9326da17 --- /dev/null +++ b/mk/host.mk @@ -0,0 +1,56 @@ +# This file is part of the OpenADK project. OpenADK is copyrighted +# material, please see the LICENCE file in the top-level directory. + +HOST_CONFIGURE_ENV+= CONFIG_SHELL='$(strip ${SHELL})' \ + CFLAGS='$(strip ${CFLAGS_FOR_BUILD})' \ + CXXFLAGS='$(strip ${CXXFLAGS_FOR_BUILD})' \ + CPPFLAGS='$(strip ${CPPFLAGS_FOR_BUILD})' \ + LDFLAGS='$(strip ${LDFLAGS_FOR_BUILD})' + +# this is environment for 'make all' and 'make install' +HOST_MAKE_ENV?= +# this is arguments for 'make all' and 'make install' +HOST_XAKE_FLAGS?= +# this is arguments for 'make all' ONLY +HOST_MAKE_FLAGS?= +# this is arguments for 'make install' ONLY +HOST_FAKE_FLAGS?= +HOST_ALL_TARGET?= all +HOST_INSTALL_TARGET?= install + +HOST_MAKE_FLAGS+= ${HOST_XAKE_FLAGS} V=1 +HOST_FAKE_FLAGS+= ${HOST_XAKE_FLAGS} + +HOST_WRKINST= ${WRKDIR}/host + +_HOST_EXTRACT_COOKIE= ${WRKDIST}/.extract_done +_HOST_PATCH_COOKIE= ${WRKDIST}/.prepared +_HOST_CONFIGURE_COOKIE= ${WRKBUILD}/.host_configure_done +_HOST_BUILD_COOKIE= ${WRKBUILD}/.host_build_done +_HOST_FAKE_COOKIE= ${HOST_WRKINST}/.host_fake_done +_HOST_COOKIE= ${PACKAGE_DIR}/.stamps/${PKG_NAME}${PKG_VERSION}-${PKG_RELEASE}-host + +hostextract: ${_HOST_EXTRACT_COOKIE} +hostpatch: ${_HOST_PATCH_COOKIE} +hostconfigure: ${_HOST_CONFIGURE_COOKIE} +hostbuild: ${_HOST_BUILD_COOKIE} +hostfake: ${_HOST_FAKE_COOKIE} + +# there are some parameters to the HOST_template function +# 1.) Config.in identifier ADK_PACKAGE_$(1) +# 2.) name of the package, for single package mostly $(PKG_NAME) +# 3.) package version (upstream version) and package release (adk version), +# always $(PKG_VERSION)-$(PKG_RELEASE) + +define HOST_template +ALL_PKGOPTS+= $(1) +PKGNAME_$(1)= $(2) +HOSTDIR_$(1)= $(WRKDIR)/host +ifneq (${ADK_PACKAGE_$(1)}${DEVELOPER},) +ALL_HOSTDIRS+= $${HOSTDIR_$(1)} +ALL_HOSTINST+= $(2)-hostinstall +endif + +$$(HOSTDIR_$(1)): ${_HOST_PATCH_COOKIE} ${_HOST_FAKE_COOKIE} + +endef |