summaryrefslogtreecommitdiffstats
path: root/source/l/libvncserver/libvncserver.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'source/l/libvncserver/libvncserver.SlackBuild')
-rwxr-xr-xsource/l/libvncserver/libvncserver.SlackBuild47
1 files changed, 23 insertions, 24 deletions
diff --git a/source/l/libvncserver/libvncserver.SlackBuild b/source/l/libvncserver/libvncserver.SlackBuild
index 458759189..015b6a5fc 100755
--- a/source/l/libvncserver/libvncserver.SlackBuild
+++ b/source/l/libvncserver/libvncserver.SlackBuild
@@ -1,7 +1,7 @@
#!/bin/bash
# Copyright 2007, 2014 Heinz Wiesinger, Amsterdam, NL
-# Copyright 2008, 2009, 2010, 2011, 2012, 2015, 2018 Patrick J. Volkerding, Sebeka, MN, USA
+# Copyright 2008, 2009, 2010, 2011, 2012, 2015, 2018, 2019 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -28,7 +28,7 @@ cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=libvncserver
VERSION=${VERSION:-$(echo LibVNCServer-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
-BUILD=${BUILD:-4}
+BUILD=${BUILD:-1}
NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "}
@@ -90,27 +90,26 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \+
-./autogen.sh
-
-CFLAGS="$SLKCFLAGS" \
-CXXFLAGS="$SLKCFLAGS" \
-./configure \
- --prefix=/usr \
- --libdir=/usr/lib${LIBDIRSUFFIX} \
- --sysconfdir=/etc \
- --localstatedir=/var \
- --mandir=/usr/man \
- --disable-static \
- --build=$TARGET || exit 1
-
-make $NUMJOBS || make || exit 1
-make install DESTDIR=$PKG || exit 1
-
-# Don't ship .la files:
-rm -f $PKG/{,usr/}lib${LIBDIRSUFFIX}/*.la
-
-if [ -x client_examples/.libs/SDLvncviewer ]; then
- cp -a client_examples/.libs/SDLvncviewer $PKG/usr/bin/SDLvncviewer
+zcat $CWD/libvncserver.CMAKE_INSTALL_LIBDIR.diff.gz | patch -p1 --verbose || exit 1
+
+# Configure, build, and install:
+mkdir cmake-build
+cd cmake-build
+ cmake \
+ -DCMAKE_C_FLAGS="$SLKCFLAGS" \
+ -DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_INSTALL_LIBDIR="lib$LIBDIRSUFFIX" \
+ -DDOC_INSTALL_DIR="doc" \
+ -DMAN_INSTALL_DIR=/usr/man \
+ .. || exit 1
+ make $NUMJOBS || make || exit 1
+ make install DESTDIR=$PKG || exit 1
+cd ..
+
+if [ -x cmake-build/client_examples/SDLvncviewer ]; then
+ mkdir -p $PKG/usr/bin
+ cp -a cmake-build/client_examples/SDLvncviewer $PKG/usr/bin/SDLvncviewer
fi
find $PKG | xargs file | grep -e "executable" -e "shared object" \
@@ -118,7 +117,7 @@ find $PKG | xargs file | grep -e "executable" -e "shared object" \
mkdir -p $PKG/usr/doc/libvncserver-$VERSION
cp -a \
- AUTHORS COPYING* INSTALL NEWS* README* TODO* \
+ AUTHORS COPYING* NEWS* README* TODO* \
$PKG/usr/doc/libvncserver-$VERSION
# If there's a ChangeLog, installing at least part of the recent history