diff options
author | Alexander F Rødseth | 2015-06-10 14:56:42 +0200 |
---|---|---|
committer | Alexander F Rødseth | 2015-06-10 14:56:42 +0200 |
commit | bbc5268094c5c05bf2f397802c3e5ac79cce4fe0 (patch) | |
tree | c746f4b16fe2f1f0ae7f43139ae73169b2ef241f | |
download | aur-bbc5268094c5c05bf2f397802c3e5ac79cce4fe0.tar.gz |
Initial import
-rw-r--r-- | .SRCINFO | 19 | ||||
-rw-r--r-- | PKGBUILD | 45 |
2 files changed, 64 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..e70494325334 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,19 @@ +pkgbase = python-pycparser-git + pkgdesc = C parser and AST generator written in Python + pkgver = 20131228 + pkgrel = 1 + url = https://github.com/eliben/pycparser + arch = x86_64 + arch = i686 + license = BSD + makedepends = git + depends = python + depends = python-ply + conflicts = pycparser + conflicts = python-pycparser + conflicts = python-pycparser-hg + source = pycparser::git://github.com/eliben/pycparser.git + sha256sums = SKIP + +pkgname = python-pycparser-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..f53a612dc23d --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,45 @@ +# Maintainer: Alexander Rødseth <rodseth@gmail.com> +# Contributor: lang2 <wenzhi.liang@gmail.com> + +pkgname=python-pycparser-git +pkgver=20131228 +pkgrel=1 +pkgdesc='C parser and AST generator written in Python' +url='https://github.com/eliben/pycparser' +makedepends=('git') +depends=('python' 'python-ply') +conflicts=('pycparser' 'python-pycparser' 'python-pycparser-hg') +arch=('x86_64' 'i686') +license=('BSD') +source=('pycparser::git://github.com/eliben/pycparser.git') +sha256sums=('SKIP') + +pkgver() { + cd pycparser + + git log -n1 --format="%ci" | awk '{print $1}' | sed s/-//g +} + +prepare() { + cd pycparser + + # generate lextab.py and yacctab.py + python -c 'import pycparser; pycparser.CParser()' + mv lextab.py yacctab.py pycparser +} + +build() { + cd pycparser + + python setup.py build +} + +package() { + cd pycparser + + python setup.py install --root="$pkgdir" --optimize=1 + install -Dm644 LICENSE \ + "$pkgdir/usr/share/licenses/$pkgname/LICENSE" +} + +# vim:set ts=2 sw=2 et: |