summaryrefslogtreecommitdiff
path: root/dev-python/quex
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-12-15 17:25:28 +0000
committerV3n3RiX <venerix@redcorelinux.org>2017-12-15 17:25:28 +0000
commit6b933047f46efec1aa747570f945344254227457 (patch)
treea12a4b87b38f954c4de435272cf4b90d721df5e8 /dev-python/quex
parentf45955e60d4da9b7f4a1088c98042f9c06669039 (diff)
gentoo resync : 15.12.2017
Diffstat (limited to 'dev-python/quex')
-rw-r--r--dev-python/quex/Manifest4
-rw-r--r--dev-python/quex/files/quex-0.65.4-gentoo.patch43
-rw-r--r--dev-python/quex/metadata.xml24
-rw-r--r--dev-python/quex/quex-0.65.4.ebuild44
4 files changed, 115 insertions, 0 deletions
diff --git a/dev-python/quex/Manifest b/dev-python/quex/Manifest
new file mode 100644
index 000000000000..80615b381803
--- /dev/null
+++ b/dev-python/quex/Manifest
@@ -0,0 +1,4 @@
+AUX quex-0.65.4-gentoo.patch 1592 BLAKE2B 2b1b03d108dfa9e10b60acf16f474a0b98c32e7caa6f7a7da08b3d13253cc54ea9cdcac304d20a3ea524a8a9a0088e5ab514c71f2bc3a37b74fb910ec3bf9cc9 SHA512 7202b8e9621357dd01d93e260c95df3c006d28648e12158c3e8031d6c23988ea623d10697042c1f0c6887a6af5bbea979faa7afa0ff477a9432aa4c6f56fd288
+DIST quex-0.65.4.tar.gz 2202154 BLAKE2B 6b273998c9641aeee458291245a4fb956b5fe9b66d8c42f0c1d9b360a4d171c830a1d487bcbab9ccea49d10b7532ed488ce66dc165f31cce9521f97c5a4575f4 SHA512 0b11d7e5c5165674626fbbe7f54853656c579c63b78bd2fef2f5a9b316171dc647812d9a37df4e7c49c05de11a307b6425089f4ab281affb6c03a9cf09e2a035
+EBUILD quex-0.65.4.ebuild 917 BLAKE2B 7a6e2039dd96dca4c8a783a632628b6a9b44fdf1d8d71886acf7e49fc90a30461d5a70713444da50d2ae1ab71c1c93197d392ea70bdbd3c61ba8ab01264180cd SHA512 fa2a765118f2ae76dcf6a25aec03253f4f3b16fc788c51718593010173535d88f343608fa43806e592b3deda8b7340eab4294c1679b5fed8d3f16436823daf3f
+MISC metadata.xml 807 BLAKE2B 778188ed4c2e4c0b626c8e732be918b44583c5b490356f2c28dcd978c1c3b76b45440c45b0175b203f36937d43f4e12aeabcc1f40183f740c1357006d5841dc2 SHA512 37a5d2bd9351e1bd4f20e6b40808a1598b7b46d1d5559210c83ef106d25dd895d2d0fc31bd6671c98129176c36564388d071edbd058a57666aca07f6ff0fb930
diff --git a/dev-python/quex/files/quex-0.65.4-gentoo.patch b/dev-python/quex/files/quex-0.65.4-gentoo.patch
new file mode 100644
index 000000000000..cbe161a18e11
--- /dev/null
+++ b/dev-python/quex/files/quex-0.65.4-gentoo.patch
@@ -0,0 +1,43 @@
+--- quex-0.65.4/quex-exe.py.old 2017-12-13 21:42:48.633280478 +0100
++++ quex-0.65.4/quex-exe.py 2017-12-13 21:43:02.066040530 +0100
+@@ -40,11 +40,6 @@
+ print("error: Please, use Python versions 2.x.")
+ sys.exit(-1)
+
+-if os.environ.has_key("QUEX_PATH") == False:
+- print("Environment variable QUEX_PATH has not been defined.")
+-else:
+- sys.path.insert(0, os.environ["QUEX_PATH"])
+-
+ try:
+ exception_checker.do_on_import(sys.argv)
+ import quex.DEFINITIONS
+--- quex-0.65.4/quex/DEFINITIONS.py.old 2017-12-13 21:48:52.887765325 +0100
++++ quex-0.65.4/quex/DEFINITIONS.py 2017-12-13 21:52:29.805877359 +0100
+@@ -23,7 +23,7 @@
+ QUEX_VERSION = '0.65.4'
+
+ try:
+- QUEX_INSTALLATION_DIR = os.environ["QUEX_PATH"]
++ QUEX_INSTALLATION_DIR = "@PYTHON_SITEDIR@"
+ # Note, that windows can also deal with backslashes.
+ QUEX_INSTALLATION_DIR = QUEX_INSTALLATION_DIR.replace("\\", "/")
+ except:
+@@ -49,15 +49,14 @@
+ sys.exit(-1) # sys.exit(-1) is acceptable
+
+ QUEX_PATH = QUEX_INSTALLATION_DIR
+-QUEX_CODEC_DB_PATH = QUEX_PATH + "/quex/engine/codec_db/database"
++QUEX_CODEC_DB_PATH = "/usr/share/quex/database"
+
+-sys.path.insert(0, QUEX_INSTALLATION_DIR)
+
+ def check():
+ global QUEX_INSTALLATION_DIR
+
+ # -- Try to acces the file 'quex-exe.py' in order to verify
+- if os.access(QUEX_INSTALLATION_DIR + "/quex-exe.py", os.F_OK) == False:
++ if False:
+ print "error: Environment variable 'QUEX_PATH' does not point to"
+ print "error: a valid installation directory of quex."
+ print "error: current setting of 'QUEX_PATH':"
diff --git a/dev-python/quex/metadata.xml b/dev-python/quex/metadata.xml
new file mode 100644
index 000000000000..7500e5f0c488
--- /dev/null
+++ b/dev-python/quex/metadata.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>python@gentoo.org</email>
+ </maintainer>
+ <maintainer type="person">
+ <email>tupone@gentoo.org</email>
+ <name>Tupone Alfredo</name>
+ </maintainer>
+ <longdescription lang="en">
+ It is:
+ a tool to generate lexical analyzers. A lexical analyzer is a program
+ that transforms a stream of characters into a stream of
+ 'atomic chunks of meaning', so called tokens.
+
+ It does:
+ generate directly coded lexical analyzers, rather than table based
+ engines.
+ respond to queries on Unicode properties and regular expressions on the
+ command line.
+ generate state transition graphs of the generated engines.
+ </longdescription>
+</pkgmetadata>
diff --git a/dev-python/quex/quex-0.65.4.ebuild b/dev-python/quex/quex-0.65.4.ebuild
new file mode 100644
index 000000000000..0bf833a64191
--- /dev/null
+++ b/dev-python/quex/quex-0.65.4.ebuild
@@ -0,0 +1,44 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python2_7 )
+
+inherit python-single-r1
+
+DESCRIPTION="Mode Oriented Directly Coded Lexical Analyser Generator"
+HOMEPAGE="http://quex.sourceforge.net/"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+DEPEND="${PYTHON_DEPS}"
+RDEPEND="${DEPEND}"
+
+PATCHES=( "${FILESDIR}"/${P}-gentoo.patch )
+
+src_prepare() {
+ default
+ sed -i \
+ -e "s:@PYTHON_SITEDIR@:$(python_get_sitedir):g" \
+ quex/DEFINITIONS.py || die
+ mv quex/engine/codec_db/database . || die
+}
+
+src_install() {
+ default
+ insinto /usr/share/quex
+ doins -r database
+ dosym $(python_get_sitedir)/quex/code_base /usr/include/quex/code_base
+
+ python_domodule quex
+ python_newexe quex-exe.py quex
+ doman manpage/quex.1
+ dodoc -r demo
+}