forked from archlinux/svntogit-packages
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
archrelease: copy trunk to extra-i686
git-svn-id: file:///srv/repos/svn-packages/svn@97327 eb2447ed-0c53-47e4-bac8-5bc4a241df78
- Loading branch information
andrea
committed
Oct 29, 2010
1 parent
6471e22
commit 068e284
Showing
3 changed files
with
84 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
# $Id$ | ||
# Maintainer: Andrea Scarpino <[email protected]> | ||
# Contributor: George Giorgidze <giorgidze (at) gmail.com> | ||
# Contributor: Stefan Husmann <[email protected]> | ||
|
||
pkgbase=antlr2 | ||
pkgname=('antlr2' 'python-antlr2') | ||
pkgver=2.7.7 | ||
pkgrel=1 | ||
arch=('i686' 'x86_64') | ||
url="http://www.antlr2.org/" | ||
license=('custom') | ||
makedepends=('java-environment' 'python2' 'sh') | ||
source=("http://www.antlr2.org/download/antlr-${pkgver}.tar.gz" | ||
'runantlr2.sh' | ||
'gcc4.4.patch') | ||
md5sums=('01cc9a2a454dd33dcd8c856ec89af090' | ||
'e4aa827cf78f97c4e5fae086831192d6' | ||
'8574c93f40e6477e83c29f9b07de49da') | ||
|
||
build() { | ||
cd "${srcdir}/antlr-${pkgver}" | ||
|
||
patch -Np0 -i ${srcdir}/gcc4.4.patch | ||
|
||
./configure --prefix=/usr \ | ||
--disable-examples \ | ||
--disable-csharp | ||
make | ||
} | ||
|
||
package_antlr2() { | ||
pkgdesc="ANother Tool for Language Recognition, (formerly PCCTS) is a language tool that provides a framework for constructing recognizers, compilers, and translators from grammatical descriptions containing C++ or Java actions" | ||
depends=('java-runtime' 'sh') | ||
replaces=('antlr') | ||
conflicts=('antlr') | ||
provides=("antlr=${pkgver}") | ||
|
||
cd ${srcdir}/antlr-${pkgver}/lib/cpp | ||
make prefix="${pkgdir}/usr" install | ||
|
||
install -Dm644 ${srcdir}/antlr-${pkgver}/antlr/antlr.jar \ | ||
"${pkgdir}/usr/share/java/antlr2.jar" | ||
install -Dm755 ${srcdir}/runantlr2.sh ${pkgdir}/usr/bin/runantlr2 | ||
install -Dm644 ${srcdir}/antlr-${pkgver}/LICENSE.txt \ | ||
"${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" | ||
} | ||
|
||
package_python-antlr2() { | ||
pkgdesc="ANother Tool for Language Recognition, (formerly PCCTS) is a language tool that provides a framework for constructing recognizers, compilers, and translators from grammatical descriptions containing C++ or Java actions (Python version)" | ||
depends=('antlr2' 'python2') | ||
replaces=('python-antlr') | ||
conflicts=('python-antlr') | ||
provides=("python-antlr=${pkgver}") | ||
|
||
cd ${srcdir}/antlr-${pkgver}/lib/python | ||
python2 setup.py install --root="${pkgdir}" --optimize=1 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
diff -Naur antlr-2.7.7.orig/lib/cpp/antlr/CharScanner.hpp antlr-2.7.7/lib/cpp/antlr/CharScanner.hpp | ||
--- lib/cpp/antlr/CharScanner.hpp 2006-11-01 22:37:17.000000000 +0100 | ||
+++ lib/cpp/antlr/CharScanner.hpp 2008-03-19 20:09:21.000000000 +0100 | ||
@@ -10,6 +10,7 @@ | ||
|
||
#include <antlr/config.hpp> | ||
|
||
+#include <cstring> | ||
#include <map> | ||
|
||
#ifdef HAS_NOT_CCTYPE_H | ||
--- lib/cpp/antlr/CharScanner.hpp~ 2008-11-11 21:24:02.000000000 +0000 | ||
+++ lib/cpp/antlr/CharScanner.hpp 2008-11-11 21:24:33.000000000 +0000 | ||
@@ -10,6 +10,7 @@ | ||
|
||
#include <antlr/config.hpp> | ||
|
||
+#include <cstdio> | ||
#include <cstring> | ||
#include <map> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/bin/sh | ||
echo Running 'java antlr.Tool $*' with /usr/share/java/antlr2.jar appended to the CLASSPATH variable | ||
export CLASSPATH | ||
CLASSPATH=$CLASSPATH:/usr/share/java/antlr2.jar | ||
java antlr.Tool $* |