]> Zhao Yanbai Git Server - minix.git/commitdiff
change rc defaults reading
authorBen Gras <ben@minix3.org>
Wed, 23 Nov 2011 15:01:00 +0000 (15:01 +0000)
committerBen Gras <ben@minix3.org>
Wed, 23 Nov 2011 15:36:51 +0000 (15:36 +0000)
. always install them (overwrite)
. source minix one from /etc/defaults/rc.conf
  so that it'll get read on existing installs
  without overwriting rc.conf (doesn't happen by default
  as it's user-editable), needed for new netconf system
. reported by Tenkawa

etc/Makefile
etc/defaults/minix.rc.conf [moved from etc/minix.rc.conf with 100% similarity]
etc/defaults/rc.conf [new file with mode: 0644]
etc/rc.conf

index 693474a7141ccc558ae39d09d0f9512523139a6c..c11703f890606db0389536a44b419a8c7e9c221a 100644 (file)
@@ -10,7 +10,7 @@ FILES1=group hostname.file inet.conf motd.install mtab profile \
 
 PWFILES=master.passwd
 FILES3=daily dhcptags.conf rc 
-DEFAULTFILES=minix.rc.conf
+DEFAULTFILES=rc.conf minix.rc.conf
 USRFILES=Makefile
 
 TOOL_PWD_MKDB= pwd_mkdb
@@ -25,7 +25,7 @@ install:: installpw   # installpw needed to bootstrap pw db
        @echo "Making hierarchy.."
        sh mtree.sh mtree/minix.tree
        @for f in $(FILES3); do if [ -f $(USRETC)/$$f ]; then :; else cp usr/$$f $(USRETC); chmod 755 $(USRETC)/$$f; fi; done
-       for f in $(DEFAULTFILES); do cp $$f $(DEFAULTS); chmod 644 $(DEFAULTS)/$$f; done
+       for f in $(DEFAULTFILES); do cp defaults/$$f $(DEFAULTS)/; chmod 644 $(DEFAULTS)/$$f; done
        @echo "Making devices.."
        p=`pwd` && cd /dev && sh $$p/../commands/MAKEDEV/MAKEDEV.sh null
        p=`pwd` && cd /dev && sh $$p/../commands/MAKEDEV/MAKEDEV.sh std  2>/dev/null
similarity index 100%
rename from etc/minix.rc.conf
rename to etc/defaults/minix.rc.conf
diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf
new file mode 100644 (file)
index 0000000..eee37ed
--- /dev/null
@@ -0,0 +1,4 @@
+if [ -r /etc/defaults/minix.rc.conf ]; then
+       . /etc/defaults/minix.rc.conf
+fi
+
index ef877d54378a956387626b9ae4fa7bcb254cbc71..257ced00d109782e4f338403418c7db65e663c2e 100644 (file)
@@ -13,10 +13,6 @@ if [ -r /etc/defaults/rc.conf ]; then
        . /etc/defaults/rc.conf
 fi
 
-if [ -r /etc/defaults/minix.rc.conf ]; then
-       . /etc/defaults/minix.rc.conf
-fi
-
 # If this is not set to YES, the system will drop into single-user mode.
 # (Doesn't matter for Minix.)
 rc_configured=NO