aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2014-09-25 14:10:38 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2014-09-25 14:10:38 +0000
commit470259ffec324fc5ec0f16bec6f846596a9bfcb3 (patch)
treec64fb2939b2ec6e04afcf0dec8cfde64c0266d17
parentc44d7e7c4825ac1509f17fcc1d3c8d865ed4892a (diff)
downloadaports-470259ffec324fc5ec0f16bec6f846596a9bfcb3.tar.bz2
aports-470259ffec324fc5ec0f16bec6f846596a9bfcb3.tar.xz
main/openrc: fix and cleanup modloop initd
- fix mounting of modloop - drop support for .cmg - if modloop=/path/file boot option specified but file does not exist, then fail instead of searching for fallback
-rw-r--r--main/openrc/APKBUILD8
-rw-r--r--main/openrc/modloop.initd24
2 files changed, 14 insertions, 18 deletions
diff --git a/main/openrc/APKBUILD b/main/openrc/APKBUILD
index e740ef2509..0c6bc7ea02 100644
--- a/main/openrc/APKBUILD
+++ b/main/openrc/APKBUILD
@@ -2,7 +2,7 @@
pkgname=openrc
pkgver=0.12.4
_ver=${pkgver/_git*/}
-pkgrel=3
+pkgrel=4
pkgdesc="OpenRC manages the services, startup and shutdown of a host"
url="http://git.overlays.gentoo.org/gitweb/?p=proj/openrc.git"
arch="all"
@@ -77,7 +77,7 @@ c32e15b0858eef708497e7ee6355a055 hostname.initd
ce3832d8ed5906367ef0f4776b38f3bd hwdrivers.initd
33ca3e558c42cdd17adccbc7807298f7 keymaps.initd
098a1f16812f56fcb56eb6b6f0fa31f6 modules.initd
-ec007d7607266ca307dd9213d524e04c modloop.initd
+8af223f60f2bdab06467f7d94ebf7fce modloop.initd
55aeca82475cb5a146abff8333bfdf85 networking.initd
c1ec888202d868710b5749f7b217d1e3 modloop.confd"
sha256sums="c4edda2fff4b613f50b9cc265bb457a9ab0170fbc1fe7c26eccd4a5d63b2625c openrc-0.12.4.tar.bz2
@@ -92,7 +92,7 @@ e91790d23135c43102ea73e5768d4b0d25e9a7d28fca90f1b902aac9c41e1d5c hostname.initd
a71a38309beb6f4718a2ece863659735a5e157a7c927518265e562cd90fc71ff hwdrivers.initd
a6f013c02ca3efb4e29b4844e4d27710cfd319e66157c4fd88a8169e06e7151f keymaps.initd
42f7add323ee77d1ee04d96ed4b52897dd1d2a32ab361fd755d4eb707d67e5be modules.initd
-c571a08c40ed89f3607725b386d7f80d004ecc6b8a9bb4dfa4030ec59dcf7370 modloop.initd
+b31825961d3ef533cdf3756b228f5abcfe2854065b4c51135af458f6f3083ed4 modloop.initd
dc30c4e0cac37597dda3f97f68aa2f8a5e87a9856de8b2fd08579916117de8ed networking.initd
a5a0316cd59f5401b1d789bb466c98186201277ba6f014017b14965fcc10c254 modloop.confd"
sha512sums="14e188e382dfe02037d3e4211fa3265152d5ec92ca491b1e86154c0615583ddfc0a2592ca849ab453068dd60000886e57e7da024036fa58d7474acdbb6b92208 openrc-0.12.4.tar.bz2
@@ -107,6 +107,6 @@ c5b8806c693b0ea48ff87e0e3669304f5c2f95954ad54814889047a933f367081a8c8d3bb771dd1e
932669915d0e4c8b7d23823c6d057d5d3bbc7f2f67532547201fea986c7e3208607d69cfdd41b0b0b1828f33c4e87efb8d65f7a715c33a8c9cdc846b7ec7439b hwdrivers.initd
ee58de9b8608d3f3aa6111b9b43977b91bd2c39bcc3471711812fe740dbc49eee8a7ddd6f2878b90c8eb9bcc5a2f543cb2d82c04f16c263ffad58de7955d8db5 keymaps.initd
103889e4e183105b87052ead50747358c5cb17627f93c83b84434f9e615f8cad3ae554fb78e1f9f4c634265313d7ae11fe3760a5c97a5d8b4ddf48aa2b489be7 modules.initd
-88247c76a9d97fff4ee08e8e1fdc8f3a3a4811b376e6c5ad3fa5e73234182ea30e61fa5f906cfbe36825d158cc382e3899763e035021016235798116dccf5796 modloop.initd
+907d29d8b9ff6f82046c8577a9e2f3482c61328ceb2f95530a02496065c2e86c336621f24923283adf02bd31dc70a0a3a5d331c09d0ece134f3de2c70a7d903a modloop.initd
b46b34d96ba01aa7d19cae12560fbb2724762223fb5717b9d8d8c46c09dbc35829b9626c96cc08b9388614baa990e2fb526aab12c44667851731cae949bded1a networking.initd
aa702a7da8e6c0e5d8738febaf6b4e4cb021b30ce5c1809b530abf2b36739079446b16fc054740da8d86ed099942cf5deed6597cedb64c058f3def587a8b4689 modloop.confd"
diff --git a/main/openrc/modloop.initd b/main/openrc/modloop.initd
index ec52697446..e26bdcbb49 100644
--- a/main/openrc/modloop.initd
+++ b/main/openrc/modloop.initd
@@ -73,17 +73,17 @@ find_media() {
}
start() {
- local modloop= mount_opts= modloop_mounted= modloop_dldir="/lib"
+ local modloop= mount_opts= modloop_dldir="/lib"
find_media
case "$KOPT_modloop" in
http://*|https://|ftp://*)
wget -P "$modloop_dldir" "$KOPT_modloop" \
- && modloop=$modloop_dldir/$(basename $KOPT_modloop)
+ && modloop=$modloop_dldir/${KOPT_modloop##/*}
;;
*)
- if [ -z "$alpine_dev" ] ; then
+ if [ -z "$alpine_dev" ]; then
return 0
fi
if [ -z "$alpine_mounted" ]; then
@@ -93,21 +93,17 @@ start() {
eend $? || return 1
fi
for modloop in ${alpine_mnt}$KOPT_modloop \
- ${alpine_mnt}$KOPT_BOOT_IMAGE.modloop.* \
- ${alpine_mnt}$KOPT_BOOT_IMAGE.cmg; do
- [ -f "$modloop" ] || continue
+ ${alpine_mnt}$KOPT_BOOT_IMAGE.modloop.*; do
+
+ [ -f "$modloop" -o -n "$KOPT_modloop" ] && break
done
;;
esac
- if [ -f "$modloop" ]; then
- ebegin "Mounting modloop $modloop"
- mkdir -p /.modloop /lib
- mount -o loop,ro $fs_opt $modloop /.modloop \
- && modloop_mounted=1
- eend $? || return 1
- fi
- [ "$modloop_mounted" = "1" ] || return 1
+ ebegin "Mounting modloop $modloop"
+ mkdir -p /.modloop /lib
+ mount -o loop,ro $fs_opt $modloop /.modloop
+ eend $? || return 1
#use unionfs is available and configured
if grep -q -w "unionfs$" /proc/filesystems && [ -n "$unionfs_size" ]; then