summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichel Zou2015-11-30 20:15:14 +0100
committerMichel Zou2015-11-30 20:15:14 +0100
commitdd48667a6d9cbc4ff6cbafd54dbe9f4d05d3de3a (patch)
treea263600c19d2ce6c3012cf82b0eba8e971e95a1b
downloadaur-dd48667a6d9cbc4ff6cbafd54dbe9f4d05d3de3a.tar.gz
Initial import
-rw-r--r--.SRCINFO60
-rw-r--r--PKGBUILD100
2 files changed, 160 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..4f8c26701a1
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,60 @@
+pkgbase = python-sphinx-git
+ pkgver = r5767.1cef30f
+ pkgrel = 1
+ url = http://sphinx.pocoo.org/
+ arch = any
+ license = BSD
+ checkdepends = python-nose
+ checkdepends = python2-nose
+ checkdepends = texlive-latexextra
+ checkdepends = python-snowballstemmer
+ checkdepends = python2-snowballstemmer
+ checkdepends = python-babel
+ checkdepends = python2-babel
+ checkdepends = python-sphinx-alabaster-theme
+ checkdepends = python2-sphinx-alabaster-theme
+ checkdepends = python-sphinx_rtd_theme
+ checkdepends = python2-sphinx_rtd_theme
+ checkdepends = python2-mock
+ makedepends = git
+ makedepends = python-setuptools
+ makedepends = python-docutils
+ makedepends = python-jinja
+ makedepends = python-pygments
+ makedepends = python-six
+ makedepends = python2-setuptools
+ makedepends = python2-docutils
+ makedepends = python2-jinja
+ makedepends = python2-pygments
+ makedepends = python2-six
+ source = git+https://github.com/sphinx-doc/sphinx.git
+ md5sums = SKIP
+
+pkgname = python-sphinx-git
+ pkgdesc = Python3 documentation generator
+ depends = python-jinja
+ depends = python-pygments
+ depends = python-docutils
+ depends = python-sphinx_rtd_theme
+ depends = python-sphinx-alabaster-theme
+ depends = python-babel
+ depends = python-snowballstemmer
+ depends = python-six
+ optdepends = texlive-latexextra: for generation of PDF documentation
+ provides = python-sphinx
+ conflicts = python-sphinx
+
+pkgname = python2-sphinx-git
+ pkgdesc = Python2 documentation generator
+ depends = python2-jinja
+ depends = python2-pygments
+ depends = python2-docutils
+ depends = python2-sphinx_rtd_theme
+ depends = python2-sphinx-alabaster-theme
+ depends = python2-babel
+ depends = python2-snowballstemmer
+ depends = python2-six
+ optdepends = texlive-latexextra: for generation of PDF documentation
+ provides = python2-sphinx
+ conflicts = python2-sphinx
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..e8349600b2f
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,100 @@
+
+pkgbase=python-sphinx-git
+pkgname=('python-sphinx-git' 'python2-sphinx-git')
+pkgver=r5767.1cef30f
+pkgrel=1
+arch=('any')
+url='http://sphinx.pocoo.org/'
+license=('BSD')
+makedepends=('git'
+ 'python-setuptools'
+ 'python-docutils'
+ 'python-jinja'
+ 'python-pygments'
+ 'python-six'
+ 'python2-setuptools'
+ 'python2-docutils'
+ 'python2-jinja'
+ 'python2-pygments'
+ 'python2-six'
+)
+checkdepends=(
+ 'python-nose' 'python2-nose'
+ 'texlive-latexextra'
+ 'python-snowballstemmer' 'python2-snowballstemmer'
+ 'python-babel' 'python2-babel'
+ 'python-sphinx-alabaster-theme' 'python2-sphinx-alabaster-theme'
+ 'python-sphinx_rtd_theme' 'python2-sphinx_rtd_theme'
+ 'python2-mock'
+)
+source=("git+https://github.com/sphinx-doc/sphinx.git")
+md5sums=('SKIP')
+
+pkgver() {
+ cd "${srcdir}/sphinx"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+
+ # souce duplication is required because makefile modify source code
+ # setyp.py --build tricks don't works well
+ cp -a sphinx sphinx2
+ # change python2 interpreter
+ find sphinx2 -type f -exec \
+ sed -i '1s,^#! \?/usr/bin/\(env \|\)python$,#!/usr/bin/python2,' {} \;
+ # change sphinx-binaries name in source code
+ find sphinx2 -type f -name '*.py' -exec \
+ sed -ri 's,(sphinx-(:?build|apidoc|autogen|quickstart)),\12,' {} \;
+}
+
+build() {
+ msg2 'Python 3 version'
+ cd "$srcdir"/sphinx
+ make PYTHON=python3 build
+ msg2 'Python 2 version'
+ cd "$srcdir"/sphinx2
+ make PYTHON=python2 build
+}
+
+check() {
+ msg2 'Python 3 version'
+ cd "$srcdir"/sphinx
+# make PYTHON=python3 test
+ rm -r tests
+
+ msg2 'Python 2 version'
+ cd "$srcdir"/sphinx2
+ make PYTHON=python2 test
+ rm -r tests
+}
+
+package_python-sphinx-git() {
+ pkgdesc='Python3 documentation generator'
+ depends=('python-jinja' 'python-pygments' 'python-docutils' 'python-sphinx_rtd_theme' 'python-sphinx-alabaster-theme' 'python-babel'
+'python-snowballstemmer' 'python-six')
+ optdepends=('texlive-latexextra: for generation of PDF documentation')
+ provides=('python-sphinx')
+ conflicts=('python-sphinx')
+
+ cd sphinx
+ python setup.py install --root="$pkgdir" --optimize=1
+
+ install -Dm644 "$srcdir"/sphinx/LICENSE "$pkgdir"/usr/share/licenses/python-sphinx/LICENSE
+}
+
+package_python2-sphinx-git() {
+ pkgdesc='Python2 documentation generator'
+ depends=('python2-jinja' 'python2-pygments' 'python2-docutils' 'python2-sphinx_rtd_theme' 'python2-sphinx-alabaster-theme' 'python2-babel'
+'python2-snowballstemmer' 'python2-six')
+ optdepends=('texlive-latexextra: for generation of PDF documentation')
+ provides=('python2-sphinx')
+ conflicts=('python2-sphinx')
+
+ cd sphinx2
+ python2 setup.py install --root="$pkgdir" --optimize=1
+
+ install -Dm644 "$srcdir"/sphinx/LICENSE "$pkgdir"/usr/share/licenses/python2-sphinx/LICENSE
+}
+
+# vim:set ts=2 sw=2 et: