[proaudio] [2091] games-misc/linthesia import. |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/proaudio Archives
]
Revision: 2091
Author: gavlee
Date: 2012-01-23 12:36:37 +0100 (Mon, 23 Jan 2012)
Log Message:
-----------
games-misc/linthesia import. piano training application
Added Paths:
-----------
trunk/overlays/proaudio/games-misc/
trunk/overlays/proaudio/games-misc/linthesia/
trunk/overlays/proaudio/games-misc/linthesia/ChangeLog
trunk/overlays/proaudio/games-misc/linthesia/Manifest
trunk/overlays/proaudio/games-misc/linthesia/files/
trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-Makefiles.patch
trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-pango-font-loading.patch
trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-wordsize-bugs.patch
trunk/overlays/proaudio/games-misc/linthesia/linthesia-0.4_p2.ebuild
trunk/overlays/proaudio/games-misc/linthesia/metadata.xml
Added: trunk/overlays/proaudio/games-misc/linthesia/ChangeLog
===================================================================
--- trunk/overlays/proaudio/games-misc/linthesia/ChangeLog (rev 0)
+++ trunk/overlays/proaudio/games-misc/linthesia/ChangeLog 2012-01-23 11:36:37 UTC (rev 2091)
@@ -0,0 +1,12 @@
+# ChangeLog for games-misc/linthesia
+# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
+# $Header: $
+
+*linthesia-0.4_p2 (23 Jan 2012)
+
+ 23 Jan 2012; Gavin Pryke <gavinlee303@xxxxxxxxxxxxxx>
+ +linthesia-0.4_p2.ebuild, +files/linthesia-0.4_p2-Makefiles.patch,
+ +files/linthesia-0.4_p2-pango-font-loading.patch,
+ +files/linthesia-0.4_p2-wordsize-bugs.patch, +metadata.xml:
+ import from my overlay
+
Added: trunk/overlays/proaudio/games-misc/linthesia/Manifest
===================================================================
--- trunk/overlays/proaudio/games-misc/linthesia/Manifest (rev 0)
+++ trunk/overlays/proaudio/games-misc/linthesia/Manifest 2012-01-23 11:36:37 UTC (rev 2091)
@@ -0,0 +1,7 @@
+AUX linthesia-0.4_p2-Makefiles.patch 1413 RMD160 52e06510a339469749b4a438317a97b21983ecd0 SHA1 f856973265551f4f07f92266d744748c37986486 SHA256 f0956e043d86b247d961a3c885ecc8a17c7203339a32eecc729f18efffc5f3d2
+AUX linthesia-0.4_p2-pango-font-loading.patch 260 RMD160 16898708ca1834cc4ab6b34ace95c1ee060a77f0 SHA1 f464be019083d654fd5679ffbf082aacb830dca4 SHA256 b702466159a2cff629c239e930d5abb526b8eeedac27cf80bc6923bf7305d116
+AUX linthesia-0.4_p2-wordsize-bugs.patch 2043 RMD160 b595b492d4b62c3a5860ef668acb4b646eca3ba1 SHA1 b0d32ffcab02562090d880c4f929b40721770355 SHA256 13ddd417cc5a393301284eb06a4a22a4ce643753e45448b888d1ba64d409dd68
+DIST linthesia-0.4-2.src.tgz 399392 RMD160 eac8ebf40f85e6a29e7b2ed7237883ed47bb21ae SHA1 644427626085896606a2af1e2b00d8009694fd6a SHA256 b9002f5605a517e634f031d7781e4cf8853308fa719e790af520032bd7229132
+EBUILD linthesia-0.4_p2.ebuild 1747 RMD160 eee88022949e7206dd54980add1ee28c4da1001a SHA1 02697caaf21ba1318a6525b6d750c190380d7aed SHA256 fc2873911fc9f444f6da967cc453bf87d6547265cda8ba6cefaac1943a8f36ab
+MISC ChangeLog 419 RMD160 56c349e22dc334e1495130a7beeb39eaf8e80b74 SHA1 4860da5ef0ef37ac8008387e0ba414c405ea95b8 SHA256 3ef10cb28293198578cbfcd182f71f061b0ec7f69cd6007d86da6f67833551ca
+MISC metadata.xml 246 RMD160 cdd725771833663c8cfa684c4c71e57d86d9993d SHA1 973be5799e631fd26fb4abcfc8da942f2f759d06 SHA256 f32f31abe9dcc1f9a5dc9b6a36996d773abd006d92c13c4df48f8d7d1061060f
Added: trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-Makefiles.patch
===================================================================
--- trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-Makefiles.patch (rev 0)
+++ trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-Makefiles.patch 2012-01-23 11:36:37 UTC (rev 2091)
@@ -0,0 +1,46 @@
+--- src/Makefile.orig 2012-01-06 22:36:53.525717440 +0000
++++ src/Makefile 2012-01-06 23:21:41.457211051 +0000
+@@ -2,10 +2,10 @@
+
+ GRAPHDIR?=../graphics
+
+-CXX = g++
+-CXXFLAGS = -I . -I libmidi -ggdb -Wall -ansi
++CXX ?= g++
++CXXFLAGS += -I . -I libmidi -Wall -ansi
+ 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`
++LDLIBS = `pkg-config --libs gtkmm-2.4 gconfmm-2.6 gtkglextmm-1.2 alsa`
+ TARGET = linthesia
+
+ all: $(TARGET)
+@@ -16,14 +16,14 @@
+ MenuLayout.o DeviceTile.o StringTile.o MidiComm.o \
+ TrackSelectionState.o TrackTile.o PlayingState.o \
+ StatsState.o KeyboardDisplay.o libmidi/libmidi.a
+- $(CXX) $(LDFLAGS) -o $@ $^
++ $(CXX) $(LDFLAGS) -o $@ $^ $(LDLIBS)
+
+ libmidi/libmidi.a:
+ $(MAKE) -C libmidi
+
+ install: all
+- -mkdir -p $(DESTDIR)/usr/games
+- install -m 755 $(TARGET) -g root -o root $(DESTDIR)/usr/games/
++ -mkdir -p $(DESTDIR)/usr/games/bin
++ install -m 755 $(TARGET) -g root -o root $(DESTDIR)/usr/games/bin
+
+ .PHONY:clean
+ clean:
+--- src/libmidi/Makefile.orig 2012-01-06 23:00:25.946224754 +0000
++++ src/libmidi/Makefile 2012-01-06 23:05:09.815316612 +0000
+@@ -1,7 +1,7 @@
+ # -*- mode: makefile-gmake; coding: utf-8 -*-
+
+-CXX = g++
+-CXXFLAGS = -I . -I .. -ansi -Wall
++CXX ?= g++
++CXXFLAGS += -I . -I .. -ansi -Wall
+ TARGET = libmidi.a
+
+ all: $(TARGET)
Added: trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-pango-font-loading.patch
===================================================================
--- trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-pango-font-loading.patch (rev 0)
+++ trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-pango-font-loading.patch 2012-01-23 11:36:37 UTC (rev 2091)
@@ -0,0 +1,11 @@
+--- src/TextWriter.cpp.orig
++++ src/TextWriter.cpp
+@@ -47,7 +47,7 @@
+
+ // Or set it if there is no default
+ if (fontname.empty()) {
+- fontname = "Arial";
++ fontname = "Sans";
+ UserSetting::Set(key, fontname);
+ }
+ }
Added: trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-wordsize-bugs.patch
===================================================================
--- trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-wordsize-bugs.patch (rev 0)
+++ trunk/overlays/proaudio/games-misc/linthesia/files/linthesia-0.4_p2-wordsize-bugs.patch 2012-01-23 11:36:37 UTC (rev 2091)
@@ -0,0 +1,55 @@
+Index: linthesia/src/libmidi/Midi.cpp
+===================================================================
+--- linthesia.orig/src/libmidi/Midi.cpp 2011-06-07 23:29:40.731882380 +0200
++++ linthesia/src/libmidi/Midi.cpp 2011-06-07 23:31:34.196263533 +0200
+@@ -13,6 +13,7 @@
+
+ #include <fstream>
+ #include <map>
++#include <stdint.h>
+
+ using namespace std;
+
+@@ -50,7 +51,7 @@
+ // defined and will always have a 4-byte header. We use 5 so we get
+ // free null termination.
+ char header_id[5] = { 0, 0, 0, 0, 0 };
+- unsigned long header_length;
++ uint32_t header_length;
+ unsigned short format;
+ unsigned short track_count;
+ unsigned short time_division;
+@@ -74,7 +75,7 @@
+ }
+ }
+
+- stream.read(reinterpret_cast<char*>(&header_length), sizeof(unsigned long));
++ stream.read(reinterpret_cast<char*>(&header_length), sizeof(uint32_t));
+ stream.read(reinterpret_cast<char*>(&format), sizeof(unsigned short));
+ stream.read(reinterpret_cast<char*>(&track_count), sizeof(unsigned short));
+ stream.read(reinterpret_cast<char*>(&time_division), sizeof(unsigned short));
+Index: linthesia/src/libmidi/MidiTrack.cpp
+===================================================================
+--- linthesia.orig/src/libmidi/MidiTrack.cpp 2011-06-07 23:31:59.436348321 +0200
++++ linthesia/src/libmidi/MidiTrack.cpp 2011-06-07 23:32:39.252481736 +0200
+@@ -11,6 +11,7 @@
+ #include "MidiUtil.h"
+ #include "Midi.h"
+
++#include <stdint.h>
+ #include <sstream>
+ #include <string>
+ #include <map>
+@@ -26,10 +27,10 @@
+ // defined and will always have a 4-byte header. We use 5 so we get
+ // free null termination.
+ char header_id[5] = { 0, 0, 0, 0, 0 };
+- unsigned long track_length;
++ uint32_t track_length;
+
+ stream.read(header_id, static_cast<streamsize>(MidiTrackHeader.length()));
+- stream.read(reinterpret_cast<char*>(&track_length), sizeof(unsigned long));
++ stream.read(reinterpret_cast<char*>(&track_length), sizeof(uint32_t));
+
+ if (stream.fail())
+ throw MidiError(MidiError_TrackHeaderTooShort);
Added: trunk/overlays/proaudio/games-misc/linthesia/linthesia-0.4_p2.ebuild
===================================================================
--- trunk/overlays/proaudio/games-misc/linthesia/linthesia-0.4_p2.ebuild (rev 0)
+++ trunk/overlays/proaudio/games-misc/linthesia/linthesia-0.4_p2.ebuild 2012-01-23 11:36:37 UTC (rev 2091)
@@ -0,0 +1,67 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=3
+inherit games toolchain-funcs versionator
+
+MY_SFVER="$(get_version_component_range 1-2)"
+MY_PV=${PV/_p/-}
+
+DESCRIPTION="A fork of Synthesia, A game of playing music! You only need a MIDI file to play, and a MIDI keyboard"
+HOMEPAGE="http://linthesia.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/v${MY_SFVER}/${PN}-${MY_PV}.src.tgz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-cpp/gconfmm-2.6
+ >=dev-cpp/gtkglextmm-1.2:1.0
+ >=dev-cpp/gtkmm-2.4:2.4
+ >=media-libs/alsa-lib-1.0.24.1"
+RDEPEND="${DEPEND}"
+
+S=${WORKDIR}/${PN}
+
+PATCHES=(
+# edit makefiles for gentoo
+"${FILESDIR}/${P}-Makefiles.patch"
+# patch taken from ubuntu fixes crash on start when loading midi file on 64-bit
+"${FILESDIR}/${P}-wordsize-bugs.patch"
+# fixes crash for font loading with pango
+"${FILESDIR}/${P}-pango-font-loading.patch"
+)
+
+src_prepare() {
+ base_src_prepare
+ sed -i -e "s|/usr/share/linthesia|${GAMES_DATADIR}/${PN}|g" Makefile || die
+}
+
+src_compile() {
+ GRAPHDIR="${GAMES_DATADIR}/${PN}/graphics" emake || die
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die
+ dodoc README
+
+ insinto /usr/share/applications
+ doins extra/${PN}.desktop
+
+ insinto /usr/share/pixmaps
+ doins extra/${PN}.xpm
+
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ einfo "The ${PN}-${MY_PV}.src.tgz source tarball contains several midi"
+ einfo "files in the ${PN}/music/ sub-directory for practicing,"
+ einfo "these were not installed due to the potential of copyright"
+ einfo "infringment."
+ einfo "Please manually unpack this directory to a suitable location if you"
+ einfo "wish to use them with the application."
+}
Added: trunk/overlays/proaudio/games-misc/linthesia/metadata.xml
===================================================================
--- trunk/overlays/proaudio/games-misc/linthesia/metadata.xml (rev 0)
+++ trunk/overlays/proaudio/games-misc/linthesia/metadata.xml 2012-01-23 11:36:37 UTC (rev 2091)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>proaudio@xxxxxxxxxxxxx</email>
+ <name>pro-audio overlay team</name>
+ </maintainer>
+</pkgmetadata>