summaryrefslogtreecommitdiffstats
path: root/network/x11vnc/x11vnc.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'network/x11vnc/x11vnc.SlackBuild')
-rw-r--r--network/x11vnc/x11vnc.SlackBuild18
1 files changed, 15 insertions, 3 deletions
diff --git a/network/x11vnc/x11vnc.SlackBuild b/network/x11vnc/x11vnc.SlackBuild
index 53048bb837..dca9d17bea 100644
--- a/network/x11vnc/x11vnc.SlackBuild
+++ b/network/x11vnc/x11vnc.SlackBuild
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
# Slackbuild for x11vnc.
# Original script for version 0.9.3 10/11/2007
@@ -32,10 +32,13 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=x11vnc
VERSION=${VERSION:-0.9.16}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -45,7 +48,14 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
@@ -78,6 +88,8 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+patch -p1 < $CWD/gcc10.patch
+
autoreconf -i
CFLAGS="$SLKCFLAGS" \
./configure \
@@ -107,4 +119,4 @@ mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE