From 4531dadac8235af1f327a4bb726845ac155f334f Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 14 Dec 2021 17:05:31 +0100 Subject: [PATCH 01/28] kubescape: 1.0.134 -> 1.0.135 --- pkgs/tools/security/kubescape/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/tools/security/kubescape/default.nix b/pkgs/tools/security/kubescape/default.nix index 9fe00e4a4e9b..e1d1349c01e7 100644 --- a/pkgs/tools/security/kubescape/default.nix +++ b/pkgs/tools/security/kubescape/default.nix @@ -6,13 +6,13 @@ buildGoModule rec { pname = "kubescape"; - version = "1.0.134"; + version = "1.0.135"; src = fetchFromGitHub { owner = "armosec"; repo = pname; rev = "v${version}"; - sha256 = "sha256-jcMaLp3SOeH6kE9V5fYSNP5klJwqWt3mrKz1VHOzjx4="; + sha256 = "sha256-8nl4DSftiv0ZT6aUfAk0eLdpf/ScqDQqntK/2xbOn7k="; }; nativeBuildInputs = [ From a922b0637cea0039aee3f2532e3002718a1f613d Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:08:11 +0000 Subject: [PATCH 02/28] =?UTF-8?q?rocm-cmake:=204.3.1=20=E2=86=92=204.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkgs/development/tools/build-managers/rocm-cmake/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/tools/build-managers/rocm-cmake/default.nix b/pkgs/development/tools/build-managers/rocm-cmake/default.nix index ad6ac4fc2e5f..6c366be8b42f 100644 --- a/pkgs/development/tools/build-managers/rocm-cmake/default.nix +++ b/pkgs/development/tools/build-managers/rocm-cmake/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "rocm-cmake"; - version = "4.3.1"; + version = "4.5.2"; src = fetchFromGitHub { owner = "RadeonOpenCompute"; repo = "rocm-cmake"; rev = "rocm-${version}"; - hash = "sha256-BhpYOL7+IlBpkzeFjfy6KLO7ail472KQWFfQX/sXLGo="; + hash = "sha256-5RwhIIOtqeMl/Gyufl5U1gTEpoCjdPJP5MbVnhEKYMM="; }; nativeBuildInputs = [ cmake ]; From 56b17318d523a5149a3b6a6b61c02faf227e1fbe Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:08:20 +0000 Subject: [PATCH 03/28] =?UTF-8?q?rocm-thunk:=204.3.1=20=E2=86=92=204.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkgs/development/libraries/rocm-thunk/default.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/rocm-thunk/default.nix b/pkgs/development/libraries/rocm-thunk/default.nix index 4d641f873021..e76b7c1993ae 100644 --- a/pkgs/development/libraries/rocm-thunk/default.nix +++ b/pkgs/development/libraries/rocm-thunk/default.nix @@ -3,18 +3,19 @@ , writeScript , cmake , pkg-config +, libdrm , numactl }: stdenv.mkDerivation rec { pname = "rocm-thunk"; - version = "4.3.1"; + version = "4.5.2"; src = fetchFromGitHub { owner = "RadeonOpenCompute"; repo = "ROCT-Thunk-Interface"; rev = "rocm-${version}"; - hash = "sha256-jpwFL4UbEnWkw1AiM4U1s1t7GiqzBeOwa55VpnOG2Dk="; + hash = "sha256-s/N1wkAgpxYCK6rIiWH8cGQU5YFGj0q4Dxj9j3yIys8="; }; preConfigure = '' @@ -23,7 +24,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ cmake pkg-config ]; - buildInputs = [ numactl ]; + buildInputs = [ libdrm numactl ]; postInstall = '' cp -r $src/include $out From ed649174ee3e296d04572f8a1d65e8ea835cc720 Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:08:28 +0000 Subject: [PATCH 04/28] =?UTF-8?q?rocm-runtime:=204.3.1=20=E2=86=92=204.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkgs/development/libraries/rocm-runtime/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/rocm-runtime/default.nix b/pkgs/development/libraries/rocm-runtime/default.nix index f7ed0107fa5e..54ecd4f59b8d 100644 --- a/pkgs/development/libraries/rocm-runtime/default.nix +++ b/pkgs/development/libraries/rocm-runtime/default.nix @@ -14,13 +14,13 @@ stdenv.mkDerivation rec { pname = "rocm-runtime"; - version = "4.3.1"; + version = "4.5.2"; src = fetchFromGitHub { owner = "RadeonOpenCompute"; repo = "ROCR-Runtime"; rev = "rocm-${version}"; - hash = "sha256-B67v9B8LXDbWNxYNRxM3dgFFLjFSyJmm0zd3G5Bgvek="; + hash = "sha256-DJDlEHnXhegcenO8BIY/8GnZdHldVs0GFLrQy4Z6heY="; }; sourceRoot = "source/src"; From 849829862ee62f6ad6983b674a7b0611f636427b Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:08:36 +0000 Subject: [PATCH 05/28] =?UTF-8?q?rocm-opencl-runtime:=204.3.1=20=E2=86=92?= =?UTF-8?q?=204.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix the build with rocclr distributed by source. --- .../libraries/rocm-opencl-runtime/default.nix | 20 ++++++++----------- 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/pkgs/development/libraries/rocm-opencl-runtime/default.nix b/pkgs/development/libraries/rocm-opencl-runtime/default.nix index f92d495a83c4..f69165c5811e 100644 --- a/pkgs/development/libraries/rocm-opencl-runtime/default.nix +++ b/pkgs/development/libraries/rocm-opencl-runtime/default.nix @@ -13,7 +13,8 @@ , lld , llvm , mesa -, python2 +, numactl +, python3 , rocclr , rocm-comgr , rocm-device-libs @@ -23,13 +24,13 @@ stdenv.mkDerivation rec { pname = "rocm-opencl-runtime"; - version = "4.3.1"; + version = "4.5.2"; src = fetchFromGitHub { owner = "RadeonOpenCompute"; repo = "ROCm-OpenCL-Runtime"; rev = "rocm-${version}"; - hash = "sha256-4+PNxRqvAvU0Nj2igYl3WiS5h5HGV63J+cHbIVW89LE="; + hash = "sha256-0OGYF4urlscr8tMkQwo2yATXwN0DjB092KQ+CBEhfIA="; }; nativeBuildInputs = [ cmake rocm-cmake ]; @@ -43,8 +44,8 @@ stdenv.mkDerivation rec { lld llvm mesa - python2 - rocclr + numactl + python3 rocm-comgr rocm-device-libs rocm-runtime @@ -52,12 +53,8 @@ stdenv.mkDerivation rec { ]; cmakeFlags = [ - "-DAMDGPU_TARGET_TRIPLE='amdgcn-amd-amdhsa'" - "-DCLANG_OPTIONS_APPEND=-Wno-bitwise-conditional-parentheses" - "-DClang_DIR=${clang-unwrapped}/lib/cmake/clang" - "-DLIBROCclr_STATIC_DIR=${rocclr}/lib/cmake" - "-DLLVM_DIR=${llvm.out}/lib/cmake/llvm" - "-DUSE_COMGR_LIBRARY='yes'" + "-DAMD_OPENCL_PATH=${src}" + "-DROCCLR_PATH=${rocclr}" ]; dontStrip = true; @@ -72,7 +69,6 @@ stdenv.mkDerivation rec { postPatch = '' substituteInPlace khronos/icd/loader/linux/icd_linux.c \ --replace 'ICD_VENDOR_PATH' '"${addOpenGLRunpath.driverLink}/etc/OpenCL/vendors/"' - echo 'add_dependencies(amdocl64 OpenCL)' >> amdocl/CMakeLists.txt ''; passthru.updateScript = writeScript "update.sh" '' From 5d29036a68b230a101adba06c67a9161ca7643d8 Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:08:45 +0000 Subject: [PATCH 06/28] =?UTF-8?q?rocm-device-libs:=204.3.1=20=E2=86=92=204?= =?UTF-8?q?.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkgs/development/libraries/rocm-device-libs/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/rocm-device-libs/default.nix b/pkgs/development/libraries/rocm-device-libs/default.nix index e32331486569..13a326581117 100644 --- a/pkgs/development/libraries/rocm-device-libs/default.nix +++ b/pkgs/development/libraries/rocm-device-libs/default.nix @@ -10,13 +10,13 @@ stdenv.mkDerivation rec { pname = "rocm-device-libs"; - version = "4.3.1"; + version = "4.5.2"; src = fetchFromGitHub { owner = "RadeonOpenCompute"; repo = "ROCm-Device-Libs"; rev = "rocm-${version}"; - hash = "sha256-fPD9vevO2UDaFaclSI0CC/lRfM5WemWmxP1K5ajXHbk="; + hash = "sha256-UeunsDRLhmsDOzesiEgYIzYotwecehB6VswshzdRwjw="; }; nativeBuildInputs = [ cmake ]; From 66bdbb56e2ac0e69b657457dc0ffa29ab3fc7119 Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:08:53 +0000 Subject: [PATCH 07/28] =?UTF-8?q?rocm-comgr:=204.3.1=20=E2=86=92=204.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkgs/development/libraries/rocm-comgr/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/rocm-comgr/default.nix b/pkgs/development/libraries/rocm-comgr/default.nix index ee646b008a04..3ae872f23158 100644 --- a/pkgs/development/libraries/rocm-comgr/default.nix +++ b/pkgs/development/libraries/rocm-comgr/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "rocm-comgr"; - version = "4.3.1"; + version = "4.5.2"; src = fetchFromGitHub { owner = "RadeonOpenCompute"; repo = "ROCm-CompilerSupport"; rev = "rocm-${version}"; - hash = "sha256-wHSAhp1cqR9xOreGt2M2Td/ELCuLEHjpMRRkqE9dUy0="; + hash = "sha256-enGzu1EOo87/S5oH1eEqPy0AtsBhCcroG3DYemeNgR0="; }; sourceRoot = "source/lib/comgr"; From 923ad46057ba955a3c0e37845494617754510890 Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:09:01 +0000 Subject: [PATCH 08/28] =?UTF-8?q?rocclr:=204.3.1=20=E2=86=92=204.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit rocclr cannot be built alone and needs to be distributed by source now. --- pkgs/development/libraries/rocclr/default.nix | 41 +++++-------------- pkgs/top-level/all-packages.nix | 4 +- 2 files changed, 11 insertions(+), 34 deletions(-) diff --git a/pkgs/development/libraries/rocclr/default.nix b/pkgs/development/libraries/rocclr/default.nix index eed5b998ee7b..4d78209f1411 100644 --- a/pkgs/development/libraries/rocclr/default.nix +++ b/pkgs/development/libraries/rocclr/default.nix @@ -1,55 +1,34 @@ { lib, stdenv , fetchFromGitHub , writeScript -, cmake -, rocm-cmake -, clang , rocm-comgr -, rocm-opencl-runtime -, rocm-runtime -, rocm-thunk -, libelf -, libglvnd -, libX11 -, numactl }: stdenv.mkDerivation rec { pname = "rocclr"; - version = "4.3.1"; + version = "4.5.2"; src = fetchFromGitHub { owner = "ROCm-Developer-Tools"; repo = "ROCclr"; rev = "rocm-${version}"; - hash = "sha256-3lk7Zucoam+11gFBzg/TWQI1L8uAlxTrPz/mDwTwod4="; + hash = "sha256-fsQANBND/oDeC/+wmCH/aLlDTxPIi7Z/oN1HnNHHnm0="; }; - nativeBuildInputs = [ cmake rocm-cmake ]; - - buildInputs = [ clang rocm-comgr rocm-runtime rocm-thunk ]; - - propagatedBuildInputs = [ libelf libglvnd libX11 numactl ]; - prePatch = '' - substituteInPlace CMakeLists.txt \ - --replace 'set (CMAKE_LIBRARY_OUTPUT_DIRECTORY ''${CMAKE_CURRENT_BINARY_DIR}/lib)' \ - 'set (CMAKE_LIBRARY_OUTPUT_DIRECTORY ''${CMAKE_INSTALL_LIBDIR})' substituteInPlace device/comgrctx.cpp \ --replace "libamd_comgr.so" "${rocm-comgr}/lib/libamd_comgr.so" ''; - cmakeFlags = [ - "-DOPENCL_DIR=${rocm-opencl-runtime.src}" - ]; + buildPhase = ""; - preFixup = '' - # Work around broken cmake files - ln -s $out/include/compiler/lib/include/* $out/include - ln -s $out/include/elf/elfio $out/include/elfio + installPhase = '' + runHook preInstall - substituteInPlace $out/lib/cmake/rocclr/ROCclrConfig.cmake \ - --replace "/build/source/build" "$out" + mkdir -p $out + cp -r * $out/ + + runHook postInstall ''; passthru.updateScript = writeScript "update.sh" '' @@ -60,7 +39,7 @@ stdenv.mkDerivation rec { ''; meta = with lib; { - description = "Radeon Open Compute common language runtime"; + description = "Source package of the Radeon Open Compute common language runtime"; homepage = "https://github.com/ROCm-Developer-Tools/ROCclr"; license = licenses.mit; maintainers = with maintainers; [ lovesegfault ]; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 36a2f96455fc..7b207867144e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -12780,9 +12780,7 @@ with pkgs; rgxg = callPackage ../tools/text/rgxg { }; - rocclr = callPackage ../development/libraries/rocclr { - inherit (llvmPackages_rocm) clang; - }; + rocclr = callPackage ../development/libraries/rocclr { }; hip = callPackage ../development/compilers/hip { inherit (llvmPackages_rocm) clang clang-unwrapped compiler-rt lld llvm; From de8041b44e87a25127ed0dac048f4eb3ab5defb6 Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:10:15 +0000 Subject: [PATCH 09/28] =?UTF-8?q?llvmPackages=5Frocm.llvm:=204.3.1=20?= =?UTF-8?q?=E2=86=92=204.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix compiler-rt build and use ninja for faster builds. --- ...235cb58f988c71b403334cd9482d663841ab.patch | 78 +++++++++++++++++++ .../llvm/rocm/compiler-rt/default.nix | 8 +- .../compilers/llvm/rocm/default.nix | 4 +- .../compilers/llvm/rocm/llvm/default.nix | 3 +- 4 files changed, 84 insertions(+), 9 deletions(-) create mode 100644 pkgs/development/compilers/llvm/rocm/compiler-rt/68d5235cb58f988c71b403334cd9482d663841ab.patch diff --git a/pkgs/development/compilers/llvm/rocm/compiler-rt/68d5235cb58f988c71b403334cd9482d663841ab.patch b/pkgs/development/compilers/llvm/rocm/compiler-rt/68d5235cb58f988c71b403334cd9482d663841ab.patch new file mode 100644 index 000000000000..43803164a00f --- /dev/null +++ b/pkgs/development/compilers/llvm/rocm/compiler-rt/68d5235cb58f988c71b403334cd9482d663841ab.patch @@ -0,0 +1,78 @@ +--- a/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc ++++ b/lib/sanitizer_common/sanitizer_common_interceptors_ioctl.inc +@@ -370,15 +370,6 @@ + + #if SANITIZER_GLIBC + // _(SIOCDEVPLIP, WRITE, struct_ifreq_sz); // the same as EQL_ENSLAVE +- _(CYGETDEFTHRESH, WRITE, sizeof(int)); +- _(CYGETDEFTIMEOUT, WRITE, sizeof(int)); +- _(CYGETMON, WRITE, struct_cyclades_monitor_sz); +- _(CYGETTHRESH, WRITE, sizeof(int)); +- _(CYGETTIMEOUT, WRITE, sizeof(int)); +- _(CYSETDEFTHRESH, NONE, 0); +- _(CYSETDEFTIMEOUT, NONE, 0); +- _(CYSETTHRESH, NONE, 0); +- _(CYSETTIMEOUT, NONE, 0); + _(EQL_EMANCIPATE, WRITE, struct_ifreq_sz); + _(EQL_ENSLAVE, WRITE, struct_ifreq_sz); + _(EQL_GETMASTRCFG, WRITE, struct_ifreq_sz); +--- a/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp ++++ b/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp +@@ -143,7 +143,6 @@ + # include + #endif + #include +-#include + #include + #include + #include +@@ -460,7 +459,6 @@ + + #if SANITIZER_GLIBC + unsigned struct_ax25_parms_struct_sz = sizeof(struct ax25_parms_struct); +- unsigned struct_cyclades_monitor_sz = sizeof(struct cyclades_monitor); + #if EV_VERSION > (0x010000) + unsigned struct_input_keymap_entry_sz = sizeof(struct input_keymap_entry); + #else +@@ -824,15 +822,6 @@ + #endif // SANITIZER_LINUX + + #if SANITIZER_LINUX && !SANITIZER_ANDROID +- unsigned IOCTL_CYGETDEFTHRESH = CYGETDEFTHRESH; +- unsigned IOCTL_CYGETDEFTIMEOUT = CYGETDEFTIMEOUT; +- unsigned IOCTL_CYGETMON = CYGETMON; +- unsigned IOCTL_CYGETTHRESH = CYGETTHRESH; +- unsigned IOCTL_CYGETTIMEOUT = CYGETTIMEOUT; +- unsigned IOCTL_CYSETDEFTHRESH = CYSETDEFTHRESH; +- unsigned IOCTL_CYSETDEFTIMEOUT = CYSETDEFTIMEOUT; +- unsigned IOCTL_CYSETTHRESH = CYSETTHRESH; +- unsigned IOCTL_CYSETTIMEOUT = CYSETTIMEOUT; + unsigned IOCTL_EQL_EMANCIPATE = EQL_EMANCIPATE; + unsigned IOCTL_EQL_ENSLAVE = EQL_ENSLAVE; + unsigned IOCTL_EQL_GETMASTRCFG = EQL_GETMASTRCFG; +--- a/lib/sanitizer_common/sanitizer_platform_limits_posix.h ++++ b/lib/sanitizer_common/sanitizer_platform_limits_posix.h +@@ -983,7 +983,6 @@ + + #if SANITIZER_LINUX && !SANITIZER_ANDROID + extern unsigned struct_ax25_parms_struct_sz; +-extern unsigned struct_cyclades_monitor_sz; + extern unsigned struct_input_keymap_entry_sz; + extern unsigned struct_ipx_config_data_sz; + extern unsigned struct_kbdiacrs_sz; +@@ -1328,15 +1327,6 @@ + #endif // SANITIZER_LINUX + + #if SANITIZER_LINUX && !SANITIZER_ANDROID +-extern unsigned IOCTL_CYGETDEFTHRESH; +-extern unsigned IOCTL_CYGETDEFTIMEOUT; +-extern unsigned IOCTL_CYGETMON; +-extern unsigned IOCTL_CYGETTHRESH; +-extern unsigned IOCTL_CYGETTIMEOUT; +-extern unsigned IOCTL_CYSETDEFTHRESH; +-extern unsigned IOCTL_CYSETDEFTIMEOUT; +-extern unsigned IOCTL_CYSETTHRESH; +-extern unsigned IOCTL_CYSETTIMEOUT; + extern unsigned IOCTL_EQL_EMANCIPATE; + extern unsigned IOCTL_EQL_ENSLAVE; + extern unsigned IOCTL_EQL_GETMASTRCFG; diff --git a/pkgs/development/compilers/llvm/rocm/compiler-rt/default.nix b/pkgs/development/compilers/llvm/rocm/compiler-rt/default.nix index 6ea4fb281f8f..575082905fed 100644 --- a/pkgs/development/compilers/llvm/rocm/compiler-rt/default.nix +++ b/pkgs/development/compilers/llvm/rocm/compiler-rt/default.nix @@ -31,12 +31,8 @@ stdenv.mkDerivation rec { patches = [ ./compiler-rt-codesign.patch # Revert compiler-rt commit that makes codesign mandatory - (fetchpatch { - name = "libsanitizer-no-cyclades-rocm.patch"; - url = "https://gist.github.com/lovesegfault/b255dcf2fa4e202411a6a04b61e6cc04/raw"; - sha256 = "sha256-PMMSLr2zHuNDn1OWqumqHwB74ktJSHxhJWkqEKB7Z64="; - stripLen = 1; - }) + # https://github.com/llvm/llvm-project/commit/68d5235cb58f988c71b403334cd9482d663841ab.diff but the compiler-rt part of the path is stripped + ./68d5235cb58f988c71b403334cd9482d663841ab.patch ]; diff --git a/pkgs/development/compilers/llvm/rocm/default.nix b/pkgs/development/compilers/llvm/rocm/default.nix index 3497f910d6dc..b1297d7d0d1f 100644 --- a/pkgs/development/compilers/llvm/rocm/default.nix +++ b/pkgs/development/compilers/llvm/rocm/default.nix @@ -1,12 +1,12 @@ { stdenv, lib, buildPackages, fetchFromGitHub, callPackage, wrapCCWith, overrideCC }: let - version = "4.3.1"; + version = "4.5.2"; src = fetchFromGitHub { owner = "RadeonOpenCompute"; repo = "llvm-project"; rev = "rocm-${version}"; - hash = "sha256-7XVtHcrTpw+NYUvuKQFWWFE0FlOTt8EnfZpvepQqE1c="; + hash = "sha256-XWh81+2yyXQEPO+5SgxHh66fzFG1bVbvnjPfvXDC+fU="; }; in rec { clang = wrapCCWith rec { diff --git a/pkgs/development/compilers/llvm/rocm/llvm/default.nix b/pkgs/development/compilers/llvm/rocm/llvm/default.nix index 06dfd1870b07..724fd6b63f76 100644 --- a/pkgs/development/compilers/llvm/rocm/llvm/default.nix +++ b/pkgs/development/compilers/llvm/rocm/llvm/default.nix @@ -3,6 +3,7 @@ , fetchFromGitHub , writeScript , cmake +, ninja , python3 , libxml2 , libffi @@ -30,7 +31,7 @@ in stdenv.mkDerivation rec { outputs = [ "out" "python" ] ++ lib.optional enableSharedLibraries "lib"; - nativeBuildInputs = [ cmake python3 ]; + nativeBuildInputs = [ cmake ninja python3 ]; buildInputs = [ libxml2 libffi ]; From 134de12b20a0d43da8072e7c92155081552391e2 Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Tue, 14 Dec 2021 17:46:36 +0100 Subject: [PATCH 10/28] rocm-smi: 4.5.0 -> 4.5.2 --- pkgs/tools/system/rocm-smi/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/tools/system/rocm-smi/default.nix b/pkgs/tools/system/rocm-smi/default.nix index d3da169c01ae..c91f5d818b17 100644 --- a/pkgs/tools/system/rocm-smi/default.nix +++ b/pkgs/tools/system/rocm-smi/default.nix @@ -2,7 +2,7 @@ stdenv.mkDerivation rec { pname = "rocm-smi"; - version = "4.5.0"; + version = "4.5.2"; src = fetchFromGitHub { owner = "RadeonOpenCompute"; From 9659611dc15fdafe7eba0c0ce2455fe43f671959 Mon Sep 17 00:00:00 2001 From: "Neubauer, Sebastian" Date: Mon, 8 Nov 2021 10:10:33 +0000 Subject: [PATCH 11/28] =?UTF-8?q?hip:=204.3.1=20=E2=86=92=204.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit hip was split into multiple repositories. This builds the version for AMD GPUs. --- pkgs/development/compilers/hip/default.nix | 201 +++++++++------------ 1 file changed, 89 insertions(+), 112 deletions(-) diff --git a/pkgs/development/compilers/hip/default.nix b/pkgs/development/compilers/hip/default.nix index 6a1e6383958d..68c6ea39cf7e 100644 --- a/pkgs/development/compilers/hip/default.nix +++ b/pkgs/development/compilers/hip/default.nix @@ -8,9 +8,13 @@ , fetchpatch , file , lib +, libglvnd +, libX11 +, libxml2 , lld , llvm , makeWrapper +, numactl , perl , python , rocclr @@ -24,28 +28,96 @@ , writeText }: +let + hip = stdenv.mkDerivation rec { + pname = "hip"; + version = "4.5.2"; + + src = fetchFromGitHub { + owner = "ROCm-Developer-Tools"; + repo = "HIP"; + rev = "rocm-${version}"; + sha256 = "sha256-AuA5ubRPywXaBBrjdHg5AT8rrVKULKog6Lh8jPaUcXY="; + }; + + # - fix bash paths + # - fix path to rocm_agent_enumerator + # - fix hcc path + # - fix hcc version parsing + # - add linker flags for libhsa-runtime64 and hc_am since libhip_hcc + # refers to them. + prePatch = '' + for f in $(find bin -type f); do + sed -e 's,#!/usr/bin/perl,#!${perl}/bin/perl,' \ + -e 's,#!/bin/bash,#!${stdenv.shell},' \ + -i "$f" + done + + substituteInPlace bin/hip_embed_pch.sh \ + --replace '$LLVM_DIR/bin/' "" + + sed 's,#!/usr/bin/python,#!${python}/bin/python,' -i hip_prof_gen.py + + sed -e 's,$ROCM_AGENT_ENUM = "''${ROCM_PATH}/bin/rocm_agent_enumerator";,$ROCM_AGENT_ENUM = "${rocminfo}/bin/rocm_agent_enumerator";,' \ + -e 's,^\($DEVICE_LIB_PATH=\).*$,\1"${rocm-device-libs}/amdgcn/bitcode";,' \ + -e 's,^\($HIP_COMPILER=\).*$,\1"clang";,' \ + -e 's,^\($HIP_RUNTIME=\).*$,\1"ROCclr";,' \ + -e 's,^\([[:space:]]*$HSA_PATH=\).*$,\1"${rocm-runtime}";,'g \ + -e 's,^\([[:space:]]*\)$HIP_CLANG_INCLUDE_PATH = abs_path("$HIP_CLANG_PATH/../lib/clang/$HIP_CLANG_VERSION/include");,\1$HIP_CLANG_INCLUDE_PATH = "${clang-unwrapped}/lib/clang/$HIP_CLANG_VERSION/include";,' \ + -e 's,^\([[:space:]]*$HIPCXXFLAGS .= " -isystem \\"$HIP_CLANG_INCLUDE_PATH/..\\"\)";,\1 -isystem ${rocm-runtime}/include";,' \ + -e 's,`file,`${file}/bin/file,g' \ + -e 's,`readelf,`${binutils-unwrapped}/bin/readelf,' \ + -e 's, ar , ${binutils-unwrapped}/bin/ar ,g' \ + -i bin/hipcc + + sed -e 's,^\($HSA_PATH=\).*$,\1"${rocm-runtime}";,' \ + -e 's,^\($HIP_CLANG_PATH=\).*$,\1"${clang}/bin";,' \ + -e 's,^\($HIP_PLATFORM=\).*$,\1"amd";,' \ + -e 's,$HIP_CLANG_PATH/llc,${llvm}/bin/llc,' \ + -e 's, abs_path, Cwd::abs_path,' \ + -i bin/hipconfig + + sed -e 's, abs_path, Cwd::abs_path,' -i bin/hipvars.pm + ''; + + buildPhase = ""; + + installPhase = '' + runHook preInstall + + mkdir -p $out + cp -r * $out/ + + runHook postInstall + ''; + + meta = with lib; { + description = "C++ Heterogeneous-Compute Interface for Portability"; + homepage = "https://github.com/ROCm-Developer-Tools/HIP"; + license = licenses.mit; + maintainers = with maintainers; [ lovesegfault ]; + platforms = platforms.linux; + }; + }; +in stdenv.mkDerivation rec { - name = "hip"; - version = "4.3.1"; + pname = "hip"; + version = "4.5.2"; + src = fetchFromGitHub { owner = "ROCm-Developer-Tools"; - repo = "HIP"; + repo = "hipamd"; rev = "rocm-${version}"; - sha256 = "sha256-dUdP32H0u6kVItS+VUE549vvxkV1mSN84HvyfeK2hEE="; + sha256 = "WvOuQu/EN81Kwcoc3ZtGlhb996edQJ3OWFsmPuqeNXE="; }; - # FIXME: https://github.com/ROCm-Developer-Tools/HIP/issues/2317 - postPatch = '' - cp ${rocm-opencl-runtime.src}/amdocl/cl_vk_amd.hpp amdocl/ - ''; - - nativeBuildInputs = [ cmake python makeWrapper ]; + nativeBuildInputs = [ cmake python makeWrapper perl ]; + buildInputs = [ libxml2 numactl libglvnd libX11 ]; propagatedBuildInputs = [ clang compiler-rt lld llvm - rocclr rocm-comgr rocm-device-libs rocm-runtime @@ -58,123 +130,28 @@ stdenv.mkDerivation rec { export DEVICE_LIB_PATH=${rocm-device-libs}/lib ''; - # The patch version is the last two digits of year + week number + - # day in the week: date -d "2021-07-25" +%y%U%w - workweek = "21300"; - cmakeFlags = [ - "-DHSA_PATH=${rocm-runtime}" - "-DHIP_COMPILER=clang" "-DHIP_PLATFORM=amd" - "-DHIP_VERSION_GITDATE=${workweek}" - "-DCMAKE_C_COMPILER=${clang}/bin/clang" - "-DCMAKE_CXX_COMPILER=${clang}/bin/clang++" - "-DLLVM_ENABLE_RTTI=ON" - "-DLIBROCclr_STATIC_DIR=${rocclr}/lib/cmake" - "-DROCclr_DIR=${rocclr}" - "-DHIP_CLANG_ROOT=${clang-unwrapped}" + "-DAMD_OPENCL_PATH=${rocm-opencl-runtime.src}" + "-DHIP_COMMON_DIR=${hip}" + "-DROCCLR_PATH=${rocclr}" ]; - patches = [ - (fetchpatch { - name = "no-git-during-build"; - url = "https://github.com/acowley/HIP/commit/310b7e972cfb23216250c0240ba6134741679aee.patch"; - sha256 = "08ky7v1yvajabn9m5x3afzrnz38gnrgc7vgqlbyr7s801c383ha1"; - }) - (fetchpatch { - name = "use-PATH-when-compiling-pch"; - url = "https://github.com/acowley/HIP/commit/bfb4dd1eafa9714a2c05a98229cc35ffa3429b37.patch"; - sha256 = "1wp0m32df7pf4rhx3k5n750fd7kz10zr60z0wllb0mw6h00w6xpz"; - }) - ]; - - # - fix bash paths - # - fix path to rocm_agent_enumerator - # - fix hcc path - # - fix hcc version parsing - # - add linker flags for libhsa-runtime64 and hc_am since libhip_hcc - # refers to them. - prePatch = '' - for f in $(find bin -type f); do - sed -e 's,#!/usr/bin/perl,#!${perl}/bin/perl,' \ - -e 's,#!/bin/bash,#!${stdenv.shell},' \ - -i "$f" - done - - for f in $(find . -regex '.*\.cpp\|.*\.h\(pp\)?'); do - if grep -q __hcc_workweek__ "$f" ; then - substituteInPlace "$f" --replace '__hcc_workweek__' '${workweek}' - fi - done - - sed 's,#!/usr/bin/python,#!${python}/bin/python,' -i hip_prof_gen.py - - sed -e 's,$ROCM_AGENT_ENUM = "''${ROCM_PATH}/bin/rocm_agent_enumerator";,$ROCM_AGENT_ENUM = "${rocminfo}/bin/rocm_agent_enumerator";,' \ - -e "s,^\($HIP_LIB_PATH=\).*$,\1\"$out/lib\";," \ - -e 's,^\($HIP_CLANG_PATH=\).*$,\1"${clang}/bin";,' \ - -e 's,^\($DEVICE_LIB_PATH=\).*$,\1"${rocm-device-libs}/amdgcn/bitcode";,' \ - -e 's,^\($HIP_COMPILER=\).*$,\1"clang";,' \ - -e 's,^\($HIP_RUNTIME=\).*$,\1"ROCclr";,' \ - -e 's,^\([[:space:]]*$HSA_PATH=\).*$,\1"${rocm-runtime}";,'g \ - -e 's,\([[:space:]]*$HOST_OSNAME=\).*,\1"nixos";,' \ - -e 's,\([[:space:]]*$HOST_OSVER=\).*,\1"${lib.versions.majorMinor lib.version}";,' \ - -e 's,^\([[:space:]]*\)$HIP_CLANG_INCLUDE_PATH = abs_path("$HIP_CLANG_PATH/../lib/clang/$HIP_CLANG_VERSION/include");,\1$HIP_CLANG_INCLUDE_PATH = "${clang-unwrapped}/lib/clang/$HIP_CLANG_VERSION/include";,' \ - -e 's,^\([[:space:]]*$HIPCXXFLAGS .= " -isystem $HIP_CLANG_INCLUDE_PATH\)";,\1 -isystem ${rocm-runtime}/include";,' \ - -e 's,\($HIPCXXFLAGS .= " -isystem \\"$HIP_INCLUDE_PATH\\"\)" ;,\1 --rocm-path=${rocclr}";,' \ - -e "s,\$HIP_PATH/\(bin\|lib\),$out/\1,g" \ - -e "s,^\$HIP_LIB_PATH=\$ENV{'HIP_LIB_PATH'};,\$HIP_LIB_PATH=\"$out/lib\";," \ - -e 's,`file,`${file}/bin/file,g' \ - -e 's,`readelf,`${binutils-unwrapped}/bin/readelf,' \ - -e 's, ar , ${binutils-unwrapped}/bin/ar ,g' \ - -i bin/hipcc - - sed -e 's,^\($HSA_PATH=\).*$,\1"${rocm-runtime}";,' \ - -e 's,^\($HIP_CLANG_PATH=\).*$,\1"${clang}/bin";,' \ - -e 's,^\($HIP_PLATFORM=\).*$,\1"amd";,' \ - -e 's,$HIP_CLANG_PATH/llc,${llvm}/bin/llc,' \ - -e 's, abs_path, Cwd::abs_path,' \ - -i bin/hipconfig - - sed -e 's, abs_path, Cwd::abs_path,' -i bin/hipvars.pm - - sed -e 's|_IMPORT_PREFIX}/../include|_IMPORT_PREFIX}/include|g' \ - -e 's|''${HIP_CLANG_ROOT}/lib/clang/\*/include|${clang-unwrapped}/lib/clang/*/include|' \ - -i hip-config.cmake.in - ''; - - preInstall = '' - mkdir -p $out/lib/cmake - ''; - - # The upstream ROCclr setup wants everything built into the same - # ROCclr output directory. We copy things into the HIP output - # directory, since it is downstream of ROCclr in terms of dependency - # direction. Thus we have device-libs and rocclr pieces in the HIP - # output directory. postInstall = '' - mkdir -p $out/share - mv $out/lib/cmake $out/share/ - mv $out/cmake/* $out/share/cmake/hip - mkdir -p $out/lib - ln -s ${rocm-device-libs}/lib $out/lib/bitcode - mkdir -p $out/include - ln -s ${clang-unwrapped}/lib/clang/11.0.0/include $out/include/clang - ln -s ${rocclr}/lib/*.* $out/lib - ln -s ${rocclr}/include/* $out/include - wrapProgram $out/bin/hipcc --set HIP_PATH $out --set HSA_PATH ${rocm-runtime} --set HIP_CLANG_PATH ${clang}/bin --prefix PATH : ${lld}/bin --set NIX_CC_WRAPPER_TARGET_HOST_${stdenv.cc.suffixSalt} 1 --prefix NIX_LDFLAGS ' ' -L${compiler-rt}/lib --prefix NIX_LDFLAGS_FOR_TARGET ' ' -L${compiler-rt}/lib + wrapProgram $out/bin/hipcc --set HIP_PATH $out --set HSA_PATH ${rocm-runtime} --set HIP_CLANG_PATH ${clang}/bin --prefix PATH : ${lld}/bin --set NIX_CC_WRAPPER_TARGET_HOST_${stdenv.cc.suffixSalt} 1 --prefix NIX_LDFLAGS ' ' -L${compiler-rt}/lib --prefix NIX_LDFLAGS_FOR_TARGET ' ' -L${compiler-rt}/lib --add-flags "-nogpuinc" wrapProgram $out/bin/hipconfig --set HIP_PATH $out --set HSA_PATH ${rocm-runtime} --set HIP_CLANG_PATH ${clang}/bin ''; passthru.updateScript = writeScript "update.sh" '' #!/usr/bin/env nix-shell #!nix-shell -i bash -p curl jq common-updater-scripts - version="$(curl -sL "https://api.github.com/repos/ROCm-Developer-Tools/HIP/tags" | jq '.[].name | split("-") | .[1] | select( . != null )' --raw-output | sort -n | tail -1)" + version="$(curl -sL "https://api.github.com/repos/ROCm-Developer-Tools/hipamd/tags" | jq '.[].name | split("-") | .[1] | select( . != null )' --raw-output | sort -n | tail -1)" update-source-version hip "$version" ''; meta = with lib; { description = "C++ Heterogeneous-Compute Interface for Portability"; - homepage = "https://github.com/ROCm-Developer-Tools/HIP"; + homepage = "https://github.com/ROCm-Developer-Tools/hipamd"; license = licenses.mit; maintainers = with maintainers; [ lovesegfault ]; platforms = platforms.linux; From db68f29fa02157897cf1ac201399a94eba1a2759 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 22 Dec 2021 15:09:45 +0000 Subject: [PATCH 12/28] signal-desktop: 5.26.0 -> 5.26.1 --- .../networking/instant-messengers/signal-desktop/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/networking/instant-messengers/signal-desktop/default.nix b/pkgs/applications/networking/instant-messengers/signal-desktop/default.nix index f9fb19a80f97..38e718972f32 100644 --- a/pkgs/applications/networking/instant-messengers/signal-desktop/default.nix +++ b/pkgs/applications/networking/instant-messengers/signal-desktop/default.nix @@ -24,7 +24,7 @@ let in stdenv.mkDerivation rec { pname = "signal-desktop"; - version = "5.26.0"; # Please backport all updates to the stable channel. + version = "5.26.1"; # Please backport all updates to the stable channel. # All releases have a limited lifetime and "expire" 90 days after the release. # When releases "expire" the application becomes unusable until an update is # applied. The expiration date for the current release can be extracted with: @@ -34,7 +34,7 @@ in stdenv.mkDerivation rec { src = fetchurl { url = "https://updates.signal.org/desktop/apt/pool/main/s/signal-desktop/signal-desktop_${version}_amd64.deb"; - sha256 = "1l61m976x2pha3bvlcjppkgwn6b8ws1nqfa9zk7xwq4c5qz9mpj2"; + sha256 = "sha256-QIRt16AHILBNxKPxsOQ0n65W/bbalhXH1fM7KIaXP10="; }; nativeBuildInputs = [ From 1da89cedf0f7429a688b8ee38156575e46a182b3 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 22 Dec 2021 16:47:29 +0000 Subject: [PATCH 13/28] flexget: 3.2.6 -> 3.2.7 --- pkgs/applications/networking/flexget/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/networking/flexget/default.nix b/pkgs/applications/networking/flexget/default.nix index 58fb7aa26963..950dd24f3309 100644 --- a/pkgs/applications/networking/flexget/default.nix +++ b/pkgs/applications/networking/flexget/default.nix @@ -2,14 +2,14 @@ python3Packages.buildPythonApplication rec { pname = "flexget"; - version = "3.2.6"; + version = "3.2.7"; # Fetch from GitHub in order to use `requirements.in` src = fetchFromGitHub { owner = "flexget"; repo = "flexget"; rev = "v${version}"; - sha256 = "0cwzhk1w2wpf33cqbnrzckqy91b58qqpnkmh5nxv02z6fl7psmbh"; + sha256 = "12nj1jcxbkpc0x59rg59fsryignpppsx0wiwncdv6fzr58pdhd3v"; }; postPatch = '' From 3f4f5ee59132d826a93e0bb8b3cb00118a415b43 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Wed, 22 Dec 2021 17:38:25 +0100 Subject: [PATCH 14/28] =?UTF-8?q?coqPackages.paco:=204.1.1=20=E2=86=92=204?= =?UTF-8?q?.1.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkgs/development/coq-modules/paco/default.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/development/coq-modules/paco/default.nix b/pkgs/development/coq-modules/paco/default.nix index d01bfbed721b..81455ba168d9 100644 --- a/pkgs/development/coq-modules/paco/default.nix +++ b/pkgs/development/coq-modules/paco/default.nix @@ -5,9 +5,12 @@ with lib; mkCoqDerivation { owner = "snu-sf"; inherit version; defaultVersion = with versions; switch coq.coq-version [ - { case = range "8.6" "8.13"; out = "4.1.1"; } + { case = range "8.12" "8.15"; out = "4.1.2"; } + { case = range "8.9" "8.13"; out = "4.1.1"; } + { case = range "8.6" "8.13"; out = "4.0.2"; } { case = isEq "8.5"; out = "1.2.8"; } ] null; + release."4.1.2".sha256 = "sha256:1l8mwakqp4wnppsldl8wp2j24h1jvadnvrsgf35xnvdyygypjp2v"; release."4.1.1".sha256 = "1qap8cyv649lr1s11r7h5jzdjd4hsna8kph15qy5fw24h5nx6byy"; release."4.0.2".sha256 = "1q96bsxclqx84xn5vkid501jkwlc1p6fhb8szrlrp82zglj58b0b"; release."1.2.8".sha256 = "05fskx5x1qgaf9qv626m38y5izichzzqc7g2rglzrkygbskrrwsb"; From a2aaaee3d9a46e7d9799b5e3e92d64f3d292361f Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Wed, 22 Dec 2021 17:50:40 +0100 Subject: [PATCH 15/28] coqPackages.ITree: enable for Coq 8.14 --- pkgs/development/coq-modules/ITree/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/coq-modules/ITree/default.nix b/pkgs/development/coq-modules/ITree/default.nix index 95174d9547ed..1ba8080e0b10 100644 --- a/pkgs/development/coq-modules/ITree/default.nix +++ b/pkgs/development/coq-modules/ITree/default.nix @@ -5,7 +5,7 @@ with lib; mkCoqDerivation rec { owner = "DeepSpec"; inherit version; defaultVersion = with versions; switch coq.coq-version [ - { case = range "8.10" "8.13"; out = "4.0.0"; } + { case = range "8.10" "8.14"; out = "4.0.0"; } ] null; release."4.0.0".sha256 = "0h5rhndl8syc24hxq1gch86kj7mpmgr89bxp2hmf28fd7028ijsm"; releaseRev = v: "${v}"; From 4e5a391e7ef16b9d44e8c06b187acfc94d1457ad Mon Sep 17 00:00:00 2001 From: Gabriella Gonzalez Date: Wed, 22 Dec 2021 10:14:59 -0800 Subject: [PATCH 16/28] haskell.packages.ghcjs.stm: Fix evaluation error --- pkgs/development/haskell-modules/configuration-ghcjs.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/haskell-modules/configuration-ghcjs.nix b/pkgs/development/haskell-modules/configuration-ghcjs.nix index aa416012759e..2bdf5cfbe51e 100644 --- a/pkgs/development/haskell-modules/configuration-ghcjs.nix +++ b/pkgs/development/haskell-modules/configuration-ghcjs.nix @@ -24,7 +24,7 @@ self: super: # GHCJS does not ship with the same core packages as GHC. # https://github.com/ghcjs/ghcjs/issues/676 - stm = doJailbreak self.stm_2_5_0_1; + stm = doJailbreak self.stm_2_5_0_2; exceptions = dontCheck self.exceptions_0_10_4; ## OTHER PACKAGES From c934f6b624aa1165bcae820b11374c09d2ddb014 Mon Sep 17 00:00:00 2001 From: Bart Brouns Date: Wed, 22 Dec 2021 20:03:45 +0100 Subject: [PATCH 17/28] nova-filters: pin boost (#151732) --- pkgs/top-level/all-packages.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a72ee7ab0e3e..7c0415235f98 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -27568,7 +27568,9 @@ with pkgs; notmuch-addrlookup = callPackage ../applications/networking/mailreaders/notmuch-addrlookup { }; - nova-filters = callPackage ../applications/audio/nova-filters { }; + nova-filters = callPackage ../applications/audio/nova-filters { + boost = boost172; + }; nvi = callPackage ../applications/editors/nvi { }; From a08ebda88eef42cb878bf443656ede0439dd0893 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 22 Dec 2021 19:09:11 +0000 Subject: [PATCH 18/28] python38Packages.winacl: 0.1.1 -> 0.1.2 --- pkgs/development/python-modules/winacl/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/winacl/default.nix b/pkgs/development/python-modules/winacl/default.nix index 9aca67e2ed8d..76d6d71c0b63 100644 --- a/pkgs/development/python-modules/winacl/default.nix +++ b/pkgs/development/python-modules/winacl/default.nix @@ -5,11 +5,11 @@ buildPythonPackage rec { pname = "winacl"; - version = "0.1.1"; + version = "0.1.2"; src = fetchPypi { inherit pname version; - sha256 = "sha256-V+W0WRtL4rJD1LeYgr0PtiKdWTDQYv2ulB1divaqKe4="; + sha256 = "187b4394ef247806f50e1d8320bdb9e33ad1f759d9e61e2e391b97b9adf5f58a"; }; # Project doesn't have tests From 043454484669781bc942d7e312dc225ad8671878 Mon Sep 17 00:00:00 2001 From: "R. Ryantm" Date: Wed, 22 Dec 2021 20:20:25 +0000 Subject: [PATCH 19/28] python38Packages.pynetbox: 6.4.0 -> 6.4.1 --- pkgs/development/python-modules/pynetbox/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/pynetbox/default.nix b/pkgs/development/python-modules/pynetbox/default.nix index 4fa5c7483020..eeb6ad017984 100644 --- a/pkgs/development/python-modules/pynetbox/default.nix +++ b/pkgs/development/python-modules/pynetbox/default.nix @@ -10,13 +10,13 @@ buildPythonPackage rec { pname = "pynetbox"; - version = "6.4.0"; + version = "6.4.1"; src = fetchFromGitHub { owner = "netbox-community"; repo = pname; rev = "v${version}"; - sha256 = "0q272asmmciy50hakb6p0p70rqgf22sqryh9f07jrnlpvsc6pi91"; + sha256 = "08k2zxfz23gzbk49r3hmh6r3m5rgx1gk7w83qxi1v4gbm4wr0v9m"; }; SETUPTOOLS_SCM_PRETEND_VERSION = version; From e71626c849a1ae5090a2c7abef7858a2054c536d Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Wed, 22 Dec 2021 14:39:47 +0100 Subject: [PATCH 20/28] =?UTF-8?q?qarte:=204.12.0=20=E2=86=92=204.15.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkgs/applications/video/qarte/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/applications/video/qarte/default.nix b/pkgs/applications/video/qarte/default.nix index 116cf39e3fb8..5fc62912c24a 100644 --- a/pkgs/applications/video/qarte/default.nix +++ b/pkgs/applications/video/qarte/default.nix @@ -4,12 +4,12 @@ let pythonEnv = python3.withPackages (ps: with ps; [ pyqt5_with_qtmultimedia ]); in mkDerivation { pname = "qarte"; - version = "4.12.0"; + version = "4.15.1"; src = fetchbzr { url = "http://bazaar.launchpad.net/~vincent-vandevyvre/qarte/qarte-4"; - rev = "56"; - sha256 = "0cq9dg04grl45xw43gi9wsb0vm8c4bcvh813h5lm4ry8b94lfx2i"; + rev = "67"; + sha256 = "sha256:0ajvrvpyqyyxnq9nv69p3sr6c1kplphvrpph75k76yl0av94j2s3"; }; buildInputs = [ pythonEnv ]; From 21a3136d25e1652cb32197445e9799e6a5154588 Mon Sep 17 00:00:00 2001 From: Gabriella Gonzalez Date: Wed, 22 Dec 2021 12:42:14 -0800 Subject: [PATCH 21/28] haskellPackages.happy_1_19_12: Disable tests This disable the tests for the same reason as `haskellPackages.happy` (see the link in the associated comment). `happy_1_19_12` is used specifically by GHCJS on `aarch64-darwin`, which is why this additional `dontCheck` is required. --- pkgs/development/haskell-modules/configuration-arm.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/development/haskell-modules/configuration-arm.nix b/pkgs/development/haskell-modules/configuration-arm.nix index 29a962270559..9e95e0bdad2a 100644 --- a/pkgs/development/haskell-modules/configuration-arm.nix +++ b/pkgs/development/haskell-modules/configuration-arm.nix @@ -36,6 +36,7 @@ self: super: { # Similar to https://ghc.haskell.org/trac/ghc/ticket/13062 happy = dontCheck super.happy; + happy_1_19_12 = doDistribute (dontCheck super.happy_1_19_12); } // lib.optionalAttrs pkgs.stdenv.hostPlatform.isAarch64 { # AARCH64-SPECIFIC OVERRIDES From bddfc03e71bf16b5b51e8afca058678c7b7a3469 Mon Sep 17 00:00:00 2001 From: sternenseemann Date: Tue, 21 Dec 2021 13:07:49 +0100 Subject: [PATCH 22/28] packages-config.nix: make sure all GHCs are added to packages.json Currently only the default GHC (8.10.7) is added to packages.json, leading e. g. repology to believe we don't ship an up to date GHC which is inaccurate. --- pkgs/top-level/packages-config.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/top-level/packages-config.nix b/pkgs/top-level/packages-config.nix index d7dfbf5860bb..1602eaf9f45f 100644 --- a/pkgs/top-level/packages-config.nix +++ b/pkgs/top-level/packages-config.nix @@ -31,6 +31,13 @@ zeroadPackages ; + # Make sure haskell.compiler is included, so alternative GHC versions show up, + # but don't add haskell.packages.* since they contain the same packages (at + # least by name) as haskellPackages. + haskell = super.haskell // { + compiler = recurseIntoAttrs super.haskell.compiler; + }; + # This is an alias which we disallow by default; explicitly allow it emacs27Packages = emacs27.pkgs; }; From 16938f5f42ac183001e376ba33df35282039b537 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 22 Dec 2021 22:14:04 +0100 Subject: [PATCH 23/28] kubescape: 1.0.135 -> 1.0.136 --- pkgs/tools/security/kubescape/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/security/kubescape/default.nix b/pkgs/tools/security/kubescape/default.nix index e1d1349c01e7..0a13b54d2bfa 100644 --- a/pkgs/tools/security/kubescape/default.nix +++ b/pkgs/tools/security/kubescape/default.nix @@ -6,20 +6,20 @@ buildGoModule rec { pname = "kubescape"; - version = "1.0.135"; + version = "1.0.136"; src = fetchFromGitHub { owner = "armosec"; repo = pname; rev = "v${version}"; - sha256 = "sha256-8nl4DSftiv0ZT6aUfAk0eLdpf/ScqDQqntK/2xbOn7k="; + sha256 = "sha256-g7gM+fZIDb6YK3QDiBqiQaTEyFtIQ30mTe6AAR3S3iw="; }; nativeBuildInputs = [ installShellFiles ]; - vendorSha256 = "sha256-om9ASiMz59xaX76qByjziECuagCB+6jDBBsouEMQfe8="; + vendorSha256 = "sha256-hEj69RsYj+KxfZPri2j+vFxUU2S8wuK85EYGND5wtWg="; ldflags = [ "-s" From 13e673d154a2ee007cccc8f610096af9ec782a68 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 22 Dec 2021 22:26:39 +0100 Subject: [PATCH 24/28] python3Packages.weconnect: 0.26.0 -> 0.28.0 --- pkgs/development/python-modules/weconnect/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/weconnect/default.nix b/pkgs/development/python-modules/weconnect/default.nix index 4c560695ca58..70da78edb603 100644 --- a/pkgs/development/python-modules/weconnect/default.nix +++ b/pkgs/development/python-modules/weconnect/default.nix @@ -11,7 +11,7 @@ buildPythonPackage rec { pname = "weconnect"; - version = "0.26.0"; + version = "0.28.0"; format = "setuptools"; disabled = pythonOlder "3.7"; @@ -20,7 +20,7 @@ buildPythonPackage rec { owner = "tillsteinbach"; repo = "WeConnect-python"; rev = "v${version}"; - sha256 = "sha256-30guJudGOY8WAYupX89hx6mFwfAPASnKMSa+0kDbtfQ="; + sha256 = "sha256-J7T62L6wT9rkl/Ukf2y5kBbJEdzh2XnGgCgedkxVEmA="; }; propagatedBuildInputs = [ From d5cb587a9cd4061c3d1fc139bfeea534f11c95e0 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 22 Dec 2021 22:28:49 +0100 Subject: [PATCH 25/28] python3Packages.weconnect-mqtt: 0.20.0 -> 0.21.0 --- pkgs/development/python-modules/weconnect-mqtt/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/weconnect-mqtt/default.nix b/pkgs/development/python-modules/weconnect-mqtt/default.nix index cda023f1b47c..0e00a08145e6 100644 --- a/pkgs/development/python-modules/weconnect-mqtt/default.nix +++ b/pkgs/development/python-modules/weconnect-mqtt/default.nix @@ -9,7 +9,7 @@ buildPythonPackage rec { pname = "weconnect-mqtt"; - version = "0.20.0"; + version = "0.21.0"; format = "setuptools"; disabled = pythonOlder "3.7"; @@ -18,7 +18,7 @@ buildPythonPackage rec { owner = "tillsteinbach"; repo = "WeConnect-mqtt"; rev = "v${version}"; - sha256 = "sha256-RUOOHVX9IY24ZpDE7nQr//JxtQZgowcT5PrTgzaTK6Q="; + sha256 = "sha256-wagFjVXTjYFryaUiVeqU+T9ya+NzUFMX3uPlRZGe1v0="; }; propagatedBuildInputs = [ From 284756dda09515da74a29e4f4688c8f47b7e84b4 Mon Sep 17 00:00:00 2001 From: Jonas Chevalier Date: Wed, 22 Dec 2021 23:33:18 +0100 Subject: [PATCH 26/28] Revert "gitlab-runner: 14.5.2 -> 14.6.0 (#151600)" (#151843) This reverts commit b03be5896e23609d7f417681e761d2a600d9103d. --- ...nner-don-t-checked-for-fixed-runtime.patch | 30 +++++++++++++++++++ .../gitlab-runner/default.nix | 5 ++-- 2 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 pkgs/development/tools/continuous-integration/gitlab-runner/0001-gitlab-runner-don-t-checked-for-fixed-runtime.patch diff --git a/pkgs/development/tools/continuous-integration/gitlab-runner/0001-gitlab-runner-don-t-checked-for-fixed-runtime.patch b/pkgs/development/tools/continuous-integration/gitlab-runner/0001-gitlab-runner-don-t-checked-for-fixed-runtime.patch new file mode 100644 index 000000000000..a1736d83a656 --- /dev/null +++ b/pkgs/development/tools/continuous-integration/gitlab-runner/0001-gitlab-runner-don-t-checked-for-fixed-runtime.patch @@ -0,0 +1,30 @@ +From 13c633bf0075daa6ff973f368a25cf205caa017e Mon Sep 17 00:00:00 2001 +From: Pascal Bach +Date: Sat, 11 Dec 2021 10:07:01 +0100 +Subject: [PATCH] gitlab-runner: don't checked for fixed runtime + +We already use 1.16.12 which has the proper fix +--- + helpers/patches/issue_28732/syscall.go | 7 +------ + 1 file changed, 1 insertion(+), 6 deletions(-) + +diff --git a/helpers/patches/issue_28732/syscall.go b/helpers/patches/issue_28732/syscall.go +index 580513b57..fa9e4cc85 100644 +--- a/helpers/patches/issue_28732/syscall.go ++++ b/helpers/patches/issue_28732/syscall.go +@@ -2,11 +2,6 @@ + + package issue_28732 + +-import ( +- "syscall" +-) +- + func AssertFixPresent() { +- // Ensure that Issue28732Fix fixed runtime is used +- syscall.Issue28732Fix() ++ // Issue already fixed by using go 1.16.12 + } +-- +2.34.0 + diff --git a/pkgs/development/tools/continuous-integration/gitlab-runner/default.nix b/pkgs/development/tools/continuous-integration/gitlab-runner/default.nix index 2aa7e6542bf4..d902b5f4c6a1 100644 --- a/pkgs/development/tools/continuous-integration/gitlab-runner/default.nix +++ b/pkgs/development/tools/continuous-integration/gitlab-runner/default.nix @@ -1,7 +1,7 @@ { lib, buildGoPackage, fetchFromGitLab, fetchurl }: let - version = "14.6.0"; + version = "14.5.2"; in buildGoPackage rec { inherit version; @@ -19,11 +19,12 @@ buildGoPackage rec { owner = "gitlab-org"; repo = "gitlab-runner"; rev = "v${version}"; - sha256 = "1sgz8gri51i2pxnzzkcvwx5ncw1rjz7ain82hlcx6f3874qfsniy"; + sha256 = "07mr9w1rp3rnrlixmqziin1gw78s3gncg47b4z9h9zzpy3acy3xd"; }; patches = [ ./fix-shell-path.patch + ./0001-gitlab-runner-don-t-checked-for-fixed-runtime.patch ]; meta = with lib; { From b55a253e154160d2fde0db1e05ea3a16b46bcb18 Mon Sep 17 00:00:00 2001 From: Guillaume Girol Date: Wed, 22 Dec 2021 12:00:00 +0000 Subject: [PATCH 27/28] nixos/collectd: add nixos test --- nixos/tests/all-tests.nix | 1 + nixos/tests/collectd.nix | 33 ++++++++++++++++++++++++++ pkgs/tools/system/collectd/default.nix | 5 ++++ 3 files changed, 39 insertions(+) create mode 100644 nixos/tests/collectd.nix diff --git a/nixos/tests/all-tests.nix b/nixos/tests/all-tests.nix index 8f4d800abbfd..8ac2cb7fe790 100644 --- a/nixos/tests/all-tests.nix +++ b/nixos/tests/all-tests.nix @@ -70,6 +70,7 @@ in cloud-init = handleTest ./cloud-init.nix {}; cntr = handleTest ./cntr.nix {}; cockroachdb = handleTestOn ["x86_64-linux"] ./cockroachdb.nix {}; + collectd = handleTest ./collectd.nix {}; consul = handleTest ./consul.nix {}; containers-bridge = handleTest ./containers-bridge.nix {}; containers-custom-pkgs.nix = handleTest ./containers-custom-pkgs.nix {}; diff --git a/nixos/tests/collectd.nix b/nixos/tests/collectd.nix new file mode 100644 index 000000000000..cb196224a231 --- /dev/null +++ b/nixos/tests/collectd.nix @@ -0,0 +1,33 @@ +import ./make-test-python.nix ({ pkgs, ... }: { + name = "collectd"; + meta = { }; + + machine = + { pkgs, ... }: + + { + services.collectd = { + enable = true; + plugins = { + rrdtool = '' + DataDir "/var/lib/collectd/rrd" + ''; + load = ""; + }; + }; + environment.systemPackages = [ pkgs.rrdtool ]; + }; + + testScript = '' + machine.wait_for_unit("collectd.service") + hostname = machine.succeed("hostname").strip() + file = f"/var/lib/collectd/rrd/{hostname}/load/load.rrd" + machine.wait_for_file(file); + machine.succeed(f"rrdinfo {file} | logger") + # check that this file contains a shortterm metric + machine.succeed(f"rrdinfo {file} | grep -F 'ds[shortterm].min = '") + # check that there are frequent updates + machine.succeed(f"cp {file} before") + machine.wait_until_fails(f"cmp before {file}") + ''; +}) diff --git a/pkgs/tools/system/collectd/default.nix b/pkgs/tools/system/collectd/default.nix index 600c5cbfecd3..cdd51aa9fa3e 100644 --- a/pkgs/tools/system/collectd/default.nix +++ b/pkgs/tools/system/collectd/default.nix @@ -2,6 +2,7 @@ , autoreconfHook , pkg-config , libtool +, nixosTests , ... }@args: let @@ -41,6 +42,10 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; + passthru.tests = { + inherit (nixosTests) collectd; + }; + meta = with lib; { description = "Daemon which collects system performance statistics periodically"; homepage = "https://collectd.org"; From d96a3994cc9b032778a3d3f3a29f660332ef91bc Mon Sep 17 00:00:00 2001 From: Guillaume Girol Date: Wed, 22 Dec 2021 12:00:00 +0000 Subject: [PATCH 28/28] nixos/collectd: validate config file syntax at build time --- .../modules/services/monitoring/collectd.nix | 21 ++++++++++++++++++- pkgs/tools/system/collectd/default.nix | 9 ++++++++ 2 files changed, 29 insertions(+), 1 deletion(-) diff --git a/nixos/modules/services/monitoring/collectd.nix b/nixos/modules/services/monitoring/collectd.nix index 660d108587de..8d81737a3ef0 100644 --- a/nixos/modules/services/monitoring/collectd.nix +++ b/nixos/modules/services/monitoring/collectd.nix @@ -5,7 +5,7 @@ with lib; let cfg = config.services.collectd; - conf = pkgs.writeText "collectd.conf" '' + unvalidated_conf = pkgs.writeText "collectd-unvalidated.conf" '' BaseDir "${cfg.dataDir}" AutoLoadPlugin ${boolToString cfg.autoLoadPlugin} Hostname "${config.networking.hostName}" @@ -30,6 +30,15 @@ let ${cfg.extraConfig} ''; + conf = if cfg.validateConfig then + pkgs.runCommand "collectd.conf" {} '' + echo testing ${unvalidated_conf} + # collectd -t fails if BaseDir does not exist. + sed '1s/^BaseDir.*$/BaseDir "."/' ${unvalidated_conf} > collectd.conf + ${package}/bin/collectd -t -C collectd.conf + cp ${unvalidated_conf} $out + '' else unvalidated_conf; + package = if cfg.buildMinimalPackage then minimalPackage @@ -43,6 +52,16 @@ in { options.services.collectd = with types; { enable = mkEnableOption "collectd agent"; + validateConfig = mkOption { + default = true; + description = '' + Validate the syntax of collectd configuration file at build time. + Disable this if you use the Include directive on files unavailable in + the build sandbox, or when cross-compiling. + ''; + type = types.bool; + }; + package = mkOption { default = pkgs.collectd; defaultText = literalExpression "pkgs.collectd"; diff --git a/pkgs/tools/system/collectd/default.nix b/pkgs/tools/system/collectd/default.nix index cdd51aa9fa3e..8d272b15acf1 100644 --- a/pkgs/tools/system/collectd/default.nix +++ b/pkgs/tools/system/collectd/default.nix @@ -17,6 +17,15 @@ stdenv.mkDerivation rec { sha256 = "1mh97afgq6qgmpvpr84zngh58m0sl1b4wimqgvvk376188q09bjv"; }; + patches = [ + # fix -t never printing syntax errors + # should be included in next release + (fetchpatch { + url = "https://github.com/collectd/collectd/commit/3f575419e7ccb37a3b10ecc82adb2e83ff2826e1.patch"; + sha256 = "0jwjdlfl0dp7mlbwygp6h0rsbaqfbgfm5z07lr5l26z6hhng2h2y"; + }) + ]; + nativeBuildInputs = [ pkg-config autoreconfHook ]; buildInputs = [ libtool