From c2bf40c4e6ffb962aa28b68e35f41faa59250308 Mon Sep 17 00:00:00 2001 From: Mark Wright Date: Sun, 8 Jan 2012 14:48:53 +0000 Subject: [PATCH] New p9m4 prover9 mace4 gui ebuild by me fixes #398021 Package-Manager: portage-2.1.10.44/cvs/Linux x86_64 --- sci-mathematics/p9m4/ChangeLog | 11 ++ sci-mathematics/p9m4/Manifest | 18 +++ .../p9m4/files/p9m4-v05-package.patch | 62 ++++++++++ .../p9m4/files/p9m4-v05-python2.6.patch | 44 +++++++ .../p9m4/files/p9m4-v05-use-inst-paths.patch | 42 +++++++ sci-mathematics/p9m4/metadata.xml | 11 ++ sci-mathematics/p9m4/p9m4-05.ebuild | 110 ++++++++++++++++++ 7 files changed, 298 insertions(+) create mode 100644 sci-mathematics/p9m4/ChangeLog create mode 100644 sci-mathematics/p9m4/Manifest create mode 100644 sci-mathematics/p9m4/files/p9m4-v05-package.patch create mode 100644 sci-mathematics/p9m4/files/p9m4-v05-python2.6.patch create mode 100644 sci-mathematics/p9m4/files/p9m4-v05-use-inst-paths.patch create mode 100644 sci-mathematics/p9m4/metadata.xml create mode 100644 sci-mathematics/p9m4/p9m4-05.ebuild diff --git a/sci-mathematics/p9m4/ChangeLog b/sci-mathematics/p9m4/ChangeLog new file mode 100644 index 000000000000..077f6418e21b --- /dev/null +++ b/sci-mathematics/p9m4/ChangeLog @@ -0,0 +1,11 @@ +# ChangeLog for sci-mathematics/p9m4 +# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/p9m4/ChangeLog,v 1.1 2012/01/08 14:48:52 gienah Exp $ + +*p9m4-05 (08 Jan 2012) + + 08 Jan 2012; Mark Wright +files/p9m4-v05-package.patch, + +files/p9m4-v05-python2.6.patch, +p9m4-05.ebuild, + +files/p9m4-v05-use-inst-paths.patch, +metadata.xml: + New p9m4 prover9 mace4 gui ebuild by me fixes #398021 + diff --git a/sci-mathematics/p9m4/Manifest b/sci-mathematics/p9m4/Manifest new file mode 100644 index 000000000000..ab2c296bf4e0 --- /dev/null +++ b/sci-mathematics/p9m4/Manifest @@ -0,0 +1,18 @@ +-----BEGIN PGP SIGNED MESSAGE----- +Hash: SHA256 + +AUX p9m4-v05-package.patch 1647 RMD160 758a169ad8fd6a9de0c57655c35b50ccab79bf0e SHA1 b1619304175563356ccf0b4bdc3f38c4b77699f6 SHA256 8612543b43d9c64783c2a4ba3064963f0c372a2a547886d58459c8d7aa16c45d +AUX p9m4-v05-python2.6.patch 1909 RMD160 fb7d591117027b838dd661562689918c89beefc6 SHA1 c472365725753ebfaf3bab0f430860a97b040672 SHA256 1b0156a2d425eaabf0f7fcb2b8bd7c3dd5036fd043ba073ba95ec937c1a957d6 +AUX p9m4-v05-use-inst-paths.patch 1151 RMD160 0d09e9bbcc40871487ac24229fc00523b9de4e50 SHA1 af0514a66f10654c21b93ee32e0b3f076d50b1da SHA256 67e84e86bd6af5ee972cd45b22df0c4c3c517345d144d6e960cd377d7168471b +DIST p9m4-v05-64bit.patch.bz2 5095 RMD160 9b432f1990fd1ccbed5f383882d841e8be7e16f7 SHA1 593c1d38ef3c9ca7276454362fa8ac0415b04e5d SHA256 038eafb0198deabb358e3b9aabe19052970730e7cace2b7dbbbc09947d901d6f +DIST p9m4-v05.tar.gz 889707 RMD160 00f64fd5dc07adeb0752218c319e1dfa130b51e1 SHA1 c9ce24400b96faaec23a0b83d33d3e283aaf4c67 SHA256 451a05179fcb025b666ec992cd45e0d71dac26e43c1fca814747bef541a040b4 +EBUILD p9m4-05.ebuild 2980 RMD160 9a99c70a74d029ddf1c0ffc5d4334a5bbff9337f SHA1 8b32f53af8242b21aaaa081e2680e4afb7ec3809 SHA256 c4f33d45f987167147f5c653885ce5e7818ad1c45708cffe8cceb93023ba9fc8 +MISC ChangeLog 479 RMD160 66a99d87325081e5ef831c6356e458c53cc67dc6 SHA1 39c15bb3109c27c35773c85509872866ae521ca5 SHA256 8f0353b2bf4b1941e6689edbb410537e3b01a6d6f8c01ed6683d5eac1565f92b +MISC metadata.xml 462 RMD160 926c8b017cb544c2ad52effa16d3b30e98502bc2 SHA1 02c0acd10acd158aa05108ea59d3a0303472139f SHA256 ae4d76ff5d6564e732a99eda291abf75d587d957c4052875fe0ba03f4a207d8b +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v2.0.17 (GNU/Linux) + +iF4EAREIAAYFAk8JrOsACgkQoBEVQmGOlx86MgEAjwK4lZ0/hYvhEBYEO9EUNSQt +VosZkhHhPbRSVhSTYe8A/i3vf+iYJe3q57/PO09UPro3J86jo/gW2091cnGB01I9 +=dCu7 +-----END PGP SIGNATURE----- diff --git a/sci-mathematics/p9m4/files/p9m4-v05-package.patch b/sci-mathematics/p9m4/files/p9m4-v05-package.patch new file mode 100644 index 000000000000..bf7acd8d7f34 --- /dev/null +++ b/sci-mathematics/p9m4/files/p9m4-v05-package.patch @@ -0,0 +1,62 @@ +--- p9m4-v05-orig/setup.py 2007-11-17 09:31:26.000000000 +1100 ++++ p9m4-v05/setup.py 2012-01-08 20:02:53.917240674 +1100 +@@ -26,23 +26,21 @@ + + from setuptools import setup + +-APP = ['prover9-mace4.py'] +-DATA_FILES = ['platforms.py', +- 'utilities.py', +- 'wx_utilities.py', +- 'files.py', +- 'options.py', +- 'partition_input.py', +- 'my_setup.py', +- 'control.py', +- 'Images', +- 'Samples', +- 'bin-mac'] +-OPTIONS = {'argv_emulation': True, 'iconfile': '/Users/mccune/gui/v4/p9.icns'} ++OPTIONS = {'argv_emulation': True, 'iconfile': '/usr/share/p9m4/Images/p9.ico'} + + setup( +- app=APP, +- data_files=DATA_FILES, ++ name='p9m4', ++ version='05', ++ scripts=['prover9-mace4.py'], ++ package_dir = {'p9m4': 'p9m4'}, ++ py_modules=['p9m4.platforms', ++ 'p9m4.utilities', ++ 'p9m4.wx_utilities', ++ 'p9m4.files', ++ 'p9m4.options', ++ 'p9m4.partition_input', ++ 'p9m4.my_setup', ++ 'p9m4.control'], + options={'py2app': OPTIONS}, + setup_requires=['py2app'], + ) +--- p9m4-v05-orig/prover9-mace4.py 2007-12-08 03:27:13.000000000 +1100 ++++ p9m4-v05/prover9-mace4.py 2012-01-08 18:12:09.970620044 +1100 +@@ -27,13 +27,13 @@ + + # local imports + +-import partition_input +-import utilities +-from files import * +-from platforms import * +-from wx_utilities import * +-from my_setup import * +-from control import * ++import p9m4.partition_input ++import p9m4.utilities ++from p9m4.files import * ++from p9m4.platforms import * ++from p9m4.wx_utilities import * ++from p9m4.my_setup import * ++from p9m4.control import * + + Program_name = 'Prover9-Mace4' + Program_version = '0.5' diff --git a/sci-mathematics/p9m4/files/p9m4-v05-python2.6.patch b/sci-mathematics/p9m4/files/p9m4-v05-python2.6.patch new file mode 100644 index 000000000000..70cb006d268e --- /dev/null +++ b/sci-mathematics/p9m4/files/p9m4-v05-python2.6.patch @@ -0,0 +1,44 @@ +diff -Nur p9m4-0.5/my_setup.py p9m4-0.5.new/my_setup.py +--- p9m4-0.5/my_setup.py 2008-01-14 23:30:55.000000000 +0000 ++++ p9m4-0.5.new/my_setup.py 2008-01-14 23:35:45.000000000 +0000 +@@ -158,7 +158,9 @@ + self.ed.SetStyle(start, end, + wx.TextAttr('RED', + wx.Colour(200,200,255))) +- error_dialog('%s\n%s' % (message,error if error else '')) ++ error_dialog('%s\n%s' % (message,error)) ++ else: ++ error_dialog(message) + else: + frame = Text_frame(self, to_top(self).box_font, + 'Error Output', +diff -Nur p9m4-0.5/partition_input.py p9m4-0.5.new/partition_input.py +--- p9m4-0.5/partition_input.py 2008-01-14 23:30:55.000000000 +0000 ++++ p9m4-0.5.new/partition_input.py 2008-01-14 23:35:45.000000000 +0000 +@@ -63,14 +63,23 @@ + m2 = r2.search(str, m1.end()) + while m2 and in_span(m2.start(), comments): + m2 = r2.search(str, m2.end()) +- match_end = m2.end() if m2 else len(str) ++ if m2: ++ match_end = m2.end() ++ else: ++ match_end = len(str) + other += str[other_start:m1.start()] + if remove_patterns: + keep_start = m1.end() +- keep_end = m2.start() if m2 else len(str) ++ if m2: ++ keep_end = m2.start() ++ else: ++ keep_end = len(str) + else: + keep_start = m1.start() +- keep_end = m2.end() if m2 else len(str) ++ if m2: ++ keep_end = m2.end() ++ else: ++ keep_end = len(str) + matched += str[keep_start:keep_end] + next = other_start = match_end + else: diff --git a/sci-mathematics/p9m4/files/p9m4-v05-use-inst-paths.patch b/sci-mathematics/p9m4/files/p9m4-v05-use-inst-paths.patch new file mode 100644 index 000000000000..5b48b94b27bf --- /dev/null +++ b/sci-mathematics/p9m4/files/p9m4-v05-use-inst-paths.patch @@ -0,0 +1,42 @@ +diff -Nur p9m4-0.5/files.py p9m4-0.5.new/files.py +--- p9m4-0.5/files.py 2008-01-14 23:31:00.000000000 +0000 ++++ p9m4-0.5.new/files.py 2008-01-14 23:39:51.000000000 +0000 +@@ -51,6 +51,9 @@ + return sys.path[0] + # return os.path.dirname(os.path.abspath(sys.argv[0])) + ++def data_dir(): ++ return '/usr/share/p9m4' ++ + def bin(): + if Win32(): + return 'bin-win32' +@@ -63,13 +66,13 @@ + return 'bin' + + def bin_dir(): +- return os.path.join(program_dir(), bin()) ++ return '/usr/bin' + + def image_dir(): +- return os.path.join(program_dir(), 'Images') ++ return os.path.join(data_dir(), 'Images') + + def sample_dir(): +- return os.path.join(program_dir(), 'Samples') ++ return os.path.join(data_dir(), 'Samples') + + def binary_ok(fullpath): + if not fullpath: +diff -Nur p9m4-0.5/prover9-mace4.py p9m4-0.5.new/prover9-mace4.py +--- p9m4-0.5/prover9-mace4.py 2007-12-07 16:27:13.000000000 +0000 ++++ p9m4-0.5.new/prover9-mace4.py 2008-02-10 22:45:45.000000000 +0000 +@@ -27,6 +27,8 @@ + + # local imports + ++sys.path.append('/usr/share/p9m4/lib') ++ + import partition_input + import utilities + from files import * diff --git a/sci-mathematics/p9m4/metadata.xml b/sci-mathematics/p9m4/metadata.xml new file mode 100644 index 000000000000..e8386cec0b2b --- /dev/null +++ b/sci-mathematics/p9m4/metadata.xml @@ -0,0 +1,11 @@ + + + +sci-mathematics + + This is a Graphical User Interface for Prover9 and Mace4. + Prover9 is an automated theorem prover for first-order and + equational logic, and Mace4 searches for finite models and + counterexamples. Prover9 is the successor of the Otter prover. + + diff --git a/sci-mathematics/p9m4/p9m4-05.ebuild b/sci-mathematics/p9m4/p9m4-05.ebuild new file mode 100644 index 000000000000..2f1ef8620859 --- /dev/null +++ b/sci-mathematics/p9m4/p9m4-05.ebuild @@ -0,0 +1,110 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/p9m4/p9m4-05.ebuild,v 1.1 2012/01/08 14:48:52 gienah Exp $ + +EAPI="4" +PYTHON_DEPEND="2:2.5" + +inherit base distutils + +MY_PN="p9m4-v" +MY_P="${MY_PN}${PV}" + +DESCRIPTION="This is a Graphical User Interface for Prover9 and Mace4." +HOMEPAGE="http://www.cs.unm.edu/~mccune/mace4/" +SRC_URI="http://www.cs.unm.edu/~mccune/prover9/gui/${MY_P}.tar.gz + http://dev.gentoo.org/~gienah/2big4tree/sci-mathematics/p9m4/p9m4-v05-64bit.patch.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="examples" + +RDEPEND="dev-python/wxpython + sci-mathematics/prover9" +DEPEND="${RDEPEND} + dev-python/setuptools" + +PATCHES=("${DISTDIR}/${MY_PN}05-64bit.patch.bz2" + "${FILESDIR}/${MY_PN}05-use-inst-paths.patch" + "${FILESDIR}/${MY_PN}05-package.patch" + "${FILESDIR}/${MY_PN}05-python2.6.patch") + +pkg_setup() { + python_set_active_version 2 + python_pkg_setup +} + +src_prepare() { + rm -f p9m4-v05/bin/prover9 \ + p9m4-v05/bin/mace4 \ + p9m4-v05/bin/interpformat \ + p9m4-v05/bin/prooftrans \ + p9m4-v05/bin/isofilter \ + p9m4-v05/bin/isofilter2 || die "Could not rm old executables" + base_src_prepare + mkdir p9m4 || die "Could not create directory p9m4" + mv Mac-setup.py \ + Win32-setup.py \ + control.py \ + files.py \ + my_setup.py \ + options.py \ + partition_input.py \ + platforms.py \ + utilities.py \ + wx_utilities.py \ + p9m4 \ + || die "Could not move package p9m4 python files to p9m4 directory" + touch p9m4/__init__.py \ + || die "Could not create empty p9m4/__init__.py file" + distutils_src_prepare +} + +src_install() { + distutils_src_install + dosym /usr/bin/prover9-mace4.py /usr/bin/prover9-mace4 + insinto /usr/share + dodir /usr/share/${PN}/Images + insinto /usr/share/${PN}/Images + cd "${S}/Images" \ + die "Could not cd to Images" + doins *.gif *.ico + if use examples; then + dodir /usr/share/${PN}/Samples + insinto /usr/share/${PN}/Samples + cd "${S}/Samples" \ + || die "Could not cd to Samples" + doins *.in + + dodir /usr/share/${PN}/Samples/Equality/Mace4 + insinto /usr/share/${PN}/Samples/Equality/Mace4 + cd "${S}/Samples/Equality/Mace4" \ + || die "Could not cd to Samples/Equality/Mace4" + doins *.in + + dodir /usr/share/${PN}/Samples/Equality/Prover9 + insinto /usr/share/${PN}/Samples/Equality/Prover9 + cd "${S}/Samples/Equality/Prover9" \ + || die "Could not cd to Samples/Equality/Prover9" + doins *.in + + dodir /usr/share/${PN}/Samples/Non-Equality/Mace4 + insinto /usr/share/${PN}/Samples/Non-Equality/Mace4 + cd "${S}/Samples/Non-Equality/Mace4" \ + || die "Could cd to Samples/Non-Equality/Mace4" + doins *.in + + dodir /usr/share/${PN}/Samples/Non-Equality/Prover9 + insinto /usr/share/${PN}/Samples/Non-Equality/Prover9 + cd "${S}/Samples/Non-Equality/Prover9" \ + || die "Could not cd to Samples/Non-Equality/Prover9" + doins *.in + fi +} + +pkg_postinst() { + distutils_pkg_postinst +} + +S="${WORKDIR}/${MY_P}/" -- 2.26.2