PERFORCE change 81655 for review

soc-saturnero soc-saturnero at FreeBSD.org
Mon Aug 8 16:38:03 GMT 2005


http://perforce.freebsd.org/chv.cgi?CH=81655

Change 81655 by soc-saturnero at soc-saturnero_sberta on 2005/08/08 16:37:17

	Adding pkginstall target.
	Minor fixes to the pkgselect script

Affected files ...

.. //depot/projects/soc2005/freesbie/Makefile#9 edit
.. //depot/projects/soc2005/freesbie/scripts/pkginstall.sh#1 add
.. //depot/projects/soc2005/freesbie/scripts/pkgselect.sh#2 edit

Differences ...

==== //depot/projects/soc2005/freesbie/Makefile#9 (text+ko) ====

@@ -49,8 +49,15 @@
 	@sh ./scripts/launch.sh installkernel .tmp_installkernel
 	@mv .tmp_installkernel .done_installkernel
 
+pkginstall: .done_pkginstall
+.done_pkginstall: .done_installworld
+	@-rm -f .tmp_pkginstall
+	@touch .tmp_pkginstall
+	@sh ./scripts/launch.sh pkginstall .tmp_pkginstall
+	@mv .tmp_pkginstall .done_pkginstall
+
 clonefs: .done_clonefs
-.done_clonefs: .done_installkernel
+.done_clonefs: .done_installkernel .done_pkginstall
 	@-rm -f .tmp_clonefs
 	@touch .tmp_clonefs
 	@sh ./scripts/launch.sh clonefs .tmp_clonefs

==== //depot/projects/soc2005/freesbie/scripts/pkgselect.sh#2 (text+ko) ====

@@ -15,8 +15,6 @@
 WORKDIR=$(mktemp -d -t freesbie)
 PKGFILE=${PKGFILE:-${LOCALDIR}/conf/packages};
 
-trap "rm -rf ${WORKDIR} && rm -rf ${LOGFILE} && exit 1" INT
-
 create_lists() {
     cd ${WORKDIR}
     echo "Creating list of available packages on the build machine..."
@@ -42,6 +40,7 @@
 	echo "Using ${PKGFILE} as source..."
 
 	while read row; do
+	    if [ -z ${row} ]; then continue; fi
 	    pkg=$(echo $row | cut -d\  -f 1)
 
 	    # pkg_info might fail if the listed package isn't present
@@ -193,9 +192,10 @@
 purge_wd() {
     cd ${LOCALDIR}
     rm -rf ${WORKDIR}
-    exit
 }
 
+trap "purge_wd && exit 1" INT
+
 create_lists
 main_dialog
 purge_wd


More information about the p4-projects mailing list