bin/151416: pc-sysinstall patch that fixes component listing if
components don't exist
John Hixson
john at ixsystems.com
Tue Oct 12 22:20:06 UTC 2010
>Number: 151416
>Category: bin
>Synopsis: pc-sysinstall patch that fixes component listing if components don't exist
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: update
>Submitter-Id: current-users
>Arrival-Date: Tue Oct 12 22:20:05 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator: John Hixson
>Release: 9.0-CURRENT
>Organization:
iXsystems
>Environment:
FreeBSD thinkbsd 9.0-CURRENT FreeBSD 9.0-CURRENT #6: Sat Sep 25 05:21:08 PDT 2010 john at thinkbsd:/usr/obj/usr/src/sys/THINKBSD amd64
>Description:
This patch will only list components if the directory exists. The directory exist on PC-BSD but not FreeBSD, so an extra check is made.
>How-To-Repeat:
>Fix:
Patch attached with submission follows:
diff -urN usr.sbin/pc-sysinstall.orig/backend-query/list-components.sh usr.sbin/pc-sysinstall/backend-query/list-components.sh
--- usr.sbin/pc-sysinstall.orig/backend-query/list-components.sh 2010-10-12 14:53:43.000000000 -0700
+++ usr.sbin/pc-sysinstall/backend-query/list-components.sh 2010-10-12 15:06:23.000000000 -0700
@@ -32,23 +32,24 @@
echo "Available Components:"
-cd ${COMPDIR}
-for i in `ls -d *`
-do
- if [ -e "${i}/component.cfg" -a -e "${i}/install.sh" -a -e "${i}/distfiles" ]
- then
- NAME="`grep 'name:' ${i}/component.cfg | cut -d ':' -f 2`"
- DESC="`grep 'description:' ${i}/component.cfg | cut -d ':' -f 2`"
- TYPE="`grep 'type:' ${i}/component.cfg | cut -d ':' -f 2`"
- echo " "
- echo "name: ${i}"
- echo "desc:${DESC}"
- echo "type:${TYPE}"
- if [ -e "${i}/component.png" ]
+if [ -d "${COMPDIR}" ]
+then
+ cd ${COMPDIR}
+ for i in `ls -d *`
+ do
+ if [ -e "${i}/component.cfg" -a -e "${i}/install.sh" -a -e "${i}/distfiles" ]
then
- echo "icon: ${COMPDIR}/${i}/component.png"
+ NAME="`grep 'name:' ${i}/component.cfg | cut -d ':' -f 2`"
+ DESC="`grep 'description:' ${i}/component.cfg | cut -d ':' -f 2`"
+ TYPE="`grep 'type:' ${i}/component.cfg | cut -d ':' -f 2`"
+ echo " "
+ echo "name: ${i}"
+ echo "desc:${DESC}"
+ echo "type:${TYPE}"
+ if [ -e "${i}/component.png" ]
+ then
+ echo "icon: ${COMPDIR}/${i}/component.png"
+ fi
fi
- fi
-
-done
-
+ done
+fi
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-bugs
mailing list