From ae460b682e223fc1f66366ade2737b11fe56eead Mon Sep 17 00:00:00 2001 From: Schrijvers Luc Date: Sun, 28 Apr 2019 14:39:26 +0200 Subject: [PATCH] love: bump version (#3798) --- games-engines/love/love-11.2.recipe | 125 ++++++++++++++++++ games-engines/love/patches/love-11.2.patchset | 81 ++++++++++++ 2 files changed, 206 insertions(+) create mode 100644 games-engines/love/love-11.2.recipe create mode 100644 games-engines/love/patches/love-11.2.patchset diff --git a/games-engines/love/love-11.2.recipe b/games-engines/love/love-11.2.recipe new file mode 100644 index 000000000..930aac0ca --- /dev/null +++ b/games-engines/love/love-11.2.recipe @@ -0,0 +1,125 @@ +SUMMARY="A framework to make 2D games in Lua" +DESCRIPTION="LÖVE is a framework to make 2D games in Lua. +It's free, open-source, and works also on Windows, Mac OS X and Linux." +HOMEPAGE="http://love2d.org/" +COPYRIGHT="2010-2018 Löve" +LICENSE="Zlib" +REVISION="1" +SOURCE_URI="https://bitbucket.org/rude/love/downloads/love-$portVersion-linux-src.tar.gz" +CHECKSUM_SHA256="6aaf8104fc35bb8bbd7865986b98079e7564ffdb374ea4d33604b46b458444f6" +PATCHES="love-$portVersion.patchset" +ADDITIONAL_FILES="love.rdef.in" + +ARCHITECTURES="!x86_gcc2 x86 x86_64" +SECONDARY_ARCHITECTURES="x86" + +PROVIDES=" + love$secondaryArchSuffix = $portVersion + cmd:love$secondaryArchSuffix = $portVersion + lib:liblove_11.2$secondaryArchSuffix = $portVersion + " +REQUIRES=" + haiku$secondaryArchSuffix + lib:libbz2$secondaryArchSuffix + lib:libfreetype$secondaryArchSuffix + lib:libGL$secondaryArchSuffix + lib:libIL$secondaryArchSuffix + lib:libjasper$secondaryArchSuffix + lib:libjpeg$secondaryArchSuffix + lib:libluajit_5.1$secondaryArchSuffix + lib:libmng$secondaryArchSuffix + lib:libmodplug$secondaryArchSuffix + lib:libmpg123$secondaryArchSuffix + lib:libogg$secondaryArchSuffix + lib:libopenal$secondaryArchSuffix + lib:libphysfs$secondaryArchSuffix + lib:libpng16$secondaryArchSuffix + lib:libSDL2_2.0$secondaryArchSuffix + lib:libtheora$secondaryArchSuffix + lib:libtiff$secondaryArchSuffix + lib:libvorbis$secondaryArchSuffix + lib:libvorbisfile$secondaryArchSuffix + lib:libz$secondaryArchSuffix + " + +PROVIDES_devel=" + love${secondaryArchSuffix}_devel = $portVersion + devel:liblove$secondaryArchSuffix = $portVersion + devel:liblove_11.2$secondaryArchSuffix = $portVersion + " +REQUIRES_devel=" + love$secondaryArchSuffix == $portVersion base + " + +BUILD_REQUIRES=" + haiku${secondaryArchSuffix}_devel + devel:libbz2$secondaryArchSuffix + devel:libfreetype$secondaryArchSuffix + devel:libGL$secondaryArchSuffix + devel:libIL$secondaryArchSuffix + devel:libjasper$secondaryArchSuffix + devel:libjpeg$secondaryArchSuffix + devel:libluajit_5.1$secondaryArchSuffix + devel:libmng$secondaryArchSuffix + devel:libmodplug$secondaryArchSuffix + devel:libmpg123$secondaryArchSuffix + devel:libogg$secondaryArchSuffix + devel:libopenal$secondaryArchSuffix + devel:libphysfs$secondaryArchSuffix + devel:libpng16$secondaryArchSuffix + devel:libSDL2_2.0$secondaryArchSuffix + devel:libtheora$secondaryArchSuffix + devel:libtiff$secondaryArchSuffix + devel:libvorbis$secondaryArchSuffix + devel:libvorbisfile$secondaryArchSuffix + devel:libz$secondaryArchSuffix + " +BUILD_PREREQUIRES=" + cmd:awk + cmd:cmp + cmd:dd + cmd:diff + cmd:gcc$secondaryArchSuffix + cmd:ld$secondaryArchSuffix + cmd:make + cmd:pkg_config$secondaryArchSuffix + " + +BUILD() +{ + runConfigure ./configure + + make $jobArgs +} + +INSTALL() +{ + make install + + # remove libtool file *.la + rm -f $libDir/*.la + + # remove not relevant files + rm -rf $dataDir/{applications,icons,pixmaps} + + local MAJOR="`echo "$portVersion" | cut -d. -f1`" + local MIDDLE="`echo "$portVersion" | cut -d. -f2`" + local MINOR="0" + sed \ + -e "s|@MAJOR@|$MAJOR|" \ + -e "s|@MIDDLE@|$MIDDLE|" \ + -e "s|@MINOR@|$MINOR|" \ + $portDir/additional-files/love.rdef.in > love.rdef + + addResourcesToBinaries love.rdef $binDir/love + + prepareInstalledDevelLibs liblove-11.2 liblove + + packageEntries devel \ + $developDir +} + +TEST() +{ + make test +} diff --git a/games-engines/love/patches/love-11.2.patchset b/games-engines/love/patches/love-11.2.patchset new file mode 100644 index 000000000..9c3a440e5 --- /dev/null +++ b/games-engines/love/patches/love-11.2.patchset @@ -0,0 +1,81 @@ +From 54940c74788c7448aef59ed905382f325d2e0725 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Zolt=C3=A1n=20Mizsei?= +Date: Sat, 6 May 2017 11:09:02 +0200 +Subject: Add Haiku to the known platforms + + +diff --git a/src/common/config.h b/src/common/config.h +index 8180f6a..72b2496 100644 +--- a/src/common/config.h ++++ b/src/common/config.h +@@ -48,7 +48,7 @@ + # define LOVE_MACOSX 1 + # endif + #endif +-#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) ++#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__HAIKU__) + // I know it's not linux, but it seems most "linux-only" code is bsd-compatible + # define LOVE_LINUX 1 + #endif +-- +2.21.0 + + +From 7c7271e6df5942b92772e3c66729ac7544d9157a Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Zolt=C3=A1n=20Mizsei?= +Date: Sat, 6 May 2017 11:18:30 +0200 +Subject: Build fix for Haiku + + +diff --git a/src/modules/system/System.cpp b/src/modules/system/System.cpp +index d85a947..3a9d441 100644 +--- a/src/modules/system/System.cpp ++++ b/src/modules/system/System.cpp +@@ -39,8 +39,10 @@ + #if defined(LOVE_ANDROID) + #include "common/android.h" + #elif defined(LOVE_LINUX) ++#ifndef __HAIKU__ + #include + #endif ++#endif + + namespace love + { +@@ -106,8 +108,10 @@ bool System::openURL(const std::string &url) const + + // Note: at the moment this process inherits our file descriptors. + // Note: the below const_cast is really ugly as well. ++ #ifndef __HAIKU__ + if (posix_spawnp(&pid, "xdg-open", nullptr, nullptr, const_cast(argv), environ) != 0) + return false; ++ #endif + + // Check if xdg-open already completed (or failed.) + int status = 0; +-- +2.21.0 + + +From 7aa2107230bf7b8ec1322f38bd16e87a87bcfadb Mon Sep 17 00:00:00 2001 +From: begasus +Date: Fri, 26 Apr 2019 19:14:39 +0200 +Subject: Build fix for Haiku #2 + + +diff --git a/src/libraries/luasocket/libluasocket/compat.h b/src/libraries/luasocket/libluasocket/compat.h +index 7bf8010..9e3b43f 100644 +--- a/src/libraries/luasocket/libluasocket/compat.h ++++ b/src/libraries/luasocket/libluasocket/compat.h +@@ -5,6 +5,8 @@ + #include "lauxlib.h" + + #if LUA_VERSION_NUM==501 ++#define luaL_setfuncs socket_setfuncs ++#define luaL_testudata socket_testudata + void luaL_setfuncs (lua_State *L, const luaL_Reg *l, int nup); + #endif + +-- +2.21.0 +