at 15.09-beta 1.9 kB view raw
1{ stdenv, fetchurl, buildPythonPackage, pythonPackages, pyqt4 ? null 2, notebookSupport ? true # ipython notebook 3, qtconsoleSupport ? true # ipython qtconsole 4, pylabSupport ? true # '%pylab' magic (backend: agg - no gui, just file) 5, pylabQtSupport ? true # '%pylab qt' (backend: Qt4Agg - plot to window) 6}: 7 8# ipython qtconsole works with both pyside and pyqt4. But ipython --pylab=qt 9# only works with pyqt4 (at least this is true for ipython 0.13.1). So just use 10# pyqt4 for both. 11 12assert qtconsoleSupport == true -> pyqt4 != null; 13assert pylabQtSupport == true -> pyqt4 != null; 14 15buildPythonPackage rec { 16 name = "ipython-${version}"; 17 version = "3.2.1"; 18 namePrefix = ""; 19 20 src = fetchurl { 21 url = "https://pypi.python.org/packages/source/i/ipython/${name}.tar.gz"; 22 sha256 = "c913adee7ae5b338055274c51a7d2b3cea468b5b316046fa520cd8a434b09177"; 23 }; 24 25 propagatedBuildInputs = [ 26 pythonPackages.readline 27 pythonPackages.sqlite3 # required for history support 28 ] ++ stdenv.lib.optionals notebookSupport [ 29 pythonPackages.tornado 30 pythonPackages.pyzmq 31 pythonPackages.jinja2 32 pythonPackages.jsonschema 33 ] ++ stdenv.lib.optionals qtconsoleSupport [ 34 pythonPackages.pygments 35 pythonPackages.pyzmq 36 pyqt4 37 ] ++ stdenv.lib.optionals pylabSupport [ 38 pythonPackages.matplotlib 39 ] ++ stdenv.lib.optionals pylabQtSupport [ 40 pythonPackages.matplotlib 41 pyqt4 42 ]; 43 44 doCheck = false; 45 46 meta = { 47 homepage = http://ipython.scipy.org/; 48 description = "An interactive computing environment for Python"; 49 license = stdenv.lib.licenses.bsd3; 50 longDescription = '' 51 The goal of IPython is to create a comprehensive environment 52 for interactive and exploratory computing. It consists of an 53 enhanced interactive Python shell and an architecture for 54 interactive parallel computing. 55 ''; 56 maintainers = with stdenv.lib.maintainers; [ bjornfor jgeerds ]; 57 }; 58}