[arch-commits] Commit in sagemath-doc/repos (4 files)

Antonio Rojas arojas at archlinux.org
Sun May 6 12:52:02 UTC 2018


    Date: Sunday, May 6, 2018 @ 12:52:01
  Author: arojas
Revision: 319017

archrelease: copy trunk to community-testing-any

Added:
  sagemath-doc/repos/community-testing-any/
  sagemath-doc/repos/community-testing-any/PKGBUILD
    (from rev 319016, sagemath-doc/trunk/PKGBUILD)
  sagemath-doc/repos/community-testing-any/docbuild_main.patch
    (from rev 319016, sagemath-doc/trunk/docbuild_main.patch)
  sagemath-doc/repos/community-testing-any/sagemath-sphinx-1.7.patch
    (from rev 319016, sagemath-doc/trunk/sagemath-sphinx-1.7.patch)

---------------------------+
 PKGBUILD                  |   65 ++++++++++++++++++++++++++++++++++++++++++++
 docbuild_main.patch       |    6 ++++
 sagemath-sphinx-1.7.patch |   13 ++++++++
 3 files changed, 84 insertions(+)

Copied: sagemath-doc/repos/community-testing-any/PKGBUILD (from rev 319016, sagemath-doc/trunk/PKGBUILD)
===================================================================
--- community-testing-any/PKGBUILD	                        (rev 0)
+++ community-testing-any/PKGBUILD	2018-05-06 12:52:01 UTC (rev 319017)
@@ -0,0 +1,65 @@
+# $Id$
+# Maintainer: Antonio Rojas <arojas at archlinux.org>
+
+pkgname=sagemath-doc
+pkgver=8.2
+pkgrel=1
+pkgdesc="HTML documentation and inline help for SageMath"
+arch=(any)
+url="http://www.sagemath.org"
+license=(GPL)
+depends=(python2-sphinx gap-doc thebe)
+makedepends=(sage-notebook python2-pyzmq python2-docutils python2-jupyter_client python2-pkgconfig cython2 python2-ipywidgets)
+source=("$pkgname-$pkgver.tar.gz::https://github.com/sagemath/sage/archive/$pkgver.tar.gz"
+        docbuild_main.patch sagemath-sphinx-1.7.patch
+        pari-ratpoints.patch::"https://github.com/sagemath/sage/commit/83458400.patch")
+sha256sums=('41ba2c2dde7a02e1bb6880ae875d37ab058567cc26e760efe87eeb12188cd65b'
+            'ea5e17bb7a7cb36a22e5e3872fcc2585852bc971c4b139b0b2cd69a36c1b009b'
+            '4c7865deff9d6ad2f9ba807a55b4ffc7e9951f387c2bd438095ab0117c9eaf60'
+            'e24ad879f6b2eb970778fc5e867bcbe0a6d393feca8f11f5cb8d07da1f024be9')
+
+prepare() {
+  cd sage-$pkgver
+
+# fix relative imports
+  patch -p0 -i ../docbuild_main.patch
+# fix build with sphinx 1.7
+  patch -p1 -i ../sagemath-sphinx-1.7.patch
+# revert usage of development PARI features
+  patch -Rp1 -i ../pari-ratpoints.patch
+
+# use sage_setup imports from sagemath source, but use system sage ones (which include compiled modules)
+  mkdir -p local-python
+  ln -sr src/sage_setup local-python
+}
+
+build() {
+  cd sage-$pkgver/src
+
+  export SAGE_LOCAL="/usr"
+  export SAGE_ROOT="/usr"
+  export SAGE_SRC="$PWD"
+  export SAGE_DOC_SRC="$SAGE_SRC"/doc
+  export SAGE_DOC="$SAGE_SRC"/doc
+  export SAGE_DOC_MATHJAX=yes
+  export PYTHONPATH="$srcdir"/sage-$pkgver/local-python
+  python2 sage_setup/docbuild --no-pdf-links -k all html
+}
+
+package() {
+  cd sage-$pkgver/src/doc
+ 
+  mkdir -p "$pkgdir"/usr/share/doc/sage/en
+  cp -r en/introspect "$pkgdir"/usr/share/doc/sage/en
+  cp -r common "$pkgdir"/usr/share/doc/sage
+  cp -r html "$pkgdir"/usr/share/doc/sage
+
+# Replace duplicated files by symlinks (Gentoo)
+  cd "$pkgdir"/usr/share/doc/sage
+  mv html/en/_static{,.tmp}
+  for _dir in `find -name _static` ; do
+        rm -r $_dir
+        ln -s /usr/share/doc/sage/html/en/_static $_dir
+  done
+  mv html/en/_static{.tmp,}
+}

Copied: sagemath-doc/repos/community-testing-any/docbuild_main.patch (from rev 319016, sagemath-doc/trunk/docbuild_main.patch)
===================================================================
--- community-testing-any/docbuild_main.patch	                        (rev 0)
+++ community-testing-any/docbuild_main.patch	2018-05-06 12:52:01 UTC (rev 319017)
@@ -0,0 +1,6 @@
+--- src/sage_setup/docbuild/__main__.py.orig
++++ src/sage_setup/docbuild/__main__.py
+@@ -1,2 +1,2 @@
+-from . import main
++from sage_setup.docbuild import main
+ main()

Copied: sagemath-doc/repos/community-testing-any/sagemath-sphinx-1.7.patch (from rev 319016, sagemath-doc/trunk/sagemath-sphinx-1.7.patch)
===================================================================
--- community-testing-any/sagemath-sphinx-1.7.patch	                        (rev 0)
+++ community-testing-any/sagemath-sphinx-1.7.patch	2018-05-06 12:52:01 UTC (rev 319017)
@@ -0,0 +1,13 @@
+diff --git a/src/sage_setup/docbuild/__init__.py b/src/sage_setup/docbuild/__init__.py
+index fada71126c..72eb35ee4c 100644
+--- a/src/sage_setup/docbuild/__init__.py
++++ b/src/sage_setup/docbuild/__init__.py
+@@ -99,7 +99,7 @@ def builder_helper(type):
+         logger.debug(build_command)
+ 
+         # Run Sphinx with Sage's special logger
+-        sys.argv = ["sphinx-build"] + build_command.split()
++        sys.argv = build_command.split()
+         from .sphinxbuild import runsphinx
+         try:
+             runsphinx()



More information about the arch-commits mailing list