diff options
Diffstat (limited to 'games-puzzle/einstein')
-rw-r--r-- | games-puzzle/einstein/Manifest | 2 | ||||
-rw-r--r-- | games-puzzle/einstein/einstein-2.0.ebuild | 43 | ||||
-rw-r--r-- | games-puzzle/einstein/files/einstein-2.0-64bit.patch | 31 | ||||
-rw-r--r-- | games-puzzle/einstein/files/einstein-2.0-as-needed.patch | 11 | ||||
-rw-r--r-- | games-puzzle/einstein/files/einstein-2.0-gcc43.patch | 20 | ||||
-rw-r--r-- | games-puzzle/einstein/metadata.xml | 8 |
6 files changed, 115 insertions, 0 deletions
diff --git a/games-puzzle/einstein/Manifest b/games-puzzle/einstein/Manifest new file mode 100644 index 000000000000..21b3f3dd737b --- /dev/null +++ b/games-puzzle/einstein/Manifest @@ -0,0 +1,2 @@ +DIST einstein-2.0-src.tar.gz 722301 SHA256 0f2d1c7d46d36f27a856b98cd4bbb95813970c8e803444772be7bd9bec45a548 SHA512 45599546f2f7fce32f7441cfdae88b72297f4a506d9eb98a64c3b24ec2e2fd86a63d59961a21e017df6a7a676d864ad12598d735f9049adf43cddd91d661f619 WHIRLPOOL aa0327d50a87a3e73e5812585cc6fd505eebda91eedbe43b83210a9e574c20be90c026a1d660d634a8a617b650c43a61e7df91c606780e5e5d7a6b2a1765ece1 +DIST einstein.png 932 SHA256 87416ad30823294a55be626adf3bbf3d32f98cf7c8d7e9e65470d78ed37a66a5 SHA512 9e19d351e915509a11d7275ef0ea7e246d0d334933ec4b48ea0f56aa552ac69041a5c2a64075b02ec3601b1c2b8307cef314c9427ab7615b16e689faaa074283 WHIRLPOOL 6a83e7e0de616f843a67a828a2b9fdeb47bfb134f5759dc2b04605b4eb89bba18183a3be2f5e92075c88fedb875f80e948dcc906572ba8c3513ff0455501f098 diff --git a/games-puzzle/einstein/einstein-2.0.ebuild b/games-puzzle/einstein/einstein-2.0.ebuild new file mode 100644 index 000000000000..6973c9b64319 --- /dev/null +++ b/games-puzzle/einstein/einstein-2.0.ebuild @@ -0,0 +1,43 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 +inherit eutils games + +DESCRIPTION="A puzzle game inspired by Albert Einstein" +HOMEPAGE="https://freecode.com/projects/einsteinpuzzle" +SRC_URI="mirror://gentoo/${P}-src.tar.gz + mirror://gentoo/${PN}.png" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 x86" +IUSE="" + +DEPEND="media-libs/libsdl[sound,video] + media-libs/sdl-mixer + media-libs/sdl-ttf" +RDEPEND="${DEPEND}" + +src_prepare() { + epatch "${FILESDIR}"/${P}*.patch + sed -i \ + -e "/PREFIX/s:/usr/local:${GAMES_PREFIX}:" \ + -e "s:\$(PREFIX)/share/einstein:${GAMES_DATADIR}/${PN}:" \ + -e "s:\$(PREFIX)/bin:${GAMES_BINDIR}:" \ + -e "s/\(OPTIMIZE=[^#]*\)/\0 ${CXXFLAGS}/" Makefile \ + || die + sed -i \ + -e "s:PREFIX L\"/share/einstein:L\"${GAMES_DATADIR}/${PN}:" main.cpp \ + || die +} + +src_install() { + dogamesbin "${PN}" + insinto "${GAMES_DATADIR}/${PN}/res" + doins einstein.res + doicon "${DISTDIR}"/${PN}.png + make_desktop_entry ${PN} "Einstein Puzzle" + prepgamesdirs +} diff --git a/games-puzzle/einstein/files/einstein-2.0-64bit.patch b/games-puzzle/einstein/files/einstein-2.0-64bit.patch new file mode 100644 index 000000000000..4d6656252898 --- /dev/null +++ b/games-puzzle/einstein/files/einstein-2.0-64bit.patch @@ -0,0 +1,31 @@ +--- einstein-2.0.orig/formatter.cpp ++++ einstein-2.0/formatter.cpp +@@ -58,7 +58,7 @@ + if ((c.type == INT_ARG) || (c.type == STRING_ARG) || + (c.type == FLOAT_ARG) || (c.type == DOUBLE_ARG)) + { +- int no = (int)c.data; ++ long int no = (long int)c.data; + args[no - 1] = c.type; + } + } +@@ -123,7 +123,7 @@ + std::wstring Formatter::format(std::vector<ArgValue*> &argValues) const + { + std::wstring s; +- int no; ++ long int no; + + for (int i = 0; i < commandsCnt; i++) { + Command *cmd = &commands[i]; +@@ -135,8 +135,8 @@ + + case STRING_ARG: + case INT_ARG: +- no = (int)cmd->data - 1; +- if (no < (int)argValues.size()) ++ no = (long int)cmd->data - 1; ++ if (no < (long int)argValues.size()) + s += argValues[no]->format(cmd); + break; + diff --git a/games-puzzle/einstein/files/einstein-2.0-as-needed.patch b/games-puzzle/einstein/files/einstein-2.0-as-needed.patch new file mode 100644 index 000000000000..fe870bf036e7 --- /dev/null +++ b/games-puzzle/einstein/files/einstein-2.0-as-needed.patch @@ -0,0 +1,11 @@ +--- Makefile.old 2009-02-09 16:37:58.000000000 +0100 ++++ Makefile 2009-02-09 16:38:13.000000000 +0100 +@@ -49,7 +49,7 @@ + + + $(TARGET): $(OBJECTS) +- $(CXX) $(LNFLAGS) $(OBJECTS) -o $(TARGET) ++ $(CXX) $(LDFLAGS) $(OBJECTS) -o $(TARGET) $(LNFLAGS) + + clean: + rm -f $(OBJECTS) core* *core $(TARGET) *~ diff --git a/games-puzzle/einstein/files/einstein-2.0-gcc43.patch b/games-puzzle/einstein/files/einstein-2.0-gcc43.patch new file mode 100644 index 000000000000..25e1815e5e41 --- /dev/null +++ b/games-puzzle/einstein/files/einstein-2.0-gcc43.patch @@ -0,0 +1,20 @@ +--- einstein-2.0.orig/convert.h ++++ einstein-2.0/convert.h +@@ -5,6 +5,7 @@ + #include <iostream> + #include <sstream> + #include <string> ++#include <typeinfo> + + #include "exceptions.h" + #include "unicode.h" + +--- einstein-2.0.orig/unicode.cpp ++++ einstein-2.0/unicode.cpp +@@ -1,5 +1,6 @@ + #include <wchar.h> + #include <stdlib.h> ++#include <string.h> + #ifdef WIN32 + #include <windows.h> + #endif diff --git a/games-puzzle/einstein/metadata.xml b/games-puzzle/einstein/metadata.xml new file mode 100644 index 000000000000..f83be4edcc0b --- /dev/null +++ b/games-puzzle/einstein/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>games</herd> + <upstream> + <remote-id type="freecode">einsteinpuzzle</remote-id> + </upstream> +</pkgmetadata> |