[PC-BSD Commits] r3693 - pcbsd/trunk/installcd-overlay/usr/local/pcbsd/scripts

svn at pcbsd.org svn at pcbsd.org
Mon Mar 30 09:53:12 PST 2009


Author: kris
Date: 2009-03-30 10:53:12 -0700 (Mon, 30 Mar 2009)
New Revision: 3693

Modified:
   pcbsd/trunk/installcd-overlay/usr/local/pcbsd/scripts/PCBSD.InstallCD2.sh
Log:

Fixed the fstab manipulation in InstallCD2.sh, we don't need to add linprocfs and /procfs when doing an upgrade, if they arlready exists in fstab :)



Modified: pcbsd/trunk/installcd-overlay/usr/local/pcbsd/scripts/PCBSD.InstallCD2.sh
===================================================================
--- pcbsd/trunk/installcd-overlay/usr/local/pcbsd/scripts/PCBSD.InstallCD2.sh	2009-03-30 17:39:47 UTC (rev 3692)
+++ pcbsd/trunk/installcd-overlay/usr/local/pcbsd/scripts/PCBSD.InstallCD2.sh	2009-03-30 17:53:12 UTC (rev 3693)
@@ -51,21 +51,27 @@
 echo "Setting up kernel...";
 cp f /usr/local/pcbsd/LANGS/* ${FSMNT}/PCBSD/LANGS/ >/dev/null
 
-cp /tmp/fstab ${FSMNT}/etc/fstab
+# Copy over the generated fstab
+if [ ! -e "/tmp/runningUpgrade" ]
+then
+  cp /tmp/fstab ${FSMNT}/etc/fstab
+fi
 
 # Enable the linprocfs support
-echo "linprocfs	/compat/linux/proc	linprocfs rw	0  0" >> ${FSMNT}/etc/fstab
+grep "^linprocfs" ${FSMNT}/etc/fstab >/dev/null 2>/dev/null
+if [ "$?" != "0" ]
+then
+  echo "linprocfs	/compat/linux/proc	linprocfs rw	0  0" >> ${FSMNT}/etc/fstab
+fi
 
 # Enable the procfs since Policy Kit needs it
-echo "proc	/proc	procfs rw	0  0" >> ${FSMNT}/etc/fstab
+grep "^proc" ${FSMNT}/etc/fstab >/dev/null 2>/dev/null
+if [ "$?" != "0" ]
+then
+  echo "proc	/proc	procfs rw	0  0" >> ${FSMNT}/etc/fstab
+fi
 
 
-# Remove the lp /usr/bin files for cups to work properly
-#rm /mnt/usr/bin/lp >/dev/null 2>/dev/null
-#rm /mnt/usr/bin/lpr >/dev/null 2>/dev/null
-#rm /mnt/usr/bin/lpq >/dev/null 2>/dev/null
-#rm /mnt/usr/bin/lprm >/dev/null 2>/dev/null
-
 # Make directories for src / obj / ports
 mkdir ${FSMNT}/usr/src >/dev/null 2>/dev/null
 mkdir ${FSMNT}/usr/obj >/dev/null 2>/dev/null



More information about the Commits mailing list