[arch-commits] Commit in ipython/trunk (PKGBUILD)

Kyle Keen kkeen at archlinux.org
Fri Aug 14 05:24:14 UTC 2015


    Date: Friday, August 14, 2015 @ 07:24:14
  Author: kkeen
Revision: 138339

upgpkg: ipython 4.0.0-1

Modified:
  ipython/trunk/PKGBUILD

----------+
 PKGBUILD |  163 +++++++++++++++++++++++++++++++++++++------------------------
 1 file changed, 100 insertions(+), 63 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2015-08-14 05:21:37 UTC (rev 138338)
+++ PKGBUILD	2015-08-14 05:24:14 UTC (rev 138339)
@@ -6,45 +6,95 @@
 # Contributor : Douglas Soares de Andrade <dsa at aur.archlinux.org>
 
 pkgbase=ipython 
-pkgname=(ipython ipython2 ipython-notebook ipython2-notebook)
-pkgver=3.2.1
+pkgname=(ipython ipython2)
+pkgver=4.0.0
 pkgrel=1
 pkgdesc="An enhanced Interactive Python shell."
 arch=('any')
 url="http://ipython.org"
 license=('BSD')
-depends=('python' 'sqlite' 'python-setuptools')
-makedepends=('python-setuptools' 'python2-setuptools' 'sqlite')
-optdepends=("python-nose: for IPython's test suite"
-            "python-pyqt4: for ipython qtconsole"
-            "python-sip: for ipython qtconsole"
-            "python-pygments: for ipython qtconsole"
-            "python-pyzmq: for ipython qtconsole"
-            "ipython-notebook: for the notebook")
+depends=('python' 'python-decorator' 'python-pexpect' 'sqlite' 'python-setuptools')
+makedepends=('python-setuptools' 'python2-setuptools')
+optdepends=("python-nose: for IPython's test suite")
 install=ipython.install
+
+# qtconsole isn't released for 4 yet
+# qtconsole deps: python-pyqt4 python-sip python-pygments python-pyzmq
+
 #source=("http://archive.ipython.org/release/$pkgver/ipython-$pkgver.tar.gz")
 #source=("https://github.com/ipython/ipython/archive/rel-$pkgver.tar.gz")
-source=("https://pypi.python.org/packages/source/i/ipython/$pkgbase-$pkgver.tar.gz")
-md5sums=('61c2d5665ff1bd65eceb19fa7f1b23c7')
+source=("https://pypi.python.org/packages/source/i/ipython/$pkgbase-$pkgver.tar.gz"
+        "ipykernel.tgz::https://github.com/ipython/ipykernel/archive/4.0.3.tar.gz"
+        "https://pypi.python.org/packages/source/t/traitlets/traitlets-4.0.0.tar.gz"
+        "https://pypi.python.org/packages/source/i/ipython_genutils/ipython_genutils-0.1.0.tar.gz"
+        "https://pypi.python.org/packages/source/p/pickleshare/pickleshare-0.5.tar.gz"
+        "https://pypi.python.org/packages/source/p/path.py/path.py-7.6.tar.gz"
+        "https://pypi.python.org/packages/source/s/simplegeneric/simplegeneric-0.8.1.zip")
+md5sums=('c2fecbcf1c0fbdc82625c77a50733dd6'
+         '690f424a89e38a5559802bb58223142e'
+         '27df56a921848686cf52766177a434f2'
+         '9a8afbe0978adbcbfcb3b35b2d015a56'
+         '25337740507cb855ad58bfcf60f7710e'
+         'e70090139fc136462d52460b0e4a00d1'
+         'f9c1fab00fd981be588fc32759f474e3')
 
+# With 4.0 many previously bundled external libraries are no longer bundled
+# Since there are so many and they are so small, they get re-bundled here
+# Break them out if any non-ipython package ends up needing these
+
+# traitlets (depends on python-decorator)
+# ipython_genutils
+# "Pretend this doesn’t exist. Nobody should use it."
+# "Vestigial IPython utilities: DO NOT USE"
+# (still required for now though, but drop at first chance)
+# pickleshare (depends on path.py)
+# path.py
+# simplegeneric (so old that it only comes in .zip and still refers to the cheeseshop)
+
 # confirm that an update does not break sage?
 
