summaryrefslogtreecommitdiff
path: root/scripts/build_rootfs.sh
diff options
context:
space:
mode:
authorMikael Magnusson <mikma@users.sourceforge.net>2018-03-21 21:25:05 +0100
committerMikael Magnusson <mikma@users.sourceforge.net>2018-03-21 21:25:05 +0100
commit37f6c414131f6a233d669611f9468697cb4672d6 (patch)
tree982785370c40103f8c6dfd89644c31925b918f58 /scripts/build_rootfs.sh
parent6c5d8db655259bb97fb47b3a6b2eb9b254ef900e (diff)
Update package list
Diffstat (limited to 'scripts/build_rootfs.sh')
-rwxr-xr-xscripts/build_rootfs.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/build_rootfs.sh b/scripts/build_rootfs.sh
index ab9a399..10f3a93 100755
--- a/scripts/build_rootfs.sh
+++ b/scripts/build_rootfs.sh
@@ -123,8 +123,11 @@ add_packages() {
done
}
-update_packages() {
+opkg_update() {
$OPKG update
+}
+
+update_packages() {
local upgradable="$($OPKG list-upgradable|grep -e '^.* - .* - .*'|cut -d ' ' -f 1)"
for pkg in $upgradable; do
echo Upgrading $pkg
@@ -147,6 +150,7 @@ if test -n "$metadata"; then
fi
add_files templates/ $dir/templates/
add_packages bin/packages/${arch}/${subarch}
+opkg_update
if test -n "$upgrade"; then
update_packages
fi