diff options
author | Abdoulaye Walsimou Gaye <awg@embtoolkit.org> | 2011-06-02 19:59:34 +0200 |
---|---|---|
committer | Abdoulaye Walsimou Gaye <awg@embtoolkit.org> | 2011-06-02 19:59:34 +0200 |
commit | a275ce5e108f03fd1abcb8c9010fb196aa346796 (patch) | |
tree | 9230d95e296bfe47846a500d9cd5a8613fdecf7e /mk | |
parent | 71fff4edf79e819f703d95c55cb44c5fe4fb13df (diff) | |
download | embtoolkit-a275ce5e108f03fd1abcb8c9010fb196aa346796.tar.gz embtoolkit-a275ce5e108f03fd1abcb8c9010fb196aa346796.tar.bz2 embtoolkit-a275ce5e108f03fd1abcb8c9010fb196aa346796.tar.xz |
Build system: decompress macros: install .patched and .decompressed files in SRC
Signed-off-by: Abdoulaye Walsimou Gaye <awg@embtoolkit.org>
Diffstat (limited to 'mk')
-rw-r--r-- | mk/macros.mk | 30 |
1 files changed, 16 insertions, 14 deletions
diff --git a/mk/macros.mk b/mk/macros.mk index b539630..625059c 100644 --- a/mk/macros.mk +++ b/mk/macros.mk @@ -386,30 +386,31 @@ endef define EMBTK_DECOMPRESS_PKG $(call EMBTK_GENERIC_MSG,"Decrompressing $($(1)_PACKAGE) ...") @if [ "x$(CONFIG_EMBTK_$(1)_PKG_IS_TARGZ)" == "xy" ] && \ - [ ! -e $($(1)_BUILD_DIR)/.decompressed ]; then \ + [ ! -e $($(1)_SRC_DIR)/.decompressed ]; then \ tar -C $(PACKAGES_BUILD) -xzf \ $(DOWNLOAD_DIR)/$($(1)_PACKAGE) && \ mkdir -p $($(1)_BUILD_DIR) && \ - touch $($(1)_BUILD_DIR)/.decompressed; \ + touch $($(1)_SRC_DIR)/.decompressed; \ elif [ "x$(CONFIG_EMBTK_$(1)_PKG_IS_TARBZ2)" == "xy" ] && \ - [ ! -e $($(1)_BUILD_DIR)/.decompressed ]; then \ + [ ! -e $($(1)_SRC_DIR)/.decompressed ]; then \ tar -C $(PACKAGES_BUILD) -xjf \ $(DOWNLOAD_DIR)/$($(1)_PACKAGE) && \ mkdir -p $($(1)_BUILD_DIR) && \ - touch $($(1)_BUILD_DIR)/.decompressed; \ + touch $($(1)_SRC_DIR)/.decompressed; \ elif [ "x$(CONFIG_EMBTK_$(1)_PKG_IS_TARBZ2)" == "x" ] && \ [ "x$(CONFIG_EMBTK_$(1)_PKG_IS_TARGZ)" == "x" ] && \ - [ ! -e $($(1)_BUILD_DIR)/.decompressed ]; then \ + [ ! -e $($(1)_SRC_DIR)/.decompressed ]; then \ echo -e "\E[1;31m!Unknown package compression type!\E[0m"; \ exit 1; \ fi @if [ "x$(CONFIG_EMBTK_$(1)_NEED_PATCH)" == "xy" ] && \ - [ ! -e $($(1)_BUILD_DIR)/.patched ]; then \ + [ ! -e $($(1)_SRC_DIR)/.patched ]; then \ cd $($(1)_SRC_DIR); \ patch -p1 < \ $(DOWNLOAD_DIR)/$($(1)_NAME)-$($(1)_VERSION).patch && \ - touch $($(1)_BUILD_DIR)/.patched; \ + touch $($(1)_SRC_DIR)/.patched; \ fi + @mkdir -p $($(1)_BUILD_DIR) endef # @@ -421,30 +422,31 @@ endef define EMBTK_DECOMPRESS_HOSTPKG $(call EMBTK_GENERIC_MSG,"Decrompressing $($(1)_PACKAGE) ...") @if [ "x$(CONFIG_EMBTK_$(1)_PKG_IS_TARGZ)" == "xy" ] && \ - [ ! -e $($(1)_BUILD_DIR)/.decompressed ]; then \ + [ ! -e $($(1)_SRC_DIR)/.decompressed ]; then \ tar -C $(TOOLS_BUILD) -xzf \ $(DOWNLOAD_DIR)/$($(1)_PACKAGE) && \ mkdir -p $($(1)_BUILD_DIR) && \ - touch $($(1)_BUILD_DIR)/.decompressed; \ + touch $($(1)_SRC_DIR)/.decompressed; \ elif [ "x$(CONFIG_EMBTK_$(1)_PKG_IS_TARBZ2)" == "xy" ] && \ - [ ! -e $($(1)_BUILD_DIR)/.decompressed ]; then \ + [ ! -e $($(1)_SRC_DIR)/.decompressed ]; then \ tar -C $(TOOLS_BUILD) -xjf \ $(DOWNLOAD_DIR)/$($(1)_PACKAGE) && \ mkdir -p $($(1)_BUILD_DIR) && \ - touch $($(1)_BUILD_DIR)/.decompressed; \ + touch $($(1)_SRC_DIR)/.decompressed; \ elif [ "x$(CONFIG_EMBTK_$(1)_PKG_IS_TARBZ2)" == "x" ] && \ [ "x$(CONFIG_EMBTK_$(1)_PKG_IS_TARGZ)" == "x" ] && \ - [ ! -e $($(1)_BUILD_DIR)/.decompressed ]; then \ + [ ! -e $($(1)_SRC_DIR)/.decompressed ]; then \ echo -e "\E[1;31m!Unknown package compression type!\E[0m"; \ exit 1; \ fi @if [ "x$(CONFIG_EMBTK_$(1)_NEED_PATCH)" == "xy" ] && \ - [ ! -e $($(1)_BUILD_DIR)/.patched ]; then \ + [ ! -e $($(1)_SRC_DIR)/.patched ]; then \ cd $($(1)_SRC_DIR); \ patch -p1 < \ $(DOWNLOAD_DIR)/$($(1)_NAME)-$($(1)_VERSION).patch && \ - touch $($(1)_BUILD_DIR)/.patched; \ + touch $($(1)_SRC_DIR)/.patched; \ fi + @mkdir -p $($(1)_BUILD_DIR) endef # |