+prepare() {
+  cd "$srcdir"
+  cp -r ipython-$pkgver        ipython2-$pkgver
+  cp -r ipykernel-4.0.3        python2-ipykernel-4.0.3
+  cp -r ipython_genutils-0.1.0 ipython2_genutils-0.1.0
+  cp -r pickleshare-0.5        python2-pickleshare-0.5
+  cp -r traitlets-4.0.0        python2-traitlets-4.0.0
+  cp -r path.py-7.6            python2-path.py-7.6
+  cp -r simplegeneric-0.8.1    python2-simplegeneric-0.8.1
+}
+
 build() {
   cd "$srcdir"
-  cp -r ipython-$pkgver ipython2-$pkgver
 }
 
 package_ipython() {
-  provides=('ipython3')
-  replaces=('ipython3')
   cd "$srcdir/ipython-$pkgver"
 
   # see https://github.com/ipython/ipython/issues/2057
   #export LC_ALL=en_US.UTF-8
   python3 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
-  find "$pkgdir/" -name '*.pyc' -delete
-  find "$pkgdir/" -type d -empty -delete
 
+  # TEMPORARY!
+  pushd "$srcdir/ipython_genutils-0.1.0"
+  python3 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/pickleshare-0.5"
+  python3 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/traitlets-4.0.0"
+  python3 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/path.py-7.6"
+  python3 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/simplegeneric-0.8.1"
+  python3 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/ipykernel-4.0.3"
+  python3 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+
   install -Dm644 docs/source/about/license_and_copyright.rst "$pkgdir/usr/share/licenses/ipython/LICENSE"
 
   pushd "examples/IPython Kernel/"
@@ -51,33 +101,46 @@
   # FS#45120
   sed -i 's/gnome-netstatus-idle/ipython/' *.desktop
   install -Dm644 ipython.desktop "$pkgdir/usr/share/applications/ipython.desktop"
-  install -Dm644 ipython-qtconsole.desktop "$pkgdir/usr/share/applications/ipython-qtconsole.desktop"
+  #install -Dm644 ipython-qtconsole.desktop "$pkgdir/usr/share/applications/ipython-qtconsole.desktop"
   popd
-  pushd IPython/qt/console/resources/icon/
-  install -Dm644 IPythonConsole.svg "$pkgdir/usr/share/icons/hicolor/scalable/apps/ipython.svg"
-  popd
+  #pushd IPython/qt/console/resources/icon/
+  #install -Dm644 IPythonConsole.svg "$pkgdir/usr/share/icons/hicolor/scalable/apps/ipython.svg"
+  #popd
+
+
 }
 
 package_ipython2() {
   pkgdesc="An enhanced Interactive Python2 shell."
-  depends=('python2' 'sqlite' 'python2-setuptools')
+  depends=('python2' 'python2-decorator' 'python2-pexpect' 'sqlite' 'python2-setuptools')
   optdepends=("wxpython: needed for ipython2 --gui=wx"
-              "python2-nose: for IPython's test suite"
-              "python2-pyqt4: for ipython qtconsole"
-              "python2-sip: for ipython qtconsole"
-              "python2-pygments: for ipython qtconsole"
-              "python2-pyzmq: for ipython qtconsole"
-              "ipython2-notebook: for the notebook")
+              "python2-nose: for IPython's test suite")
+  # "wxpython: needed for ipython2 --gui=wx"   does this still work?
 
   cd "$srcdir/ipython2-$pkgver"
 
   python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
-  rm -rf "$pkgdir/usr/share/doc"
-  find "$pkgdir" -name '*.py' -print0 | xargs -0 \
-    sed -i -e 's,^#!/usr/bin/env python$,#!/usr/bin/env python2,' \
-    -e 's,^#!/usr/bin/python$,#!/usr/bin/python2,'
-  find "$pkgdir/" -name '*.pyc' -delete
 
+  # TEMPORARY!
+  pushd "$srcdir/ipython2_genutils-0.1.0"
+  python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/python2-pickleshare-0.5"
+  python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/python2-traitlets-4.0.0"
+  python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/python2-path.py-7.6"
+  python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/python2-simplegeneric-0.8.1"
+  python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+  pushd "$srcdir/python2-ipykernel-4.0.3"
+  #python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=0
+  popd
+
   install -Dm644 docs/source/about/license_and_copyright.rst "$pkgdir/usr/share/licenses/ipython2/LICENSE"
 
   # hack to get around ipython collision
@@ -92,36 +155,10 @@
   sed -i 's/ython/ython2/g' *.desktop
   sed -i 's/gnome-netstatus-idle/ipython2/' *.desktop
   install -Dm644 ipython.desktop "$pkgdir/usr/share/applications/ipython2.desktop"
-  install -Dm644 ipython-qtconsole.desktop "$pkgdir/usr/share/applications/ipython2-qtconsole.desktop"
+  #install -Dm644 ipython-qtconsole.desktop "$pkgdir/usr/share/applications/ipython2-qtconsole.desktop"
   popd
-  pushd IPython/qt/console/resources/icon/
-  install -Dm644 IPythonConsole.svg "$pkgdir/usr/share/icons/hicolor/scalable/apps/ipython2.svg"
-  popd
-
-
+  #pushd IPython/qt/console/resources/icon/
+  #install -Dm644 IPythonConsole.svg "$pkgdir/usr/share/icons/hicolor/scalable/apps/ipython2.svg"
+  #popd
 }
 
-# Nothing in these packages except dependencies because five optdeps is too many
-
-package_ipython-notebook() {
-  pkgdesc="Web-based environment where you can combine code, text, math, plots and media into a single document"
-  depends=('ipython' 'python-pyzmq' 'python-tornado' 'python-terminado'
-           'python-jinja' 'python-jsonschema' 'python-mistune'
-           'python-pygments')
-  optdepends=('haskell-pandoc: ipython notebook conversion'
-              'texlive-bin: notebook pdf export')
-  cd "$srcdir/ipython-$pkgver"
-  install -Dm644 docs/source/about/license_and_copyright.rst "$pkgdir/usr/share/licenses/ipython-notebook/LICENSE"
-}
-
-package_ipython2-notebook() {
-  pkgdesc="Web-based environment where you can combine code, text, math, plots and media into a single document"
-  depends=('ipython2' 'python2-pyzmq' 'python2-tornado' 'python2-terminado'
-           'python2-jinja' 'python2-jsonschema' 'python2-mistune'
-           'python2-pygments')
-  optdepends=('haskell-pandoc: ipython notebook conversion'
-              'texlive-bin: notebook pdf export')
-  cd "$srcdir/ipython2-$pkgver"
-  install -Dm644 docs/source/about/license_and_copyright.rst "$pkgdir/usr/share/licenses/ipython2-notebook/LICENSE"
-}
-



More information about the arch-commits mailing list