aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--games/oblige/README18
-rw-r--r--games/oblige/compile_fixes.diff12
-rw-r--r--games/oblige/doinst.sh4
-rw-r--r--games/oblige/lua_compile_fixes.diff53
-rw-r--r--games/oblige/oblige.SlackBuild76
-rw-r--r--games/oblige/oblige.desktop8
-rw-r--r--games/oblige/oblige.info10
-rw-r--r--games/oblige/oblige.pngbin0 -> 15879 bytes
-rw-r--r--games/oblige/slack-desc19
9 files changed, 200 insertions, 0 deletions
diff --git a/games/oblige/README b/games/oblige/README
new file mode 100644
index 0000000000000..a0e093c5817cb
--- /dev/null
+++ b/games/oblige/README
@@ -0,0 +1,18 @@
+OBLIGE is a random level generator for various classic games, including
+DOOM, DOOM II, Heretic, and Quake. The goal is to produce high quality
+levels which are fun to play.
+
+This requires lua, fltk, and glbsp.
+
+A Doom (or Heretic, or Quake) engine is required if you actually want to
+play the levels you generate (currently, prboom and zdoom are available
+at SBo).
+
+Also required: the data file(s) for whichever game(s) you're playing
+(registered versions, not shareware):
+
+Game: File:
+Doom doom.wad
+Doom II doom2.wad
+Heretic heretic.wad
+Quake pak0.pak and pak1.pak
diff --git a/games/oblige/compile_fixes.diff b/games/oblige/compile_fixes.diff
new file mode 100644
index 0000000000000..c8589e37e8e8a
--- /dev/null
+++ b/games/oblige/compile_fixes.diff
@@ -0,0 +1,12 @@
+diff -Naur oblige_357_src/gui/q_bsp.cc oblige_357_src.patched//gui/q_bsp.cc
+--- oblige_357_src/gui/q_bsp.cc 2010-03-07 05:24:42.000000000 -0500
++++ oblige_357_src.patched//gui/q_bsp.cc 2010-12-17 18:24:48.000000000 -0500
+@@ -107,7 +107,7 @@
+ // convert each newline into CR/LF pair
+ while (*str)
+ {
+- char *next = strchr(str, '\n');
++ char *next = (char *)strchr(str, '\n');
+
+ Append(str, next ? (next - str) : strlen(str));
+
diff --git a/games/oblige/doinst.sh b/games/oblige/doinst.sh
new file mode 100644
index 0000000000000..4e8ba7071dea7
--- /dev/null
+++ b/games/oblige/doinst.sh
@@ -0,0 +1,4 @@
+if [ -x /usr/bin/update-desktop-database ]; then
+ /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
+fi
+
diff --git a/games/oblige/lua_compile_fixes.diff b/games/oblige/lua_compile_fixes.diff
new file mode 100644
index 0000000000000..a86af989756b8
--- /dev/null
+++ b/games/oblige/lua_compile_fixes.diff
@@ -0,0 +1,53 @@
+diff -Naur oblige_351_src.orig/gui/Makefile.unixy oblige_351_src/gui/Makefile.unixy
+--- oblige_351_src.orig/gui/Makefile.unixy 2010-01-21 07:34:30.000000000 -0500
++++ oblige_351_src/gui/Makefile.unixy 2010-02-28 15:58:31.000000000 -0500
+@@ -40,10 +40,10 @@
+ FLTK_LIBS=-lfltk_images -lfltk -lX11 -lXext -lpng -ljpeg
+
+ LUA_FLAGS=-I$(LUA_DIR)/src
+-LUA_LIBS=$(LUA_DIR)/src/liblua.a
++LUA_LIBS=-llua
+
+ GLBSP_FLAGS=-I$(GLBSP_DIR)/src
+-GLBSP_LIBS=$(GLBSP_DIR)/libglbsp.a
++GLBSP_LIBS=-lglbsp
+
+ CXXFLAGS=$(OPTIMISE) -Wall -DFHS_INSTALL -D$(OS) \
+ $(FLTK_FLAGS) $(LUA_FLAGS) $(GLBSP_FLAGS)
+diff -Naur oblige_351_src.orig/gui/hdr_lua.h oblige_351_src/gui/hdr_lua.h
+--- oblige_351_src.orig/gui/hdr_lua.h 2009-07-17 05:25:10.000000000 -0400
++++ oblige_351_src/gui/hdr_lua.h 2010-02-28 15:58:02.000000000 -0500
+@@ -23,9 +23,7 @@
+
+ /* LUA Scripting Language */
+
+-#include "lua.h"
+-#include "lauxlib.h"
+-#include "lualib.h"
++#include "lua.hpp"
+
+ #endif // __OB_HDR_LUA__
+
+diff -Naur oblige_351_src.orig/vis_viewer/Makefile oblige_351_src/vis_viewer/Makefile
+--- oblige_351_src.orig/vis_viewer/Makefile 2009-10-01 05:01:34.000000000 -0400
++++ oblige_351_src/vis_viewer/Makefile 2010-02-28 15:59:43.000000000 -0500
+@@ -23,15 +23,15 @@
+ #--- Internal stuff from here -----------------------------------
+
+ FLTK_FLAGS=-I$(FLTK_DIR)
+-FLTK_LIBS=$(FLTK_DIR)/lib/libfltk_images.a \
+- $(FLTK_DIR)/lib/libfltk.a \
++FLTK_LIBS=-lfltk_images \
++ -lfltk \
+ -lX11 -lXext -lpng -ljpeg
+
+ LUA_FLAGS=-I$(LUA_DIR)/src
+-LUA_LIBS=$(LUA_DIR)/src/liblua.a
++LUA_LIBS=-llua
+
+ GLBSP_FLAGS=-I$(GLBSP_DIR)/src
+-GLBSP_LIBS=$(GLBSP_DIR)/libglbsp.a
++GLBSP_LIBS=-lglbsp
+
+ CXXFLAGS=$(OPTIMISE) -Wall -D$(OS) \
+ $(FLTK_FLAGS) $(LUA_FLAGS) $(GLBSP_FLAGS)
diff --git a/games/oblige/oblige.SlackBuild b/games/oblige/oblige.SlackBuild
new file mode 100644
index 0000000000000..e306e5c7b19b9
--- /dev/null
+++ b/games/oblige/oblige.SlackBuild
@@ -0,0 +1,76 @@
+#!/bin/sh
+
+# Slackware build script for oblige
+
+# Written by B. Watson (yalhcru@gmail.com)
+
+PRGNAM=oblige
+VERSION=${VERSION:-3.57}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i486 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i486" ]; then
+ SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -e
+
+SRCVER=$( echo $VERSION | sed 's/\.//g' )
+
+rm -rf $PKG
+mkdir -p $TMP $PKG/usr/bin $PKG/usr/share/$PRGNAM $OUTPUT
+cd $TMP
+rm -rf ${PRGNAM}_${SRCVER}_src
+unzip $CWD/$PRGNAM-$SRCVER-src.zip
+cd ${PRGNAM}_${SRCVER}_src
+chown -R root:root .
+find . \
+ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
+ -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
+ -exec chmod 644 {} \;
+
+patch -p1 < $CWD/compile_fixes.diff
+patch -p1 < $CWD/lua_compile_fixes.diff
+
+cd gui
+make -f Makefile.unixy OPTIMISE="$SLKCFLAGS"
+make -f Makefile.unixy install INSTALL_PREFIX=$PKG/usr
+
+mkdir -p $PKG/usr/share/pixmaps $PKG/usr/share/applications
+cat $CWD/$PRGNAM.png > $PKG/usr/share/pixmaps/$PRGNAM.png
+cat $CWD/$PRGNAM.desktop > $PKG/usr/share/applications/$PRGNAM.desktop
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp ../*.txt ../doc/*.txt $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+cat $CWD/doinst.sh > $PKG/install/doinst.sh
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
diff --git a/games/oblige/oblige.desktop b/games/oblige/oblige.desktop
new file mode 100644
index 0000000000000..eaf1178bfc6bb
--- /dev/null
+++ b/games/oblige/oblige.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Type=Application
+Name=Oblige
+GenericName=Doom Level Generator
+Icon=oblige
+Exec=oblige %f
+Terminal=false
+Categories=Game;ActionGame;Utility;
diff --git a/games/oblige/oblige.info b/games/oblige/oblige.info
new file mode 100644
index 0000000000000..d28720edb98d2
--- /dev/null
+++ b/games/oblige/oblige.info
@@ -0,0 +1,10 @@
+PRGNAM="oblige"
+VERSION="3.57"
+HOMEPAGE="http://oblige.sourceforge.net/"
+DOWNLOAD="http://downloads.sourceforge.net/oblige/oblige-357-src.zip"
+MD5SUM="e07ab38282ebcb8cd9e531c2a6d14a55"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+MAINTAINER="B. Watson"
+EMAIL="yalhcru@gmail.com"
+APPROVED="Niels Horn"
diff --git a/games/oblige/oblige.png b/games/oblige/oblige.png
new file mode 100644
index 0000000000000..7d6b6a0f66562
--- /dev/null
+++ b/games/oblige/oblige.png
Binary files differ
diff --git a/games/oblige/slack-desc b/games/oblige/slack-desc
new file mode 100644
index 0000000000000..7d054a6441bd4
--- /dev/null
+++ b/games/oblige/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+oblige: oblige (random level generator for various classic games)
+oblige:
+oblige: OBLIGE is a random level generator for various classic games,
+oblige: including DOOM, DOOM II, Heretic, and Quake. The goal is to produce
+oblige: high quality levels which are fun to play.
+oblige:
+oblige:
+oblige:
+oblige:
+oblige:
+oblige: