[openwrt/openwrt] image: apk: remove explicit distfeeds handling
LEDE Commits
lede-commits at lists.infradead.org
Sun Nov 17 03:03:23 PST 2024
jogo pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/bdfae5a16679b41746b836a8f5dee66d1c778e41
commit bdfae5a16679b41746b836a8f5dee66d1c778e41
Author: Petr Štetiar <ynezz at true.cz>
AuthorDate: Sun Nov 17 06:50:05 2024 +0000
image: apk: remove explicit distfeeds handling
Currently the build fails due to the following:
mv: cannot stat 'linux-mediatek_filogic/target-dir-7872e783/etc/apk/repositories': No such file or directory
as the changes done in the commit e031dab93ec3 ("base-files: move apk
distfeeds into directory") forget to adapt image generation part.
While looking into this, I've realized, that we don't need this explicit
handling in the image generating code since the feeds are solely
configured by `base-files` and `apk` packages, so those should always
provide the correct feeds content, so lets simply drop this unnecessary
code.
Moving away /etc/opkg is done to prevent opkg from picking up the remote
feeds defined from base-files and only use the local feeds, but for apk
we explicitly pass --repositories-file which disables parsing of
/etc/apk/repositories and /etc/apk/repositories.d, so we do not need to
backup anything.
Fixes: #16981
Fixes: e031dab93ec3 ("base-files: move apk distfeeds into directory")
Reported-by: Chen Minqiang <ptpt52 at gmail.com>
Signed-off-by: Petr Štetiar <ynezz at true.cz>
[jonas.gorski: add an explicit explanation where the original mv comes
from and why we don't need it for apk].
Signed-off-by: Jonas Gorski <jonas.gorski at gmail.com>
---
include/image.mk | 2 --
1 file changed, 2 deletions(-)
diff --git a/include/image.mk b/include/image.mk
index 881d420ae1..70dc8e069b 100644
--- a/include/image.mk
+++ b/include/image.mk
@@ -372,12 +372,10 @@ target-dir-%: FORCE
ifneq ($(CONFIG_USE_APK),)
rm -rf $(mkfs_cur_target_dir)
$(CP) $(TARGET_DIR_ORIG) $(mkfs_cur_target_dir)
- mv $(mkfs_cur_target_dir)/etc/apk/repositories $(mkfs_cur_target_dir).repositories
$(if $(mkfs_packages_remove), \
$(apk_target) del $(mkfs_packages_remove))
$(if $(mkfs_packages_add), \
$(apk_target) add $(mkfs_packages_add))
- mv $(mkfs_cur_target_dir).repositories $(mkfs_cur_target_dir)/etc/apk/repositories
else
rm -rf $(mkfs_cur_target_dir) $(mkfs_cur_target_dir).opkg
$(CP) $(TARGET_DIR_ORIG) $(mkfs_cur_target_dir)
More information about the lede-commits
mailing list