summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Weber <xmw@gentoo.org>2010-09-16 15:53:09 +0000
committerMichael Weber <xmw@gentoo.org>2010-09-16 15:53:09 +0000
commitf99eb557f36b7fa51830d1ade36340c33468e59a (patch)
tree8d960d4cad22cbdc830a08990655a97b15fa0fb1 /app-misc/golly
parentCleaned up our masks a little to reflect reality. (diff)
downloadhistorical-f99eb557f36b7fa51830d1ade36340c33468e59a.tar.gz
historical-f99eb557f36b7fa51830d1ade36340c33468e59a.tar.bz2
historical-f99eb557f36b7fa51830d1ade36340c33468e59a.zip
Initial import from sunrise overlay.
Package-Manager: portage-2.1.8.3/cvs/Linux x86_64
Diffstat (limited to 'app-misc/golly')
-rw-r--r--app-misc/golly/ChangeLog14
-rw-r--r--app-misc/golly/Manifest8
-rw-r--r--app-misc/golly/files/golly-2.1-as-needed.patch30
-rw-r--r--app-misc/golly/files/golly-2.1-perl-ldopts.patch11
-rw-r--r--app-misc/golly/files/golly-2.1-python-amd64.patch39
-rw-r--r--app-misc/golly/files/golly-separate-data-directory.patch62
-rw-r--r--app-misc/golly/golly-2.1.ebuild68
-rw-r--r--app-misc/golly/metadata.xml10
8 files changed, 242 insertions, 0 deletions
diff --git a/app-misc/golly/ChangeLog b/app-misc/golly/ChangeLog
new file mode 100644
index 000000000000..1c25d5fd2498
--- /dev/null
+++ b/app-misc/golly/ChangeLog
@@ -0,0 +1,14 @@
+# ChangeLog for app-misc/golly
+# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/app-misc/golly/ChangeLog,v 1.1 2010/09/16 15:53:09 xmw Exp $
+
+*golly-2.1 (16 Sep 2010)
+
+ 16 Sep 2010; Michael Weber <xmw@gentoo.org> +golly-2.1.ebuild,
+ +files/golly-2.1-as-needed.patch, +files/golly-2.1-perl-ldopts.patch,
+ +files/golly-2.1-python-amd64.patch,
+ +files/golly-separate-data-directory.patch, +metadata.xml:
+ Initial import from sunrise overlay. Thanks to Maks Verver
+ <maksverver@geocities.com> on bug #323219 for the ebuild and patches,
+ great work.
+
diff --git a/app-misc/golly/Manifest b/app-misc/golly/Manifest
new file mode 100644
index 000000000000..02e7fda4a476
--- /dev/null
+++ b/app-misc/golly/Manifest
@@ -0,0 +1,8 @@
+AUX golly-2.1-as-needed.patch 1248 RMD160 fe39cfb39af27e6a475cfed4afcbfafa0768c66c SHA1 1fc5426096943454e26547aedf1f80d1a39e7b49 SHA256 a5f782518b90fba1c74e7ed3e085c6c4ba65fdd4de729663f51cb96696c8b17f
+AUX golly-2.1-perl-ldopts.patch 601 RMD160 c3120483bbccd864d89a52b5fec0c61dcc0c0fec SHA1 c48ca9e4d8882612f637a44877a0b2eb85c68679 SHA256 f98245df74f571913dc1a6a1d0ef5569e6f0dd2ae1619f8bee69cf521aea9ccd
+AUX golly-2.1-python-amd64.patch 1169 RMD160 974e2e6c016f1aad3f5148825dc9170c294c5e2c SHA1 b9449caa47c3c5b78c88107b50d91078280d0065 SHA256 26d607f961f14f9759f2669ff57e65774baee7e171358aadb322fa7f06d6ff68
+AUX golly-separate-data-directory.patch 2375 RMD160 02283791a7ff63e6b29e284bfc16a739bb71975b SHA1 3fb21d16e5c38aea5ba6e1ef59e140b371e834d6 SHA256 6bb1f21d516a9b9bc48808708b29215f12582236aec729214bcecb02d78b6f79
+DIST golly-2.1-src.tar.gz 2394506 RMD160 d7ea0adf6525a8f4a9beecc0a060cfdc791b1c28 SHA1 553bcc6b1ece0dfbc5728713cb7e5c736b15516c SHA256 bfe561fd2f7f20fedfb76abc77c6c8cc5a8cb0586a37a6f7bb5df37b16f83a55
+EBUILD golly-2.1.ebuild 1805 RMD160 8320ad084ffca3e6dc92089ebf94a984e2b40b6b SHA1 3a09b55f2c7aedf1dc684f84cc6e81888876197d SHA256 b3501d4adfe55909d52e28c32d3b3cf2b16f2140c102400a9a5eadf4d2a9434b
+MISC ChangeLog 609 RMD160 cdf4cf3b58d708d354c198e2420d4015de833946 SHA1 58263e6456d8bd08c914e592d7a7b6e42927b854 SHA256 cc7f482caa144edb46877f2c19fef3afa2afd07ca5f1118cf179fe69f7642f38
+MISC metadata.xml 245 RMD160 6b03982a4d5f32d9fa6b9259ae36f9fcb07c8404 SHA1 fb16c7b4c5ab071dd979f761b8bb075f5396b737 SHA256 375a1da02cd2c393ce2378a73c1ce08134bc030b3bb378c6a4d6ca9cd5be1f8d
diff --git a/app-misc/golly/files/golly-2.1-as-needed.patch b/app-misc/golly/files/golly-2.1-as-needed.patch
new file mode 100644
index 000000000000..f65df4a5925c
--- /dev/null
+++ b/app-misc/golly/files/golly-2.1-as-needed.patch
@@ -0,0 +1,30 @@
+diff --git a/makefile-gtk b/makefile-gtk
+index 56b31d0..a09aad4 100644
+--- a/makefile-gtk
++++ b/makefile-gtk
+@@ -21,7 +21,7 @@ BINFILES = golly bgolly RuleTableToTree
+ CXXC = g++
+ CXXFLAGS = `wx-config --cxxflags` -O5 -DZLIB -DVERSION=$(VERSION) \
+ -Wall -Wno-non-virtual-dtor -fno-strict-aliasing
+-LDFLAGS = `wx-config --libs` -lz
++LIBS = `wx-config --libs` -lz
+
+ # for Perl script support
+ PERL_INCLUDE = `perl -MExtUtils::Embed -e ccopts`
+@@ -72,13 +72,13 @@ clean:
+ rm -f golly bgolly RuleTableToTree
+
+ golly: $(BASEOBJ) $(WXOBJ)
+- $(CXXC) $(CXXFLAGS) -o golly $(BASEOBJ) $(WXOBJ) $(LDFLAGS) $(PYTHON_LINK) $(PERL_LINK)
++ $(CXXC) $(CXXFLAGS) $(LDFLAGS) -o golly $(BASEOBJ) $(WXOBJ) $(LIBS) $(PYTHON_LINK) $(PERL_LINK)
+
+ bgolly: $(BASEOBJ) $(OBJDIR)/bgolly.o
+- $(CXXC) $(CXXFLAGS) -o bgolly $(BASEOBJ) $(OBJDIR)/bgolly.o $(LDFLAGS)
++ $(CXXC) $(CXXFLAGS) $(LDFLAGS) -o bgolly $(BASEOBJ) $(OBJDIR)/bgolly.o $(LIBS)
+
+ RuleTableToTree: $(BASEOBJ) $(OBJDIR)/RuleTableToTree.o
+- $(CXXC) $(CXXFLAGS) -o RuleTableToTree $(BASEOBJ) $(OBJDIR)/RuleTableToTree.o $(LDFLAGS)
++ $(CXXC) $(CXXFLAGS) $(LDFLAGS) -o RuleTableToTree $(BASEOBJ) $(OBJDIR)/RuleTableToTree.o $(LIBS)
+
+ $(OBJDIR)/bgolly.o: bgolly.cpp
+ $(CXXC) $(CXXFLAGS) -c -o $@ bgolly.cpp
diff --git a/app-misc/golly/files/golly-2.1-perl-ldopts.patch b/app-misc/golly/files/golly-2.1-perl-ldopts.patch
new file mode 100644
index 000000000000..a98178f8f2d1
--- /dev/null
+++ b/app-misc/golly/files/golly-2.1-perl-ldopts.patch
@@ -0,0 +1,11 @@
+--- golly-2.1-src.old/makefile-gtk 2009-09-07 02:33:06.000000000 +0200
++++ golly-2.1-src.new/makefile-gtk 2010-06-08 17:32:21.000000000 +0200
+@@ -29,7 +29,7 @@
+ # than 5.10 (this is necessary because boot_DynaLoader is in DynaLoader.a);
+ # if using 5.10 or later we can dynamically load the Perl library because
+ # it contains the boot_DynaLoader code
+-PERL_LINK = `perl -MExtUtils::Embed -e '$$]<5.010 && ldopts'`
++PERL_LINK = `perl -MExtUtils::Embed -e 'ldopts'`
+
+ # for Python script support
+ PYTHON_INCLUDE = -I`python -c "import distutils.sysconfig; print distutils.sysconfig.get_python_inc()"`
diff --git a/app-misc/golly/files/golly-2.1-python-amd64.patch b/app-misc/golly/files/golly-2.1-python-amd64.patch
new file mode 100644
index 000000000000..9c43d53d8372
--- /dev/null
+++ b/app-misc/golly/files/golly-2.1-python-amd64.patch
@@ -0,0 +1,39 @@
+--- wxpython.cpp 2009/09/04 00:36:39 1.70
++++ wxpython.cpp 2009/10/04 23:03:13 1.71
+@@ -106,7 +106,11 @@
+ {
+ // startup/shutdown
+ void(*G_Py_Initialize)(void) = NULL;
++#ifdef __LP64__
++ PyObject*(*G_Py_InitModule4_64)(char*, struct PyMethodDef*, char*, PyObject*, int) = NULL;
++#else
+ PyObject*(*G_Py_InitModule4)(char*, struct PyMethodDef*, char*, PyObject*, int) = NULL;
++#endif
+ void(*G_Py_Finalize)(void) = NULL;
+
+ // errors
+@@ -145,7 +149,11 @@
+
+ // redefine the Py* functions to their equivalent G_* wrappers
+ #define Py_Initialize G_Py_Initialize
+-#define Py_InitModule4 G_Py_InitModule4
++#ifdef __LP64__
++ #define Py_InitModule4_64 G_Py_InitModule4_64
++#else
++ #define Py_InitModule4 G_Py_InitModule4
++#endif
+ #define Py_Finalize G_Py_Finalize
+ #define PyErr_Occurred G_PyErr_Occurred
+ #define PyErr_SetString G_PyErr_SetString
+@@ -185,7 +193,11 @@
+ } pythonFuncs[] =
+ {
+ PYTHON_FUNC(Py_Initialize)
++#ifdef __LP64__
++ PYTHON_FUNC(Py_InitModule4_64)
++#else
+ PYTHON_FUNC(Py_InitModule4)
++#endif
+ PYTHON_FUNC(Py_Finalize)
+ PYTHON_FUNC(PyErr_Occurred)
+ PYTHON_FUNC(PyErr_SetString)
diff --git a/app-misc/golly/files/golly-separate-data-directory.patch b/app-misc/golly/files/golly-separate-data-directory.patch
new file mode 100644
index 000000000000..abbaedf476f7
--- /dev/null
+++ b/app-misc/golly/files/golly-separate-data-directory.patch
@@ -0,0 +1,62 @@
+--- golly-2.1-src.old/wxgolly.cpp 2009-09-07 02:35:55.000000000 +0200
++++ golly-2.1-src.new/wxgolly.cpp 2010-06-08 17:34:51.000000000 +0200
+@@ -195,42 +195,6 @@
+
+ // -----------------------------------------------------------------------------
+
+-void SetAppDirectory(const char* argv0)
+-{
+- #ifdef __WXMSW__
+- // on Windows we need to reset current directory to app directory if user
+- // dropped file from somewhere else onto app to start it up (otherwise we
+- // can't find Help files)
+- wxString appdir = wxStandardPaths::Get().GetDataDir();
+- wxString currdir = wxGetCwd();
+- if ( currdir.CmpNoCase(appdir) != 0 )
+- wxSetWorkingDirectory(appdir);
+- // avoid VC++ warning
+- wxUnusedVar(argv0);
+- #elif defined(__WXMAC__)
+- // wxMac has set current directory to location of .app bundle so no need
+- // to do anything
+- #else // assume Unix
+- // user might have started app from a different directory so find
+- // last "/" in argv0 and change cwd if "/" isn't part of "./" prefix
+- unsigned int pos = strlen(argv0);
+- while (pos > 0) {
+- pos--;
+- if (argv0[pos] == '/') break;
+- }
+- if ( pos > 0 && !(pos == 1 && argv0[0] == '.') ) {
+- char appdir[2048];
+- if (pos < sizeof(appdir)) {
+- strncpy(appdir, argv0, pos);
+- appdir[pos] = 0;
+- wxSetWorkingDirectory(wxString(appdir,wxConvLocal));
+- }
+- }
+- #endif
+-}
+-
+-// -----------------------------------------------------------------------------
+-
+ void GollyApp::SetFrameIcon(wxFrame* frame)
+ {
+ // set frame icon
+@@ -280,13 +244,12 @@
+ wxSystemOptions::SetOption(wxMAC_TEXTCONTROL_USE_MLTE, 1);
+ #endif
+
+- // get current working directory before calling SetAppDirectory
++ // get current working directory before changing to data directory
+ wxString initdir = wxFileName::GetCwd();
+ if (initdir.Last() != wxFILE_SEP_PATH) initdir += wxFILE_SEP_PATH;
+
+- // make sure current working directory contains application otherwise
+- // we can't open Help files
+- SetAppDirectory( wxString(argv[0]).mb_str(wxConvLocal) );
++ // change to data directory
++ wxSetWorkingDirectory(wxString("/usr/share/golly", wxConvLocal));
+
+ // now set global gollydir for use in GetPrefs and elsewhere
+ gollydir = wxFileName::GetCwd();
diff --git a/app-misc/golly/golly-2.1.ebuild b/app-misc/golly/golly-2.1.ebuild
new file mode 100644
index 000000000000..2f170be0b21d
--- /dev/null
+++ b/app-misc/golly/golly-2.1.ebuild
@@ -0,0 +1,68 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-misc/golly/golly-2.1.ebuild,v 1.1 2010/09/16 15:53:09 xmw Exp $
+
+EAPI=2
+PYTHON_DEPEND=2
+WX_GTK_VER=2.8
+
+inherit eutils python wxwidgets toolchain-funcs
+
+MY_P=${P}-src
+DESCRIPTION="A simulator for Conway's Game of Life and other cellular automata"
+HOMEPAGE="http://golly.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND="dev-lang/perl
+ || ( <=x11-libs/wxGTK-2.8.10.1-r5:2.8[X] >=x11-libs/wxGTK-2.8.11.0:2.8[X,tiff] )"
+RDEPEND="${DEPEND}"
+
+S=${WORKDIR}/${MY_P}
+
+pkg_setup() {
+ python_set_active_version 2
+}
+
+src_prepare() {
+ # Fix linker flags to work with Perl 5.10.1 (fixed in CVS)
+ epatch "${FILESDIR}"/${P}-perl-ldopts.patch
+
+ # Fix Python symbol names on AMD64 (fixed in CVS)
+ epatch "${FILESDIR}"/${P}-python-amd64.patch
+
+ # Fix installing data files into a different directory than binaries:
+ epatch "${FILESDIR}"/${PN}-separate-data-directory.patch
+
+ # We need this for correct linking
+ epatch "${FILESDIR}"/${P}-as-needed.patch
+
+ # Get rid of .DS_Store and other stuff that should not be installed:
+ find -type f -name '.*' -exec rm -f {} + || die
+ find Scripts/Python -name '*.pyc' -exec rm -f {} + || die
+
+ # Fix Python library path:
+ sed -i -e "s|libpython2.5.so|$(python_get_library)|" wxprefs.cpp || die
+
+ # Insert user-specified compiler flags into Makefile:
+ sed -i -e "/^CXXFLAGS = /s/-O5/${CXXFLAGS}/" makefile-gtk || die
+}
+
+src_compile() {
+ emake \
+ CXXC="$(tc-getCXX)" \
+ -f makefile-gtk || die
+}
+
+src_install() {
+ dobin golly bgolly RuleTableToTree || die
+
+ insinto /usr/share/${PN}
+ doins -r Help Patterns Scripts Rules || die
+
+ dodoc README || die
+}
diff --git a/app-misc/golly/metadata.xml b/app-misc/golly/metadata.xml
new file mode 100644
index 000000000000..02b909e46b7e
--- /dev/null
+++ b/app-misc/golly/metadata.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>no-herd</herd>
+<maintainer>
+<email>xmw@gentoo.org</email>
+<name>Michael Weber</name>
+</maintainer>
+</pkgmetadata>
+