2013-06-06 23:54:13 +02:00
|
|
|
################################################################################
|
2007-07-17 14:19:56 +02:00
|
|
|
#
|
|
|
|
# at91bootstrap
|
|
|
|
#
|
2013-06-06 23:54:13 +02:00
|
|
|
################################################################################
|
2013-06-06 01:53:25 +02:00
|
|
|
|
2011-07-05 21:54:00 +02:00
|
|
|
AT91BOOTSTRAP_VERSION = 1.16
|
2014-07-31 10:46:58 +02:00
|
|
|
AT91BOOTSTRAP_SITE = ftp://www.at91.com/pub/at91bootstrap
|
2011-07-05 21:54:00 +02:00
|
|
|
AT91BOOTSTRAP_SOURCE = AT91Bootstrap$(AT91BOOTSTRAP_VERSION).zip
|
2007-07-17 14:19:56 +02:00
|
|
|
|
2011-07-05 21:54:00 +02:00
|
|
|
AT91BOOTSTRAP_BOARD = $(call qstrip,$(BR2_TARGET_AT91BOOTSTRAP_BOARD))
|
|
|
|
AT91BOOTSTRAP_MEMORY = $(call qstrip,$(BR2_TARGET_AT91BOOTSTRAP_MEMORY))
|
|
|
|
AT91BOOTSTRAP_MAKE_SUBDIR = board/$(AT91BOOTSTRAP_BOARD)/$(AT91BOOTSTRAP_MEMORY)
|
|
|
|
AT91BOOTSTRAP_BINARY = $(AT91BOOTSTRAP_MAKE_SUBDIR)/$(AT91BOOTSTRAP_MEMORY)_$(AT91BOOTSTRAP_BOARD).bin
|
2008-04-10 23:05:30 +02:00
|
|
|
|
2011-07-05 21:54:00 +02:00
|
|
|
AT91BOOTSTRAP_INSTALL_IMAGES = YES
|
|
|
|
AT91BOOTSTRAP_INSTALL_TARGET = NO
|
2007-07-17 14:19:56 +02:00
|
|
|
|
2011-07-05 21:54:00 +02:00
|
|
|
define AT91BOOTSTRAP_EXTRACT_CMDS
|
2014-10-29 10:18:41 +01:00
|
|
|
$(UNZIP) -d $(BUILD_DIR) $(DL_DIR)/$(AT91BOOTSTRAP_SOURCE)
|
2011-07-05 21:54:00 +02:00
|
|
|
mv $(BUILD_DIR)/Bootstrap-v$(AT91BOOTSTRAP_VERSION)/* $(@D)
|
|
|
|
rmdir $(BUILD_DIR)/Bootstrap-v$(AT91BOOTSTRAP_VERSION)
|
|
|
|
endef
|
2007-07-17 14:19:56 +02:00
|
|
|
|
2012-02-02 23:29:26 +01:00
|
|
|
ifneq ($(call qstrip,$(BR2_TARGET_AT91BOOTSTRAP_CUSTOM_PATCH_DIR)),)
|
|
|
|
define AT91BOOTSTRAP_APPLY_CUSTOM_PATCHES
|
2014-10-22 18:20:10 +02:00
|
|
|
$(APPLY_PATCHES) $(@D) $(BR2_TARGET_AT91BOOTSTRAP_CUSTOM_PATCH_DIR) \
|
2012-02-02 23:29:26 +01:00
|
|
|
at91bootstrap-$(AT91BOOTSTRAP_VERSION)-\*.patch
|
|
|
|
endef
|
|
|
|
|
|
|
|
AT91BOOTSTRAP_POST_PATCH_HOOKS += AT91BOOTSTRAP_APPLY_CUSTOM_PATCHES
|
|
|
|
endif
|
|
|
|
|
2011-07-05 21:54:00 +02:00
|
|
|
define AT91BOOTSTRAP_BUILD_CMDS
|
2013-05-29 00:36:37 +02:00
|
|
|
$(MAKE1) CROSS_COMPILE=$(TARGET_CROSS) -C $(@D)/$(AT91BOOTSTRAP_MAKE_SUBDIR)
|
2011-07-05 21:54:00 +02:00
|
|
|
endef
|
2009-01-03 01:07:25 +01:00
|
|
|
|
2011-07-05 21:54:00 +02:00
|
|
|
define AT91BOOTSTRAP_INSTALL_IMAGES_CMDS
|
|
|
|
cp $(@D)/$(AT91BOOTSTRAP_BINARY) $(BINARIES_DIR)
|
|
|
|
endef
|
2008-04-10 23:05:30 +02:00
|
|
|
|
2012-07-03 00:07:32 +02:00
|
|
|
$(eval $(generic-package))
|
2007-07-17 14:19:56 +02:00
|
|
|
|
2008-12-08 09:15:58 +01:00
|
|
|
ifeq ($(BR2_TARGET_AT91BOOTSTRAP),y)
|
2010-12-05 21:52:51 +01:00
|
|
|
# we NEED a board name unless we're at make source
|
|
|
|
ifeq ($(filter source,$(MAKECMDGOALS)),)
|
2010-03-17 08:46:56 +01:00
|
|
|
ifeq ($(AT91BOOTSTRAP_BOARD),)
|
|
|
|
$(error No AT91Bootstrap board name set. Check your BR2_TARGET_AT91BOOTSTRAP_BOARD setting)
|
|
|
|
endif
|
|
|
|
endif
|
2010-12-05 21:52:51 +01:00
|
|
|
endif
|