summaryrefslogtreecommitdiff
path: root/games/megaglest/megaglest.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'games/megaglest/megaglest.SlackBuild')
-rw-r--r--games/megaglest/megaglest.SlackBuild16
1 files changed, 14 insertions, 2 deletions
diff --git a/games/megaglest/megaglest.SlackBuild b/games/megaglest/megaglest.SlackBuild
index e72f00d757..b6a644667c 100644
--- a/games/megaglest/megaglest.SlackBuild
+++ b/games/megaglest/megaglest.SlackBuild
@@ -22,6 +22,15 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 20210215 bkw: modified by SlackBuilds.org: This build was broken for
+# *3 years* and nobody ever complained...
+# - Add -std=c++11 to CXXFLAGS.
+# - Force cmake to use lua 5.1. This fixes the build on systems where
+# both lua and (lua52 and/or lua53) are installed.
+# - Add -j1 to the 'make install' because the xvfb-run script fails if
+# a 2nd instance is started (and get rid of parallel build warning
+# in README).
+
PRGNAM=megaglest
VERSION=${VERSION:-3.13.0}
BUILD=${BUILD:-1}
@@ -82,17 +91,20 @@ patch -p1 < $CWD/megaglest-underlink.patch
mkdir build
cd build
cmake -G "Unix Makefiles" \
+ -DLUA_LIBRARY="/usr/lib$LIBDIRSUFFIX/liblua.so" \
+ -DLUA_INCLUDE_DIR="/usr/include/" \
+ -DLUA_MATH_LIBRARY="/usr/lib$LIBDIRSUFFIX/libm.so" \
-DCMAKE_INSTALL_PREFIX:PATH=/usr \
-DWANT_GIT_STAMP=OFF \
-DMEGAGLEST_BIN_INSTALL_PATH:PATH="games/" \
-DMEGAGLEST_MANPAGE_INSTALL_PATH:PATH="man/man6/" \
-DWANT_USE_XercesC:BOOL=ON \
-DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
- -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
+ -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS -std=c++11" \
-DCMAKE_BUILD_TYPE=Release ..
make VERBOSE=1
- make install DESTDIR=$PKG
+ make -j1 install DESTDIR=$PKG
cd -
# Now install the game data