From f469bd83bb9390807f1cdbe2de8d56bb8a710eb5 Mon Sep 17 00:00:00 2001 From: Pascal Bach Date: Sat, 20 May 2017 00:30:51 +0200 Subject: [PATCH 01/47] mysql service: change default data directory for 17.09 The new directory is now moved to /var/lib/mysql. This makes it consistent with with upstream. --- nixos/modules/services/databases/mysql.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/nixos/modules/services/databases/mysql.nix b/nixos/modules/services/databases/mysql.nix index fcf1f123cfb..bae6b170c47 100644 --- a/nixos/modules/services/databases/mysql.nix +++ b/nixos/modules/services/databases/mysql.nix @@ -72,7 +72,7 @@ in dataDir = mkOption { type = types.path; - default = "/var/mysql"; # !!! should be /var/db/mysql + example = "/var/lib/mysql"; description = "Location where MySQL stores its table files"; }; @@ -166,6 +166,10 @@ in config = mkIf config.services.mysql.enable { + services.mysql.dataDir = + mkDefault (if versionAtLeast config.system.stateVersion "17.09" then "/var/lib/mysql" + else "/var/mysql"); + users.extraUsers.mysql = { description = "MySQL server user"; group = "mysql"; From 6509ba66a804390191e4bcf2f068686946e6fc56 Mon Sep 17 00:00:00 2001 From: Herwig Hochleitner Date: Fri, 12 May 2017 13:22:17 +0200 Subject: [PATCH 02/47] ninja: 1.7.1 -> 1.7.2 --- pkgs/development/tools/build-managers/ninja/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/tools/build-managers/ninja/default.nix b/pkgs/development/tools/build-managers/ninja/default.nix index cadda36a0e6..39d0d4e0e39 100644 --- a/pkgs/development/tools/build-managers/ninja/default.nix +++ b/pkgs/development/tools/build-managers/ninja/default.nix @@ -2,12 +2,12 @@ stdenv.mkDerivation rec { name = "ninja-${version}"; - version = "1.7.1"; + version = "1.7.2"; src = fetchurl { name = "${name}.tar.gz"; url = "https://github.com/ninja-build/ninja/archive/v${version}.tar.gz"; - sha256 = "06dy2dc1aafm61ynw9gzig88la3km9dsh53bxf4mnw7l7kjisn2i"; + sha256 = "1n8n3g26ppwh7zwrc37n3alkbpbj0wki34ih53s3rkhs8ajs1p9f"; }; buildInputs = [ python asciidoc re2c ]; From ab65bf9dbdfdd1f5c3750ac3ec39d1217381de85 Mon Sep 17 00:00:00 2001 From: Herwig Hochleitner Date: Thu, 4 May 2017 13:39:55 +0200 Subject: [PATCH 03/47] chromium: 57.0.2987.133 -> 58.0.3029.96 --- .../browsers/chromium/upstream-info.nix | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/pkgs/applications/networking/browsers/chromium/upstream-info.nix b/pkgs/applications/networking/browsers/chromium/upstream-info.nix index 2800a3ed5d2..475ff464504 100644 --- a/pkgs/applications/networking/browsers/chromium/upstream-info.nix +++ b/pkgs/applications/networking/browsers/chromium/upstream-info.nix @@ -1,18 +1,18 @@ # This file is autogenerated from update.sh in the same directory. { beta = { - sha256 = "1q9iqmq5amzfw03jiw18g1w285b6x2qckn8gc60r5m3xx1hbivv2"; - sha256bin64 = "1ddhhcydcwwc2pkwm4c8rlr60968zy5vda410g4bwx0v5q7p22q9"; - version = "58.0.3029.68"; + sha256 = "16m7q5xfbzf1j9figilis56m1ls68v0i4zm9vp0rg64n8xny2qhw"; + sha256bin64 = "0wzzmsyp0qvbvbb8g1gjzc572c1gnn442kx3rkvcmdfakjamq93s"; + version = "59.0.3071.36"; }; dev = { - sha256 = "0zvnj9n2p057fxx7n4d1qc0nw34qhlsvrx20fwigq96blamckvd8"; - sha256bin64 = "1s1r3h7x49bp64lzzphm4jcg7g68l0x7mr3airj3hqii58dvndm0"; - version = "59.0.3067.0"; + sha256 = "0dmmkv0vf7l37x394brb81s0b4ganq3kflzq09xl3d0lp9pc2v3x"; + sha256bin64 = "04z1ck7lnxdgwni99mgx8d6iwbk6jypq4hcmrdiywp7pp3sizv89"; + version = "60.0.3080.5"; }; stable = { - sha256 = "1xwchazqqx0cs9rd15r80kw6p918zp9libx34qlcj8p5lxq1f0bh"; - sha256bin64 = "0ggn5rljch36sx0i37qzp6ldcy3ibdj0z9217lqzjq3r7ixsfqja"; - version = "57.0.2987.133"; + sha256 = "10ai9bzw6b5p6ak2fd90pg8jlk79ahiz21gzm2fx12xmsdxgsf2x"; + sha256bin64 = "06k6h93jff9slrmhl3bblq3kskxdp1357jqrzajg2zl23ja47f8m"; + version = "58.0.3029.96"; }; } From 232507a73cedbc3acfe9edb1b84938c016bf25af Mon Sep 17 00:00:00 2001 From: Herwig Hochleitner Date: Fri, 12 May 2017 13:28:48 +0200 Subject: [PATCH 04/47] chromium: 58.0.3029.96 -> 58.0.3029.110 --- .../browsers/chromium/upstream-info.nix | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/pkgs/applications/networking/browsers/chromium/upstream-info.nix b/pkgs/applications/networking/browsers/chromium/upstream-info.nix index 475ff464504..7ee28c7fc27 100644 --- a/pkgs/applications/networking/browsers/chromium/upstream-info.nix +++ b/pkgs/applications/networking/browsers/chromium/upstream-info.nix @@ -1,18 +1,18 @@ # This file is autogenerated from update.sh in the same directory. { beta = { - sha256 = "16m7q5xfbzf1j9figilis56m1ls68v0i4zm9vp0rg64n8xny2qhw"; - sha256bin64 = "0wzzmsyp0qvbvbb8g1gjzc572c1gnn442kx3rkvcmdfakjamq93s"; - version = "59.0.3071.36"; + sha256 = "1dcad79kfayagqiv85ycla3iv3gc99k0rvnvnpar9hd6x1iv8cfl"; + sha256bin64 = "0ywf50rfzv1kkfpld62fi5g0kz33an0p03xqf7wkcqi7hild607v"; + version = "59.0.3071.47"; }; dev = { - sha256 = "0dmmkv0vf7l37x394brb81s0b4ganq3kflzq09xl3d0lp9pc2v3x"; - sha256bin64 = "04z1ck7lnxdgwni99mgx8d6iwbk6jypq4hcmrdiywp7pp3sizv89"; - version = "60.0.3080.5"; + sha256 = "05kxl938mh41341lh5xsxcqxv9hhx8yn6nkawgg241sfwdx72db8"; + sha256bin64 = "1mr2615r30zjxa55mdcbfi0k2grgyykzawslmg41aw0jy5hfamal"; + version = "60.0.3095.5"; }; stable = { - sha256 = "10ai9bzw6b5p6ak2fd90pg8jlk79ahiz21gzm2fx12xmsdxgsf2x"; - sha256bin64 = "06k6h93jff9slrmhl3bblq3kskxdp1357jqrzajg2zl23ja47f8m"; - version = "58.0.3029.96"; + sha256 = "1zvqim75mlqckvf7awrbyggis71dlkz4gjpfrmfdvydcs8yyyk7j"; + sha256bin64 = "0vfx2m5zqfvfb6sgd3dg1sji72dzjcd1sf4r6qwhnz38wadys7id"; + version = "58.0.3029.110"; }; } From bafcf4226ead4a6bdc5d652164e4d18509af35a7 Mon Sep 17 00:00:00 2001 From: Herwig Hochleitner Date: Fri, 12 May 2017 13:22:39 +0200 Subject: [PATCH 05/47] chromium: add bootstrap gn patch --- .../networking/browsers/chromium/common.nix | 1 + .../browsers/chromium/patches/fix-bootstrap-gn.patch | 12 ++++++++++++ 2 files changed, 13 insertions(+) create mode 100644 pkgs/applications/networking/browsers/chromium/patches/fix-bootstrap-gn.patch diff --git a/pkgs/applications/networking/browsers/chromium/common.nix b/pkgs/applications/networking/browsers/chromium/common.nix index dac821a4898..fc7483d2fa2 100644 --- a/pkgs/applications/networking/browsers/chromium/common.nix +++ b/pkgs/applications/networking/browsers/chromium/common.nix @@ -105,6 +105,7 @@ let patches = [ ./patches/nix_plugin_paths_52.patch + ./patches/fix-bootstrap-gn.patch ] ++ optional (versionOlder version "57.0") ./patches/glibc-2.24.patch ++ optional enableWideVine ./patches/widevine.patch; diff --git a/pkgs/applications/networking/browsers/chromium/patches/fix-bootstrap-gn.patch b/pkgs/applications/networking/browsers/chromium/patches/fix-bootstrap-gn.patch new file mode 100644 index 00000000000..34efb4f7a45 --- /dev/null +++ b/pkgs/applications/networking/browsers/chromium/patches/fix-bootstrap-gn.patch @@ -0,0 +1,12 @@ +diff --git a/tools/gn/bootstrap/bootstrap.py b/tools/gn/bootstrap/bootstrap.py +index 3148ccf..38cfb11 100755 +--- a/tools/gn/bootstrap/bootstrap.py ++++ b/tools/gn/bootstrap/bootstrap.py +@@ -385,6 +385,7 @@ def write_gn_ninja(path, root_gen_dir, options): + 'base/base_switches.cc', + 'base/build_time.cc', + 'base/callback_internal.cc', ++ 'base/callback_helpers.cc', + 'base/command_line.cc', + 'base/debug/activity_tracker.cc', + 'base/debug/alias.cc', From 1fe7bd9ed6a5dd780e4991241b75fc0640576b2b Mon Sep 17 00:00:00 2001 From: Herwig Hochleitner Date: Sun, 14 May 2017 15:03:21 +0200 Subject: [PATCH 06/47] chromium: softlink system nodejs into third_party somehow, the build seems to have changed with chromium 58, to not auto download the node binary. It is needed to generate webui files and we can substitute our own. --- pkgs/applications/networking/browsers/chromium/common.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/networking/browsers/chromium/common.nix b/pkgs/applications/networking/browsers/chromium/common.nix index fc7483d2fa2..f36f28ac880 100644 --- a/pkgs/applications/networking/browsers/chromium/common.nix +++ b/pkgs/applications/networking/browsers/chromium/common.nix @@ -1,4 +1,4 @@ -{ stdenv, ninja, which +{ stdenv, ninja, which, nodejs # default dependencies , bzip2, flac, speex, libopus @@ -87,7 +87,7 @@ let nativeBuildInputs = [ ninja which python2Packages.python perl pkgconfig - python2Packages.ply python2Packages.jinja2 + python2Packages.ply python2Packages.jinja2 nodejs ]; buildInputs = defaultDependencies ++ [ @@ -131,6 +131,9 @@ let }' gpu/config/gpu_control_list.cc patchShebangs . + # use our own nodejs + mkdir -p third_party/node/linux/node-linux-x64/bin + ln -s $(which node) third_party/node/linux/node-linux-x64/bin/node '' + optionalString (versionAtLeast version "52.0.0.0") '' sed -i -re 's/([^:])\<(isnan *\()/\1std::\2/g' \ third_party/pdfium/xfa/fxbarcode/utils.h From 5e659e94a6061c9acd983ad0b5c26206b83f5735 Mon Sep 17 00:00:00 2001 From: Will Dietz Date: Thu, 25 May 2017 15:07:00 -0500 Subject: [PATCH 07/47] lldb-4: Patch to fix libedit usage on Linux Idea from: https://bugs.llvm.org//show_bug.cgi?id=28898#c7 Fixes ability to use arrow keys. --- .../compilers/llvm/4/lldb-libedit.patch | 30 +++++++++++++++++++ pkgs/development/compilers/llvm/4/lldb.nix | 7 ++--- 2 files changed, 32 insertions(+), 5 deletions(-) create mode 100644 pkgs/development/compilers/llvm/4/lldb-libedit.patch diff --git a/pkgs/development/compilers/llvm/4/lldb-libedit.patch b/pkgs/development/compilers/llvm/4/lldb-libedit.patch new file mode 100644 index 00000000000..73459ce6c86 --- /dev/null +++ b/pkgs/development/compilers/llvm/4/lldb-libedit.patch @@ -0,0 +1,30 @@ +From 94764369222a8e6c65420a6981d7f179a18a5417 Mon Sep 17 00:00:00 2001 +From: Will Dietz +Date: Thu, 25 May 2017 15:03:42 -0500 +Subject: [PATCH] EditLine.h: libedit supports wide chars on NixOS + +--- + include/lldb/Host/Editline.h | 5 +---- + 1 file changed, 1 insertion(+), 4 deletions(-) + +diff --git a/include/lldb/Host/Editline.h b/include/lldb/Host/Editline.h +index faed373bc..b248cdee1 100644 +--- a/include/lldb/Host/Editline.h ++++ b/include/lldb/Host/Editline.h +@@ -43,12 +43,9 @@ + // will only be + // used in cases where this is true. This is a compile time dependecy, for now + // selected per target Platform +-#if defined(__APPLE__) || defined(__FreeBSD__) || defined(__NetBSD__) ++// (libedit on NixOS is always wide-char capable) + #define LLDB_EDITLINE_USE_WCHAR 1 + #include +-#else +-#define LLDB_EDITLINE_USE_WCHAR 0 +-#endif + + #include "lldb/Host/ConnectionFileDescriptor.h" + #include "lldb/lldb-private.h" +-- +2.13.0 + diff --git a/pkgs/development/compilers/llvm/4/lldb.nix b/pkgs/development/compilers/llvm/4/lldb.nix index 6e6fdf012dd..953755ab6ee 100644 --- a/pkgs/development/compilers/llvm/4/lldb.nix +++ b/pkgs/development/compilers/llvm/4/lldb.nix @@ -19,7 +19,8 @@ stdenv.mkDerivation { src = fetch "lldb" "0g83hbw1r4gd0z8hlph9i34xs6dlcc69vz3h2bqwkhb2qq2qzg9d"; - patchPhase = '' + patches = [ ./lldb-libedit.patch ]; + postPatch = '' # Fix up various paths that assume llvm and clang are installed in the same place sed -i 's,".*ClangConfig.cmake","${clang-unwrapped}/lib/cmake/clang/ClangConfig.cmake",' \ cmake/modules/LLDBStandalone.cmake @@ -35,10 +36,6 @@ stdenv.mkDerivation { CXXFLAGS = "-fno-rtti"; hardeningDisable = [ "format" ]; - cmakeFlags = [ - "-DLLDB_DISABLE_LIBEDIT=ON" - ]; - enableParallelBuilding = true; meta = with stdenv.lib; { From ac8a58b5b44859f805e9613ec6cd55c3904ecbc0 Mon Sep 17 00:00:00 2001 From: Robert Scott Date: Sun, 28 May 2017 01:07:47 +0100 Subject: [PATCH 08/47] python.pkgs.django_compat: get tests working & enable them also add self as maintainer --- .../python-modules/django-compat/default.nix | 31 +++++++++++++++---- 1 file changed, 25 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/django-compat/default.nix b/pkgs/development/python-modules/django-compat/default.nix index 22f78533142..59103191285 100644 --- a/pkgs/development/python-modules/django-compat/default.nix +++ b/pkgs/development/python-modules/django-compat/default.nix @@ -1,4 +1,4 @@ -{ stdenv, buildPythonPackage, fetchurl, +{ stdenv, buildPythonPackage, fetchFromGitHub, python, django, django_nose, six }: buildPythonPackage rec { @@ -6,19 +6,38 @@ buildPythonPackage rec { name = "${pname}-${version}"; version = "1.0.14"; - src = fetchurl { - url = "mirror://pypi/d/django-compat/${name}.tar.gz"; - sha256 = "18y5bxxmafcd4np42mzbalva5lpssq0b8ki7zckbzvdv2mnv43xj"; + # the pypi packages don't include everything required for the tests + src = fetchFromGitHub { + owner = "arteria"; + repo = "django-compat"; + rev = "v${version}"; + sha256 = "11g6ra6djkchqk44v8k7biaxd1v69qyyyask5l92vmrvb0qiwvm8"; }; - doCheck = false; + checkPhase = '' + runHook preCheck - buildInputs = [ django_nose ]; + # we have to do a little bit of tinkering to convince the tests to run against the installed package, not the + # source directory + mkdir -p testbase/compat + pushd testbase + # note we're not copying the direct contents of compat/ (notably __init__.py) so python won't recognize this as a + # package, but the tests need to be in a specific path for the test templates to get picked up. + cp -r ../compat/tests compat/ + cp ../runtests.py . + ${python.interpreter} runtests.py compat/tests + popd + + runHook postCheck + ''; + + checkInputs = [ django_nose ]; propagatedBuildInputs = [ django six ]; meta = with stdenv.lib; { description = "Forward and backwards compatibility layer for Django 1.4, 1.7, 1.8, 1.9, 1.10 and 1.11"; homepage = https://github.com/arteria/django-compat; license = licenses.mit; + maintainers = with maintainers; [ ris ]; }; } From fa44b72d91625bcf5aee5438b10abdd0eb4e5acb Mon Sep 17 00:00:00 2001 From: Robert Scott Date: Sun, 28 May 2017 12:24:02 +0100 Subject: [PATCH 09/47] python.pkgs.django_hijack: 2.0.7 -> 2.1.4 also fix & enable tests, add self as maintainer --- .../python-modules/django-hijack/default.nix | 39 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 20 +--------- 2 files changed, 41 insertions(+), 18 deletions(-) create mode 100644 pkgs/development/python-modules/django-hijack/default.nix diff --git a/pkgs/development/python-modules/django-hijack/default.nix b/pkgs/development/python-modules/django-hijack/default.nix new file mode 100644 index 00000000000..8eb98924491 --- /dev/null +++ b/pkgs/development/python-modules/django-hijack/default.nix @@ -0,0 +1,39 @@ +{ stdenv, buildPythonPackage, fetchFromGitHub, python, + django, django_compat, django_nose +}: +buildPythonPackage rec { + name = "django-hijack-${version}"; + version = "2.1.4"; + + # the pypi packages don't include everything required for the tests + src = fetchFromGitHub { + owner = "arteria"; + repo = "django-hijack"; + rev = "v${version}"; + sha256 = "1wbm6l8mzpkj4wsj4fyfamzpzi3day2v1cva5j89v4dn4403jq21"; + }; + + checkInputs = [ django_nose ]; + propagatedBuildInputs = [ django django_compat ]; + + checkPhase = '' + runHook preCheck + + # we have to do a little bit of tinkering to convince the tests to run against the installed package, not the + # source directory + mkdir testbase + pushd testbase + cp ../runtests.py . + ${python.interpreter} runtests.py hijack + popd + + runHook postCheck + ''; + + meta = with stdenv.lib; { + description = "Allows superusers to hijack (=login as) and work on behalf of another user"; + homepage = https://github.com/arteria/django-hijack; + license = licenses.mit; + maintainers = with maintainers; [ ris ]; + }; +} \ No newline at end of file diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 3732556bfad..83f2e9cfcae 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -10195,26 +10195,10 @@ in { }; }; - # This package likely needs an older version of Django. + # This package may need an older version of Django. # Override the package set and set e.g. `django = super.django_1_9`. # See the Nixpkgs manual for examples on how to override the package set. - django_hijack = buildPythonPackage rec { - name = "django-hijack-${version}"; - version = "2.0.7"; - - src = pkgs.fetchurl { - url = "mirror://pypi/d/django-hijack/${name}.tar.gz"; - sha256 = "0rpi1bkfx74xfbb2nk874kfdra1jcqp2vzky1r3z7zidlc9kah04"; - }; - - propagatedBuildInputs = with self; [ django django_compat ]; - - meta = { - description = "Allows superusers to hijack (=login as) and work on behalf of another user"; - homepage = https://github.com/arteria/django-hijack; - license = licenses.mit; - }; - }; + django_hijack = callPackage ../development/python-modules/django-hijack { }; django_nose = buildPythonPackage rec { name = "django-nose-${version}"; From dc955ad2d7a392757ed845caa332fda565211b6e Mon Sep 17 00:00:00 2001 From: Pascal Wittmann Date: Mon, 29 May 2017 09:58:10 +0200 Subject: [PATCH 10/47] halibut: 1.1 -> 1.2 --- pkgs/tools/typesetting/halibut/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/typesetting/halibut/default.nix b/pkgs/tools/typesetting/halibut/default.nix index 487af940077..84cd2cf921a 100644 --- a/pkgs/tools/typesetting/halibut/default.nix +++ b/pkgs/tools/typesetting/halibut/default.nix @@ -1,11 +1,11 @@ {stdenv, fetchurl, perl}: stdenv.mkDerivation rec { - name = "halibut-1.1"; + name = "halibut-1.2"; src = fetchurl { - url = "http://www.chiark.greenend.org.uk/~sgtatham/halibut/${name}.tar.gz"; - sha256 = "18409ir55rsa5gkizw2hsr86wgv176jms2dc52px62gd246rar5r"; + url = "http://www.chiark.greenend.org.uk/~sgtatham/halibut/${name}/${name}.tar.gz"; + sha256 = "0gqnhfqf555rfpk5xj1imbdxnbkkrv4wl3rrdb1r0wgj81igpv8s"; }; buildInputs = [ perl ]; From 5831eb9afca276616cc89b2c2c17ee5f1c4b2729 Mon Sep 17 00:00:00 2001 From: Pascal Wittmann Date: Mon, 29 May 2017 11:32:58 +0200 Subject: [PATCH 11/47] colm: 0.13.0.4 -> 0.13.0.5 --- pkgs/development/compilers/colm/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/development/compilers/colm/default.nix b/pkgs/development/compilers/colm/default.nix index 767023053c6..ee9224b380c 100644 --- a/pkgs/development/compilers/colm/default.nix +++ b/pkgs/development/compilers/colm/default.nix @@ -1,15 +1,15 @@ -{ stdenv, fetchurl, makeWrapper, gcc }: +{ stdenv, fetchurl, makeWrapper, gcc, asciidoc }: stdenv.mkDerivation rec { name = "colm-${version}"; - version = "0.13.0.4"; + version = "0.13.0.5"; src = fetchurl { url = "http://www.colm.net/files/colm/${name}.tar.gz"; - sha256 = "04xcb7w82x9i4ygxqla9n39y646n3jw626khdp5297z1dkxx1czx"; + sha256 = "1320bx96ycd1xwww137cixrb983838wnrgkfsym8x5bnf5kj9rik"; }; - buildInputs = [ makeWrapper ]; + nativeBuildInputs = [ makeWrapper asciidoc ]; doCheck = true; From 58e5078487fcebbdfb77567fe348d0f8c3a39278 Mon Sep 17 00:00:00 2001 From: Pascal Wittmann Date: Mon, 29 May 2017 11:38:36 +0200 Subject: [PATCH 12/47] ragelDev: 7.0.0.9 -> 7.0.0.10 --- pkgs/development/tools/parsing/ragel/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/tools/parsing/ragel/default.nix b/pkgs/development/tools/parsing/ragel/default.nix index 0fe243e8aaf..5140719c62b 100644 --- a/pkgs/development/tools/parsing/ragel/default.nix +++ b/pkgs/development/tools/parsing/ragel/default.nix @@ -42,7 +42,7 @@ in }; ragelDev = generic { - version = "7.0.0.9"; - sha256 = "1w2jhfg3fxl15gcmm7z3jbi6splgc83mmwcfbp08lfc8sg2wmrmr"; + version = "7.0.0.10"; + sha256 = "1v4ddzxal4gf8l8nkn32qabba6nbpd2mg8sphgmdn8kaqv52nmj0"; }; } From d0be062d10871acb71dde761f43680201fc23f16 Mon Sep 17 00:00:00 2001 From: Pascal Wittmann Date: Mon, 29 May 2017 12:19:00 +0200 Subject: [PATCH 13/47] perlPackagrs.NTLM: init at 1.09 --- pkgs/top-level/perl-packages.nix | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/pkgs/top-level/perl-packages.nix b/pkgs/top-level/perl-packages.nix index 4874d5d01a2..5bab2ab8927 100644 --- a/pkgs/top-level/perl-packages.nix +++ b/pkgs/top-level/perl-packages.nix @@ -10157,6 +10157,19 @@ let self = _self // overrides; _self = with self; { }; }; + NTLM = buildPerlPackage rec { + name = "NTLM-1.09"; + src = fetchurl { + url = "mirror://cpan/authors/id/N/NB/NBEBOUT/${name}.tar.gz"; + sha256 = "c823e30cda76bc15636e584302c960e2b5eeef9517c2448f7454498893151f85"; + }; + propagatedBuildInputs = [ DigestHMAC ]; + meta = { + license = with stdenv.lib.licenses; [ artistic1 gpl1Plus ]; + maintainers = [ maintainers.pSub ]; + }; + }; + ObjectAccessor = buildPerlPackage { name = "Object-Accessor-0.48"; src = fetchurl { From c63339567bb2097b2b851f0a00e73e964b270d7e Mon Sep 17 00:00:00 2001 From: Pascal Wittmann Date: Mon, 29 May 2017 12:19:29 +0200 Subject: [PATCH 14/47] imapsync: 1.684 -> 1.727 --- pkgs/tools/networking/imapsync/default.nix | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/pkgs/tools/networking/imapsync/default.nix b/pkgs/tools/networking/imapsync/default.nix index d01e0ededb3..c05928fa34b 100644 --- a/pkgs/tools/networking/imapsync/default.nix +++ b/pkgs/tools/networking/imapsync/default.nix @@ -1,10 +1,10 @@ {stdenv, makeWrapper, fetchurl, perl, openssl, perlPackages }: stdenv.mkDerivation rec { - name = "imapsync-1.684"; + name = "imapsync-1.727"; src = fetchurl { - url = "https://fedorahosted.org/released/imapsync/${name}.tgz"; - sha256 = "1ilqdaabh6xiwpjfdg2mrhygvjlxj6jdkmqjqadq5z29172hji5b"; + url = "https://releases.pagure.org/imapsync/${name}.tgz"; + sha256 = "1axacjw2wyaphczfw3kfmi5cl83fyr8nb207nks40fxkbs8q5dlr"; }; patchPhase = '' @@ -20,7 +20,8 @@ stdenv.mkDerivation rec { buildInputs = with perlPackages; [ perl openssl MailIMAPClient TermReadKey IOSocketSSL DigestHMAC URI FileCopyRecursive IOTee UnicodeString DataUniqid JSONWebToken TestMockGuard LWP CryptOpenSSLRSA - LWPProtocolHttps + LWPProtocolHttps Readonly TestPod TestMockObject ParseRecDescent + IOSocketInet6 NTLM ]; meta = with stdenv.lib; { From 13f2f8673b184599e7a65df422c968730554820f Mon Sep 17 00:00:00 2001 From: Robin Gloster Date: Mon, 29 May 2017 12:20:05 +0200 Subject: [PATCH 15/47] OVMF: fix build $fd for the output was overwritten during the build --- pkgs/applications/virtualization/OVMF/default.nix | 7 +++++-- pkgs/games/wesnoth/dev.nix | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/virtualization/OVMF/default.nix b/pkgs/applications/virtualization/OVMF/default.nix index 4f7ea37ca18..121875a69de 100644 --- a/pkgs/applications/virtualization/OVMF/default.nix +++ b/pkgs/applications/virtualization/OVMF/default.nix @@ -23,6 +23,9 @@ stdenv.mkDerivation (edk2.setup "OvmfPkg/OvmfPkg${targetArch}.dsc" { hardeningDisable = [ "stackprotector" "pic" "fortify" ]; unpackPhase = '' + # $fd is overwritten during the build + export OUTPUT_FD=$fd + for file in \ "${edk2.src}"/{UefiCpuPkg,MdeModulePkg,IntelFrameworkModulePkg,PcAtChipsetPkg,FatBinPkg,EdkShellBinPkg,MdePkg,ShellPkg,OptionRomPkg,IntelFrameworkPkg}; do @@ -51,8 +54,8 @@ stdenv.mkDerivation (edk2.setup "OvmfPkg/OvmfPkg${targetArch}.dsc" { ''; postFixup = '' - mkdir -p $fd/FV - mv $out/FV/OVMF{,_CODE,_VARS}.fd $fd/FV + mkdir -vp $OUTPUT_FD/FV + mv -v $out/FV/OVMF{,_CODE,_VARS}.fd $OUTPUT_FD/FV ''; dontPatchELF = true; diff --git a/pkgs/games/wesnoth/dev.nix b/pkgs/games/wesnoth/dev.nix index 0b335812ff0..315f9ea7a5e 100644 --- a/pkgs/games/wesnoth/dev.nix +++ b/pkgs/games/wesnoth/dev.nix @@ -5,13 +5,13 @@ stdenv.mkDerivation rec { pname = "wesnoth"; - version = "1.13.6"; + version = "1.13.8"; name = "${pname}-${version}"; src = fetchurl { url = "mirror://sourceforge/sourceforge/${pname}/${name}.tar.bz2"; - sha256 = "0z4k2r4ss46ik9fx5clffpd7vfr0l4l6d0j1war676dwz0z1j2m1"; + sha256 = "0snm4n7l21cr4443rk93wnaqdzr91pihn452w66344zqwf33xgfr"; }; nativeBuildInputs = [ cmake pkgconfig ]; From 1e95e114e5eefdb0f792f9f7a620c9472e6d7da3 Mon Sep 17 00:00:00 2001 From: Franz Pletz Date: Thu, 25 May 2017 19:33:13 +0200 Subject: [PATCH 16/47] nixos/xsession: use graphical systemd user target While systemd suggests using the pre-defined graphical-session user target, I found that this interface is difficult to use. Additionally, no other major distribution, even in their unstable versions, currently use this mechanism. The window or desktop manager is supposed to run in a systemd user service which activates graphical-session.target and the user services that are binding to this target. The issue is that we can't elegantly pass the xsession environment to the window manager session, in particular whereas the PassEnvironment option does work for DISPLAY, it for some mysterious reason won't for PATH. This commit implements a new graphical user target that works just like default.target. Services which should be run in a graphical session just need to declare wantedBy graphical.target. The graphical target will be activated in the xsession before executing the window or display manager. Fixes #17858. --- nixos/modules/config/pulseaudio.nix | 7 +++++-- nixos/modules/programs/ssh.nix | 5 ++--- nixos/modules/services/monitoring/arbtt.nix | 3 ++- nixos/modules/services/x11/compton.nix | 4 ++-- .../services/x11/display-managers/default.nix | 13 +++++++++++++ nixos/modules/services/x11/redshift.nix | 9 ++------- nixos/modules/services/x11/unclutter-xfixes.nix | 3 ++- nixos/modules/services/x11/unclutter.nix | 8 +++----- nixos/modules/services/x11/urxvtd.nix | 5 ++--- nixos/modules/services/x11/xbanish.nix | 3 ++- 10 files changed, 35 insertions(+), 25 deletions(-) diff --git a/nixos/modules/config/pulseaudio.nix b/nixos/modules/config/pulseaudio.nix index bf66994b502..bd80c811348 100644 --- a/nixos/modules/config/pulseaudio.nix +++ b/nixos/modules/config/pulseaudio.nix @@ -240,11 +240,14 @@ in { }; systemd.user = { services.pulseaudio = { + restartIfChanged = true; serviceConfig = { RestartSec = "500ms"; + PassEnvironment = "DISPLAY"; }; - environment = { DISPLAY = ":${toString config.services.xserver.display}"; }; - restartIfChanged = true; + }; + sockets.pulseaudio = { + wantedBy = [ "sockets.target" ]; }; }; }) diff --git a/nixos/modules/programs/ssh.nix b/nixos/modules/programs/ssh.nix index a00fc0dfd19..4faef2c609b 100644 --- a/nixos/modules/programs/ssh.nix +++ b/nixos/modules/programs/ssh.nix @@ -199,9 +199,8 @@ in environment.etc."ssh/ssh_known_hosts".text = knownHostsText; # FIXME: this should really be socket-activated for über-awesomeness. - systemd.user.services.ssh-agent = - { enable = cfg.startAgent; - description = "SSH Agent"; + systemd.user.services.ssh-agent = mkIf cfg.startAgent + { description = "SSH Agent"; wantedBy = [ "default.target" ]; serviceConfig = { ExecStartPre = "${pkgs.coreutils}/bin/rm -f %t/ssh-agent"; diff --git a/nixos/modules/services/monitoring/arbtt.nix b/nixos/modules/services/monitoring/arbtt.nix index a8d5e3b7fa0..b41a3c7b501 100644 --- a/nixos/modules/services/monitoring/arbtt.nix +++ b/nixos/modules/services/monitoring/arbtt.nix @@ -48,7 +48,8 @@ in { config = mkIf cfg.enable { systemd.user.services.arbtt = { description = "arbtt statistics capture service"; - wantedBy = [ "default.target" ]; + wantedBy = [ "graphical-session.target" ]; + partOf = [ "graphical-session.target" ]; serviceConfig = { Type = "simple"; diff --git a/nixos/modules/services/x11/compton.nix b/nixos/modules/services/x11/compton.nix index d75d24830f8..56bc66b7179 100644 --- a/nixos/modules/services/x11/compton.nix +++ b/nixos/modules/services/x11/compton.nix @@ -208,13 +208,13 @@ in { config = mkIf cfg.enable { systemd.user.services.compton = { description = "Compton composite manager"; - wantedBy = [ "default.target" ]; + wantedBy = [ "graphical-session.target" ]; + partOf = [ "graphical-session.target" ]; serviceConfig = { ExecStart = "${cfg.package}/bin/compton --config ${configFile}"; RestartSec = 3; Restart = "always"; }; - environment.DISPLAY = ":0"; }; environment.systemPackages = [ cfg.package ]; diff --git a/nixos/modules/services/x11/display-managers/default.nix b/nixos/modules/services/x11/display-managers/default.nix index cf6efb7dae7..58773685ec1 100644 --- a/nixos/modules/services/x11/display-managers/default.nix +++ b/nixos/modules/services/x11/display-managers/default.nix @@ -122,6 +122,9 @@ let source ~/.xprofile fi + # Start systemd user services for graphical sessions + ${config.systemd.package}/bin/systemctl --user start graphical-session.target + # Allow the user to setup a custom session type. if test -x ~/.xsession; then exec ~/.xsession @@ -164,6 +167,9 @@ let ''} test -n "$waitPID" && wait "$waitPID" + + ${config.systemd.package}/bin/systemctl --user stop graphical-session.target + exit 0 ''; @@ -325,6 +331,13 @@ in config = { services.xserver.displayManager.xserverBin = "${xorg.xorgserver.out}/bin/X"; + + systemd.user.targets.graphical-session = { + unitConfig = { + RefuseManualStart = false; + StopWhenUnneeded = false; + }; + }; }; imports = [ diff --git a/nixos/modules/services/x11/redshift.nix b/nixos/modules/services/x11/redshift.nix index eb5dfdf9584..992709ed000 100644 --- a/nixos/modules/services/x11/redshift.nix +++ b/nixos/modules/services/x11/redshift.nix @@ -95,7 +95,8 @@ in { config = mkIf cfg.enable { systemd.user.services.redshift = { description = "Redshift colour temperature adjuster"; - wantedBy = [ "default.target" ]; + wantedBy = [ "graphical-session.target" ]; + partOf = [ "graphical-session.target" ]; serviceConfig = { ExecStart = '' ${cfg.package}/bin/redshift \ @@ -107,12 +108,6 @@ in { RestartSec = 3; Restart = "always"; }; - environment = { - DISPLAY = ":${toString ( - let display = config.services.xserver.display; - in if display != null then display else 0 - )}"; - }; }; }; diff --git a/nixos/modules/services/x11/unclutter-xfixes.nix b/nixos/modules/services/x11/unclutter-xfixes.nix index b94dfb1a26a..71262431b68 100644 --- a/nixos/modules/services/x11/unclutter-xfixes.nix +++ b/nixos/modules/services/x11/unclutter-xfixes.nix @@ -43,7 +43,8 @@ in { config = mkIf cfg.enable { systemd.user.services.unclutter-xfixes = { description = "unclutter-xfixes"; - wantedBy = [ "graphical.target" ]; + wantedBy = [ "graphical-session.target" ]; + partOf = [ "graphical-session.target" ]; serviceConfig.ExecStart = '' ${cfg.package}/bin/unclutter \ --timeout ${toString cfg.timeout} \ diff --git a/nixos/modules/services/x11/unclutter.nix b/nixos/modules/services/x11/unclutter.nix index a22e5ac2c95..5f16a680050 100644 --- a/nixos/modules/services/x11/unclutter.nix +++ b/nixos/modules/services/x11/unclutter.nix @@ -56,19 +56,17 @@ in { config = mkIf cfg.enable { systemd.user.services.unclutter = { description = "unclutter"; - wantedBy = [ "default.target" ]; + wantedBy = [ "graphical-session.target" ]; + partOf = [ "graphical-session.target" ]; serviceConfig.ExecStart = '' ${cfg.package}/bin/unclutter \ -idle ${toString cfg.timeout} \ - -display :${toString ( - let display = config.services.xserver.display; - in if display != null then display else 0 - )} \ -jitter ${toString (cfg.threeshold - 1)} \ ${optionalString cfg.keystroke "-keystroke"} \ ${concatMapStrings (x: " -"+x) cfg.extraOptions} \ -not ${concatStringsSep " " cfg.excluded} \ ''; + serviceConfig.PassEnvironment = "DISPLAY"; serviceConfig.RestartSec = 3; serviceConfig.Restart = "always"; }; diff --git a/nixos/modules/services/x11/urxvtd.nix b/nixos/modules/services/x11/urxvtd.nix index 57ad93f2017..f2ce089ce19 100644 --- a/nixos/modules/services/x11/urxvtd.nix +++ b/nixos/modules/services/x11/urxvtd.nix @@ -21,9 +21,8 @@ in { systemd.user = { sockets.urxvtd = { description = "socket for urxvtd, the urxvt terminal daemon"; - after = [ "graphical.target" ]; - wants = [ "graphical.target" ]; - wantedBy = [ "sockets.target" ]; + wantedBy = [ "graphical-session.target" ]; + partOf = [ "graphical-session.target" ]; socketConfig = { ListenStream = "%t/urxvtd-socket"; }; diff --git a/nixos/modules/services/x11/xbanish.nix b/nixos/modules/services/x11/xbanish.nix index e1e3cbc8e44..b95fac68f16 100644 --- a/nixos/modules/services/x11/xbanish.nix +++ b/nixos/modules/services/x11/xbanish.nix @@ -20,7 +20,8 @@ in { config = mkIf cfg.enable { systemd.user.services.xbanish = { description = "xbanish hides the mouse pointer"; - wantedBy = [ "default.target" ]; + wantedBy = [ "graphical-session.target" ]; + partOf = [ "graphical-session.target" ]; serviceConfig.ExecStart = '' ${pkgs.xbanish}/bin/xbanish ${cfg.arguments} ''; From 04158d9aba1d8b98e49770702922b63ba075728b Mon Sep 17 00:00:00 2001 From: Franz Pletz Date: Thu, 25 May 2017 21:14:39 +0200 Subject: [PATCH 17/47] gnupg agent module: init Creates a systemd user service and updates the tty on new logins so that gpg-agent may find the current tty even if the SSH agent mode is used. --- nixos/modules/module-list.nix | 1 + nixos/modules/programs/gnupg.nix | 75 ++++++++++++++++++++++++++++++++ 2 files changed, 76 insertions(+) create mode 100644 nixos/modules/programs/gnupg.nix diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index 5e1ff91acab..7afcb9051bd 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -80,6 +80,7 @@ ./programs/environment.nix ./programs/fish.nix ./programs/freetds.nix + ./programs/gnupg.nix ./programs/gphoto2.nix ./programs/info.nix ./programs/java.nix diff --git a/nixos/modules/programs/gnupg.nix b/nixos/modules/programs/gnupg.nix new file mode 100644 index 00000000000..c5277f40d26 --- /dev/null +++ b/nixos/modules/programs/gnupg.nix @@ -0,0 +1,75 @@ +{ config, lib, pkgs, ... }: + +with lib; + +let + + cfg = config.programs.gnupg; + +in + +{ + + options.programs.gnupg = { + agent.enable = mkOption { + type = types.bool; + default = false; + description = '' + Enables GnuPG agent with socket-activation for every user session. + ''; + }; + + agent.enableSSHSupport = mkOption { + type = types.bool; + default = true; + description = '' + Enable SSH agent support in GnuPG agent. Also sets SSH_AUTH_SOCK + environment variable correctly. This will disable socket-activation + and thus always start a GnuPG agent per user session. + ''; + }; + }; + + config = mkIf cfg.agent.enable { + systemd.user.services.gpg-agent = { + serviceConfig = { + ExecStart = [ + "" + ("${pkgs.gnupg}/bin/gpg-agent --supervised " + + optionalString cfg.agent.enableSSHSupport "--enable-ssh-support") + ]; + }; + }; + + systemd.user.sockets.gpg-agent = { + wantedBy = [ "sockets.target" ]; + }; + + systemd.user.sockets.gpg-agent-ssh = mkIf cfg.agent.enableSSHSupport { + wantedBy = [ "sockets.target" ]; + }; + + systemd.packages = [ pkgs.gnupg ]; + + environment.extraInit = '' + # Bind gpg-agent to this TTY if gpg commands are used. + export GPG_TTY=$(tty) + + '' + (optionalString cfg.agent.enableSSHSupport '' + # SSH agent protocol doesn't support changing TTYs, so bind the agent + # to every new TTY. + ${pkgs.gnupg}/bin/gpg-connect-agent --quiet updatestartuptty /bye > /dev/null + + if [ -z "$SSH_AUTH_SOCK" ]; then + export SSH_AUTH_SOCK=$(${pkgs.gnupg}/bin/gpgconf --list-dirs agent-ssh-socket) + fi + ''); + + assertions = [ + { assertion = cfg.agent.enableSSHSupport && !config.programs.ssh.startAgent; + message = "You can't use ssh-agent and GnuPG agent with SSH support enabled at the same time!"; + } + ]; + }; + +} From a78af5196c1b8229ac2311e38d41809249b47932 Mon Sep 17 00:00:00 2001 From: Tim Steinbach Date: Mon, 29 May 2017 09:32:42 -0400 Subject: [PATCH 18/47] linux: 4.12-rc2 -> 4.12-rc3 --- pkgs/os-specific/linux/kernel/linux-testing.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/os-specific/linux/kernel/linux-testing.nix b/pkgs/os-specific/linux/kernel/linux-testing.nix index f783828f031..8c8da674f4d 100644 --- a/pkgs/os-specific/linux/kernel/linux-testing.nix +++ b/pkgs/os-specific/linux/kernel/linux-testing.nix @@ -1,13 +1,13 @@ { stdenv, fetchurl, perl, buildLinux, ... } @ args: import ./generic.nix (args // rec { - version = "4.12-rc2"; - modDirVersion = "4.12.0-rc2"; + version = "4.12-rc3"; + modDirVersion = "4.12.0-rc3"; extraMeta.branch = "4.12"; src = fetchurl { url = "https://git.kernel.org/torvalds/t/linux-${version}.tar.gz"; - sha256 = "18p68ig9irblbxbg68jz766158bxr81824q91mnf372i5z9irj9w"; + sha256 = "0jwhsmw4igf5iwf4qndqbjzayag2wj2riypzl0v3yrh5zkhfl4dm"; }; features.iwlwifi = true; From 2c39927c7aa0b80165e88c2300bce822110e6552 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Mon, 29 May 2017 14:33:04 +0100 Subject: [PATCH 19/47] pythonPackages.alembic: 0.8.3 -> 0.9.2 --- .../python-modules/alembic/default.nix | 24 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 18 +------------- 2 files changed, 25 insertions(+), 17 deletions(-) create mode 100644 pkgs/development/python-modules/alembic/default.nix diff --git a/pkgs/development/python-modules/alembic/default.nix b/pkgs/development/python-modules/alembic/default.nix new file mode 100644 index 00000000000..0538e7cf416 --- /dev/null +++ b/pkgs/development/python-modules/alembic/default.nix @@ -0,0 +1,24 @@ +{ stdenv, buildPythonPackage, fetchPypi +, pytest, pytestcov, mock, coverage +, Mako, sqlalchemy, python-editor, dateutil +}: + +buildPythonPackage rec { + name = "${pname}-${version}"; + pname = "alembic"; + version = "0.9.2"; + + src = fetchPypi { + inherit pname version; + sha256 = "0iw6wysm83hycvrycymf9b4mkji47536kl3x7grynfcbyjcvbdm2"; + }; + + buildInputs = [ pytest pytestcov mock coverage ]; + propagatedBuildInputs = [ Mako sqlalchemy python-editor dateutil ]; + + meta = with stdenv.lib; { + homepage = http://bitbucket.org/zzzeek/alembic; + description = "A database migration tool for SQLAlchemy"; + license = licenses.mit; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 3f5b20a62d6..107fd715b94 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -640,23 +640,7 @@ in { }; - alembic = buildPythonPackage rec { - name = "alembic-0.8.3"; - - src = pkgs.fetchurl { - url = "mirror://pypi/a/alembic/${name}.tar.gz"; - sha256 = "1sgwvwylzd5h14130mwr0cbyy0fil0a1bq0d0ki97wqvkic3db7f"; - }; - - buildInputs = with self; [ pytest pytestcov mock coverage ]; - propagatedBuildInputs = with self; [ Mako sqlalchemy python-editor ]; - - meta = { - homepage = http://bitbucket.org/zzzeek/alembic; - description = "A database migration tool for SQLAlchemy"; - license = licenses.mit; - }; - }; + alembic = callPackage ../development/python-modules/alembic {}; ansicolors = buildPythonPackage rec { name = "ansicolors-${version}"; From a49c2366efad78d296375b7c17065cacee3c3975 Mon Sep 17 00:00:00 2001 From: Franz Pletz Date: Mon, 29 May 2017 17:24:27 +0200 Subject: [PATCH 20/47] nixos/firewall: clean up rpfilter rules properly The rpfilter rules wouldn't be removed if it was previously enabled but disabled in a new generation. --- nixos/modules/services/networking/firewall.nix | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/nixos/modules/services/networking/firewall.nix b/nixos/modules/services/networking/firewall.nix index 243cd04c96c..68a814b2305 100644 --- a/nixos/modules/services/networking/firewall.nix +++ b/nixos/modules/services/networking/firewall.nix @@ -114,14 +114,15 @@ let # The "nixos-fw" chain does the actual work. ip46tables -N nixos-fw - # Perform a reverse-path test to refuse spoofers - # For now, we just drop, as the raw table doesn't have a log-refuse yet - ${optionalString (kernelHasRPFilter && (cfg.checkReversePath != false)) '' - # Clean up rpfilter rules - ip46tables -t raw -D PREROUTING -j nixos-fw-rpfilter 2> /dev/null || true - ip46tables -t raw -F nixos-fw-rpfilter 2> /dev/null || true - ip46tables -t raw -N nixos-fw-rpfilter 2> /dev/null || true + # Clean up rpfilter rules + ip46tables -t raw -D PREROUTING -j nixos-fw-rpfilter 2> /dev/null || true + ip46tables -t raw -F nixos-fw-rpfilter 2> /dev/null || true + ip46tables -t raw -X nixos-fw-rpfilter 2> /dev/null || true + ${optionalString (kernelHasRPFilter && (cfg.checkReversePath != false)) '' + # Perform a reverse-path test to refuse spoofers + # For now, we just drop, as the raw table doesn't have a log-refuse yet + ip46tables -t raw -N nixos-fw-rpfilter 2> /dev/null || true ip46tables -t raw -A nixos-fw-rpfilter -m rpfilter ${optionalString (cfg.checkReversePath == "loose") "--loose"} -j RETURN # Allows this host to act as a DHCPv4 server From 1d56c2fa434b2cf875aab4eabcfd69fa89fe25eb Mon Sep 17 00:00:00 2001 From: timor Date: Mon, 29 May 2017 17:56:52 +0200 Subject: [PATCH 21/47] NetworkManager: fix openconnect for console tools This patch allows `nmcli` and `nmtui to work correctly with openconnect. This is dony by hard-coding the openconnect binary location. see #25915 --- .../networking/network-manager/default.nix | 5 +++- .../openconnect_helper_path.patch | 29 +++++++++++++++++++ 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 pkgs/tools/networking/network-manager/openconnect_helper_path.patch diff --git a/pkgs/tools/networking/network-manager/default.nix b/pkgs/tools/networking/network-manager/default.nix index 58e5e9343a7..585ffe1d3b1 100644 --- a/pkgs/tools/networking/network-manager/default.nix +++ b/pkgs/tools/networking/network-manager/default.nix @@ -3,7 +3,7 @@ , libgcrypt, dnsmasq, bluez5, readline , gobjectIntrospection, modemmanager, openresolv, libndp, newt, libsoup , ethtool, iputils, gnused, coreutils, file, inetutils, kmod, jansson, libxslt -, python3Packages, docbook_xsl, fetchpatch }: +, python3Packages, docbook_xsl, fetchpatch, openconnect }: stdenv.mkDerivation rec { name = "network-manager-${version}"; @@ -41,6 +41,8 @@ stdenv.mkDerivation rec { --replace /bin/sed ${gnused}/bin/sed substituteInPlace data/NetworkManager.service.in \ --replace /bin/kill ${coreutils}/bin/kill + substituteInPlace clients/common/nm-vpn-helpers.c \ + --subst-var-by openconnect ${openconnect} # to enable link-local connections configureFlags="$configureFlags --with-udev-dir=$out/lib/udev" ''; @@ -76,6 +78,7 @@ stdenv.mkDerivation rec { name = "null-dereference.patch"; url = "https://github.com/NetworkManager/NetworkManager/commit/4e8eddd100bbc8429806a70620c90b72cfd29cb1.patch"; }) + ./openconnect_helper_path.patch ]; buildInputs = [ systemd libgudev libnl libuuid polkit ppp libndp diff --git a/pkgs/tools/networking/network-manager/openconnect_helper_path.patch b/pkgs/tools/networking/network-manager/openconnect_helper_path.patch new file mode 100644 index 00000000000..597fb753e26 --- /dev/null +++ b/pkgs/tools/networking/network-manager/openconnect_helper_path.patch @@ -0,0 +1,29 @@ +diff --git a/clients/common/nm-vpn-helpers.c b/clients/common/nm-vpn-helpers.c +index 15611c45c..4a7444d3a 100644 +--- a/clients/common/nm-vpn-helpers.c ++++ b/clients/common/nm-vpn-helpers.c +@@ -203,23 +203,8 @@ nm_vpn_openconnect_authenticate_helper (const char *host, + gboolean ret; + char **strv = NULL, **iter; + char *argv[4]; +- const char *path; +- const char *const DEFAULT_PATHS[] = { +- "/sbin/", +- "/usr/sbin/", +- "/usr/local/sbin/", +- "/bin/", +- "/usr/bin/", +- "/usr/local/bin/", +- NULL, +- }; +- +- path = nm_utils_file_search_in_paths ("openconnect", "/usr/sbin/openconnect", DEFAULT_PATHS, +- G_FILE_TEST_IS_EXECUTABLE, NULL, NULL, error); +- if (!path) +- return FALSE; + +- argv[0] = (char *) path; ++ argv[0] = "@openconnect@/bin/openconnect"; + argv[1] = "--authenticate"; + argv[2] = (char *) host; + argv[3] = NULL; From 3d2cfabad6b79dd1a3c6ddd75cdc2959d16b476e Mon Sep 17 00:00:00 2001 From: Frederik Rietdijk Date: Mon, 29 May 2017 21:25:30 +0200 Subject: [PATCH 22/47] hdf5: add comment about multiple outputs --- pkgs/tools/misc/hdf5/default.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkgs/tools/misc/hdf5/default.nix b/pkgs/tools/misc/hdf5/default.nix index 176f8aa1f51..192da26b452 100644 --- a/pkgs/tools/misc/hdf5/default.nix +++ b/pkgs/tools/misc/hdf5/default.nix @@ -12,6 +12,9 @@ # (--enable-unsupported could be used to force the build) assert !cpp || mpi == null; +# No point splitting version 1.8.18 into multiple outputs. +# The library /lib/libhdf5.so has a reference to gcc-wrapper + let inherit (stdenv.lib) optional optionals; in stdenv.mkDerivation rec { From 97eddf0907edfbb2e80258b1104034dbff90bd53 Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Wed, 24 May 2017 17:37:05 +0200 Subject: [PATCH 23/47] vimer: init at 0.2.0 --- pkgs/tools/misc/vimer/default.nix | 32 +++++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 34 insertions(+) create mode 100644 pkgs/tools/misc/vimer/default.nix diff --git a/pkgs/tools/misc/vimer/default.nix b/pkgs/tools/misc/vimer/default.nix new file mode 100644 index 00000000000..231ee9ac157 --- /dev/null +++ b/pkgs/tools/misc/vimer/default.nix @@ -0,0 +1,32 @@ +{ stdenv, fetchFromGitHub }: + +stdenv.mkDerivation rec { + version = "0.2.0"; + name = "vimer-${version}"; + + src = fetchFromGitHub { + owner = "susam"; + repo = "vimer"; + rev = version; + sha256 = "01qhr3i7wasbaxvms39c81infpry2vk0nzh7r5m5b9p713p0phsi"; + }; + + installPhase = '' + mkdir $out/bin/ -p + cp vimer $out/bin/ + chmod +x $out/bin/vimer + ''; + + meta = with stdenv.lib; { + homepage = "https://github.com/susam/vimer"; + description = '' + A convenience wrapper for gvim/mvim --remote(-tab)-silent to open files + in an existing instance of GVim or MacVim. + ''; + license = licenses.mit; + maintainers = [ maintainers.matthiasbeyer ]; + platforms = platforms.linux; + }; + +} + diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 2007e8262cd..11e0e16fe47 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -4489,6 +4489,8 @@ with pkgs; vim-vint = callPackage ../development/tools/vim-vint { }; + vimer = callPackage ../tools/misc/vimer { }; + vit = callPackage ../applications/misc/vit { }; vnc2flv = callPackage ../tools/video/vnc2flv {}; From a61e58b12106e043970b699e58d4d743e1f27e61 Mon Sep 17 00:00:00 2001 From: Kranium Gikos Mendoza Date: Fri, 26 May 2017 23:36:19 +1000 Subject: [PATCH 24/47] pythonPackages.argcomplete: init at 1.8.2 --- .../python-modules/argcomplete/default.nix | 27 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 29 insertions(+) create mode 100644 pkgs/development/python-modules/argcomplete/default.nix diff --git a/pkgs/development/python-modules/argcomplete/default.nix b/pkgs/development/python-modules/argcomplete/default.nix new file mode 100644 index 00000000000..cd0cc47d9e7 --- /dev/null +++ b/pkgs/development/python-modules/argcomplete/default.nix @@ -0,0 +1,27 @@ +{ buildPythonPackage, fetchPypi, lib, + coverage, dicttoxml, flake8, pexpect, prettytable, requests_toolbelt +}: +buildPythonPackage rec { + name = "${pname}-${version}"; + pname = "argcomplete"; + version = "1.8.2"; + + src = fetchPypi { + inherit pname version; + sha256 = "0sslhl1klvh92c8hjsz3y3mmnpcqspcgi49g5cik2rpbfkhcsb3s"; + }; + + doCheck = false; # bash-completion test fails with "compgen: command not found". + + # re-enable if we are able to make testing work + # buildInputs = [ coverage flake8 ]; + + propagatedBuildInputs = [ dicttoxml pexpect prettytable requests_toolbelt ]; + + meta = with lib; { + description = "Bash tab completion for argparse"; + homepage = "https://argcomplete.readthedocs.io"; + maintainers = [ maintainers.womfoo ]; + license = [ licenses.asl20 ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index f40f60c6294..c3cc72a05a9 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -1159,6 +1159,8 @@ in { }; }; + argcomplete = callPackage ../development/python-modules/argcomplete { }; + area53 = buildPythonPackage (rec { name = "Area53-0.94"; From 4126cc18be480ffc1599488d40c4fb4b3cfe32ae Mon Sep 17 00:00:00 2001 From: Kranium Gikos Mendoza Date: Fri, 26 May 2017 23:36:47 +1000 Subject: [PATCH 25/47] cloudmonkey: init at 5.3.3 --- .../virtualization/cloudmonkey/default.nix | 27 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 2 files changed, 29 insertions(+) create mode 100644 pkgs/tools/virtualization/cloudmonkey/default.nix diff --git a/pkgs/tools/virtualization/cloudmonkey/default.nix b/pkgs/tools/virtualization/cloudmonkey/default.nix new file mode 100644 index 00000000000..b133bc094f9 --- /dev/null +++ b/pkgs/tools/virtualization/cloudmonkey/default.nix @@ -0,0 +1,27 @@ +{ python2Packages, lib }: + +with python2Packages; + +buildPythonApplication rec { + + name = "${pname}-${version}"; + pname = "cloudmonkey"; + version = "5.3.3"; + + propagatedBuildInputs = [ argcomplete pygments ]; + + doCheck = false; # upstream has no tests defined + + src = fetchPypi { + inherit pname version; + sha256 = "064yk3lwl272nyn20xxrh0qxzh3r1rl9015qqf2i4snqdzwd5cf7"; + }; + + meta = with lib; { + description = "CLI for Apache CloudStack."; + homepage = "https://cwiki.apache.org/confluence/display/CLOUDSTACK/CloudStack+cloudmonkey+CLI"; + license = [ licenses.asl20 ]; + maintainers = [ maintainers.womfoo ]; + }; + +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 16b52fa6f67..9c0b155b80c 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -814,6 +814,8 @@ with pkgs; cloud-init = callPackage ../tools/virtualization/cloud-init { }; + cloudmonkey = callPackage ../tools/virtualization/cloudmonkey { }; + clib = callPackage ../tools/package-management/clib { }; colord-kde = libsForQt5.callPackage ../tools/misc/colord-kde {}; From 75a94a5a28b33f6bad29f17c2986f3c173929cd7 Mon Sep 17 00:00:00 2001 From: Robin Stumm Date: Mon, 29 May 2017 20:24:31 +0200 Subject: [PATCH 26/47] mcrcon: init at 0.0.5 --- lib/maintainers.nix | 1 + pkgs/tools/networking/mcrcon/default.nix | 33 ++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 3 files changed, 36 insertions(+) create mode 100644 pkgs/tools/networking/mcrcon/default.nix diff --git a/lib/maintainers.nix b/lib/maintainers.nix index ad1ba299a53..db40b36fd6a 100644 --- a/lib/maintainers.nix +++ b/lib/maintainers.nix @@ -132,6 +132,7 @@ deepfire = "Kosyrev Serge <_deepfire@feelingofgreen.ru>"; demin-dmitriy = "Dmitriy Demin "; DerGuteMoritz = "Moritz Heidkamp "; + dermetfan = "Robin Stumm "; DerTim1 = "Tim Digel "; desiderius = "Didier J. Devroye "; devhell = "devhell <\"^\"@regexmail.net>"; diff --git a/pkgs/tools/networking/mcrcon/default.nix b/pkgs/tools/networking/mcrcon/default.nix new file mode 100644 index 00000000000..eda93c82cce --- /dev/null +++ b/pkgs/tools/networking/mcrcon/default.nix @@ -0,0 +1,33 @@ +{ stdenv, fetchFromGitHub }: + +stdenv.mkDerivation rec { + name = "mcrcon-${version}"; + version = "0.0.5"; + + src = fetchFromGitHub { + owner = "Tiiffi"; + repo = "mcrcon"; + rev = "v${version}"; + sha256 = "1pwr1cjldjy8bxqpp7w03nvdpw8l4vqfnk6w6b3mf0qpap1k700z"; + }; + + buildPhase = '' + $CC mcrcon.c -o mcrcon + ''; + + installPhase = '' + install -Dm 755 mcrcon $out/bin/mcrcon + ''; + + meta = { + homepage = https://bukkit.org/threads/admin-rcon-mcrcon-remote-connection-client-for-minecraft-servers.70910/; + description = "Minecraft console client with Bukkit coloring support."; + longDescription = '' + Mcrcon is a powerful Minecraft RCON terminal client with Bukkit coloring support. + It is well suited for remote administration and to be used as part of automated server maintenance scripts. + It does not trigger "IO: Broken pipe" or "IO: Connection reset" spam bugs on the server side. + ''; + maintainers = with stdenv.lib.maintainers; [ dermetfan ]; + license = with stdenv.lib.licenses; [ zlib libpng ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 11e0e16fe47..6d7f5adae99 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1689,6 +1689,8 @@ with pkgs; eid-viewer = callPackage ../tools/security/eid-viewer { }; + mcrcon = callPackage ../tools/networking/mcrcon {}; + ### DEVELOPMENT / EMSCRIPTEN buildEmscriptenPackage = callPackage ../development/em-modules/generic { }; From a49eb2f3b8fa9adb2b6d80fe279f4f6b6cd10740 Mon Sep 17 00:00:00 2001 From: Marius Bergmann Date: Mon, 29 May 2017 23:53:49 +0200 Subject: [PATCH 27/47] restic: 0.5.0 -> 0.6.0 --- pkgs/tools/backup/restic/default.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/backup/restic/default.nix b/pkgs/tools/backup/restic/default.nix index b816aac99a1..92821290667 100644 --- a/pkgs/tools/backup/restic/default.nix +++ b/pkgs/tools/backup/restic/default.nix @@ -2,7 +2,7 @@ buildGoPackage rec { name = "restic-${version}"; - version = "0.5.0"; + version = "0.6.0"; goPackagePath = "github.com/restic/restic"; @@ -10,7 +10,7 @@ buildGoPackage rec { owner = "restic"; repo = "restic"; rev = "v${version}"; - sha256 = "0dj6zg4b00pwgs6nj7w5s0jxm6cfavd9kdcq0z4spypwdf211cgl"; + sha256 = "0kjk8fyfmbnh2jayfjq4ggkc99rh02jkv8gvqcpyqnw3dxznwrk2"; }; buildPhase = '' @@ -28,5 +28,6 @@ buildGoPackage rec { description = "A backup program that is fast, efficient and secure"; platforms = platforms.linux; license = licenses.bsd2; + maintainers = [ maintainers.mbrgm ]; }; } From 20e756a0936fb75ce8f9d9ef0b7a511198bf7eea Mon Sep 17 00:00:00 2001 From: John Ericson Date: Tue, 23 May 2017 18:04:15 -0400 Subject: [PATCH 28/47] lib: Consolidate platform configurations (used for crossSystem) This is good for maintenance and education. --- doc/cross-compilation.xml | 52 +++++-- lib/systems/default.nix | 1 + lib/systems/examples.nix | 130 ++++++++++++++++++ lib/systems/platforms.nix | 9 +- .../linux/make-bootstrap-tools-cross.nix | 92 ++----------- pkgs/top-level/release-cross.nix | 89 +----------- 6 files changed, 200 insertions(+), 173 deletions(-) create mode 100644 lib/systems/examples.nix diff --git a/doc/cross-compilation.xml b/doc/cross-compilation.xml index de1b9b80d30..e99e90bac9c 100644 --- a/doc/cross-compilation.xml +++ b/doc/cross-compilation.xml @@ -85,7 +85,8 @@ This field is obsolete and will soon disappear—please do not use it. - The exact scheme these fields is a bit ill-defined due to a long and convoluted evolution, but this is slowly being cleaned up. + The exact schema these fields follow is a bit ill-defined due to a long and convoluted evolution, but this is slowly being cleaned up. + You can see examples of ones used in practice in lib.systems.examples; note how they are not all very consistent. For now, here are few fields can count on them containing: @@ -118,8 +119,27 @@ This is a nix representation of a parsed LLVM target triple with white-listed components. This can be specified directly, or actually parsed from the config. [Technically, only one need be specified and the others can be inferred, though the precision of inference may not be very good.] - See lib.systems.parse for the exact representation, along with some is*predicates. - These predicates are superior to the ones in stdenv as they aren't tied to the build platform (host, as previously discussed, would be a saner default). + See lib.systems.parse for the exact representation. + + + + + libc + + + This is a string identifying the standard C library used. + Valid identifiers include "glibc" for GNU libc, "libsystem" for Darwin's Libsystem, and "uclibc" for µClibc. + It should probably be refactored to use the module system, like parse. + + + + + is* + + + These predicates are defined in lib.systems.inspect, and slapped on every platform. + They are superior to the ones in stdenv as they force the user to be explicit about which platform they are inspecting. + Please use these instead of those. @@ -128,7 +148,7 @@ This is, quite frankly, a dumping ground of ad-hoc settings (it's an attribute set). - See lib.systems.platforms for examples—there's hopefully one in there that will work verbatim for each platform one is working. + See lib.systems.platforms for examples—there's hopefully one in there that will work verbatim for each platform that is working. Please help us triage these flags and give them better homes! @@ -184,11 +204,27 @@ More information needs to moved from the old wiki, especially , for this section. - Many sources (manual, wiki, etc) probably mention passing system, platform, and, optionally, crossSystem to nixpkgs: - import <nixpkgs> { system = ..; platform = ..; crossSystem = ..; }. - system and platform together determine the system on which packages are built, and crossSystem specifies the platform on which packages are ultimately intended to run, if it is different. - This still works, but with more recent changes, one can alternatively pass localSystem, containing system and platform, for symmetry. + Nixpkgs can be instantiated with localSystem alone, in which case there is no cross compiling and everything is built by and for that system, + or also with crossSystem, in which case packages run on the latter, but all building happens on the former. + Both parameters take the same schema as the 3 (build, host, and target) platforms defined in the previous section. + As mentioned above, lib.systems.examples has some platforms which are used as arguments for these parameters in practice. + You can use them programmatically, or on the command line like nix-build <nixpkgs> --arg crossSystem '(import <nixpkgs/lib>).systems.examples.fooBarBaz'. + + While one is free to pass both parameters in full, there's a lot of logic to fill in missing fields. + As discussed in the previous section, only one of system, config, and parsed is needed to infer the other two. + Additionally, libc will be inferred from parse. + Finally, localSystem.system is also impurely inferred based on the platform evaluation occurs. + This means it is often not necessary to pass localSystem at all, as in the command-line example in the previous paragraph. + + + + Many sources (manual, wiki, etc) probably mention passing system, platform, along with the optional crossSystem to nixpkgs: + import <nixpkgs> { system = ..; platform = ..; crossSystem = ..; }. + Passing those two instead of localSystem is still supported for compatibility, but is discouraged. + Indeed, much of the inference we do for these parameters is motivated by compatibility as much as convenience. + + One would think that localSystem and crossSystem overlap horribly with the three *Platforms (buildPlatform, hostPlatform, and targetPlatform; see stage.nix or the manual). Actually, those identifiers are purposefully not used here to draw a subtle but important distinction: diff --git a/lib/systems/default.nix b/lib/systems/default.nix index c37b6be2523..c22c9956196 100644 --- a/lib/systems/default.nix +++ b/lib/systems/default.nix @@ -5,6 +5,7 @@ rec { parse = import ./parse.nix; inspect = import ./inspect.nix; platforms = import ./platforms.nix; + examples = import ./examples.nix; # Elaborate a `localSystem` or `crossSystem` so that it contains everything # necessary. diff --git a/lib/systems/examples.nix b/lib/systems/examples.nix new file mode 100644 index 00000000000..da9b95a6454 --- /dev/null +++ b/lib/systems/examples.nix @@ -0,0 +1,130 @@ +# These can be passed to nixpkgs as either the `localSystem` or +# `crossSystem`. They are put here for user convenience, but also used by cross +# tests and linux cross stdenv building, so handle with care! + +let platforms = import ./platforms.nix; in + +rec { + # + # Linux + # + + sheevaplug = rec { + config = "armv5te-unknown-linux-gnueabi"; + bigEndian = false; + arch = "armv5te"; + float = "soft"; + withTLS = true; + libc = "glibc"; + platform = platforms.sheevaplug; + openssl.system = "linux-generic32"; + inherit (platform) gcc; + }; + + raspberryPi = rec { + config = "armv6l-unknown-linux-gnueabihf"; + bigEndian = false; + arch = "armv6l"; + float = "hard"; + fpu = "vfp"; + withTLS = true; + libc = "glibc"; + platform = platforms.raspberrypi; + openssl.system = "linux-generic32"; + inherit (platform) gcc; + }; + + armv7l-hf-multiplatform = rec { + config = "arm-unknown-linux-gnueabihf"; + bigEndian = false; + arch = "armv7-a"; + float = "hard"; + fpu = "vfpv3-d16"; + withTLS = true; + libc = "glibc"; + platform = platforms.armv7l-hf-multiplatform; + openssl.system = "linux-generic32"; + inherit (platform) gcc; + }; + + aarch64-multiplatform = rec { + config = "aarch64-unknown-linux-gnu"; + bigEndian = false; + arch = "aarch64"; + withTLS = true; + libc = "glibc"; + platform = platforms.aarch64-multiplatform; + inherit (platform) gcc; + }; + + scaleway-c1 = armv7l-hf-multiplatform // rec { + platform = platforms.scaleway-c1; + inherit (platform) gcc; + inherit (gcc) fpu; + }; + + pogoplug4 = rec { + arch = "armv5tel"; + config = "armv5tel-softfloat-linux-gnueabi"; + float = "soft"; + + platform = platforms.pogoplug4; + + inherit (platform) gcc; + libc = "glibc"; + + withTLS = true; + openssl.system = "linux-generic32"; + }; + + fuloongminipc = rec { + config = "mips64el-unknown-linux-gnu"; + bigEndian = false; + arch = "mips"; + float = "hard"; + withTLS = true; + libc = "glibc"; + platform = platforms.fuloong2f_n32; + openssl.system = "linux-generic32"; + inherit (platform) gcc; + }; + + # + # Darwin + # + + iphone64 = { + config = "aarch64-apple-darwin14"; + arch = "arm64"; + libc = "libsystem"; + platform = {}; + }; + + iphone32 = { + config = "arm-apple-darwin10"; + arch = "armv7-a"; + libc = "libsystem"; + platform = {}; + }; + + # + # Windows + # + + # 32 bit mingw-w64 + mingw32 = { + config = "i686-pc-mingw32"; + arch = "x86"; # Irrelevant + libc = "msvcrt"; # This distinguishes the mingw (non posix) toolchain + platform = {}; + }; + + # 64 bit mingw-w64 + mingwW64 = { + # That's the triplet they use in the mingw-w64 docs. + config = "x86_64-pc-mingw32"; + arch = "x86_64"; # Irrelevant + libc = "msvcrt"; # This distinguishes the mingw (non posix) toolchain + platform = {}; + }; +} diff --git a/lib/systems/platforms.nix b/lib/systems/platforms.nix index 0bea38ab419..ae4fc355c71 100644 --- a/lib/systems/platforms.nix +++ b/lib/systems/platforms.nix @@ -255,6 +255,10 @@ rec { arch = "armv6"; fpu = "vfp"; float = "hard"; + # TODO(@Ericson2314) what is this and is it a good idea? It was + # used in some cross compilation examples but not others. + # + # abi = "aapcs-linux"; }; }; @@ -460,7 +464,10 @@ rec { ''; kernelTarget = "vmlinux"; uboot = null; - gcc.arch = "loongson2f"; + gcc = { + arch = "loongson2f"; + abi = "n32"; + }; }; beaglebone = armv7l-hf-multiplatform // { diff --git a/pkgs/stdenv/linux/make-bootstrap-tools-cross.nix b/pkgs/stdenv/linux/make-bootstrap-tools-cross.nix index 50fd563e7c2..0378891b27a 100644 --- a/pkgs/stdenv/linux/make-bootstrap-tools-cross.nix +++ b/pkgs/stdenv/linux/make-bootstrap-tools-cross.nix @@ -6,91 +6,19 @@ let lib = import ../../../lib; pkgsFun = import ../../..; - sheevaplugCrossSystem = { - crossSystem = rec { - config = "arm-linux-gnueabi"; - bigEndian = false; - arch = "armv5te"; - float = "soft"; - withTLS = true; - libc = "glibc"; - platform = lib.systems.platforms.sheevaplug; - openssl.system = "linux-generic32"; - inherit (platform) gcc; - }; - }; - - raspberrypiCrossSystem = { - crossSystem = rec { - config = "arm-linux-gnueabihf"; - bigEndian = false; - arch = "armv6"; - float = "hard"; - fpu = "vfp"; - withTLS = true; - libc = "glibc"; - platform = lib.systems.platforms.raspberrypi; - openssl.system = "linux-generic32"; - inherit (platform) gcc; - }; - }; - - armv7l-hf-multiplatform-crossSystem = { - crossSystem = rec { - config = "arm-linux-gnueabihf"; - bigEndian = false; - arch = "armv7-a"; - float = "hard"; - fpu = "vfpv3-d16"; - withTLS = true; - libc = "glibc"; - platform = lib.systems.platforms.armv7l-hf-multiplatform; - openssl.system = "linux-generic32"; - inherit (platform) gcc; - }; - }; - - aarch64-multiplatform-crossSystem = { - crossSystem = rec { - config = "aarch64-linux-gnu"; - bigEndian = false; - arch = "aarch64"; - withTLS = true; - libc = "glibc"; - platform = lib.systems.platforms.aarch64-multiplatform; - inherit (platform) gcc; - }; - }; - - scaleway-c1-crossSystem.crossSystem = armv7l-hf-multiplatform-crossSystem.crossSystem // rec { - platform = lib.systems.platforms.scaleway-c1; - inherit (platform) gcc; - inherit (gcc) fpu; - }; - - pogoplug4-crossSystem.crossSystem = { - arch = "armv5tel"; - config = "armv5tel-softfloat-linux-gnueabi"; - float = "soft"; - - platform = lib.systems.platforms.pogoplug4; - - inherit (lib.systems.platforms.pogoplug4) gcc; - libc = "glibc"; - - withTLS = true; - openssl.system = "linux-generic32"; - }; + inherit (lib.systems.examples) + sheevaplug raspberryPi armv7l-hf-multiplatform + aarch64-multiplatform scaleway-c1 pogoplug4; selectedCrossSystem = - if toolsArch == "armv5tel" then sheevaplugCrossSystem else - if toolsArch == "scaleway" then scaleway-c1-crossSystem else - if toolsArch == "pogoplug4" then pogoplug4-crossSystem else - if toolsArch == "armv6l" then raspberrypiCrossSystem else - if toolsArch == "armv7l" then armv7l-hf-multiplatform-crossSystem else - if toolsArch == "aarch64" then aarch64-multiplatform-crossSystem else null; + if toolsArch == "armv5tel" then sheevaplug else + if toolsArch == "scaleway" then scaleway-c1 else + if toolsArch == "pogoplug4" then pogoplug4 else + if toolsArch == "armv6l" then raspberryPi else + if toolsArch == "armv7l" then armv7l-hf-multiplatform else + if toolsArch == "aarch64" then aarch64-multiplatform else null; - pkgs = pkgsFun ({inherit system;} // selectedCrossSystem); + pkgs = pkgsFun ({ inherit system; crossSystem = selectedCrossSystem; }); glibc = pkgs.libcCross; bash = pkgs.bash; diff --git a/pkgs/top-level/release-cross.nix b/pkgs/top-level/release-cross.nix index c81d65ad0e0..94c1e6c7ad2 100644 --- a/pkgs/top-level/release-cross.nix +++ b/pkgs/top-level/release-cross.nix @@ -89,101 +89,26 @@ in guile = nativePlatforms; }; - darwinToAarch64 = let - crossSystem = { - config = "aarch64-apple-darwin14"; - arch = "arm64"; - libc = "libSystem"; - }; - in mapTestOnCross crossSystem darwinCommon; + crossIphone64 = mapTestOnCross lib.systems.examples.iphone64 darwinCommon; - darwinToArm = let - crossSystem = { - config = "arm-apple-darwin10"; - arch = "armv7-a"; - libc = "libSystem"; - }; - in mapTestOnCross crossSystem darwinCommon; + crossIphone32 = mapTestOnCross lib.systems.examples.iphone32 darwinCommon; /* Test some cross builds to the Sheevaplug */ - crossSheevaplugLinux = let - crossSystem = { - config = "armv5tel-unknown-linux-gnueabi"; - bigEndian = false; - arch = "arm"; - float = "soft"; - withTLS = true; - platform = lib.systems.platforms.sheevaplug; - libc = "glibc"; - openssl.system = "linux-generic32"; - }; - in mapTestOnCross crossSystem (linuxCommon // { + crossSheevaplugLinux = mapTestOnCross lib.systems.examples.sheevaplug (linuxCommon // { ubootSheevaplug = nativePlatforms; }); - /* Test some cross builds on 32 bit mingw-w64 */ - crossMingw32 = let - crossSystem = { - config = "i686-pc-mingw32"; - arch = "x86"; # Irrelevant - libc = "msvcrt"; # This distinguishes the mingw (non posix) toolchain - platform = {}; - }; - in mapTestOnCross crossSystem windowsCommon; - + crossMingw32 = mapTestOnCross lib.systems.examples.mingw32 windowsCommon; /* Test some cross builds on 64 bit mingw-w64 */ - crossMingwW64 = let - crossSystem = { - # That's the triplet they use in the mingw-w64 docs. - config = "x86_64-pc-mingw32"; - arch = "x86_64"; # Irrelevant - libc = "msvcrt"; # This distinguishes the mingw (non posix) toolchain - platform = {}; - }; - in mapTestOnCross crossSystem windowsCommon; - + crossMingwW64 = mapTestOnCross lib.systems.examples.mingwW64 windowsCommon; /* Linux on the fuloong */ - fuloongminipc = let - crossSystem = { - config = "mips64el-unknown-linux-gnu"; - bigEndian = false; - arch = "mips"; - float = "hard"; - withTLS = true; - libc = "glibc"; - platform = lib.systems.platforms.fuloong2f_n32; - openssl.system = "linux-generic32"; - gcc = { - arch = "loongson2f"; - abi = "n32"; - }; - }; - in mapTestOnCross crossSystem linuxCommon; - + fuloongminipc = mapTestOnCross lib.systems.examples.fuloongminipc linuxCommon; /* Linux on Raspberrypi */ - rpi = let - crossSystem = { - config = "armv6l-unknown-linux-gnueabi"; - bigEndian = false; - arch = "arm"; - float = "hard"; - fpu = "vfp"; - withTLS = true; - libc = "glibc"; - platform = lib.systems.platforms.raspberrypi; - openssl.system = "linux-generic32"; - gcc = { - arch = "armv6"; - fpu = "vfp"; - float = "softfp"; - abi = "aapcs-linux"; - }; - }; - in mapTestOnCross crossSystem (linuxCommon // { + rpi = mapTestOnCross lib.systems.examples.raspberryPi (linuxCommon // { vim = nativePlatforms; unzip = nativePlatforms; ddrescue = nativePlatforms; From 2b0a8427e6995eefddf09919ad48a7887e999965 Mon Sep 17 00:00:00 2001 From: Profpatsch Date: Tue, 30 May 2017 01:20:37 +0200 Subject: [PATCH 29/47] lib/string: make `isStorePath` total (#26216) fix #9278 --- lib/strings.nix | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/strings.nix b/lib/strings.nix index d48624257cf..1cc633c729d 100644 --- a/lib/strings.nix +++ b/lib/strings.nix @@ -438,8 +438,13 @@ rec { => true isStorePath pkgs.python => true + isStorePath [] || isStorePath 42 || isStorePath {} || … + => false */ - isStorePath = x: builtins.substring 0 1 (toString x) == "/" && dirOf (builtins.toPath x) == builtins.storeDir; + isStorePath = x: + builtins.isString x + && builtins.substring 0 1 (toString x) == "/" + && dirOf (builtins.toPath x) == builtins.storeDir; /* Convert string to int Obviously, it is a bit hacky to use fromJSON that way. From c66ff8ec3ce37a01659294efc36c4ab5e3036462 Mon Sep 17 00:00:00 2001 From: John Ericson Date: Mon, 29 May 2017 20:12:06 -0400 Subject: [PATCH 30/47] cross tests and stdenv: armv5te*l* of sheevaplug explicit The "l" suffix presumably indicates it is little-endian, which it is. --- lib/systems/examples.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/systems/examples.nix b/lib/systems/examples.nix index da9b95a6454..3ffaf393435 100644 --- a/lib/systems/examples.nix +++ b/lib/systems/examples.nix @@ -10,9 +10,9 @@ rec { # sheevaplug = rec { - config = "armv5te-unknown-linux-gnueabi"; + config = "armv5tel-unknown-linux-gnueabi"; bigEndian = false; - arch = "armv5te"; + arch = "armv5tel"; float = "soft"; withTLS = true; libc = "glibc"; From eb2994a0d5541d591cd4fc2435b978b00b19bc46 Mon Sep 17 00:00:00 2001 From: Josef Kemetmueller Date: Tue, 30 May 2017 02:14:46 +0200 Subject: [PATCH 31/47] pandas: Fix build on darwin Since the commands "locale", "pbpaste" and "pbcopy" are not in nixpkgs, as they are impure darwin dependencies, we currently cannot get the clipboard and locale functionality to work properly. We disable the tests "test_locale" and "test_clipboard" on darwin, so we get a mostly working pandas. Additionally to disabling the test via py.test, we also need to provide fake pbpaste/pbcopy commands, so py.test won't fail during the collection phase. This closes #25417 and closes #11623. --- .../python-modules/pandas/default.nix | 23 +++++++++++-------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/pandas/default.nix b/pkgs/development/python-modules/pandas/default.nix index 103907c26d1..0d3a2d2dd5c 100644 --- a/pkgs/development/python-modules/pandas/default.nix +++ b/pkgs/development/python-modules/pandas/default.nix @@ -19,7 +19,6 @@ , openpyxl , tables , xlwt -, darwin ? {} , libcxx ? null }: @@ -53,7 +52,7 @@ in buildPythonPackage rec { openpyxl tables xlwt - ] ++ optional isDarwin darwin.locale; # provides the locale command + ]; # For OSX, we need to add a dependency on libcxx, which provides # `complex.h` and other libraries that pandas depends on to build. @@ -63,16 +62,22 @@ in buildPythonPackage rec { substituteInPlace setup.py \ --replace "['pandas/src/klib', 'pandas/src']" \ "['pandas/src/klib', 'pandas/src', '$cpp_sdk']" - - # disable clipboard tests since pbcopy/pbpaste are not open source - substituteInPlace pandas/io/tests/test_clipboard.py \ - --replace pandas.util.clipboard no_such_module \ - --replace OSError ImportError ''; checkPhase = '' runHook preCheck - py.test $out/${python.sitePackages}/pandas --skip-slow --skip-network + '' + # TODO: Get locale and clipboard support working on darwin. + # Until then we disable the tests. + + optionalString isDarwin '' + # Fake the impure dependencies pbpaste and pbcopy + echo "#!/bin/sh" > pbcopy + echo "#!/bin/sh" > pbpaste + chmod a+x pbcopy pbpaste + export PATH=$(pwd):$PATH + '' + '' + py.test $out/${python.sitePackages}/pandas --skip-slow --skip-network \ + ${if isDarwin then "-k 'not test_locale and not test_clipboard'" else ""} runHook postCheck ''; @@ -83,7 +88,7 @@ in buildPythonPackage rec { homepage = "http://pandas.pydata.org/"; description = "Python Data Analysis Library"; license = stdenv.lib.licenses.bsd3; - maintainers = with stdenv.lib.maintainers; [ raskin fridh ]; + maintainers = with stdenv.lib.maintainers; [ raskin fridh knedlsepp ]; platforms = stdenv.lib.platforms.unix; }; } From 79830172b5cad4d44123f58f822a64ca5a264cfd Mon Sep 17 00:00:00 2001 From: Fernando J Pando Date: Mon, 29 May 2017 20:44:27 -0400 Subject: [PATCH 32/47] txaio: 2.7.1 fixes - uses fetchpypi - fixes broken test - tested nixos python 27/34 --- .../python-modules/txaio/default.nix | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/txaio/default.nix b/pkgs/development/python-modules/txaio/default.nix index 36291518605..68cb28dc850 100644 --- a/pkgs/development/python-modules/txaio/default.nix +++ b/pkgs/development/python-modules/txaio/default.nix @@ -1,23 +1,27 @@ -{ stdenv, buildPythonPackage, fetchurl, - pytest, mock, six, twisted -}: +{ stdenv, buildPythonPackage, fetchPypi, pytest, mock, six, twisted }: + buildPythonPackage rec { name = "${pname}-${version}"; pname = "txaio"; version = "2.7.1"; + src = fetchPypi { + inherit pname version; + sha256 = "1lmllmjjsqzl3w4faq2qhlgkaqn1yn1m7d99k822ib7qgz18bsly"; + }; + buildInputs = [ pytest mock ]; + propagatedBuildInputs = [ six twisted ]; + patchPhase = '' + sed -i '152d' test/test_logging.py + ''; + checkPhase = '' py.test -k "not test_sdist" ''; - src = fetchurl { - url = "mirror://pypi/t/${pname}/${name}.tar.gz"; - sha256 = "9eea85c27ff8ac28049a29b55383f5c162351f855860e5081ff4632d65a5b4d2"; - }; - meta = with stdenv.lib; { description = "Utilities to support code that runs unmodified on Twisted and asyncio."; homepage = "https://github.com/crossbario/txaio"; From 47e86655950d868f514bb06dd6c1111578fc74e5 Mon Sep 17 00:00:00 2001 From: Maximilian Bosch Date: Tue, 30 May 2017 06:35:33 +0200 Subject: [PATCH 33/47] geogebra: 5-0-355-0 -> 5-0-361-0 --- pkgs/applications/science/math/geogebra/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/science/math/geogebra/default.nix b/pkgs/applications/science/math/geogebra/default.nix index bc766b96bca..2712388ffe7 100644 --- a/pkgs/applications/science/math/geogebra/default.nix +++ b/pkgs/applications/science/math/geogebra/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { name = "geogebra-${version}"; - version = "5-0-355-0"; + version = "5-0-361-0"; preferLocalBuild = true; src = fetchurl { url = "http://download.geogebra.org/installers/5.0/GeoGebra-Linux-Portable-${version}.tar.bz2"; - sha256 = "0gm6jqlc3kgnbwnqlz6i9rahdy802jq7xc9gw1q5ynk63smm3ngk"; + sha256 = "14kidnk8bidklv474zqipv3f77qnfmc697pl407v0rja481c649a"; }; srcIcon = fetchurl { From a987943fdf023bf001dda04fe5a51f817a5743e0 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Tue, 30 May 2017 06:35:05 +0000 Subject: [PATCH 34/47] ditaa: more general platform --- pkgs/tools/graphics/ditaa/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/tools/graphics/ditaa/default.nix b/pkgs/tools/graphics/ditaa/default.nix index 86ff9ec8fae..56c1c976362 100644 --- a/pkgs/tools/graphics/ditaa/default.nix +++ b/pkgs/tools/graphics/ditaa/default.nix @@ -35,7 +35,7 @@ stdenv.mkDerivation rec { description = "Convert ascii art diagrams into proper bitmap graphics"; homepage = http://ditaa.sourceforge.net/; license = licenses.gpl2; - platforms = platforms.linux; + platforms = platforms.unix; maintainers = [ maintainers.bjornfor ]; }; } From 4f6422b76cab823554e481f40c8fb831a0808e98 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Tue, 30 May 2017 06:54:56 +0000 Subject: [PATCH 35/47] unison: more general platform --- pkgs/applications/networking/sync/unison/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/applications/networking/sync/unison/default.nix b/pkgs/applications/networking/sync/unison/default.nix index 2daa846990a..ed48bce7b2e 100644 --- a/pkgs/applications/networking/sync/unison/default.nix +++ b/pkgs/applications/networking/sync/unison/default.nix @@ -36,7 +36,7 @@ stdenv.mkDerivation (rec { description = "Bidirectional file synchronizer"; license = stdenv.lib.licenses.gpl3Plus; maintainers = with stdenv.lib.maintainers; [viric]; - platforms = with stdenv.lib.platforms; linux; + platforms = with stdenv.lib.platforms; unix; }; }) From 1fdf42d4612b6872a2625b3ba2f8750263281312 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Bernardy Date: Mon, 29 May 2017 19:24:34 +0200 Subject: [PATCH 36/47] pythonPackages.tensorflow: Don't change the rpath to point to gcc4.9 When using cuda, the rpath was set to include GCC lib version 4.9. I am not sure what this was attempting to do, but an effect was to prevent certain python libraries to find the correct (newer) version of the std lib. Also avoid mentions of any specifc version in the propagatedBuildInputs --- pkgs/development/python-modules/tensorflow/default.nix | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/tensorflow/default.nix b/pkgs/development/python-modules/tensorflow/default.nix index 8946877eb14..388d27e0686 100644 --- a/pkgs/development/python-modules/tensorflow/default.nix +++ b/pkgs/development/python-modules/tensorflow/default.nix @@ -5,7 +5,6 @@ , cudaSupport ? false , cudatoolkit ? null , cudnn ? null -, gcc49 ? null , linuxPackages ? null , numpy , six @@ -13,13 +12,11 @@ , swig , werkzeug , mock -, gcc , zlib }: assert cudaSupport -> cudatoolkit != null && cudnn != null - && gcc49 != null && linuxPackages != null; # unsupported combination @@ -98,7 +95,7 @@ buildPythonPackage rec { propagatedBuildInputs = with stdenv.lib; [ numpy six protobuf3_2 swig werkzeug mock ] - ++ optionals cudaSupport [ cudatoolkit cudnn gcc49 ]; + ++ optionals cudaSupport [ cudatoolkit cudnn stdenv.cc ]; # Note that we need to run *after* the fixup phase because the # libraries are loaded at runtime. If we run in preFixup then @@ -106,10 +103,10 @@ buildPythonPackage rec { postFixup = let rpath = stdenv.lib.makeLibraryPath (if cudaSupport then - [ gcc49.cc.lib zlib cudatoolkit cudnn + [ stdenv.cc.cc.lib zlib cudatoolkit cudnn linuxPackages.nvidia_x11 ] else - [ gcc.cc.lib zlib ] + [ stdenv.cc.cc.lib zlib ] ); in '' From 4730b8ba05d2f9a71168f6196a0ccb5a1641ce38 Mon Sep 17 00:00:00 2001 From: Mikhail Volkhov Date: Tue, 30 May 2017 13:05:01 +0300 Subject: [PATCH 37/47] scudcloud: 1.54 -> 1.58 --- .../instant-messengers/scudcloud/default.nix | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/scudcloud/default.nix b/pkgs/applications/networking/instant-messengers/scudcloud/default.nix index d9a3dfc690d..9d2de536dbf 100644 --- a/pkgs/applications/networking/instant-messengers/scudcloud/default.nix +++ b/pkgs/applications/networking/instant-messengers/scudcloud/default.nix @@ -1,14 +1,12 @@ -{ stdenv, fetchgit, python3Packages }: +{ stdenv, fetchurl, python3Packages }: -python3Packages.buildPythonPackage { - name = "scudcloud-1.44"; +let version = "1.58"; +in python3Packages.buildPythonPackage { + name = "scudcloud-${version}"; - # Branch 254-port-to-qt5 - # https://github.com/raelgc/scudcloud/commit/65c304416dfdd5f456fa6f7301432a953d5e12d0 - src = fetchgit { - url = https://github.com/raelgc/scudcloud/; - rev = "65c304416dfdd5f456fa6f7301432a953d5e12d0"; - sha256 = "0h1055y88kldqw31ayqfx9zsksgxsyqd8h0hwnhj80yn3jcx0rp6"; + src = fetchurl { + url = "https://github.com/raelgc/scudcloud/archive/v${version}.tar.gz"; + sha256 = "1j84qdc2j3dvl1nhrjqm0blc8ww723p9a6hqprkkp8alw77myq1l"; }; propagatedBuildInputs = with python3Packages; [ pyqt5 dbus-python ]; From 94be2db902109537ac1e3e1e17221141d3c4f799 Mon Sep 17 00:00:00 2001 From: Pascal Wittmann Date: Tue, 30 May 2017 13:24:51 +0200 Subject: [PATCH 38/47] libfilezilla: 0.9.1 -> 0.9.2 --- pkgs/development/libraries/libfilezilla/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/libfilezilla/default.nix b/pkgs/development/libraries/libfilezilla/default.nix index d6c0c538a8f..b0f1046aa59 100644 --- a/pkgs/development/libraries/libfilezilla/default.nix +++ b/pkgs/development/libraries/libfilezilla/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { name = "libfilezilla-${version}"; - version = "0.9.1"; + version = "0.9.2"; src = fetchurl { url = "http://download.filezilla-project.org/libfilezilla/${name}.tar.bz2"; - sha256 = "06ivj40bk5b76a36zwhnwqvg564hgccncnn5nb5cqc7kf4bkkchq"; + sha256 = "1qrvddjqz5jv6920gcfqsrsjksi2845hn96g0z3vpcsm6nifhqn1"; }; meta = with stdenv.lib; { From b73fd0c5627cb5bb387669957726c857e58f5fe2 Mon Sep 17 00:00:00 2001 From: Pascal Wittmann Date: Tue, 30 May 2017 13:36:07 +0200 Subject: [PATCH 39/47] global: 6.5.6 -> 6.5.7 --- pkgs/development/tools/misc/global/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/tools/misc/global/default.nix b/pkgs/development/tools/misc/global/default.nix index 62d96b2158f..f55130ae104 100644 --- a/pkgs/development/tools/misc/global/default.nix +++ b/pkgs/development/tools/misc/global/default.nix @@ -4,11 +4,11 @@ stdenv.mkDerivation rec { name = "global-${version}"; - version = "6.5.6"; + version = "6.5.7"; src = fetchurl { url = "mirror://gnu/global/${name}.tar.gz"; - sha256 = "018m536k5y6lks1a6gqn3bsp7r8zk017znqj9kva1nm8d7x9lbqj"; + sha256 = "0cnd7a7d1pl46yk15q6mnr9i9w3xi8pxgchw4ia9njgr4jjqzh6r"; }; nativeBuildInputs = [ libtool makeWrapper ]; From a1c15989aa8363a80f32123ea0030ecef68576a9 Mon Sep 17 00:00:00 2001 From: Robert Scott Date: Tue, 30 May 2017 12:39:20 +0100 Subject: [PATCH 40/47] python.pkgs.flask_migrate: 1.7.0 -> 2.0.3 fixes build against new dependencies after some test tinkering, seems we can remove the python3-patching as there exists a "python" symlink now --- .../python-modules/flask-migrate/default.nix | 29 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 25 +--------------- 2 files changed, 30 insertions(+), 24 deletions(-) create mode 100644 pkgs/development/python-modules/flask-migrate/default.nix diff --git a/pkgs/development/python-modules/flask-migrate/default.nix b/pkgs/development/python-modules/flask-migrate/default.nix new file mode 100644 index 00000000000..26fbed4ca5e --- /dev/null +++ b/pkgs/development/python-modules/flask-migrate/default.nix @@ -0,0 +1,29 @@ +{ stdenv, buildPythonPackage, fetchPypi, isPy3k, python, glibcLocales, flask, flask_sqlalchemy, flask_script, alembic +}: + +with stdenv.lib; + +buildPythonPackage rec { + pname = "Flask-Migrate"; + version = "2.0.3"; + name = "${pname}-${version}"; + + src = fetchPypi { + inherit pname version; + sha256 = "107x78lkqsnbg92dld3dkagg07jvchp3ib3y0sivc4ipz6n1y7rk"; + }; + + checkInputs = optional isPy3k glibcLocales; + propagatedBuildInputs = [ flask flask_sqlalchemy flask_script alembic ]; + + # tests invoke the flask cli which uses click and therefore has py3k encoding troubles + preCheck = optionalString isPy3k '' + export LANG="en_US.UTF-8" + ''; + + meta = { + description = "SQLAlchemy database migrations for Flask applications using Alembic"; + license = licenses.mit; + homepage = https://github.com/miguelgrinberg/Flask-Migrate; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index aae6e2f743c..e9f2f0f19d2 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -11020,30 +11020,7 @@ in { flask_ldap_login = callPackage ../development/python-modules/flask-ldap-login.nix { }; - flask_migrate = buildPythonPackage rec { - name = "Flask-Migrate-${version}"; - version = "1.7.0"; - - src = pkgs.fetchurl { - url = "mirror://pypi/F/Flask-Migrate/Flask-Migrate-1.7.0.tar.gz"; - sha256 = "16d7vnaj9xmxvb3qbcmhahm3ldfdhzzi6y221h62x4v1v1jayx7v"; - }; - - # When tests run with python3*, tests should run commands as "python3 ", - # not "python " - patchPhase = '' - substituteInPlace tests/test_migrate.py --replace "python" "${python.executable}" - substituteInPlace tests/test_multidb_migrate.py --replace "python" "${python.executable}" - ''; - - propagatedBuildInputs = with self ; [ flask flask_sqlalchemy flask_script alembic ]; - - meta = { - description = "SQLAlchemy database migrations for Flask applications using Alembic"; - license = licenses.mit; - homepage = https://github.com/miguelgrinberg/Flask-Migrate; - }; - }; + flask_migrate = callPackage ../development/python-modules/flask-migrate { }; flask_oauthlib = callPackage ../development/python-modules/flask-oauthlib.nix { }; From 9f3c2bc8390b9e4f6f2b4cb37f08bb74fca83e27 Mon Sep 17 00:00:00 2001 From: Kranium Gikos Mendoza Date: Wed, 31 May 2017 00:25:50 +1000 Subject: [PATCH 41/47] gpxsee: 4.3 -> 4.8 --- pkgs/applications/misc/gpxsee/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/misc/gpxsee/default.nix b/pkgs/applications/misc/gpxsee/default.nix index 5b977d13796..42fc1e46e33 100644 --- a/pkgs/applications/misc/gpxsee/default.nix +++ b/pkgs/applications/misc/gpxsee/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { name = "gpxsee-${version}"; - version = "4.3"; + version = "4.8"; src = fetchFromGitHub { owner = "tumic0"; repo = "GPXSee"; rev = version; - sha256 = "15f686frxlrmdvh5cc837kx62g0ihqj4vb87i8433g7l5vqkv3lf"; + sha256 = "17s1v6b1j7pi0yj554bd0cg14bl854gssp5gj2pl51rxji6zr0wp"; }; nativeBuildInputs = [ qmakeHook qttools makeQtWrapper ]; From 1e51fdc2cd77f3f68fe12406de002dd21bdcae01 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edward=20Tj=C3=B6rnhammar?= Date: Tue, 30 May 2017 16:48:20 +0200 Subject: [PATCH 42/47] i2pd: disable AVX instructions --- pkgs/tools/networking/i2pd/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/tools/networking/i2pd/default.nix b/pkgs/tools/networking/i2pd/default.nix index 49c88d817a4..f43fac8215a 100644 --- a/pkgs/tools/networking/i2pd/default.nix +++ b/pkgs/tools/networking/i2pd/default.nix @@ -14,7 +14,7 @@ stdenv.mkDerivation rec { }; buildInputs = [ boost zlib openssl ]; - makeFlags = "USE_AESNI=no"; + makeFlags = [ "USE_AESNI=no" "USE_AVX=no" ]; installPhase = '' install -D i2pd $out/bin/i2pd From 53835c93cb4bc1c6228ee04d6788398a8ab36ab4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edward=20Tj=C3=B6rnhammar?= Date: Tue, 30 May 2017 16:48:35 +0200 Subject: [PATCH 43/47] i2pd: homepage update --- pkgs/tools/networking/i2pd/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/tools/networking/i2pd/default.nix b/pkgs/tools/networking/i2pd/default.nix index f43fac8215a..2f32c3b3a2d 100644 --- a/pkgs/tools/networking/i2pd/default.nix +++ b/pkgs/tools/networking/i2pd/default.nix @@ -21,7 +21,7 @@ stdenv.mkDerivation rec { ''; meta = with stdenv.lib; { - homepage = "https://track.privacysolutions.no/projects/i2pd"; + homepage = "https://i2pd.website"; description = "Minimal I2P router written in C++"; license = licenses.gpl2; maintainers = with maintainers; [ edwtjo ]; From 3c83ce30142426807dd7fdef02e2e404f6ad5d9e Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Tue, 30 May 2017 17:47:00 +0200 Subject: [PATCH 44/47] pythonPackages.pytest-localserver: 0.3.5 -> 0.3.7 (#26238) * pythonPackages.pytest-localserver: 0.3.5 -> 0.3.7 * pythonPackages.pytest-localserver: Change to use python packaging tools * pythonPackages.pytest-localserver: Move to own file --- .../pytest-localserver/default.nix | 33 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 23 +------------ 2 files changed, 34 insertions(+), 22 deletions(-) create mode 100644 pkgs/development/python-modules/pytest-localserver/default.nix diff --git a/pkgs/development/python-modules/pytest-localserver/default.nix b/pkgs/development/python-modules/pytest-localserver/default.nix new file mode 100644 index 00000000000..fdd1986c04f --- /dev/null +++ b/pkgs/development/python-modules/pytest-localserver/default.nix @@ -0,0 +1,33 @@ +{ buildPythonPackage +, lib +, fetchPypi +, requests +, pytest +, six +, werkzeug +}: + +buildPythonPackage rec { + pname = "pytest-localserver"; + name = "${pname}-${version}"; + version = "0.3.7"; + + src = fetchPypi { + inherit pname version; + sha256 = "1c11hn61n06ms0wmw6536vs5k4k9hlndxsb3p170nva56a9dfa6q"; + }; + + propagatedBuildInputs = [ werkzeug ]; + buildInputs = [ pytest six requests ]; + + checkPhase = '' + py.test + ''; + + meta = { + description = "Plugin for the pytest testing framework to test server connections locally"; + homepage = https://pypi.python.org/pypi/pytest-localserver; + license = lib.licenses.mit; + }; +} + diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index e9f2f0f19d2..1f10fac5041 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5281,28 +5281,7 @@ in { pytest_xdist = callPackage ../development/python-modules/pytest-xdist { }; - pytest-localserver = buildPythonPackage rec { - name = "pytest-localserver-${version}"; - version = "0.3.5"; - - src = pkgs.fetchurl { - url = "mirror://pypi/p/pytest-localserver/${name}.tar.gz"; - sha256 = "0dvqspjr6va55zwmnnc2mmpqc7mm65kxig9ya44x1z8aadzxpa4p"; - }; - - propagatedBuildInputs = with self; [ werkzeug ]; - buildInputs = with self; [ pytest six requests ]; - - checkPhase = '' - py.test - ''; - - meta = { - description = "Plugin for the pytest testing framework to test server connections locally"; - homepage = https://pypi.python.org/pypi/pytest-localserver; - license = licenses.mit; - }; - }; + pytest-localserver = callPackage ../development/python-modules/pytest-localserver { }; pytest-subtesthack = buildPythonPackage rec { name = "pytest-subtesthack-${version}"; From 13181204841f151a07d1e75155d24daa641fa0de Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 30 May 2017 18:11:37 +0200 Subject: [PATCH 45/47] Fix indentation --- .../development/interpreters/perl/default.nix | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/pkgs/development/interpreters/perl/default.nix b/pkgs/development/interpreters/perl/default.nix index 3fe04e6bde2..e4aa7db3e28 100644 --- a/pkgs/development/interpreters/perl/default.nix +++ b/pkgs/development/interpreters/perl/default.nix @@ -93,23 +93,23 @@ let passthru.libPrefix = "lib/perl5/site_perl"; - # TODO: it seems like absolute paths to some coreutils is required. - postInstall = - '' - # Remove dependency between "out" and "man" outputs. - rm "$out"/lib/perl5/*/*/.packlist + # TODO: it seems like absolute paths to some coreutils is required. + postInstall = + '' + # Remove dependency between "out" and "man" outputs. + rm "$out"/lib/perl5/*/*/.packlist - # Remove dependencies on glibc and gcc - sed "/ *libpth =>/c libpth => ' '," \ - -i "$out"/lib/perl5/*/*/Config.pm - # TODO: removing those paths would be cleaner than overwriting with nonsense. - substituteInPlace "$out"/lib/perl5/*/*/Config_heavy.pl \ - --replace "${libcInc}" /no-such-path \ - --replace "${ - if stdenv.cc.cc or null != null then stdenv.cc.cc else "/no-such-path" - }" /no-such-path \ - --replace "$man" /no-such-path - ''; # */ + # Remove dependencies on glibc and gcc + sed "/ *libpth =>/c libpth => ' '," \ + -i "$out"/lib/perl5/*/*/Config.pm + # TODO: removing those paths would be cleaner than overwriting with nonsense. + substituteInPlace "$out"/lib/perl5/*/*/Config_heavy.pl \ + --replace "${libcInc}" /no-such-path \ + --replace "${ + if stdenv.cc.cc or null != null then stdenv.cc.cc else "/no-such-path" + }" /no-such-path \ + --replace "$man" /no-such-path + ''; # */ meta = { homepage = https://www.perl.org/; From 77edba1fc4c6e54db54834025fbdf306df563deb Mon Sep 17 00:00:00 2001 From: Albert Peschar Date: Tue, 30 May 2017 18:28:41 +0200 Subject: [PATCH 46/47] pythonPackages.scrapy: fix 1.4.0 update --- pkgs/development/python-modules/scrapy/permissions-fix.patch | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pkgs/development/python-modules/scrapy/permissions-fix.patch b/pkgs/development/python-modules/scrapy/permissions-fix.patch index 5ea5269c799..53038cf74e5 100644 --- a/pkgs/development/python-modules/scrapy/permissions-fix.patch +++ b/pkgs/development/python-modules/scrapy/permissions-fix.patch @@ -21,8 +21,3 @@ index 5941066..89f8edb 100644 def run(self, args, opts): if len(args) not in (1, 2): -@@ -118,4 +117,3 @@ class Command(ScrapyCommand): - _templates_base_dir = self.settings['TEMPLATES_DIR'] or \ - join(scrapy.__path__[0], 'templates') - return join(_templates_base_dir, 'project') -- From 218c486c1c454f1ef7f2791fa1f1944d28b921e2 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Tue, 30 May 2017 17:08:47 +0000 Subject: [PATCH 47/47] fstar: fix build on darwin --- pkgs/development/compilers/fstar/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/development/compilers/fstar/default.nix b/pkgs/development/compilers/fstar/default.nix index 00714875ffc..51777f748e3 100644 --- a/pkgs/development/compilers/fstar/default.nix +++ b/pkgs/development/compilers/fstar/default.nix @@ -19,7 +19,8 @@ stdenv.mkDerivation rec { ]; preBuild = '' - substituteInPlace src/Makefile --replace "\$(RUNTIME) VS/.nuget/NuGet.exe" "true" + substituteInPlace src/Makefile --replace "\$(RUNTIME) VS/.nuget/NuGet.exe" "true" \ + --replace Darwin xyz substituteInPlace src/VS/.nuget/NuGet.targets --replace "mono" "true" # Fails with bad interpreter otherwise