[PC-BSD Commits] r19765 - in pcbsd/current/src-sh/pbi-manager: . port-files port-files/files

svn at pcbsd.org svn at pcbsd.org
Thu Oct 18 08:25:53 PDT 2012


Author: kris
Date: 2012-10-18 15:25:53 +0000 (Thu, 18 Oct 2012)
New Revision: 19765

Modified:
   pcbsd/current/src-sh/pbi-manager/install.sh
   pcbsd/current/src-sh/pbi-manager/pbi-manager
   pcbsd/current/src-sh/pbi-manager/port-files/Makefile
   pcbsd/current/src-sh/pbi-manager/port-files/files/pkg-message.in
Log:

Fix issue with PREFIX not being honored



Modified: pcbsd/current/src-sh/pbi-manager/install.sh
===================================================================
--- pcbsd/current/src-sh/pbi-manager/install.sh	2012-10-18 15:00:01 UTC (rev 19764)
+++ pcbsd/current/src-sh/pbi-manager/install.sh	2012-10-18 15:25:53 UTC (rev 19765)
@@ -35,6 +35,11 @@
 ln -f ${LB}/sbin/pbi_create ${LB}/sbin/pbid
 ln -f ${LB}/sbin/pbi_create ${LB}/sbin/pbi-crashhandler
 
+# Set the new PREFIX / LOCALBASE
+if [ "$LB" != /usr/local ] ; then
+  sed -i '' "s|PROGBASE=/usr/local|PROGBASE=$LB|g" ${LB}/sbin/pbi_create
+fi
+
 # Install manpages
 mkdir -p ${LB}/man/man1 >/dev/null 2>/dev/null
 for i in `ls man1/`
@@ -76,7 +81,7 @@
 chmod 755 /var/db/pbi/keys
 
 # Tickle the info command to setup default dirs
-/usr/local/sbin/pbi_info >/dev/null 2>/dev/null
+${LB}/sbin/pbi_info >/dev/null 2>/dev/null
 
 # Copy pbid / pbi.conf
 cp ${DIR}/rc.d/pbid ${LB}/etc/rc.d/pbid

Modified: pcbsd/current/src-sh/pbi-manager/pbi-manager
===================================================================
--- pcbsd/current/src-sh/pbi-manager/pbi-manager	2012-10-18 15:00:01 UTC (rev 19764)
+++ pcbsd/current/src-sh/pbi-manager/pbi-manager	2012-10-18 15:25:53 UTC (rev 19765)
@@ -415,8 +415,8 @@
 			echo "Your meta and index files will begin refreshing in a moment..."
 			echo "Details available in /var/log/pbid.log"
 			rm ${PBI_DBINDEXDIR}/*.time >/dev/null 2>/dev/null
-			if [ -e "/usr/local/etc/rc.d/pbid" ]; then
-			   /usr/local/etc/rc.d/pbid restart >/dev/null 2>/dev/null
+			if [ -e "${PROGBASE}/etc/rc.d/pbid" ]; then
+			   ${PROGBASE}/etc/rc.d/pbid restart >/dev/null 2>/dev/null
 			fi
 			exit 0
                         ;;
@@ -1307,8 +1307,8 @@
 	ARCH="$REALARCH"
 
         # Where is pbi-manager installed?
-        PROGBASE="/usr/local" 
-	SYS_LOCALBASE="/usr/local"
+        PROGBASE=/usr/local
+	SYS_LOCALBASE=/usr/local
 	if [ -z "${PBI_APPDIR}" -o "`basename $0`" = "pbi_makeport_chroot" ] ; then
 		PBI_APPDIR="/usr/pbi"
         fi

Modified: pcbsd/current/src-sh/pbi-manager/port-files/Makefile
===================================================================
--- pcbsd/current/src-sh/pbi-manager/port-files/Makefile	2012-10-18 15:00:01 UTC (rev 19764)
+++ pcbsd/current/src-sh/pbi-manager/port-files/Makefile	2012-10-18 15:25:53 UTC (rev 19765)
@@ -31,7 +31,7 @@
 		pbi_makepatch.8 pbi_makeport.8 pbi_makerepo.8 pbid.8
 
 do-install:
-	cd ${WRKSRC} && ./install.sh ${LOCALBASE}
+	cd ${WRKSRC} && ./install.sh ${PREFIX}
 
 post-install:
 	@${ECHO_MSG}

Modified: pcbsd/current/src-sh/pbi-manager/port-files/files/pkg-message.in
===================================================================
--- pcbsd/current/src-sh/pbi-manager/port-files/files/pkg-message.in	2012-10-18 15:00:01 UTC (rev 19764)
+++ pcbsd/current/src-sh/pbi-manager/port-files/files/pkg-message.in	2012-10-18 15:25:53 UTC (rev 19765)
@@ -5,7 +5,7 @@
 enable the "pbid" daemon, which handles downloading
 repository indexes, merging files into the hashdir and more.
 
-You may start the daemon with %%LOCALBASE%%/etc/rc.d/pbid
+You may start the daemon with %%PREFIX%%/etc/rc.d/pbid
 or by rebooting. 
 
 ************************************************************



More information about the Commits mailing list