initial import
This commit is contained in:
52
warzone2100-legacy/PKGBUILD
Normal file
52
warzone2100-legacy/PKGBUILD
Normal file
@@ -0,0 +1,52 @@
|
||||
# Maintainer: Jesus E. <heckyel@riseup.net>
|
||||
|
||||
_realpkgname=warzone2100
|
||||
pkgname=$_realpkgname-legacy
|
||||
pkgver=2.3.9
|
||||
pkgrel=4
|
||||
pkgdesc="3D realtime strategy game on a future Earth (legacy-version)"
|
||||
url='https://sourceforge.net/projects/warzone2100'
|
||||
arch=('i686' 'x86_64')
|
||||
license=('GPL-2' 'Original-BSD' 'Modified-BSD' 'Public-Domain' 'CC-BY-SA-3.0')
|
||||
depends=('sdl' 'openal' 'libpng' 'libvorbis' 'libtheora' 'physfs' 'quesoglc' 'popt' 'ttf-dejavu')
|
||||
makedepends=('gawk' 'bison' 'flex' 'zip' 'unzip' 'asciidoc')
|
||||
groups=('games')
|
||||
source=("https://sourceforge.net/projects/warzone2100/files/archives/unsupported/Warzone2100-2.3/${pkgver}/${_realpkgname}-${pkgver}.tar.gz"
|
||||
"https://sourceforge.net/projects/warzone2100/files/warzone2100/Videos/low-quality-en/sequences.wz"
|
||||
"fix-build.patch")
|
||||
sha512sums=('3af34969e701e089886a228f7e2c33b61d763adcfebe6f8f0ac3cdb24ed133173dbf051c544e12e74f278b7193f4cbc79bb1df2d1a974f8d03575557695a8662'
|
||||
'd7fab931af53dbdf33d560544984fcb332318c1e122525550c2d5f01ec5726e28d98d8f2905c09959e59fa1fdcbf0986f0fc18f80d016eaaf44938dfef6052d2'
|
||||
'4254c9b9826e1ecffcbbc858120179f2c495d4be8619af2094adfced775294d6cf677266e914571993cf8da6a4728718685ebeaaaf3295c41a281a74518720a9')
|
||||
|
||||
build() {
|
||||
cd ${_realpkgname}-${pkgver}
|
||||
|
||||
./configure LIBS="-lvorbis" \
|
||||
--prefix=/usr \
|
||||
--bindir=/usr/games \
|
||||
--datadir=/usr/share/games \
|
||||
--with-distributor="Hyperbola"
|
||||
|
||||
# additional fixes
|
||||
patch -Np1 -i ${srcdir}/fix-build.patch
|
||||
|
||||
make
|
||||
}
|
||||
|
||||
package() {
|
||||
cd ${_realpkgname}-${pkgver}
|
||||
|
||||
# package-preparation, being FHS-compliant
|
||||
make DESTDIR=${pkgdir} PREFIX="/usr" BINDIR="/usr/games" DATADIR="/usr/share/games" install
|
||||
|
||||
# correcting wrong folder-locations
|
||||
mv "${pkgdir}/usr/share/games/applications" "${pkgdir}/usr/share/"
|
||||
mv "${pkgdir}/usr/share/games/icons" "${pkgdir}/usr/share/"
|
||||
|
||||
# additional data
|
||||
install -Dm644 "${srcdir}/sequences.wz" -t "${pkgdir}/usr/share/games/${_realpkgname}"
|
||||
|
||||
# license
|
||||
install -Dm644 "${srcdir}/${_realpkgname}-${pkgver}/COPYING" -t "${pkgdir}/usr/share/licenses/${pkgname}"
|
||||
install -Dm644 "${srcdir}/${_realpkgname}-${pkgver}/COPYING.NONGPL" -t "${pkgdir}/usr/share/licenses/${pkgname}"
|
||||
}
|
||||
87
warzone2100-legacy/fix-build.patch
Normal file
87
warzone2100-legacy/fix-build.patch
Normal file
@@ -0,0 +1,87 @@
|
||||
--- a/build_tools/autorevision/autorevision.cpp 2011-10-23 22:05:12.000000000 +0200
|
||||
+++ b/build_tools/autorevision/autorevision.cpp 2021-06-16 20:25:30.037820011 +0200
|
||||
@@ -635,7 +635,7 @@
|
||||
|
||||
const string cwd(GetWorkingDir());
|
||||
if (!ChangeDir(_workingDir))
|
||||
- return false;
|
||||
+ return result;
|
||||
|
||||
set_env("LANG", "C");
|
||||
set_env("LC_ALL", "C");
|
||||
@@ -645,7 +645,7 @@
|
||||
ChangeDir(cwd);
|
||||
|
||||
if (!process)
|
||||
- return false;
|
||||
+ return result;
|
||||
|
||||
char buf[1024];
|
||||
if (fgets(buf, sizeof(buf), process))
|
||||
--- a/lib/ivis_opengl/piedraw.c 2011-10-23 22:05:14.000000000 +0200
|
||||
+++ b/lib/ivis_opengl/piedraw.c 2025-01-09 17:19:47.927557356 +0100
|
||||
@@ -648,53 +648,21 @@
|
||||
op_depth_pass_back = GL_DECR_WRAP_EXT;
|
||||
}
|
||||
|
||||
- // generic 1-pass version
|
||||
- if (GLEE_EXT_stencil_two_side)
|
||||
- {
|
||||
- glEnable(GL_STENCIL_TEST_TWO_SIDE_EXT);
|
||||
- glDisable(GL_CULL_FACE);
|
||||
- glStencilMask(~0);
|
||||
- glActiveStencilFaceEXT(GL_BACK);
|
||||
- glStencilOp(GL_KEEP, GL_KEEP, op_depth_pass_back);
|
||||
- glStencilFunc(GL_ALWAYS, 0, ~0);
|
||||
- glActiveStencilFaceEXT(GL_FRONT);
|
||||
- glStencilOp(GL_KEEP, GL_KEEP, op_depth_pass_front);
|
||||
- glStencilFunc(GL_ALWAYS, 0, ~0);
|
||||
-
|
||||
- pie_ShadowDrawLoop();
|
||||
-
|
||||
- glDisable(GL_STENCIL_TEST_TWO_SIDE_EXT);
|
||||
- }
|
||||
- // check for ATI-specific 1-pass version
|
||||
- else if (GLEE_ATI_separate_stencil)
|
||||
- {
|
||||
- glDisable(GL_CULL_FACE);
|
||||
- glStencilMask(~0);
|
||||
- glStencilOpSeparateATI(GL_BACK, GL_KEEP, GL_KEEP, op_depth_pass_back);
|
||||
- glStencilOpSeparateATI(GL_FRONT, GL_KEEP, GL_KEEP, op_depth_pass_front);
|
||||
- glStencilFunc(GL_ALWAYS, 0, ~0);
|
||||
-
|
||||
- pie_ShadowDrawLoop();
|
||||
- }
|
||||
- // fall back to default 2-pass version
|
||||
- else
|
||||
- {
|
||||
- glStencilMask(~0);
|
||||
- glStencilFunc(GL_ALWAYS, 0, ~0);
|
||||
- glEnable(GL_CULL_FACE);
|
||||
+ glStencilMask(~0);
|
||||
+ glStencilFunc(GL_ALWAYS, 0, ~0);
|
||||
+ glEnable(GL_CULL_FACE);
|
||||
|
||||
- // Setup stencil for front-facing polygons
|
||||
- glCullFace(GL_BACK);
|
||||
- glStencilOp(GL_KEEP, GL_KEEP, op_depth_pass_front);
|
||||
+ // Setup stencil for front-facing polygons
|
||||
+ glCullFace(GL_BACK);
|
||||
+ glStencilOp(GL_KEEP, GL_KEEP, op_depth_pass_front);
|
||||
|
||||
- pie_ShadowDrawLoop();
|
||||
+ pie_ShadowDrawLoop();
|
||||
|
||||
- // Setup stencil for back-facing polygons
|
||||
- glCullFace(GL_FRONT);
|
||||
- glStencilOp(GL_KEEP, GL_KEEP, op_depth_pass_back);
|
||||
+ // Setup stencil for back-facing polygons
|
||||
+ glCullFace(GL_FRONT);
|
||||
+ glStencilOp(GL_KEEP, GL_KEEP, op_depth_pass_back);
|
||||
|
||||
- pie_ShadowDrawLoop();
|
||||
- }
|
||||
+ pie_ShadowDrawLoop();
|
||||
|
||||
glEnable(GL_CULL_FACE);
|
||||
glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE);
|
||||
Reference in New Issue
Block a user