aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorB. Watson <yalhcru@gmail.com>2022-02-23 13:46:30 -0500
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2022-02-25 22:58:02 +0700
commit5aec82c779263fbb996eebd4f72164895f18d6ce (patch)
tree613d01e3e61b4ec3a7e8ced997d36dd36831d8eb
parentcabbc1914deadf9095193a7a49d6ac239ee051de (diff)
games/glPortal: Fix 15.0 build.
Signed-off-by: B. Watson <yalhcru@gmail.com> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
-rw-r--r--games/glPortal/glPortal.SlackBuild33
1 files changed, 21 insertions, 12 deletions
diff --git a/games/glPortal/glPortal.SlackBuild b/games/glPortal/glPortal.SlackBuild
index a2341e17ea8b..976c113f8637 100644
--- a/games/glPortal/glPortal.SlackBuild
+++ b/games/glPortal/glPortal.SlackBuild
@@ -22,6 +22,13 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 20220222 bkw: Modified by SlackBuilds.org, BUILD=2:
+# - fix build on 15.0.
+# - binary in /usr/games.
+# - TODO: .desktop and icon. Not today.
+# - TODO: I have never played this game before, so I don't know
+# if it's working correctly. Someone should check.
+
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=glPortal
@@ -31,7 +38,7 @@ DATAVER=${DATAVER:-d391875c9110ed2b04b9014b3ab6a587c2aa921d}
SPECVER=${SPECVER:-2bcaa5de0e6cae58e53008efcc8a9ec5f2f8ba92}
CPPGUIVER=${CPPGUIVER:-f45a7b94da031914a86e1823d5affc512cc9de66}
VHACDVER=${VHACDVER:-537b2413299a5a7d22a4aa0f9f26901b0f38daf2}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -43,9 +50,6 @@ if [ -z "$ARCH" ]; then
esac
fi
-# 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
@@ -92,12 +96,18 @@ mv vhacd-lib-$VHACDVER/ external/vhacd-lib
chown -R root:root .
find -L . \
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
- -o -perm 511 \) -exec chmod 755 {} \; -o \
+ -o -perm 511 \) -exec chmod 755 {} \+ -o \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
- -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \+
+
+# 20220223 bkw: missing includes, yay.
+sed -i '1i#include <functional>' \
+ source/engine/core/state/HandleGameFunction.hpp \
+ source/engine/core/state/PlayerState.hpp
cd source/engine
patch -p2 < $CWD/bullet286.patch
+
cd ../..
mkdir -p build
cd build
@@ -108,18 +118,17 @@ cd build
-DCMAKE_BUILD_TYPE=Release \
-DUnitTestPlusPlus_INCLUDE_DIR=/usr/include/UnitTest++/ ..
make
- make install DESTDIR=$PKG
+ make install/strip DESTDIR=$PKG
cd ..
# Remove bogus static lib
-rm $PKG/usr/bin/libVHACD_LIB.a
-
-find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
- | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+# 20220223 bkw: ...and bogus headers.
+rm -rf $PKG/usr/bin/libVHACD_LIB.a $PKG/usr/include
+mv $PKG/usr/bin $PKG/usr/games
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a \
- COMPILE.md CONTRIBUTE.md CONTRIBUTORS.md LICENSE.md README.md \
+ CONTRIBUTE.md CONTRIBUTORS.md LICENSE.md README.md \
$PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild