[PC-BSD Commits] r7626 - pcbsd/current/src-qt4/pbi-manager

svn at pcbsd.org svn at pcbsd.org
Thu Sep 23 07:24:55 PDT 2010


Author: kris
Date: 2010-09-23 07:24:55 -0700 (Thu, 23 Sep 2010)
New Revision: 7626

Modified:
   pcbsd/current/src-qt4/pbi-manager/pbi-manager
Log:

Make sure a few vars are set in pbi-manager created scripts, so they can be run stand-alone.



Modified: pcbsd/current/src-qt4/pbi-manager/pbi-manager
===================================================================
--- pcbsd/current/src-qt4/pbi-manager/pbi-manager	2010-09-23 13:48:33 UTC (rev 7625)
+++ pcbsd/current/src-qt4/pbi-manager/pbi-manager	2010-09-23 14:24:55 UTC (rev 7626)
@@ -1927,6 +1927,10 @@
         echo "#!/bin/sh" >"${dir}/${PBI_INS_PATHSCRIPT}"
         echo "#!/bin/sh" >"${dir}/${PBI_UNINS_PATHSCRIPT}"
 
+	# Make sure we also set SYS_LOCALBASE in case user runs these stand-alone at some point
+        echo "if [ -z \"\$SYS_LOCALBASE\" ] then SYS_LOCALBASE=\"${SYS_LOCALBASE}\" ; fi" >"${dir}/${PBI_INS_PATHSCRIPT}"
+        echo "if [ -z \"\$SYS_LOCALBASE\" ] then SYS_LOCALBASE=\"${SYS_LOCALBASE}\" ; fi" >"${dir}/${PBI_UNINS_PATHSCRIPT}"
+
 	touch "$_tmpextf"
 	if [ -e "$_extf" ]; then cat "${_extf}" >> "${_tmpextf}" ; fi
 	if [ -e "$_autoextf" ]; then cat "${_autoextf}" >> "${_tmpextf}" ; fi
@@ -2242,6 +2246,9 @@
 	insc="${PBI_STAGEDIR}/${PBI_FAKEBIN_DIR}/.pbi-install.sh"
 	echo "#!/bin/sh" > "$insc"
 	echo "PBI_WRAPPERBIN=\"${PBI_FAKEBIN_DIR}\"" >> "$insc"
+	echo "PBI_PROGDIRPATH=\"${PBI_PROGDIRPATH}\"" >> "$insc"
+	echo "SYS_LOCALBASE=\"${SYS_LOCALBASE}\"" >> "$insc"
+	echo "cd \"\$PBI_PROGDIRPATH}\"" >> "$insc"
 
 	# Xorg Font setup
 	if [ "${PBI_USESYSFONTS}" != "NO" ] ; then
@@ -2283,6 +2290,8 @@
 	uisc="${PBI_STAGEDIR}/${PBI_FAKEBIN_DIR}/.pbi-uninstall.sh"
 
 	echo "#!/bin/sh" > "$uisc"
+	echo "PBI_PROGDIRPATH=\"${PBI_PROGDIRPATH}\"" >> "$uisc"
+	echo "SYS_LOCALBASE=\"${SYS_LOCALBASE}\"" >> "$uisc"
 
 	# Remove the binary wrapper sym-links
         if [ -e "${PBI_STAGEDIR}/${PBI_FAKEBIN_DIR}/${PBI_UNINS_PATHSCRIPT}" ] ; then



More information about the Commits mailing list