Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at release-19.03 98 lines 2.5 kB view raw
1{ stdenv, lib, buildPythonPackage, fetchPypi, makeWrapper, isPy3k, 2 python, twisted, jinja2, zope_interface, future, sqlalchemy, 3 sqlalchemy_migrate, dateutil, txaio, autobahn, pyjwt, pyyaml, treq, 4 txrequests, txgithub, pyjade, boto3, moto, mock, python-lz4, setuptoolsTrial, 5 isort, pylint, flake8, buildbot-worker, buildbot-pkg, glibcLocales }: 6 7let 8 withPlugins = plugins: buildPythonPackage { 9 name = "${package.name}-with-plugins"; 10 phases = [ "installPhase" "fixupPhase" ]; 11 buildInputs = [ makeWrapper ]; 12 propagatedBuildInputs = plugins ++ package.propagatedBuildInputs; 13 14 installPhase = '' 15 makeWrapper ${package}/bin/buildbot $out/bin/buildbot \ 16 --prefix PYTHONPATH : "${package}/${python.sitePackages}:$PYTHONPATH" 17 ln -sfv ${package}/lib $out/lib 18 ''; 19 20 passthru = package.passthru // { 21 withPlugins = morePlugins: withPlugins (morePlugins ++ plugins); 22 }; 23 }; 24 25 package = buildPythonPackage rec { 26 pname = "buildbot"; 27 version = "1.8.1"; 28 29 src = fetchPypi { 30 inherit pname version; 31 sha256 = "1zadmyrlk7p9h1akmbzwa7p90s7jwsxvdx4xn9i54dnda450m3a7"; 32 }; 33 34 propagatedBuildInputs = [ 35 # core 36 twisted 37 jinja2 38 zope_interface 39 future 40 sqlalchemy 41 sqlalchemy_migrate 42 dateutil 43 txaio 44 autobahn 45 pyjwt 46 pyyaml 47 48 # tls 49 twisted.extras.tls 50 ]; 51 52 checkInputs = [ 53 treq 54 txrequests 55 pyjade 56 boto3 57 moto 58 mock 59 python-lz4 60 setuptoolsTrial 61 isort 62 pylint 63 flake8 64 buildbot-worker 65 buildbot-pkg 66 glibcLocales 67 ]; 68 69 patches = [ 70 # This patch disables the test that tries to read /etc/os-release which 71 # is not accessible in sandboxed builds. 72 ./skip_test_linux_distro.patch 73 ]; 74 75 postPatch = '' 76 substituteInPlace buildbot/scripts/logwatcher.py --replace '/usr/bin/tail' "$(type -P tail)" 77 ''; 78 79 # TimeoutErrors on slow machines -> aarch64 80 doCheck = !stdenv.isAarch64; 81 82 preCheck = '' 83 export LC_ALL="en_US.UTF-8" 84 export PATH="$out/bin:$PATH" 85 ''; 86 87 passthru = { 88 inherit withPlugins; 89 }; 90 91 meta = with lib; { 92 homepage = http://buildbot.net/; 93 description = "Buildbot is an open-source continuous integration framework for automating software build, test, and release processes"; 94 maintainers = with maintainers; [ nand0p ryansydnor ]; 95 license = licenses.gpl2; 96 }; 97 }; 98in package