feeds: use common macro "FeedSourcesAppend" to populate opkg configurations
This introduces a common macro to assemble the correct url templates to avoid code duplication and have the feed config handling in a central place. Signed-off-by: Jo-Philipp Wich <jow@openwrt.org> SVN-Revision: 45799
This commit is contained in:
@@ -24,3 +24,16 @@ $(strip $(if $(CONFIG_PER_FEED_REPO), \
|
||||
$(abspath $(PACKAGE_DIR)/$(if $(Package/$(1)/feed),$(Package/$(1)/feed),base)), \
|
||||
$(PACKAGE_DIR)))
|
||||
endef
|
||||
|
||||
# 1: destination file
|
||||
define FeedSourcesAppend
|
||||
( \
|
||||
$(strip $(if $(CONFIG_PER_FEED_REPO), \
|
||||
$(foreach feed,base $(FEEDS_ENABLED),echo "src/gz %n_$(feed) %U/$(feed)";) \
|
||||
$(if $(CONFIG_PER_FEED_REPO_ADD_DISABLED), \
|
||||
$(foreach feed,$(FEEDS_DISABLED),echo "$(if $(CONFIG_PER_FEED_REPO_ADD_COMMENTED),# )src/gz %n_$(feed) %U/$(feed)";)) \
|
||||
, \
|
||||
echo "src/gz %n %U"; \
|
||||
)) \
|
||||
) >> $(1)
|
||||
endef
|
||||
|
||||
Reference in New Issue
Block a user