summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorM0Rf302016-07-07 17:44:34 +0200
committerM0Rf302016-07-07 17:44:34 +0200
commitf9644dd11899bc9e36e94766e13dc5315c36a512 (patch)
treed02d7ac3ed69943e1dad4ebe1349fcab183fe10b
parent7f44953af804bdec1af84e1a82b510551c15910f (diff)
downloadaur-f9644dd11899bc9e36e94766e13dc5315c36a512.tar.gz
fixed textrender compilation issue on gcc6
-rw-r--r--.SRCINFO6
-rw-r--r--PKGBUILD13
-rw-r--r--dde2726796d8cfc4e2ad9793b045182f1a1ec082.patch33
3 files changed, 45 insertions, 7 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 11024cdd26ed..2e0639b7fc57 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,9 +1,9 @@
# Generated by mksrcinfo v8
-# Mon Jan 18 15:32:49 UTC 2016
+# Thu Jul 7 15:43:57 UTC 2016
pkgbase = assaultcube-reloaded
pkgdesc = AssaultCube Reloaded
pkgver = 2.6.3
- pkgrel = 1
+ pkgrel = 2
url = http://acr.victorz.ca
arch = i686
arch = x86_64
@@ -25,11 +25,13 @@ pkgbase = assaultcube-reloaded
source = acreloaded-server
source = acreloaded.desktop
source = acreloaded.svg
+ source = dde2726796d8cfc4e2ad9793b045182f1a1ec082.patch
md5sums = 260e71aa128710012a94e53fdde61286
md5sums = c6db5816ce66282f6d6c7d08792b6095
md5sums = 53b17712afb7f0a5646b9894032d06ff
md5sums = bff621e554812c7325b2bd7f56e9e881
md5sums = 3b142417157d73da4a7981fd07bcb628
+ md5sums = 45a0c9247df6cd6547ee9f90ff181024
pkgname = assaultcube-reloaded
diff --git a/PKGBUILD b/PKGBUILD
index 1b3ace222458..f279fc674264 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=assaultcube-reloaded
pkgver=2.6.3
-pkgrel=1
+pkgrel=2
pkgdesc='AssaultCube Reloaded'
arch=('i686' 'x86_64')
url='http://acr.victorz.ca'
@@ -13,12 +13,14 @@ source=("https://github.com/actf/acr/archive/v${pkgver}.tar.gz"
'acreloaded'
'acreloaded-server'
'acreloaded.desktop'
- 'acreloaded.svg')
+ 'acreloaded.svg'
+ dde2726796d8cfc4e2ad9793b045182f1a1ec082.patch)
package() {
- mkdir -p ${pkgdir}/usr/bin
-
+ install -d "${pkgdir}"/usr/bin
+ install -d "${pkgdir}"/usr/share/acreloaded
cd ${srcdir}/acr-${pkgver}
+ patch -Np1 -i ../dde2726796d8cfc4e2ad9793b045182f1a1ec082.patch
cd source/src
make DESTDIR=$pkgdir install
@@ -44,4 +46,5 @@ md5sums=('260e71aa128710012a94e53fdde61286'
'c6db5816ce66282f6d6c7d08792b6095'
'53b17712afb7f0a5646b9894032d06ff'
'bff621e554812c7325b2bd7f56e9e881'
- '3b142417157d73da4a7981fd07bcb628')
+ '3b142417157d73da4a7981fd07bcb628'
+ '45a0c9247df6cd6547ee9f90ff181024')
diff --git a/dde2726796d8cfc4e2ad9793b045182f1a1ec082.patch b/dde2726796d8cfc4e2ad9793b045182f1a1ec082.patch
new file mode 100644
index 000000000000..cbca543d35dc
--- /dev/null
+++ b/dde2726796d8cfc4e2ad9793b045182f1a1ec082.patch
@@ -0,0 +1,33 @@
+From dde2726796d8cfc4e2ad9793b045182f1a1ec082 Mon Sep 17 00:00:00 2001
+From: Victor <theonlypwner@users.noreply.github.com>
+Date: Mon, 4 Jul 2016 11:43:56 -0600
+Subject: [PATCH] Update blinking text code and fix #200
+
+---
+ source/src/rendertext.cpp | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/source/src/rendertext.cpp b/source/src/rendertext.cpp
+index 5ddc698..22f7a34 100644
+--- a/source/src/rendertext.cpp
++++ b/source/src/rendertext.cpp
+@@ -330,7 +330,7 @@ static void text_color(char c, char *stack, int size, int &sp, bvec color, int a
+ if(c=='r') c = stack[(sp > 0) ? --sp : sp]; // restore color
+ else if(c == 'b') { if(allowblinkingtext && !ignoreblinkingbit) stack[sp] *= -1; } // blinking text - only if allowed
+ else stack[sp] = c;
+- switch(abs(stack[sp]))
++ switch(abs(static_cast<int>(stack[sp])))
+ {
+ case '0': color = bvec( 2, 255, 128 ); break; // green: player talk
+ case '1': color = bvec( 96, 160, 255 ); break; // blue: team chat
+@@ -383,7 +383,9 @@ static void text_color(char c, char *stack, int size, int &sp, bvec color, int a
+ // white (provided color): everything else
+ //default: color = bvec( 255, 255, 255 ); break;
+ }
+- glColor4ub(color.x, color.y, color.z, stack[sp] > 0 ? a : a * min<float>(fabs(sinf(lastmillis / 200.f) * 1.15f), 1.f));
++ if (stack[sp] <= 0)
++ a = min(abs((int) (a * sinf(lastmillis / 200.0f) * 1.15f)), 100);
++ glColor4ub(color.x, color.y, color.z, a);
+ }
+ }
+