summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Chai2016-10-14 15:59:28 -0500
committerJames Chai2016-10-14 16:01:05 -0500
commit05cad5b7b76cd5b7afa8b260bf93562715d3d487 (patch)
treead83981361761c886e49b48cdd5af05b6e9b1bed
parent50f8a38f415d025589001d591589a367fb1d5d9f (diff)
downloadaur-05cad5b7b76cd5b7afa8b260bf93562715d3d487.tar.gz
now compiles in gnome 3.22
-rw-r--r--.SRCINFO8
-rw-r--r--0000-TextWriter.patch21
-rw-r--r--0001-Makefile-CXXFLAGS.patch24
-rw-r--r--PKGBUILD17
4 files changed, 61 insertions, 9 deletions
diff --git a/.SRCINFO b/.SRCINFO
index ff0ce90a6981..0029c08cf456 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,9 +1,9 @@
# Generated by mksrcinfo v8
-# Thu Dec 31 01:21:07 UTC 2015
+# Fri Oct 14 21:00:51 UTC 2016
pkgbase = linthesia
pkgdesc = A game of playing music. A fork of Synthesia
pkgver = 0.4.3
- pkgrel = 3
+ pkgrel = 4
url = http://linthesia.sourceforge.net/
arch = i686
arch = x86_64
@@ -19,7 +19,11 @@ pkgbase = linthesia
depends = alsa-lib
depends = fluidsynth
source = svn+http://svn.code.sf.net/p/linthesia/code/#revision=r87
+ source = 0000-TextWriter.patch
+ source = 0001-Makefile-CXXFLAGS.patch
sha256sums = SKIP
+ sha256sums = 7953b732355bae0417d2eaff421a46d786201f104db289caa291a6a36f6fc199
+ sha256sums = 9e331f9f4656837bb1b89c1ff36e8499a6a392eec28855f5f73b856c7dea4c78
pkgname = linthesia
diff --git a/0000-TextWriter.patch b/0000-TextWriter.patch
new file mode 100644
index 000000000000..9b397517000e
--- /dev/null
+++ b/0000-TextWriter.patch
@@ -0,0 +1,21 @@
+diff -ra -U3 a/src/TextWriter.cpp b/src/TextWriter.cpp
+--- a/src/TextWriter.cpp 2016-10-14 15:43:47.264744000 -0500
++++ b/src/TextWriter.cpp 2016-10-14 15:52:09.558097860 -0500
+@@ -62,7 +62,7 @@
+ fontname = STRING(fontname << " " << in_size);
+ Pango::FontDescription* font_desc = new Pango::FontDescription(fontname);
+ Glib::RefPtr<Pango::Font> ret = Gdk::GL::Font::use_pango_font(*font_desc, 0, 128, list_start);
+- if (ret == 0)
++ if (!ret)
+ throw LinthesiaError("An error ocurred while trying to use use_pango_font() with "
+ "font '" + fontname + "'");
+
+@@ -100,7 +100,7 @@
+ glPopMatrix();
+
+ // TODO: Should probably delete these on shutdown.
+- //glDeleteLists(1000, 128);
++ glDeleteLists(1000, 128);
+
+ return tw;
+ }
diff --git a/0001-Makefile-CXXFLAGS.patch b/0001-Makefile-CXXFLAGS.patch
new file mode 100644
index 000000000000..bbfb8b6d1762
--- /dev/null
+++ b/0001-Makefile-CXXFLAGS.patch
@@ -0,0 +1,24 @@
+diff -ra -U3 a/src/libmidi/Makefile b/src/libmidi/Makefile
+--- a/src/libmidi/Makefile 2016-10-14 15:35:27.884724000 -0500
++++ b/src/libmidi/Makefile 2016-10-14 15:39:39.681401308 -0500
+@@ -1,7 +1,7 @@
+ # -*- mode: makefile-gmake; coding: utf-8 -*-
+
+ CXX = g++
+-CXXFLAGS = -I . -I .. -ansi -Wall
++CXXFLAGS = -I . -I .. -ansi -Wall -O2 -fPIC
+ TARGET = libmidi.a
+
+ all: $(TARGET)
+diff -ra -U3 a/src/Makefile b/src/Makefile
+--- a/src/Makefile 2016-10-14 15:35:27.978057000 -0500
++++ b/src/Makefile 2016-10-14 15:39:30.234734267 -0500
+@@ -3,7 +3,7 @@
+ GRAPHDIR?=../graphics
+
+ CXX = g++
+-CXXFLAGS = -I . -I libmidi -ggdb -Wall -ansi
++CXXFLAGS = -I . -I libmidi -ggdb -Wall -ansi -O2 -std=c++11 -fPIC
+ CXXFLAGS += `pkg-config --cflags gtkmm-2.4 gconfmm-2.6 gtkglextmm-1.2 alsa` -DGRAPHDIR="\"$(GRAPHDIR)\""
+ LDFLAGS = `pkg-config --libs gtkmm-2.4 gconfmm-2.6 gtkglextmm-1.2 alsa`
+ TARGET = linthesia
diff --git a/PKGBUILD b/PKGBUILD
index d01091ab6e88..0a238c9d5f0a 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,22 +2,25 @@
pkgname=linthesia
pkgver=0.4.3
-pkgrel=3
+pkgrel=4
pkgdesc="A game of playing music. A fork of Synthesia"
arch=('i686' 'x86_64')
url="http://linthesia.sourceforge.net/"
license=('GPL2')
depends=('gtkmm' 'gconfmm' 'gtkglextmm' 'alsa-lib' 'fluidsynth')
makedepends=('gtkmm' 'gconfmm' 'gtkglextmm' 'alsa-lib' 'svn')
-source=("svn+http://svn.code.sf.net/p/linthesia/code/#revision=r87")
-sha256sums=('SKIP')
+source=("svn+http://svn.code.sf.net/p/linthesia/code/#revision=r87"
+0000-TextWriter.patch
+0001-Makefile-CXXFLAGS.patch)
+sha256sums=('SKIP' '7953b732355bae0417d2eaff421a46d786201f104db289caa291a6a36f6fc199' '9e331f9f4656837bb1b89c1ff36e8499a6a392eec28855f5f73b856c7dea4c78')
build() {
- cd "$srcdir/code/src"
- sed -i Makefile -e "s/^CXXFLAGS = -I . -I libmidi -ggdb -Wall -ansi$/CXXFLAGS = -I . -I libmidi -ggdb -Wall -ansi -std=gnu++11 -std=c++11/g"
+ cd "$srcdir/code"
+ patch -p1 -i "$srcdir/0000-TextWriter-ptr-compare.patch"
+ patch -p1 -i "$srcdir/0001-Makefile-CXXFLAGS.patch"
make GRAPHDIR="/usr/share/linthesia/graphics"
cd "$srcdir/code/extra"
- sed "s/Exec=linthesia/Exec=\/usr\/games\/linthesia/g" linthesia.desktop > linthesia.desktop.new
+ sed -i linthesia.desktop -e "s/Exec=linthesia/Exec=\/usr\/games\/linthesia/g"
}
package () {
@@ -25,7 +28,7 @@ package () {
make DESTDIR="$pkgdir" install
# Install desktop file
mkdir "$pkgdir/usr/share/applications"
- install -Tm644 extra/linthesia.desktop.new $pkgdir/usr/share/applications/linthesia.desktop
+ install -Tm644 extra/linthesia.desktop $pkgdir/usr/share/applications/linthesia.desktop
# Install pixmap
mkdir "$pkgdir/usr/share/pixmaps"
install -Tm644 extra/linthesia.xpm $pkgdir/usr/share/pixmaps/linthesia.xpm