1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2025-02-27 16:54:15 +01:00

OP-1258 fix an issue with Windows package (root folder is missing in the zip file)

This commit is contained in:
Alessio Morale 2014-04-29 10:52:41 +02:00
parent 858d81d501
commit f9f7b62f9d

View File

@ -298,6 +298,7 @@ $(1)_install: $(1)_clean | $(DL_DIR) $(TOOLS_DIR)
@$(ECHO) $(MSG_EXTRACTING) $$(call toprel, $(2))
$(V1) $(MKDIR) -p $$(call toprel, $(dir $(2)))
$(if $(filter $(suffix $(5)), .zip),
$(V1) $(UNZIP) $(UNZIP_SILENT) -d $$(call toprel, $(dir $(2))) $$(call toprel, $(DL_DIR)/$(5)),
$(V1) $(TAR) $(TAR_OPTIONS) -C $$(call toprel, $(dir $(2))) -xf $$(call toprel, $(DL_DIR)/$(5))
@ -460,9 +461,13 @@ endef
# ARM SDK
#
##############################
ifeq ($(UNAME), Windows)
#unfortunately zip package for this release is missing root directory, so adding / at the end of the path
# so that template interpret last part as directory and use the full path
$(eval $(call TOOL_INSTALL_TEMPLATE,arm_sdk,$(ARM_SDK_DIR)/,$(ARM_SDK_URL),$(ARM_SDK_MD5_URL),$(notdir $(ARM_SDK_URL))))
else
$(eval $(call TOOL_INSTALL_TEMPLATE,arm_sdk,$(ARM_SDK_DIR),$(ARM_SDK_URL),$(ARM_SDK_MD5_URL),$(notdir $(ARM_SDK_URL))))
endif
ifeq ($(shell [ -d "$(ARM_SDK_DIR)" ] && $(ECHO) "exists"), exists)
export ARM_SDK_PREFIX := $(ARM_SDK_DIR)/bin/arm-none-eabi-
else
@ -478,7 +483,7 @@ arm_sdk_version:
# Template to check ARM toolchain version before building targets
define ARM_GCC_VERSION_CHECK_TEMPLATE
if ! $(ARM_SDK_PREFIX)gcc --version --specs=nano.specs >/dev/null 2>&1; then \
$(ECHO) $(MSG_NOTICE) Please install ARM toolchain 4.7+ using \'make arm_sdk_install\' && \
$(ECHO) $(MSG_NOTICE) Please install ARM toolchain 4.8 2014q1 using \'make arm_sdk_install\' && \
$(ECHO) $(MSG_NOTICE) Older ARM SDKs do not support new \'--specs=nano.specs\' option && \
exit 1; \
fi