Merge branch 'buildPythonPackage+wheels'
This commit is contained in:
commit
67e03d0c50
@ -196,12 +196,12 @@ you need it.</para>
|
||||
|
||||
<para>
|
||||
Currently supported interpreters are <varname>python26</varname>, <varname>python27</varname>,
|
||||
<varname>python32</varname>, <varname>python33</varname>, <varname>python34</varname>
|
||||
<varname>python33</varname>, <varname>python34</varname>, <varname>python35</varname>
|
||||
and <varname>pypy</varname>.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
<varname>python</varname> is an alias of <varname>python27</varname> and <varname>python3</varname> is an alias of <varname>python34</varname>.
|
||||
<varname>python</varname> is an alias to <varname>python27</varname> and <varname>python3</varname> is an alias to <varname>python34</varname>.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
@ -231,7 +231,7 @@ are provided with all modules included.</para>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
All packages depending on any Python interpreter get appended <varname>$out/${python.libPrefix}/site-packages</varname>
|
||||
All packages depending on any Python interpreter get appended <varname>$out/${python.sitePackages}</varname>
|
||||
to <literal>$PYTHONPATH</literal> if such directory exists.
|
||||
</para>
|
||||
|
||||
@ -306,7 +306,7 @@ twisted = buildPythonPackage {
|
||||
Most of Python packages that use <varname>buildPythonPackage</varname> are defined
|
||||
in <link xlink:href="https://github.com/NixOS/nixpkgs/blob/master/pkgs/top-level/python-packages.nix"><filename>pkgs/top-level/python-packages.nix</filename></link>
|
||||
and generated for each python interpreter separately into attribute sets <varname>python26Packages</varname>,
|
||||
<varname>python27Packages</varname>, <varname>python32Packages</varname>, <varname>python33Packages</varname>,
|
||||
<varname>python27Packages</varname>, <varname>python35Packages</varname>, <varname>python33Packages</varname>,
|
||||
<varname>python34Packages</varname> and <varname>pypyPackages</varname>.
|
||||
</para>
|
||||
|
||||
@ -314,20 +314,14 @@ twisted = buildPythonPackage {
|
||||
<function>buildPythonPackage</function> mainly does four things:
|
||||
|
||||
<orderedlist>
|
||||
<listitem><para>
|
||||
In the <varname>configurePhase</varname>, it patches
|
||||
<literal>setup.py</literal> to always include setuptools before
|
||||
distutils for monkeypatching machinery to take place.
|
||||
</para></listitem>
|
||||
|
||||
<listitem><para>
|
||||
In the <varname>buildPhase</varname>, it calls
|
||||
<literal>${python.interpreter} setup.py build ...</literal>
|
||||
<literal>${python.interpreter} setup.py bdist_wheel</literal> to build a wheel binary zipfile.
|
||||
</para></listitem>
|
||||
|
||||
<listitem><para>
|
||||
In the <varname>installPhase</varname>, it calls
|
||||
<literal>${python.interpreter} setup.py install ...</literal>
|
||||
In the <varname>installPhase</varname>, it installs the wheel file using
|
||||
<literal>pip install *.whl</literal>.
|
||||
</para></listitem>
|
||||
|
||||
<listitem><para>
|
||||
@ -336,11 +330,15 @@ twisted = buildPythonPackage {
|
||||
directory to include <literal>$PYTHONPATH</literal> and <literal>$PATH</literal>
|
||||
environment variables.
|
||||
</para></listitem>
|
||||
|
||||
<listitem><para>
|
||||
In the <varname>installCheck/varname> phase, <literal>${python.interpreter} setup.py test</literal>
|
||||
is ran.
|
||||
</para></listitem>
|
||||
</orderedlist>
|
||||
</para>
|
||||
|
||||
<para>By default <varname>doCheck = true</varname> is set and tests are run with
|
||||
<literal>${python.interpreter} setup.py test</literal> command in <varname>checkPhase</varname>.</para>
|
||||
<para>By default <varname>doCheck = true</varname> is set</para>
|
||||
|
||||
<para>
|
||||
As in Perl, dependencies on other Python packages can be specified in the
|
||||
@ -382,17 +380,10 @@ twisted = buildPythonPackage {
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>setupPyInstallFlags</varname></term>
|
||||
<listitem><para>
|
||||
List of flags passed to <command>setup.py install</command> command.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>setupPyBuildFlags</varname></term>
|
||||
<listitem><para>
|
||||
List of flags passed to <command>setup.py build</command> command.
|
||||
List of flags passed to <command>setup.py build_ext</command> command.
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
@ -400,7 +391,7 @@ twisted = buildPythonPackage {
|
||||
<term><varname>pythonPath</varname></term>
|
||||
<listitem><para>
|
||||
List of packages to be added into <literal>$PYTHONPATH</literal>.
|
||||
Packages in <varname>pythonPath</varname> are not propagated into user environment
|
||||
Packages in <varname>pythonPath</varname> are not propagated
|
||||
(contrary to <varname>propagatedBuildInputs</varname>).
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
@ -419,15 +410,6 @@ twisted = buildPythonPackage {
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>distutilsExtraCfg</varname></term>
|
||||
<listitem><para>
|
||||
Extra lines passed to <varname>[easy_install]</varname> section of
|
||||
<filename>distutils.cfg</filename> (acts as global setup.cfg
|
||||
configuration).
|
||||
</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>makeWrapperArgs</varname></term>
|
||||
<listitem><para>
|
||||
|
@ -15,7 +15,7 @@ in buildPythonPackage rec {
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
coverage feedparser minimock sqlite3 mygpoclient intltool
|
||||
coverage minimock sqlite3 mygpoclient intltool
|
||||
gnome3.gnome_themes_standard gnome3.defaultIconTheme
|
||||
gnome3.gsettings_desktop_schemas
|
||||
];
|
||||
@ -27,8 +27,6 @@ in buildPythonPackage rec {
|
||||
|
||||
postPatch = "sed -ie 's/PYTHONPATH=src/PYTHONPATH=\$(PYTHONPATH):src/' makefile";
|
||||
|
||||
checkPhase = "make unittest";
|
||||
|
||||
preFixup = ''
|
||||
wrapProgram $out/bin/gpodder \
|
||||
--prefix XDG_DATA_DIRS : "${gnome3.gnome_themes_standard}/share:$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH"
|
||||
@ -40,17 +38,6 @@ in buildPythonPackage rec {
|
||||
postFixup = ''
|
||||
wrapPythonPrograms
|
||||
|
||||
if test -e $out/nix-support/propagated-build-inputs; then
|
||||
ln -s $out/nix-support/propagated-build-inputs $out/nix-support/propagated-user-env-packages
|
||||
fi
|
||||
|
||||
createBuildInputsPth build-inputs "$buildInputStrings"
|
||||
for inputsfile in propagated-build-inputs propagated-native-build-inputs; do
|
||||
if test -e $out/nix-support/$inputsfile; then
|
||||
createBuildInputsPth $inputsfile "$(cat $out/nix-support/$inputsfile)"
|
||||
fi
|
||||
done
|
||||
|
||||
sed -i "$out/bin/..gpodder-wrapped-wrapped" -e '{
|
||||
/import sys; sys.argv/d
|
||||
}'
|
||||
|
@ -10,7 +10,7 @@ pythonPackages.buildPythonPackage rec {
|
||||
sha256 = "0hhdss4i5436dj37pndxk81a4g3g8f6zqjyv04lhpqcww01290as";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [ mopidy ];
|
||||
propagatedBuildInputs = with pythonPackages; [ mopidy configobj ];
|
||||
|
||||
doCheck = false;
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
{ stdenv, pythonPackages, fetchgit }:
|
||||
|
||||
pythonPackages.buildPythonPackage rec {
|
||||
name = "leo-editor-${version}";
|
||||
version = "5.1";
|
||||
|
||||
namePrefix = "";
|
||||
version = "5.1";
|
||||
|
||||
src = fetchgit {
|
||||
url = "https://github.com/leo-editor/leo-editor";
|
||||
@ -13,6 +13,11 @@ pythonPackages.buildPythonPackage rec {
|
||||
|
||||
propagatedBuildInputs = with pythonPackages; [ pyqt4 sqlite3 ];
|
||||
|
||||
|
||||
patchPhase = ''
|
||||
rm setup.cfg
|
||||
'';
|
||||
|
||||
meta = {
|
||||
homepage = "http://leoeditor.com";
|
||||
description = "A powerful folding editor";
|
||||
|
@ -1,36 +1,36 @@
|
||||
{ stdenv, fetchsvn, buildPythonPackage, python, pyGtkGlade, makeWrapper, pyexiv2, lxml, pil, fbida, which }:
|
||||
{ stdenv, fetchsvn, buildPythonPackage, python, pyGtkGlade, makeWrapper, pyexiv2, pythonPackages, fbida, which }:
|
||||
|
||||
buildPythonPackage {
|
||||
name = "jbrout-338";
|
||||
buildPythonPackage rec {
|
||||
name = "jbrout-${version}";
|
||||
version = "338";
|
||||
|
||||
src = fetchsvn {
|
||||
url = "http://jbrout.googlecode.com/svn/trunk";
|
||||
rev = "338";
|
||||
rev = version;
|
||||
sha256 = "0257ni4vkxgd0qhs73fw5ppw1qpf11j8fgwsqc03b1k1yv3hk4hf";
|
||||
};
|
||||
|
||||
doCheck = false;
|
||||
# XXX: preConfigure to avoid this
|
||||
# File "/nix/store/vnyjxn6h3rbrn49m25yyw7i1chlxglhw-python-2.7.1/lib/python2.7/zipfile.py", line 348, in FileHeader
|
||||
# len(filename), len(extra))
|
||||
#struct.error: ushort format requires 0 <= number <= USHRT_MAX
|
||||
|
||||
preConfigure = ''
|
||||
# XXX: patchPhase to avoid this
|
||||
# File "/nix/store/vnyjxn6h3rbrn49m25yyw7i1chlxglhw-python-2.7.1/lib/python2.7/zipfile.py", line 348, in FileHeader
|
||||
# len(filename), len(extra))
|
||||
#struct.error: ushort format requires 0 <= number <= USHRT_MAX
|
||||
patchPhase = ''
|
||||
find | xargs touch
|
||||
|
||||
substituteInPlace setup.py --replace "version=__version__" "version=baseVersion"
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $out/bin
|
||||
echo '#!/bin/sh' > $out/bin/jbrout
|
||||
echo "python $out/lib/python2.7/site-packages/jbrout-src-py2.7.egg/jbrout/jbrout.py" >> $out/bin/jbrout
|
||||
mkdir $out/bin
|
||||
echo "python $out/${python.sitePackages}/jbrout/jbrout.py" > $out/bin/jbrout
|
||||
chmod +x $out/bin/jbrout
|
||||
|
||||
wrapProgram $out/bin/jbrout \
|
||||
--set PYTHONPATH "$out/lib/python:$(toPythonPath ${pyGtkGlade})/gtk-2.0:$(toPythonPath ${pyexiv2}):$(toPythonPath ${lxml}):$(toPythonPath ${pil}):$PYTHONPATH" \
|
||||
--set PATH "${fbida}/bin:${which}/bin:$PATH"
|
||||
'';
|
||||
|
||||
buildInputs = [ python pyGtkGlade makeWrapper pyexiv2 lxml pil fbida which ];
|
||||
buildInputs = [ python makeWrapper which ];
|
||||
propagatedBuildInputs = with pythonPackages; [ pillow lxml pyGtkGlade pyexiv2 fbida ];
|
||||
|
||||
meta = {
|
||||
homepage = "http://code.google.com/p/jbrout";
|
||||
description = "Photo manager";
|
||||
|
@ -32,14 +32,15 @@ pythonPackages.buildPythonPackage {
|
||||
matplotlib beautifulsoup4 pygtk lxml ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
|
||||
preConfigure = with stdenv.lib; ''
|
||||
${concatStrings (map (x: "ln -s ${x.src} models/`basename ${x.name}`;")
|
||||
${concatStrings (map (x: "cp -R ${x.src} models/`basename ${x.name}`;")
|
||||
models)}
|
||||
|
||||
substituteInPlace ocrolib/{common,default}.py --replace /usr/local $out
|
||||
'';
|
||||
|
||||
doCheck = false; # fails
|
||||
checkPhase = ''
|
||||
patchShebangs .
|
||||
substituteInPlace ./run-test \
|
||||
|
@ -16,10 +16,10 @@ python27Packages.buildPythonPackage rec {
|
||||
|
||||
doCheck = false;
|
||||
|
||||
setupPyBuildFlags = ["-i"];
|
||||
|
||||
postPatch = ''
|
||||
sed -i -r "s|/usr(/local)?/share/|$out/share/|g" printrun/utils.py
|
||||
sed -i "s|distutils.core|setuptools|" setup.py
|
||||
sed -i "s|distutils.command.install |setuptools.command.install |" setup.py
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
|
@ -27,12 +27,12 @@ pythonPackages.buildPythonPackage rec {
|
||||
# string, which allows setting an explicit MIME type.
|
||||
patches = [ ./pytrainer-webkit.patch ];
|
||||
|
||||
pythonPath = with pythonPackages; [
|
||||
propagatedBuildInputs = with pythonPackages; [
|
||||
dateutil lxml matplotlibGtk pyGtkGlade pywebkitgtk
|
||||
sqlalchemy sqlalchemy_migrate
|
||||
sqlalchemy_migrate
|
||||
];
|
||||
|
||||
buildInputs = [gpsbabel sqlite] ++ pythonPath;
|
||||
buildInputs = [ gpsbabel sqlite ];
|
||||
|
||||
# This package contains no binaries to patch or strip.
|
||||
dontPatchELF = true;
|
||||
|
@ -1,6 +1,6 @@
|
||||
{ stdenv, lib, makeWrapper, fetchurl, curl, sasl, openssh, autoconf
|
||||
, automake114x, libtool, unzip, gnutar, jdk, maven, python, wrapPython
|
||||
, setuptools, distutils-cfg, boto, pythonProtobuf, apr, subversion
|
||||
, setuptools, boto, pythonProtobuf, apr, subversion
|
||||
, leveldb, glog, perf, utillinux, libnl, iproute
|
||||
}:
|
||||
|
||||
@ -15,7 +15,7 @@ in stdenv.mkDerivation rec {
|
||||
dontDisableStatic = true;
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.apache.org/dist/mesos/${version}/mesos-${version}.tar.gz";
|
||||
url = "http://archive.apache.org/dist/mesos/${version}/${name}.tar.gz";
|
||||
sha256 = "1v5xpn4wal4vcrvcklchx9slkpa8xlwqkdbnxzy9zkzpq5g3arxr";
|
||||
};
|
||||
|
||||
@ -26,7 +26,7 @@ in stdenv.mkDerivation rec {
|
||||
|
||||
buildInputs = [
|
||||
makeWrapper autoconf automake114x libtool curl sasl jdk maven
|
||||
python wrapPython boto distutils-cfg setuptools leveldb
|
||||
python wrapPython boto setuptools leveldb
|
||||
subversion apr glog
|
||||
] ++ lib.optionals stdenv.isLinux [
|
||||
libnl
|
||||
|
@ -12,12 +12,6 @@ buildPythonPackage rec {
|
||||
sha256 = "0li4kvxjmbz3nqg6bysgn2wdazqrd7gm9fym3rd7148aiqqwa91r";
|
||||
};
|
||||
|
||||
# Sometimes the generated output isn't identical. It seems like there's a
|
||||
# race condtion while patching the Mailnag/commons/dist_cfg.py file. This is
|
||||
# a small workaround to produce deterministic builds.
|
||||
# For more information see https://github.com/NixOS/nixpkgs/pull/8279
|
||||
setupPyBuildFlags = [ "--build-base=$PWD" ];
|
||||
|
||||
buildInputs = [
|
||||
gettext gtk3 pythonPackages.pygobject3 pythonPackages.dbus
|
||||
pythonPackages.pyxdg gdk_pixbuf libnotify gst_all_1.gstreamer
|
||||
|
@ -11,89 +11,25 @@ buildPythonPackage rec {
|
||||
name = "zim-${version}";
|
||||
version = "0.63";
|
||||
namePrefix = "";
|
||||
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://zim-wiki.org/downloads/${name}.tar.gz";
|
||||
sha256 = "077vf4h0hjmbk8bxj9l0z9rxcb3dw642n32lvfn6vjdna1qm910m";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [ pythonPackages.sqlite3 pygtk /*pythonPackages.pyxdg*/ pygobject ];
|
||||
propagatedBuildInputs = [ pythonPackages.sqlite3 pygtk pythonPackages.pyxdg pygobject ];
|
||||
|
||||
preBuild = ''
|
||||
mkdir -p /tmp/home
|
||||
export HOME="/tmp/home"
|
||||
'';
|
||||
|
||||
setupPyInstallFlags = ["--skip-xdg-cmd"];
|
||||
|
||||
#
|
||||
# Exactly identical to buildPythonPackage's version but for the
|
||||
# `--old-and-unmanagable`, which I removed. This was removed because
|
||||
# this is a setuptools specific flag and as zim is overriding
|
||||
# the install step, setuptools could not perform its monkey
|
||||
# patching trick for the command. Alternate solutions were to
|
||||
#
|
||||
# - Remove the custom install step (tested as working but
|
||||
# also remove the possibility of performing the xdg-cmd
|
||||
# stuff).
|
||||
# - Explicitly replace distutils import(s) by their setuptools
|
||||
# equivalent (untested).
|
||||
#
|
||||
# Both solutions were judged unsatisfactory as altering the code
|
||||
# would be required.
|
||||
#
|
||||
# Note that a improved solution would be to expose the use of
|
||||
# the `--old-and-unmanagable` flag as an option of passed to the
|
||||
# buildPythonPackage function.
|
||||
#
|
||||
# Also note that I stripped all comments.
|
||||
#
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p "$out/lib/${python.libPrefix}/site-packages"
|
||||
|
||||
export PYTHONPATH="$out/lib/${python.libPrefix}/site-packages:$PYTHONPATH"
|
||||
|
||||
${python}/bin/${python.executable} setup.py install \
|
||||
--install-lib=$out/lib/${python.libPrefix}/site-packages \
|
||||
--prefix="$out" ${lib.concatStringsSep " " setupPyInstallFlags}
|
||||
|
||||
eapth="$out/lib/${python.libPrefix}"/site-packages/easy-install.pth
|
||||
if [ -e "$eapth" ]; then
|
||||
# move colliding easy_install.pth to specifically named one
|
||||
mv "$eapth" $(dirname "$eapth")/${name}.pth
|
||||
fi
|
||||
|
||||
rm -f "$out/lib/${python.libPrefix}"/site-packages/site.py*
|
||||
|
||||
runHook postInstall
|
||||
sed -i '/zim_install_class,/d' setup.py
|
||||
'';
|
||||
|
||||
# FIXME: this is quick and dirty hack, because zim expects the
|
||||
# path to the executable in argv[0] therefore the wrapper is
|
||||
# modified accordingly.
|
||||
postFixup = ''
|
||||
wrapProgram "$out/bin/zim" \
|
||||
--prefix XDG_DATA_DIRS : "$out/share"
|
||||
|
||||
wrapPythonPrograms
|
||||
|
||||
sed -i "s#sys\.argv\[0\] = '.zim-wrapped'#sys.argv[0] = '$out/bin/zim'#g" \
|
||||
$out/bin/..zim-wrapped-wrapped
|
||||
|
||||
if test -e $out/nix-support/propagated-build-inputs; then
|
||||
ln -s $out/nix-support/propagated-build-inputs $out/nix-support/propagated-user-env-packages
|
||||
fi
|
||||
|
||||
createBuildInputsPth build-inputs "$buildInputStrings"
|
||||
for inputsfile in propagated-build-inputs propagated-native-build-inputs; do
|
||||
if test -e $out/nix-support/$inputsfile; then
|
||||
createBuildInputsPth $inputsfile "$(cat $out/nix-support/$inputsfile)"
|
||||
fi
|
||||
done
|
||||
preFixup = ''
|
||||
export makeWrapperArgs="--prefix XDG_DATA_DIRS : $out/share --argv0 $out/bin/.zim-wrapped"
|
||||
'';
|
||||
|
||||
# Testing fails.
|
||||
doCheck = false;
|
||||
|
||||
|
@ -9,26 +9,21 @@
|
||||
|
||||
buildPythonPackage rec {
|
||||
name = "spyder-${version}";
|
||||
version = "2.3.6";
|
||||
version = "2.3.7";
|
||||
namePrefix = "";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://pypi.python.org/packages/source/s/spyder/${name}.zip";
|
||||
sha256 = "0e6502e0d3f270ea8916d1a3d7ca29915801d31932db399582bc468c01d535e2";
|
||||
sha256 = "0ywgvgcp9s64ys25nfscd2648f7di8544a21b5lb59d4f48z028h";
|
||||
};
|
||||
|
||||
buildInputs = [ unzip ];
|
||||
# NOTE: sphinx makes the build fail with: ValueError: ZIP does not support timestamps before 1980
|
||||
propagatedBuildInputs =
|
||||
[ pyside pyflakes rope sphinx numpy scipy matplotlib ipython pylint pep8 ];
|
||||
[ pyside pyflakes rope numpy scipy matplotlib ipython pylint pep8 ];
|
||||
|
||||
# There is no test for spyder
|
||||
doCheck = false;
|
||||
|
||||
# Use setuptools instead of distutils.
|
||||
preConfigure = ''
|
||||
export USE_SETUPTOOLS=True
|
||||
'';
|
||||
|
||||
desktopItem = makeDesktopItem {
|
||||
name = "Spyder";
|
||||
exec = "spyder";
|
||||
@ -41,11 +36,9 @@ buildPythonPackage rec {
|
||||
|
||||
# Create desktop item
|
||||
postInstall = ''
|
||||
mkdir -p $out/share/applications
|
||||
cp $desktopItem/share/applications/* $out/share/applications/
|
||||
|
||||
mkdir -p $out/share/icons
|
||||
cp spyderlib/images/spyder.svg $out/share/icons/
|
||||
mkdir -p $out/share/{applications,icons}
|
||||
cp $desktopItem/share/applications/* $out/share/applications/
|
||||
cp spyderlib/images/spyder.svg $out/share/icons/
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
@ -14,11 +14,10 @@ in buildPythonPackage rec {
|
||||
|
||||
buildInputs = [ ffmpeg ];
|
||||
|
||||
pythonPath = [ pygtk dbus ffmpeg mplayer dvdauthor vcdimager cdrkit ];
|
||||
propagatedBuildInputs = [ pygtk dbus ffmpeg mplayer dvdauthor vcdimager cdrkit ];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace devede --replace "/usr/share/devede" "$out/share/devede"
|
||||
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
@ -26,5 +25,6 @@ in buildPythonPackage rec {
|
||||
homepage = http://www.rastersoft.com/programas/devede.html;
|
||||
license = licenses.gpl3;
|
||||
maintainers = [ maintainers.bdimcheff ];
|
||||
broken = true; # tarball is gone
|
||||
};
|
||||
}
|
||||
|
@ -18,40 +18,26 @@ buildPythonPackage rec {
|
||||
};
|
||||
|
||||
propagatedBuildInputs =
|
||||
[ eventlet greenlet gflags netaddr sqlalchemy carrot routes
|
||||
PasteDeploy m2crypto ipy twisted sqlalchemy_migrate
|
||||
[ eventlet greenlet gflags netaddr carrot routes
|
||||
PasteDeploy m2crypto ipy twisted sqlalchemy_migrate_0_7
|
||||
distutils_extra simplejson readline glance cheetah lockfile httplib2
|
||||
urlgrabber virtinst pyGtkGlade pythonDBus gnome_python pygobject3
|
||||
libvirt libxml2Python ipaddr vte libosinfo
|
||||
libvirt libxml2Python ipaddr vte libosinfo gobjectIntrospection gtk3 mox
|
||||
gtkvnc libvirt-glib glib gsettings_desktop_schemas gnome3.defaultIconTheme
|
||||
wrapGAppsHook
|
||||
] ++ optional spiceSupport spice_gtk;
|
||||
|
||||
buildInputs =
|
||||
[ mox
|
||||
intltool
|
||||
gtkvnc
|
||||
gtk3
|
||||
libvirt-glib
|
||||
avahi
|
||||
glib
|
||||
gobjectIntrospection
|
||||
gsettings_desktop_schemas
|
||||
gnome3.defaultIconTheme
|
||||
wrapGAppsHook
|
||||
dconf
|
||||
];
|
||||
buildInputs = [ dconf avahi intltool ];
|
||||
|
||||
patchPhase = ''
|
||||
sed -i 's|/usr/share/libvirt/cpu_map.xml|${system-libvirt}/share/libvirt/cpu_map.xml|g' virtinst/capabilities.py
|
||||
sed -i "/'install_egg_info'/d" setup.py
|
||||
'';
|
||||
|
||||
configurePhase = ''
|
||||
sed -i 's/from distutils.core/from setuptools/g' setup.py
|
||||
sed -i 's/from distutils.command.install/from setuptools.command.install/g' setup.py
|
||||
python setup.py configure --prefix=$out
|
||||
postConfigure = ''
|
||||
${python.interpreter} setup.py configure --prefix=$out
|
||||
'';
|
||||
|
||||
buildPhase = "true";
|
||||
|
||||
postInstall = ''
|
||||
${glib}/bin/glib-compile-schemas "$out"/share/glib-2.0/schemas
|
||||
'';
|
||||
|
@ -6,7 +6,7 @@ assert zlibSupport -> zlib != null;
|
||||
|
||||
let
|
||||
|
||||
majorVersion = "2.6";
|
||||
majorVersion = "4.0";
|
||||
version = "${majorVersion}.0";
|
||||
libPrefix = "pypy${majorVersion}";
|
||||
|
||||
@ -18,7 +18,7 @@ let
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://bitbucket.org/pypy/pypy/get/release-${version}.tar.bz2";
|
||||
sha256 = "0xympj874cnjpxj68xm5gllq2f8bbvz8hr0md8mh1yd6fgzzxibh";
|
||||
sha256 = "008a7mxyw95asiz678v09p345v7pfchq6aa3x96fn7lkzhir67z7";
|
||||
};
|
||||
|
||||
buildInputs = [ bzip2 openssl pkgconfig pythonFull libffi ncurses expat sqlite tk tcl xlibsWrapper libX11 makeWrapper ]
|
||||
@ -119,7 +119,7 @@ let
|
||||
isPypy = true;
|
||||
buildEnv = callPackage ../python/wrapper.nix { python = self; };
|
||||
interpreter = "${self}/bin/${executable}";
|
||||
sitePackages = "lib/${libPrefix}/site-packages";
|
||||
sitePackages = "site-packages";
|
||||
};
|
||||
|
||||
enableParallelBuilding = true; # almost no parallelization without STM
|
||||
|
@ -1,12 +1,12 @@
|
||||
addPythonPath() {
|
||||
addToSearchPathWithCustomDelimiter : PYTHONPATH $1/lib/pypy2.6/site-packages
|
||||
addToSearchPathWithCustomDelimiter : PYTHONPATH $1/site-packages
|
||||
}
|
||||
|
||||
toPythonPath() {
|
||||
local paths="$1"
|
||||
local result=
|
||||
for i in $paths; do
|
||||
p="$i/lib/pypy2.6/site-packages"
|
||||
p="$i/site-packages"
|
||||
result="${result}${result:+:}$p"
|
||||
done
|
||||
echo $result
|
||||
|
51
pkgs/development/python-modules/bootstrapped-pip/default.nix
Normal file
51
pkgs/development/python-modules/bootstrapped-pip/default.nix
Normal file
@ -0,0 +1,51 @@
|
||||
{ stdenv, python, fetchurl, makeWrapper, unzip }:
|
||||
|
||||
let
|
||||
wheel_source = fetchurl {
|
||||
url = "https://pypi.python.org/packages/py2.py3/w/wheel/wheel-0.26.0-py2.py3-none-any.whl";
|
||||
sha256 = "1sl642ncvipqx0hzypvl5hsiqngy0sib0kq242g4mic7vnid6bn9";
|
||||
};
|
||||
setuptools_source = fetchurl {
|
||||
url = "https://pypi.python.org/packages/3.4/s/setuptools/setuptools-18.2-py2.py3-none-any.whl";
|
||||
sha256 = "0jhafl8wmjc8xigl1ib5hqiq9crmipcz0zcga52riymgqbf2bzh4";
|
||||
};
|
||||
in stdenv.mkDerivation rec {
|
||||
name = "python-${python.version}-bootstrapped-pip-${version}";
|
||||
version = "7.1.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://pypi.python.org/packages/py2.py3/p/pip/pip-${version}-py2.py3-none-any.whl";
|
||||
sha256 = "133hx6jaspm6hd02gza66lng37l65yficc2y2x1gh16fbhxrilxr";
|
||||
};
|
||||
|
||||
unpackPhase = ''
|
||||
mkdir -p $out/${python.sitePackages}
|
||||
unzip -d $out/${python.sitePackages} $src
|
||||
unzip -d $out/${python.sitePackages} ${setuptools_source}
|
||||
unzip -d $out/${python.sitePackages} ${wheel_source}
|
||||
'';
|
||||
|
||||
patchPhase = ''
|
||||
mkdir -p $out/bin
|
||||
|
||||
# patch pip to support "pip install --prefix"
|
||||
# https://github.com/pypa/pip/pull/3252
|
||||
pushd $out/${python.sitePackages}/
|
||||
patch -p1 < ${./pip-7.0.1-prefix.patch}
|
||||
popd
|
||||
'';
|
||||
|
||||
buildInputs = [ python makeWrapper unzip ];
|
||||
|
||||
installPhase = ''
|
||||
|
||||
# install pip binary
|
||||
echo '${python.interpreter} -m pip "$@"' > $out/bin/pip
|
||||
chmod +x $out/bin/pip
|
||||
|
||||
# wrap binaries with PYTHONPATH
|
||||
for f in $out/bin/*; do
|
||||
wrapProgram $f --prefix PYTHONPATH ":" $out/${python.sitePackages}/
|
||||
done
|
||||
'';
|
||||
}
|
@ -0,0 +1,151 @@
|
||||
commit e87c83d95bb91acdca92202e94488ca51a70e059
|
||||
Author: Domen Kožar <domen@dev.si>
|
||||
Date: Mon Nov 16 17:39:44 2015 +0100
|
||||
|
||||
WIP
|
||||
|
||||
diff --git a/pip/commands/install.py b/pip/commands/install.py
|
||||
index dbcf100..05d5a08 100644
|
||||
--- a/pip/commands/install.py
|
||||
+++ b/pip/commands/install.py
|
||||
@@ -139,6 +139,13 @@ class InstallCommand(RequirementCommand):
|
||||
"directory.")
|
||||
|
||||
cmd_opts.add_option(
|
||||
+ '--prefix',
|
||||
+ dest='prefix_path',
|
||||
+ metavar='dir',
|
||||
+ default=None,
|
||||
+ help="Installation prefix where lib, bin and other top-level folders are placed")
|
||||
+
|
||||
+ cmd_opts.add_option(
|
||||
"--compile",
|
||||
action="store_true",
|
||||
dest="compile",
|
||||
@@ -309,6 +316,7 @@ class InstallCommand(RequirementCommand):
|
||||
install_options,
|
||||
global_options,
|
||||
root=options.root_path,
|
||||
+ prefix=options.prefix_path,
|
||||
)
|
||||
reqs = sorted(
|
||||
requirement_set.successfully_installed,
|
||||
diff --git a/pip/locations.py b/pip/locations.py
|
||||
index 4e6f65d..43aeb1f 100644
|
||||
--- a/pip/locations.py
|
||||
+++ b/pip/locations.py
|
||||
@@ -163,7 +163,7 @@ site_config_files = [
|
||||
|
||||
|
||||
def distutils_scheme(dist_name, user=False, home=None, root=None,
|
||||
- isolated=False):
|
||||
+ isolated=False, prefix=None):
|
||||
"""
|
||||
Return a distutils install scheme
|
||||
"""
|
||||
@@ -187,6 +187,8 @@ def distutils_scheme(dist_name, user=False, home=None, root=None,
|
||||
i.user = user or i.user
|
||||
if user:
|
||||
i.prefix = ""
|
||||
+ else:
|
||||
+ i.prefix = prefix or i.prefix
|
||||
i.home = home or i.home
|
||||
i.root = root or i.root
|
||||
i.finalize_options()
|
||||
diff --git a/pip/req/req_install.py b/pip/req/req_install.py
|
||||
index 7c5bf8f..6f80a18 100644
|
||||
--- a/pip/req/req_install.py
|
||||
+++ b/pip/req/req_install.py
|
||||
@@ -792,7 +792,7 @@ exec(compile(
|
||||
else:
|
||||
return True
|
||||
|
||||
- def install(self, install_options, global_options=[], root=None):
|
||||
+ def install(self, install_options, global_options=[], root=None, prefix=None):
|
||||
if self.editable:
|
||||
self.install_editable(install_options, global_options)
|
||||
return
|
||||
@@ -800,7 +800,7 @@ exec(compile(
|
||||
version = pip.wheel.wheel_version(self.source_dir)
|
||||
pip.wheel.check_compatibility(version, self.name)
|
||||
|
||||
- self.move_wheel_files(self.source_dir, root=root)
|
||||
+ self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
|
||||
self.install_succeeded = True
|
||||
return
|
||||
|
||||
@@ -833,6 +833,8 @@ exec(compile(
|
||||
|
||||
if root is not None:
|
||||
install_args += ['--root', root]
|
||||
+ if prefix is not None:
|
||||
+ install_args += ['--prefix', prefix]
|
||||
|
||||
if self.pycompile:
|
||||
install_args += ["--compile"]
|
||||
@@ -988,12 +990,13 @@ exec(compile(
|
||||
def is_wheel(self):
|
||||
return self.link and self.link.is_wheel
|
||||
|
||||
- def move_wheel_files(self, wheeldir, root=None):
|
||||
+ def move_wheel_files(self, wheeldir, root=None, prefix=None):
|
||||
move_wheel_files(
|
||||
self.name, self.req, wheeldir,
|
||||
user=self.use_user_site,
|
||||
home=self.target_dir,
|
||||
root=root,
|
||||
+ prefix=prefix,
|
||||
pycompile=self.pycompile,
|
||||
isolated=self.isolated,
|
||||
)
|
||||
diff --git a/pip/wheel.py b/pip/wheel.py
|
||||
index 403f48b..14eb141 100644
|
||||
--- a/pip/wheel.py
|
||||
+++ b/pip/wheel.py
|
||||
@@ -234,12 +234,12 @@ def get_entrypoints(filename):
|
||||
|
||||
|
||||
def move_wheel_files(name, req, wheeldir, user=False, home=None, root=None,
|
||||
- pycompile=True, scheme=None, isolated=False):
|
||||
+ pycompile=True, scheme=None, isolated=False, prefix=None):
|
||||
"""Install a wheel"""
|
||||
|
||||
if not scheme:
|
||||
scheme = distutils_scheme(
|
||||
- name, user=user, home=home, root=root, isolated=isolated
|
||||
+ name, user=user, home=home, root=root, isolated=isolated, prefix=prefix,
|
||||
)
|
||||
|
||||
if root_is_purelib(name, wheeldir):
|
||||
diff --git a/pip/req/req_install.py b/pip/req/req_install.py
|
||||
index 51bf4a7..e2e285e 100644
|
||||
--- a/pip/req/req_install.py
|
||||
+++ b/pip/req/req_install.py
|
||||
@@ -795,7 +795,7 @@ exec(compile(
|
||||
def install(self, install_options, global_options=[], root=None,
|
||||
prefix=None):
|
||||
if self.editable:
|
||||
- self.install_editable(install_options, global_options)
|
||||
+ self.install_editable(install_options, global_options, prefix=prefix)
|
||||
return
|
||||
if self.is_wheel:
|
||||
version = pip.wheel.wheel_version(self.source_dir)
|
||||
@@ -929,12 +929,16 @@ exec(compile(
|
||||
rmtree(self._temp_build_dir)
|
||||
self._temp_build_dir = None
|
||||
|
||||
- def install_editable(self, install_options, global_options=()):
|
||||
+ def install_editable(self, install_options, global_options=(), prefix=None):
|
||||
logger.info('Running setup.py develop for %s', self.name)
|
||||
|
||||
if self.isolated:
|
||||
global_options = list(global_options) + ["--no-user-cfg"]
|
||||
|
||||
+ if prefix:
|
||||
+ prefix_param = ['--prefix={0}'.format(prefix)]
|
||||
+ install_options = list(install_options) + prefix_param
|
||||
+
|
||||
with indent_log():
|
||||
# FIXME: should we do --install-headers here too?
|
||||
cwd = self.source_dir
|
||||
|
30
pkgs/development/python-modules/generic/catch_conflicts.py
Normal file
30
pkgs/development/python-modules/generic/catch_conflicts.py
Normal file
@ -0,0 +1,30 @@
|
||||
import pkg_resources
|
||||
import collections
|
||||
import sys
|
||||
|
||||
do_abort = False
|
||||
packages = collections.defaultdict(list)
|
||||
|
||||
for f in sys.path:
|
||||
for req in pkg_resources.find_distributions(f):
|
||||
if req not in packages[req.project_name]:
|
||||
# some exceptions inside buildPythonPackage
|
||||
if req.project_name in ['setuptools', 'pip']:
|
||||
continue
|
||||
packages[req.project_name].append(req)
|
||||
|
||||
|
||||
for name, duplicates in packages.items():
|
||||
if len(duplicates) > 1:
|
||||
do_abort = True
|
||||
print("Found duplicated packages in closure for dependency '{}': ".format(name))
|
||||
for dup in duplicates:
|
||||
print(" " + repr(dup))
|
||||
|
||||
if do_abort:
|
||||
print("")
|
||||
print(
|
||||
'Package duplicates found in closure, see above. Usually this '
|
||||
'happens if two packages depend on different version '
|
||||
'of the same dependency.')
|
||||
sys.exit(1)
|
@ -3,7 +3,7 @@
|
||||
(http://pypi.python.org/pypi/setuptools/), which represents a large
|
||||
number of Python packages nowadays. */
|
||||
|
||||
{ python, setuptools, unzip, wrapPython, lib, recursivePthLoader, distutils-cfg }:
|
||||
{ python, setuptools, unzip, wrapPython, lib, bootstrapped-pip }:
|
||||
|
||||
{ name
|
||||
|
||||
@ -12,28 +12,18 @@
|
||||
|
||||
, buildInputs ? []
|
||||
|
||||
# pass extra information to the distutils global configuration (think as global setup.cfg)
|
||||
, distutilsExtraCfg ? ""
|
||||
|
||||
# propagate build dependencies so in case we have A -> B -> C,
|
||||
# C can import propagated packages by A
|
||||
# C can import package A propagated by B
|
||||
, propagatedBuildInputs ? []
|
||||
|
||||
# passed to "python setup.py install"
|
||||
, setupPyInstallFlags ? []
|
||||
|
||||
# passed to "python setup.py build"
|
||||
# passed to "python setup.py build_ext"
|
||||
# https://github.com/pypa/pip/issues/881
|
||||
, setupPyBuildFlags ? []
|
||||
|
||||
# enable tests by default
|
||||
, doCheck ? true
|
||||
|
||||
# List of packages that should be added to the PYTHONPATH
|
||||
# environment variable in programs built by this function. Packages
|
||||
# in the standard `propagatedBuildInputs' variable are also added.
|
||||
# The difference is that `pythonPath' is not propagated to the user
|
||||
# environment. This is preferrable for programs because it doesn't
|
||||
# pollute the user environment.
|
||||
# DEPRECATED: use propagatedBuildInputs
|
||||
, pythonPath ? []
|
||||
|
||||
# used to disable derivation, useful for specific python versions
|
||||
@ -59,106 +49,71 @@ if disabled
|
||||
then throw "${name} not supported for interpreter ${python.executable}"
|
||||
else
|
||||
|
||||
python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled"] // {
|
||||
inherit doCheck;
|
||||
|
||||
let
|
||||
# use setuptools shim (so that setuptools is imported before distutils)
|
||||
# pip does the same thing: https://github.com/pypa/pip/pull/3265
|
||||
setuppy = ./run_setup.py;
|
||||
# For backwards compatibility, let's use an alias
|
||||
doInstallCheck = doCheck;
|
||||
in
|
||||
python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled" "doCheck"] // {
|
||||
name = namePrefix + name;
|
||||
|
||||
buildInputs = [
|
||||
wrapPython setuptools
|
||||
(distutils-cfg.override { extraCfg = distutilsExtraCfg; })
|
||||
] ++ buildInputs ++ pythonPath
|
||||
buildInputs = [ wrapPython bootstrapped-pip ] ++ buildInputs ++ pythonPath
|
||||
++ (lib.optional (lib.hasSuffix "zip" attrs.src.name or "") unzip);
|
||||
|
||||
# propagate python/setuptools to active setup-hook in nix-shell
|
||||
propagatedBuildInputs = propagatedBuildInputs ++ [ recursivePthLoader python setuptools ];
|
||||
|
||||
pythonPath = pythonPath;
|
||||
propagatedBuildInputs = propagatedBuildInputs ++ [ python setuptools ];
|
||||
|
||||
configurePhase = attrs.configurePhase or ''
|
||||
runHook preConfigure
|
||||
|
||||
# patch python interpreter to write null timestamps when compiling python files
|
||||
# with following var we tell python to activate the patch so that python doesn't
|
||||
# try to update them when we freeze timestamps in nix store
|
||||
# this way python doesn't try to update them when we freeze timestamps in nix store
|
||||
export DETERMINISTIC_BUILD=1
|
||||
|
||||
# prepend following line to import setuptools before distutils
|
||||
# this way we make sure setuptools monkeypatches distutils commands
|
||||
# this way setuptools provides extra helpers such as "python setup.py test"
|
||||
sed -i '0,/import distutils/s//import setuptools;import distutils/' setup.py
|
||||
sed -i '0,/from distutils/s//import setuptools;from distutils/' setup.py
|
||||
|
||||
runHook postConfigure
|
||||
'';
|
||||
|
||||
checkPhase = attrs.checkPhase or ''
|
||||
runHook preCheck
|
||||
|
||||
${python}/bin/${python.executable} setup.py test
|
||||
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
# we copy nix_run_setup.py over so it's executed relative to the root of the source
|
||||
# many project make that assumption
|
||||
buildPhase = attrs.buildPhase or ''
|
||||
runHook preBuild
|
||||
|
||||
${python}/bin/${python.executable} setup.py build ${lib.concatStringsSep " " setupPyBuildFlags}
|
||||
|
||||
cp ${setuppy} nix_run_setup.py
|
||||
${python.interpreter} nix_run_setup.py ${lib.optionalString (setupPyBuildFlags != []) ("build_ext " + (lib.concatStringsSep " " setupPyBuildFlags))} bdist_wheel
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
installPhase = attrs.installPhase or ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p "$out/lib/${python.libPrefix}/site-packages"
|
||||
mkdir -p "$out/${python.sitePackages}"
|
||||
export PYTHONPATH="$out/${python.sitePackages}:$PYTHONPATH"
|
||||
|
||||
export PYTHONPATH="$out/lib/${python.libPrefix}/site-packages:$PYTHONPATH"
|
||||
|
||||
${python}/bin/${python.executable} setup.py install \
|
||||
--install-lib=$out/lib/${python.libPrefix}/site-packages \
|
||||
--old-and-unmanageable \
|
||||
--prefix="$out" ${lib.concatStringsSep " " setupPyInstallFlags}
|
||||
|
||||
# --install-lib:
|
||||
# sometimes packages specify where files should be installed outside the usual
|
||||
# python lib prefix, we override that back so all infrastructure (setup hooks)
|
||||
# work as expected
|
||||
|
||||
# --old-and-unmanagable:
|
||||
# instruct setuptools not to use eggs but fallback to plan package install
|
||||
# this also reduces one .pth file in the chain, but the main reason is to
|
||||
# force install process to install only scripts for the package we are
|
||||
# installing (otherwise it will install scripts also for dependencies)
|
||||
|
||||
# A pth file might have been generated to load the package from
|
||||
# within its own site-packages, rename this package not to
|
||||
# collide with others.
|
||||
eapth="$out/lib/${python.libPrefix}"/site-packages/easy-install.pth
|
||||
if [ -e "$eapth" ]; then
|
||||
# move colliding easy_install.pth to specifically named one
|
||||
mv "$eapth" $(dirname "$eapth")/${name}.pth
|
||||
fi
|
||||
|
||||
# Remove any site.py files generated by easy_install as these
|
||||
# cause collisions. If pth files are to be processed a
|
||||
# corresponding site.py needs to be included in the PYTHONPATH.
|
||||
rm -f "$out/lib/${python.libPrefix}"/site-packages/site.py*
|
||||
pushd dist
|
||||
${bootstrapped-pip}/bin/pip install *.whl --no-index --prefix=$out --no-cache
|
||||
popd
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
postFixup = attrs.postFixup or ''
|
||||
wrapPythonPrograms
|
||||
# We run all tests after software has been installed since that is
|
||||
# a common idiom in Python
|
||||
doInstallCheck = doInstallCheck;
|
||||
|
||||
# TODO: document
|
||||
createBuildInputsPth build-inputs "$buildInputStrings"
|
||||
for inputsfile in propagated-build-inputs propagated-native-build-inputs; do
|
||||
if test -e $out/nix-support/$inputsfile; then
|
||||
createBuildInputsPth $inputsfile "$(cat $out/nix-support/$inputsfile)"
|
||||
fi
|
||||
done
|
||||
'';
|
||||
installCheckPhase = attrs.checkPhase or ''
|
||||
runHook preCheck
|
||||
${python.interpreter} nix_run_setup.py test
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
postFixup = attrs.postFixup or ''
|
||||
wrapPythonPrograms
|
||||
|
||||
# check if we have two packagegs with the same name in closure and fail
|
||||
# this shouldn't happen, something went wrong with dependencies specs
|
||||
${python.interpreter} ${./catch_conflicts.py}
|
||||
'';
|
||||
|
||||
shellHook = attrs.shellHook or ''
|
||||
${preShellHook}
|
||||
@ -166,7 +121,8 @@ python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled"] // {
|
||||
tmp_path=$(mktemp -d)
|
||||
export PATH="$tmp_path/bin:$PATH"
|
||||
export PYTHONPATH="$tmp_path/${python.sitePackages}:$PYTHONPATH"
|
||||
${python.interpreter} setup.py develop --prefix $tmp_path
|
||||
mkdir -p $tmp_path/${python.sitePackages}
|
||||
${bootstrapped-pip}/bin/pip install -e . --prefix $tmp_path
|
||||
fi
|
||||
${postShellHook}
|
||||
'';
|
||||
@ -177,6 +133,7 @@ python.stdenv.mkDerivation (builtins.removeAttrs attrs ["disabled"] // {
|
||||
} // meta // {
|
||||
# add extra maintainer(s) to every package
|
||||
maintainers = (meta.maintainers or []) ++ [ chaoflow iElectric ];
|
||||
# a marker for release utilies to discover python packages
|
||||
isBuildPythonPackage = python.meta.platforms;
|
||||
};
|
||||
|
||||
})
|
||||
|
6
pkgs/development/python-modules/generic/run_setup.py
Normal file
6
pkgs/development/python-modules/generic/run_setup.py
Normal file
@ -0,0 +1,6 @@
|
||||
import setuptools
|
||||
import tokenize
|
||||
|
||||
__file__='setup.py';
|
||||
|
||||
exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\\r\\n', '\\n'), __file__, 'exec'))
|
@ -46,7 +46,7 @@ wrapPythonProgramsIn() {
|
||||
# (see pkgs/build-support/setup-hooks/make-wrapper.sh)
|
||||
local wrap_args="$f \
|
||||
--prefix PYTHONPATH ':' $program_PYTHONPATH \
|
||||
--prefix PATH ':' $program_PATH"
|
||||
--prefix PATH ':' $program_PATH:$dir/bin"
|
||||
|
||||
# Add any additional arguments provided by makeWrapperArgs
|
||||
# argument to buildPythonPackage.
|
||||
|
@ -35,6 +35,8 @@ buildPythonPackage rec {
|
||||
sed -i 's/test_use_url/fails/' lib/matplotlib/tests/test_style.py
|
||||
# Failing test: ERROR: test suite for <class 'matplotlib.sphinxext.tests.test_tinypages.TestTinyPages'>
|
||||
sed -i 's/TestTinyPages/fails/' lib/matplotlib/sphinxext/tests/test_tinypages.py
|
||||
# Transient errors
|
||||
sed -i 's/test_invisible_Line_rendering/noop/' lib/matplotlib/tests/test_lines.py
|
||||
'';
|
||||
|
||||
|
||||
|
@ -8,9 +8,11 @@ buildPythonPackage rec {
|
||||
sha256 = "6a0b7b1fe2b046875456e14eda3e42430e493bf2251a64481cf4fd1a1e21a80e";
|
||||
};
|
||||
|
||||
buildInputs = [ pythonPackages.nose pythonPackages.minimock ];
|
||||
buildInputs = with pythonPackages; [ nose minimock ];
|
||||
|
||||
checkPhase = "make test";
|
||||
checkPhase = ''
|
||||
nosetests
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "A gpodder.net client library";
|
||||
|
@ -16,30 +16,9 @@
|
||||
# .test() function, which will run the test suite.
|
||||
checkPhase = ''
|
||||
runHook preCheck
|
||||
|
||||
_python=${python}/bin/${python.executable}
|
||||
|
||||
# We will "install" into a temp directory, so that we can run the
|
||||
# tests (see below).
|
||||
install_dir="$TMPDIR/test_install"
|
||||
install_lib="$install_dir/lib/${python.libPrefix}/site-packages"
|
||||
mkdir -p $install_dir
|
||||
$_python setup.py install \
|
||||
--install-lib=$install_lib \
|
||||
--old-and-unmanageable \
|
||||
--prefix=$install_dir > /dev/null
|
||||
|
||||
# Create a directory in which to run tests (you get an error if you try to
|
||||
# import the package when you're in the current directory).
|
||||
mkdir $TMPDIR/run_tests
|
||||
pushd $TMPDIR/run_tests > /dev/null
|
||||
# Temporarily add the directory we installed in to the python path
|
||||
# (not permanently, or this pythonpath will wind up getting exported),
|
||||
# and run the test suite.
|
||||
PYTHONPATH="$install_lib:$PYTHONPATH" $_python -c \
|
||||
'import ${pkgName}; ${pkgName}.test("fast", verbose=10)'
|
||||
popd > /dev/null
|
||||
|
||||
pushd dist
|
||||
${python.interpreter} -c 'import ${pkgName}; ${pkgName}.test("fast", verbose=10)'
|
||||
popd
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, python, wrapPython, distutils-cfg }:
|
||||
{ stdenv, fetchurl, python, wrapPython }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
shortName = "setuptools-${version}";
|
||||
@ -11,23 +11,14 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "07avbdc26yl2a46s76fc7m4vg611g8sh39l26x9dr9byya6sb509";
|
||||
};
|
||||
|
||||
buildInputs = [ python wrapPython distutils-cfg ];
|
||||
|
||||
buildPhase = "${python}/bin/${python.executable} setup.py build";
|
||||
|
||||
installPhase =
|
||||
''
|
||||
dst=$out/lib/${python.libPrefix}/site-packages
|
||||
buildInputs = [ python wrapPython ];
|
||||
doCheck = false; # requires pytest
|
||||
installPhase = ''
|
||||
dst=$out/${python.sitePackages}
|
||||
mkdir -p $dst
|
||||
export PYTHONPATH="$dst:$PYTHONPATH"
|
||||
${python}/bin/${python.executable} setup.py install --prefix=$out --install-lib=$out/lib/${python.libPrefix}/site-packages
|
||||
${python.interpreter} setup.py install --prefix=$out
|
||||
wrapPythonPrograms
|
||||
'';
|
||||
|
||||
doCheck = false; # requires pytest
|
||||
|
||||
checkPhase = ''
|
||||
${python}/bin/${python.executable} setup.py test
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
@ -31,19 +31,6 @@ index 416df5a..f07c9ec 100644
|
||||
|
||||
.. changelog::
|
||||
:version: 0.7.10
|
||||
diff --git a/lib/sqlalchemy/__init__.py b/lib/sqlalchemy/__init__.py
|
||||
index 9a21a70..6523ccb 100644
|
||||
--- a/lib/sqlalchemy/__init__.py
|
||||
+++ b/lib/sqlalchemy/__init__.py
|
||||
@@ -120,7 +120,7 @@
|
||||
__all__ = sorted(name for name, obj in locals().items()
|
||||
if not (name.startswith('_') or inspect.ismodule(obj)))
|
||||
|
||||
-__version__ = '0.7.10'
|
||||
+__version__ = '0.7.11'
|
||||
|
||||
del inspect, sys
|
||||
|
||||
diff --git a/test/engine/test_execute.py b/test/engine/test_execute.py
|
||||
index 69b94f1..a37f684 100644
|
||||
--- a/test/engine/test_execute.py
|
||||
|
@ -20,7 +20,6 @@ buildPythonPackage rec {
|
||||
"--lzo=${lzo}"
|
||||
"--bzip2=${bzip2}"
|
||||
];
|
||||
setupPyInstallFlags = setupPyBuildFlags;
|
||||
|
||||
# Run the test suite.
|
||||
# It requires the build path to be in the python search path.
|
||||
|
@ -1,9 +1,6 @@
|
||||
{ callPackage, ... } @ args:
|
||||
|
||||
callPackage ./generic.nix (args // rec {
|
||||
|
||||
version = "2.8.12.1";
|
||||
|
||||
sha256 = "1l1w4i113csv3bd5r8ybyj0qpxdq83lj6jrc5p7cc10mkwyiagqz";
|
||||
|
||||
})
|
||||
|
@ -1,31 +1,28 @@
|
||||
{ stdenv, fetchurl, pkgconfig, python, buildPythonPackage, isPy3k, isPyPy, wxGTK, openglSupport ? true, pyopengl
|
||||
, version, sha256, ...
|
||||
{ stdenv, fetchurl, pkgconfig, python, isPy3k, isPyPy, wxGTK, openglSupport ? true, pyopengl
|
||||
, version, sha256, wrapPython, setuptools, ...
|
||||
}:
|
||||
|
||||
assert wxGTK.unicode;
|
||||
|
||||
buildPythonPackage rec {
|
||||
stdenv.mkDerivation rec {
|
||||
name = "wxPython-${version}";
|
||||
inherit version;
|
||||
|
||||
disabled = isPy3k || isPyPy;
|
||||
doCheck = false;
|
||||
|
||||
name = "wxPython-${version}";
|
||||
inherit version;
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/wxpython/wxPython-src-${version}.tar.bz2";
|
||||
inherit sha256;
|
||||
};
|
||||
|
||||
buildInputs = [ pkgconfig wxGTK (wxGTK.gtk) ]
|
||||
++ stdenv.lib.optional openglSupport pyopengl;
|
||||
|
||||
pythonPath = [ python setuptools ];
|
||||
buildInputs = [ python setuptools pkgconfig wxGTK (wxGTK.gtk) wrapPython ] ++ stdenv.lib.optional openglSupport pyopengl;
|
||||
preConfigure = "cd wxPython";
|
||||
|
||||
setupPyBuildFlags = [ "WXPORT=gtk2" "NO_HEADERS=1" "BUILD_GLCANVAS=${if openglSupport then "1" else "0"}" "UNICODE=1" ];
|
||||
|
||||
installPhase = ''
|
||||
${python}/bin/${python.executable} setup.py ${stdenv.lib.concatStringsSep " " setupPyBuildFlags} install --prefix=$out
|
||||
${python.interpreter} setup.py install WXPORT=gtk2 NO_HEADERS=1 BUILD_GLCANVAS=${if openglSupport then "1" else "0"} UNICODE=1 --prefix=$out
|
||||
wrapPythonPrograms
|
||||
'';
|
||||
|
||||
passthru = { inherit wxGTK openglSupport; };
|
||||
|
@ -1,5 +1,5 @@
|
||||
{ stdenv, buildPythonPackage, fetchurl, twisted, dateutil, jinja2
|
||||
, sqlalchemy , sqlalchemy_migrate
|
||||
, sqlalchemy , sqlalchemy_migrate_0_7
|
||||
, enableDebugClient ? false, pygobject ? null, pyGtkGlade ? null
|
||||
}:
|
||||
|
||||
@ -9,12 +9,12 @@
|
||||
assert enableDebugClient -> pygobject != null && pyGtkGlade != null;
|
||||
|
||||
buildPythonPackage (rec {
|
||||
name = "buildbot-0.8.10";
|
||||
name = "buildbot-0.8.12";
|
||||
namePrefix = "";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://pypi.python.org/packages/source/b/buildbot/${name}.tar.gz";
|
||||
sha256 = "1x5513mjvd3mwwadawk6v3ca2wh5mcmgnn5h9jhq1jw1plp4v5n4";
|
||||
sha256 = "1mn4h04sp6smr3ahqfflys15cpn13q9mfkapcs2jc4ppvxv6kdn6";
|
||||
};
|
||||
|
||||
patchPhase =
|
||||
@ -25,12 +25,12 @@ buildPythonPackage (rec {
|
||||
sed -i "$i" \
|
||||
-e "s|/usr/bin/python|$(type -P python)|g ; s|/usr/bin/||g"
|
||||
done
|
||||
|
||||
sed -i 's/==/>=/' setup.py
|
||||
'';
|
||||
|
||||
buildInputs = [ ];
|
||||
|
||||
propagatedBuildInputs =
|
||||
[ twisted dateutil jinja2 sqlalchemy sqlalchemy_migrate
|
||||
[ twisted dateutil jinja2 sqlalchemy_migrate_0_7
|
||||
] ++ stdenv.lib.optional enableDebugClient [ pygobject pyGtkGlade ];
|
||||
|
||||
# What's up with this?! 'trial' should be 'test', no?
|
||||
@ -51,12 +51,9 @@ buildPythonPackage (rec {
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = http://buildbot.net/;
|
||||
|
||||
license = stdenv.lib.licenses.gpl2Plus;
|
||||
|
||||
# Of course, we don't really need that on NixOS. :-)
|
||||
description = "Continuous integration system that automates the build/test cycle";
|
||||
|
||||
longDescription =
|
||||
'' The BuildBot is a system to automate the compile/test cycle
|
||||
required by most software projects to validate code changes. By
|
||||
@ -79,7 +76,6 @@ buildPythonPackage (rec {
|
||||
encouraging them to be more careful about testing before checking
|
||||
in code.
|
||||
'';
|
||||
|
||||
maintainers = with maintainers; [ bjornfor ];
|
||||
platforms = platforms.all;
|
||||
};
|
||||
|
@ -1,26 +0,0 @@
|
||||
{ stdenv, fetchurl, pythonPackages, buildPythonPackage, git }:
|
||||
|
||||
let
|
||||
upstreamName = "jenkins-job-builder";
|
||||
version = "1.2.0";
|
||||
|
||||
in
|
||||
|
||||
buildPythonPackage rec {
|
||||
name = "${upstreamName}-${version}";
|
||||
namePrefix = ""; # Don't prepend "pythonX.Y-" to the name
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://pypi.python.org/packages/source/j/${upstreamName}/${name}.tar.gz";
|
||||
sha256 = "09nxdhb0ilxpmk5gbvik6kj9b6j718j5an903dpcvi3r6vzk9b3p";
|
||||
};
|
||||
|
||||
pythonPath = with pythonPackages; [ pip six pyyaml pbr python-jenkins ];
|
||||
doCheck = false; # Requires outdated Sphinx
|
||||
|
||||
meta = {
|
||||
description = "System for configuring Jenkins jobs using simple YAML files";
|
||||
homepage = http://ci.openstack.org/jjb.html;
|
||||
license = stdenv.lib.licenses.asl20;
|
||||
};
|
||||
}
|
@ -8,15 +8,14 @@ pythonPackages.buildPythonPackage rec {
|
||||
sha256 = "0d574mbmhaqmh7kivaryj2hpghz6xkvic9ah43s1hf385y7c33kd";
|
||||
};
|
||||
|
||||
buildPhase = ''
|
||||
patchPhase = ''
|
||||
rm -rf data/po/*
|
||||
python setup.py build
|
||||
'';
|
||||
|
||||
# no tests
|
||||
doCheck = false;
|
||||
|
||||
buildInputs = [pythonPackages.docutils];
|
||||
buildInputs = [ pythonPackages.docutils ];
|
||||
propagatedBuildInputs = [ xrandr pythonPackages.pygtk ];
|
||||
|
||||
meta = {
|
||||
|
@ -16,6 +16,7 @@ python3Packages.buildPythonPackage rec {
|
||||
|
||||
preConfigure = ''
|
||||
export ATTIC_OPENSSL_PREFIX="${openssl}"
|
||||
substituteInPlace setup.py --replace "version=versioneer.get_version()" "version='${version}'"
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
@ -12,19 +12,15 @@ buildPythonPackage rec {
|
||||
|
||||
doCheck = false;
|
||||
|
||||
propagatedBuildInputs = [
|
||||
pythonPackages.gdata
|
||||
pythonPackages.IMAPClient
|
||||
pythonPackages.Logbook
|
||||
pythonPackages.argparse
|
||||
];
|
||||
propagatedBuildInputs = with pythonPackages; [ gdata IMAPClient Logbook
|
||||
argparse ];
|
||||
|
||||
startScript = ./gmvault.py;
|
||||
|
||||
patchPhase = ''
|
||||
cat ${startScript} > etc/scripts/gmvault
|
||||
chmod +x etc/scripts/gmvault
|
||||
substituteInPlace setup.py --replace "Logbook==0.4.1" "Logbook==0.4.2"
|
||||
substituteInPlace setup.py --replace "==" ">="
|
||||
'';
|
||||
|
||||
meta = {
|
||||
|
@ -1,17 +1,14 @@
|
||||
{ fetchurl, lib, unzip, buildPythonPackage, twisted, foolscap, nevow
|
||||
, simplejson, zfec, pycryptopp, sqlite3, darcsver, setuptoolsTrial
|
||||
, setuptoolsDarcs, numpy, nettools, pycrypto, pyasn1, mock }:
|
||||
, simplejson, zfec, pycryptopp, sqlite3, darcsver, setuptoolsTrial, python
|
||||
, setuptoolsDarcs, numpy, nettools, pycrypto, pyasn1, mock, zope_interface }:
|
||||
|
||||
# FAILURES: The "running build_ext" phase fails to compile Twisted
|
||||
# plugins, because it tries to write them into Twisted's (immutable)
|
||||
# store path. The problem appears to be non-fatal, but there's probably
|
||||
# some loss of functionality because of it.
|
||||
|
||||
let
|
||||
buildPythonPackage rec {
|
||||
name = "tahoe-lafs-1.10.0";
|
||||
in
|
||||
buildPythonPackage {
|
||||
inherit name;
|
||||
namePrefix = "";
|
||||
|
||||
src = fetchurl {
|
||||
@ -19,7 +16,7 @@ buildPythonPackage {
|
||||
sha256 = "1qng7j1vykk8zl5da9yklkljvgxfnjky58gcay6dypz91xq1cmcw";
|
||||
};
|
||||
|
||||
configurePhase = ''
|
||||
patchPhase = ''
|
||||
sed -i "src/allmydata/util/iputil.py" \
|
||||
-es"|_linux_path = '/sbin/ifconfig'|_linux_path = '${nettools}/bin/ifconfig'|g"
|
||||
|
||||
@ -29,45 +26,43 @@ buildPythonPackage {
|
||||
do
|
||||
sed -i "$i" -e"s/localhost/127.0.0.1/g"
|
||||
done
|
||||
|
||||
sed -i 's/"zope.interface.*"/"zope.interface"/' src/allmydata/_auto_deps.py
|
||||
sed -i 's/"pycrypto.*"/"pycrypto"/' src/allmydata/_auto_deps.py
|
||||
'';
|
||||
|
||||
buildInputs = [ unzip ]
|
||||
++ [ numpy ]; # Some tests want this + http://tahoe-lafs.org/source/tahoe-lafs/deps/tahoe-dep-sdists/mock-0.6.0.tar.bz2
|
||||
# Some tests want this + http://tahoe-lafs.org/source/tahoe-lafs/deps/tahoe-dep-sdists/mock-0.6.0.tar.bz2
|
||||
buildInputs = [ unzip numpy mock ];
|
||||
|
||||
# The `backup' command requires `sqlite3'.
|
||||
propagatedBuildInputs =
|
||||
[ twisted foolscap nevow simplejson zfec pycryptopp sqlite3
|
||||
darcsver setuptoolsTrial setuptoolsDarcs pycrypto pyasn1 mock
|
||||
darcsver setuptoolsTrial setuptoolsDarcs pycrypto pyasn1 zope_interface
|
||||
];
|
||||
|
||||
# The test suite is run in `postInstall'.
|
||||
doCheck = false;
|
||||
|
||||
postInstall = ''
|
||||
# Install the documentation.
|
||||
mkdir -p "$out/share/doc/${name}"
|
||||
cp -rv "docs/"* "$out/share/doc/${name}"
|
||||
find "$out/share/doc/${name}" -name Makefile -exec rm -v {} \;
|
||||
'';
|
||||
|
||||
# Run the tests once everything is installed.
|
||||
export PYTHON_EGG_CACHE="$TMPDIR"
|
||||
python setup.py build
|
||||
python setup.py trial
|
||||
checkPhase = ''
|
||||
# TODO: broken with wheels
|
||||
#${python.interpreter} setup.py trial
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Tahoe-LAFS, a decentralized, fault-tolerant, distributed storage system";
|
||||
|
||||
longDescription = ''
|
||||
Tahoe-LAFS is a secure, decentralized, fault-tolerant filesystem.
|
||||
This filesystem is encrypted and spread over multiple peers in
|
||||
such a way that it remains available even when some of the peers
|
||||
are unavailable, malfunctioning, or malicious.
|
||||
'';
|
||||
|
||||
homepage = http://allmydata.org/;
|
||||
license = [ lib.licenses.gpl2Plus /* or */ "TGPPLv1+" ];
|
||||
maintainers = [ lib.maintainers.simons ];
|
||||
maintainers = [ lib.maintainers.simons ];
|
||||
platforms = lib.platforms.gnu; # arbitrary choice
|
||||
};
|
||||
}
|
||||
|
@ -3,7 +3,7 @@
|
||||
let version = "0.7.6";
|
||||
|
||||
in pythonPackages.buildPythonPackage rec {
|
||||
name = "cloud-init-0.7.6";
|
||||
name = "cloud-init-${version}";
|
||||
namePrefix = "";
|
||||
|
||||
src = fetchurl {
|
||||
@ -11,20 +11,19 @@ in pythonPackages.buildPythonPackage rec {
|
||||
sha256 = "1mry5zdkfaq952kn1i06wiggc66cqgfp6qgnlpk0mr7nnwpd53wy";
|
||||
};
|
||||
|
||||
preBuild = ''
|
||||
patchPhase = ''
|
||||
patchShebangs ./tools
|
||||
|
||||
substituteInPlace setup.py \
|
||||
--replace /usr $out \
|
||||
--replace /etc $out/etc \
|
||||
--replace /lib/systemd $out/lib/systemd \
|
||||
--replace 'self.init_system = ""' 'self.init_system = "systemd"'
|
||||
'';
|
||||
|
||||
pythonPath = with pythonPackages; [ cheetah jinja2 prettytable
|
||||
propagatedBuildInputs = with pythonPackages; [ cheetah jinja2 prettytable
|
||||
oauth pyserial configobj pyyaml argparse requests jsonpatch ];
|
||||
|
||||
setupPyInstallFlags = ["--init-system systemd"];
|
||||
|
||||
meta = {
|
||||
homepage = http://cloudinit.readthedocs.org;
|
||||
description = "provides configuration and customization of cloud instance";
|
||||
|
@ -5054,7 +5054,7 @@ let
|
||||
|
||||
mesos = callPackage ../applications/networking/cluster/mesos {
|
||||
sasl = cyrus_sasl;
|
||||
inherit (pythonPackages) python boto setuptools distutils-cfg wrapPython;
|
||||
inherit (pythonPackages) python boto setuptools wrapPython;
|
||||
pythonProtobuf = pythonPackages.protobuf2_5;
|
||||
perf = linuxPackages.perf;
|
||||
};
|
||||
@ -5419,7 +5419,7 @@ let
|
||||
};
|
||||
|
||||
buildbot = callPackage ../development/tools/build-managers/buildbot {
|
||||
inherit (pythonPackages) twisted jinja2 sqlalchemy sqlalchemy_migrate;
|
||||
inherit (pythonPackages) twisted jinja2 sqlalchemy sqlalchemy_migrate_0_7;
|
||||
dateutil = pythonPackages.dateutil_1_5;
|
||||
};
|
||||
|
||||
@ -5698,7 +5698,7 @@ let
|
||||
|
||||
jenkins = callPackage ../development/tools/continuous-integration/jenkins { };
|
||||
|
||||
jenkins-job-builder = callPackage ../development/tools/continuous-integration/jenkins-job-builder { };
|
||||
jenkins-job-builder = pythonPackages.jenkins-job-builder;
|
||||
|
||||
kcov = callPackage ../development/tools/analysis/kcov { };
|
||||
|
||||
@ -12109,9 +12109,7 @@ let
|
||||
|
||||
joe = callPackage ../applications/editors/joe { };
|
||||
|
||||
jbrout = callPackage ../applications/graphics/jbrout {
|
||||
inherit (pythonPackages) lxml;
|
||||
};
|
||||
jbrout = callPackage ../applications/graphics/jbrout { };
|
||||
|
||||
jumanji = callPackage ../applications/networking/browsers/jumanji {
|
||||
webkitgtk = webkitgtk24x;
|
||||
@ -13127,7 +13125,7 @@ let
|
||||
tahoelafs = callPackage ../tools/networking/p2p/tahoe-lafs {
|
||||
inherit (pythonPackages) twisted foolscap simplejson nevow zfec
|
||||
pycryptopp sqlite3 darcsver setuptoolsTrial setuptoolsDarcs
|
||||
numpy pyasn1 mock;
|
||||
numpy pyasn1 mock zope_interface;
|
||||
};
|
||||
|
||||
tailor = builderDefsPackage (callPackage ../applications/version-management/tailor) {};
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,70 +1,26 @@
|
||||
/*
|
||||
test for example like this
|
||||
$ nix-build pkgs/top-level/release-python.nix
|
||||
$ hydra-eval-jobs pkgs/top-level/release-python.nix
|
||||
*/
|
||||
|
||||
{ nixpkgs ? { outPath = (import ./all-packages.nix {}).lib.cleanSource ../..; revCount = 1234; shortRev = "abcdef"; }
|
||||
, officialRelease ? false
|
||||
, # The platforms for which we build Nixpkgs.
|
||||
supportedSystems ? [ "x86_64-linux" "i686-linux" "x86_64-darwin" "x86_64-freebsd" "i686-freebsd" ]
|
||||
supportedSystems ? [ "x86_64-linux" ]
|
||||
}:
|
||||
|
||||
with import ../../lib;
|
||||
with import ./release-lib.nix {inherit supportedSystems; };
|
||||
|
||||
let
|
||||
jobsForDerivations = attrset: pkgs.lib.attrsets.listToAttrs
|
||||
(map
|
||||
(name: { inherit name;
|
||||
value = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };})
|
||||
(builtins.attrNames
|
||||
(pkgs.lib.attrsets.filterAttrs
|
||||
(n: v: (v.type or null) == "derivation")
|
||||
attrset)));
|
||||
|
||||
|
||||
jobs =
|
||||
{
|
||||
|
||||
# } // (mapTestOn ((packagesWithMetaPlatform pkgs) // rec {
|
||||
|
||||
} // (mapTestOn rec {
|
||||
|
||||
offlineimap = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pycairo = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pycrypto = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pycups = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pydb = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyexiv2 = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pygame = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pygobject = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pygtk = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pygtksourceview = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyGtkGlade = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyIRCt = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyMAILt = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyopenssl = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyqt4 = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyrex = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyrex096 = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyside = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pysideApiextractor = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pysideGeneratorrunner = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pysideShiboken = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pysideTools = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pystringtemplate = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
python26 = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
python27 = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
python26Full = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
python27Full = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
python26Packages = jobsForDerivations pkgs.python26Packages;
|
||||
python27Packages = jobsForDerivations pkgs.python27Packages;
|
||||
python3 = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pythonDBus = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pythonIRClib = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pythonmagick = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pythonSexy = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyx = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
pyxml = { type = "job"; systems = ["x86_64-linux"]; schedulingPriority = 4; };
|
||||
});
|
||||
|
||||
in jobs
|
||||
packagePython = mapAttrs (name: value:
|
||||
let res = builtins.tryEval (
|
||||
if isDerivation value then
|
||||
value.meta.isBuildPythonPackage or []
|
||||
else if value.recurseForDerivations or false || value.recurseForRelease or false then
|
||||
packagePython value
|
||||
else
|
||||
[]);
|
||||
in if res.success then res.value else []
|
||||
);
|
||||
in (mapTestOn (packagePython pkgs))
|
||||
|
Loading…
Reference in New Issue
Block a user