aboutsummaryrefslogtreecommitdiff
path: root/boot/at91bootstrap/at91bootstrap.mk
diff options
context:
space:
mode:
Diffstat (limited to 'boot/at91bootstrap/at91bootstrap.mk')
-rw-r--r--boot/at91bootstrap/at91bootstrap.mk9
1 files changed, 9 insertions, 0 deletions
diff --git a/boot/at91bootstrap/at91bootstrap.mk b/boot/at91bootstrap/at91bootstrap.mk
index a7a856c6e7..5592d37375 100644
--- a/boot/at91bootstrap/at91bootstrap.mk
+++ b/boot/at91bootstrap/at91bootstrap.mk
@@ -21,6 +21,15 @@ define AT91BOOTSTRAP_EXTRACT_CMDS
rmdir $(BUILD_DIR)/Bootstrap-v$(AT91BOOTSTRAP_VERSION)
endef
+ifneq ($(call qstrip,$(BR2_TARGET_AT91BOOTSTRAP_CUSTOM_PATCH_DIR)),)
+define AT91BOOTSTRAP_APPLY_CUSTOM_PATCHES
+ support/scripts/apply-patches.sh $(@D) $(BR2_TARGET_AT91BOOTSTRAP_CUSTOM_PATCH_DIR) \
+ at91bootstrap-$(AT91BOOTSTRAP_VERSION)-\*.patch
+endef
+
+AT91BOOTSTRAP_POST_PATCH_HOOKS += AT91BOOTSTRAP_APPLY_CUSTOM_PATCHES
+endif
+
define AT91BOOTSTRAP_BUILD_CMDS
$(MAKE) CROSS_COMPILE=$(TARGET_CROSS) -C $(@D)/$(AT91BOOTSTRAP_MAKE_SUBDIR)
endef