aboutsummaryrefslogtreecommitdiff
path: root/sbrun
diff options
context:
space:
mode:
Diffstat (limited to 'sbrun')
-rwxr-xr-xsbrun9
1 files changed, 9 insertions, 0 deletions
diff --git a/sbrun b/sbrun
index ec4c6fe..1772c9e 100755
--- a/sbrun
+++ b/sbrun
@@ -127,6 +127,10 @@ beginning with - must occur before [script] or [variable=value].
environment, or in one of distcc's config files. This option sets
CC and CXX, allows network access, and disables filesystem tracking.
+-u Install the package after building it. This just runs "upkg" in the
+ SlackBuild directory, so "sbrun -u" is just a shortcut for typing
+ "sbrun; upkg".
+
-h, --help
Show short usage message and exit.
@@ -247,6 +251,7 @@ Usage: $SELF [-option [-option ...]] [script] [variable=value ...]
-c Clean up (remove) source and package dirs after build completes.
-i Run an interactive shell in the source directory.
-p Run an interactive shell in the \$PKG directory.
+-u Install built package with 'upkg'.
-h, --help
Show short usage message (you're reading it now) and exit.
-H Show long help message and exit.
@@ -356,6 +361,7 @@ while printf -- "$1" | grep -q ^-; do
TRACK=no
NETWORK=yes
export CC CXX ;;
+ -u) UPKG=yes ;;
-h|-help|--help) show_help ; exit 0 ;;
-H) long_help ; exit 0 ;;
-*) show_help "$1"; exit 1 ;;
@@ -546,5 +552,8 @@ fi
cleanup_build
+# Install the package if -u.
+[ "$RET" = "0" ] && [ "$UPKG" = "yes" ] && upkg
+
# Our return status is that of the SlackBuild.
exit $RET