forked from rarias/bscpkgs
Compare commits
33 Commits
mega-merge
...
fed53adeb9
| Author | SHA1 | Date | |
|---|---|---|---|
|
fed53adeb9
|
|||
|
9ebeed42f9
|
|||
|
6f017542c1
|
|||
| c7080a4ccb | |||
| 0384c0cd2a | |||
| 46c08d79de | |||
| 208fbe5ae2 | |||
| 8c2cb9b7b6 | |||
| a02f69ad2c | |||
| 70039143ba | |||
| 208199d982 | |||
| b4df66e6a3 | |||
| 308dea2daf | |||
| 5b01778643 | |||
| f6d2dc274c | |||
| 09175e7b24 | |||
| d35378d32a | |||
| a2626194ab | |||
| f2eda78396 | |||
| 30ca57a0ad | |||
| 0071638701 | |||
| 02b0295986 | |||
| a57e16854d | |||
| 0e094a4de2 | |||
| f7773ab344 | |||
| 15526b4c98 | |||
| d87548dc35 | |||
| 1fee034d1c | |||
| 92df819edb | |||
| 6f169f4f5f | |||
| 194dd24705 | |||
| f4f034c46f | |||
| 7dd80ef936 |
35
flake.nix
35
flake.nix
@@ -2,25 +2,34 @@
|
|||||||
inputs.nixpkgs.url = "nixpkgs";
|
inputs.nixpkgs.url = "nixpkgs";
|
||||||
|
|
||||||
outputs = { self, nixpkgs, ...}:
|
outputs = { self, nixpkgs, ...}:
|
||||||
let
|
let
|
||||||
|
system = "x86_64-linux";
|
||||||
|
pkgs = import nixpkgs {
|
||||||
|
inherit system;
|
||||||
# For now we only support x86
|
# For now we only support x86
|
||||||
system = "x86_64-linux";
|
overlays = [ self.overlays.default ];
|
||||||
pkgs = import nixpkgs {
|
};
|
||||||
inherit system;
|
in
|
||||||
overlays = [ self.overlays.default ];
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
bscOverlay = import ./overlay.nix;
|
bscOverlay = import ./overlay.nix;
|
||||||
overlays.default = self.bscOverlay;
|
overlays.default = self.bscOverlay;
|
||||||
|
|
||||||
# full nixpkgs with our overlay applied
|
# full nixpkgs with our overlay applied
|
||||||
legacyPackages.${system} = pkgs;
|
legacyPackages.${system} = pkgs;
|
||||||
|
|
||||||
hydraJobs = {
|
# packages added by our overlay
|
||||||
inherit (self.legacyPackages.${system}.bsc-ci) test pkgs cross;
|
packages.${system} =
|
||||||
};
|
let
|
||||||
|
inherit (builtins) attrNames removeAttrs;
|
||||||
# propagate nixpkgs lib, so we can do bscpkgs.lib
|
inherit (nixpkgs.lib) flip filterAttrs getAttrs pipe isDerivation;
|
||||||
inherit (nixpkgs) lib;
|
in
|
||||||
|
# extract the names of the packages from the overlay, then get the
|
||||||
|
# actual packages from the full package set with the overlay applied
|
||||||
|
pipe (self.overlays.default null null) [
|
||||||
|
attrNames
|
||||||
|
(flip getAttrs pkgs)
|
||||||
|
(flip removeAttrs [ "bsc" ])
|
||||||
|
(filterAttrs (_: isDerivation))
|
||||||
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
28
overlay.nix
28
overlay.nix
@@ -2,7 +2,7 @@ final: /* Future last stage */
|
|||||||
prev: /* Previous stage */
|
prev: /* Previous stage */
|
||||||
|
|
||||||
let
|
let
|
||||||
inherit (prev.lib) collect isDerivation mapAttrs filterAttrs;
|
inherit (prev.lib) collect isDerivation mapAttrs;
|
||||||
|
|
||||||
inherit (final) callPackage;
|
inherit (final) callPackage;
|
||||||
|
|
||||||
@@ -24,9 +24,8 @@ let
|
|||||||
clangOmpss2Nodes = callPackage ./pkgs/llvm-ompss2/default.nix { ompss2rt = final.nodes; openmp = final.openmp; };
|
clangOmpss2Nodes = callPackage ./pkgs/llvm-ompss2/default.nix { ompss2rt = final.nodes; openmp = final.openmp; };
|
||||||
clangOmpss2NodesOmpv = callPackage ./pkgs/llvm-ompss2/default.nix { ompss2rt = final.nodes; openmp = final.openmpv; };
|
clangOmpss2NodesOmpv = callPackage ./pkgs/llvm-ompss2/default.nix { ompss2rt = final.nodes; openmp = final.openmpv; };
|
||||||
clangOmpss2Unwrapped = callPackage ./pkgs/llvm-ompss2/clang.nix { };
|
clangOmpss2Unwrapped = callPackage ./pkgs/llvm-ompss2/clang.nix { };
|
||||||
clsparse = callPackage ./pkgs/clsparse/package.nix { };
|
|
||||||
#extrae = callPackage ./pkgs/extrae/default.nix { }; # Broken and outdated
|
#extrae = callPackage ./pkgs/extrae/default.nix { }; # Broken and outdated
|
||||||
gpi-2 = callPackage ./pkgs/gpi-2/default.nix { };
|
#gpi-2 = callPackage ./pkgs/gpi-2/default.nix { }; # Broken: https://jungle.bsc.es/git/rarias/bscpkgs/issues/7
|
||||||
intel-apt = callPackage ./pkgs/intel-oneapi/packages.nix { };
|
intel-apt = callPackage ./pkgs/intel-oneapi/packages.nix { };
|
||||||
intelPackages_2023 = callPackage ./pkgs/intel-oneapi/2023.nix { };
|
intelPackages_2023 = callPackage ./pkgs/intel-oneapi/2023.nix { };
|
||||||
intelPackages_2024 = final.intel-apt.hpckit_2024;
|
intelPackages_2024 = final.intel-apt.hpckit_2024;
|
||||||
@@ -57,23 +56,12 @@ let
|
|||||||
stdenvClangOmpss2Nanos6 = final.stdenv.override { cc = final.clangOmpss2Nanos6; allowedRequisites = null; };
|
stdenvClangOmpss2Nanos6 = final.stdenv.override { cc = final.clangOmpss2Nanos6; allowedRequisites = null; };
|
||||||
stdenvClangOmpss2Nodes = final.stdenv.override { cc = final.clangOmpss2Nodes; allowedRequisites = null; };
|
stdenvClangOmpss2Nodes = final.stdenv.override { cc = final.clangOmpss2Nodes; allowedRequisites = null; };
|
||||||
stdenvClangOmpss2NodesOmpv = final.stdenv.override { cc = final.clangOmpss2NodesOmpv; allowedRequisites = null; };
|
stdenvClangOmpss2NodesOmpv = final.stdenv.override { cc = final.clangOmpss2NodesOmpv; allowedRequisites = null; };
|
||||||
tagaspi = callPackage ./pkgs/tagaspi/default.nix { };
|
#tagaspi = callPackage ./pkgs/tagaspi/default.nix { }; # Broken due gpi-2
|
||||||
tampi = callPackage ./pkgs/tampi/default.nix { };
|
tampi = callPackage ./pkgs/tampi/default.nix { };
|
||||||
tacuda = callPackage ./pkgs/tacuda/default.nix { };
|
|
||||||
taopencl = callPackage ./pkgs/taopencl/default.nix { };
|
taopencl = callPackage ./pkgs/taopencl/default.nix { };
|
||||||
tasycl = callPackage ./pkgs/tasycl/default.nix { };
|
tasycl = callPackage ./pkgs/tasycl/default.nix { };
|
||||||
tasycl-acpp = callPackage ./pkgs/tasycl/default.nix { useIntel = false; };
|
tasycl-acpp = callPackage ./pkgs/tasycl/default.nix { useIntel = false; };
|
||||||
wxparaver = callPackage ./pkgs/paraver/default.nix { };
|
wxparaver = callPackage ./pkgs/paraver/default.nix { };
|
||||||
|
|
||||||
# Fix for RISC-V cross compilation
|
|
||||||
# TODO: remove once we update to 25.11
|
|
||||||
# https://github.com/NixOS/nixpkgs/commit/d9c222c81435b
|
|
||||||
prrte = prev.prrte.overrideAttrs (prevAttrs: {
|
|
||||||
configureFlags = (prevAttrs.configureFlags or []) ++ [
|
|
||||||
"--with-pmix=${prev.lib.getDev final.pmix}"
|
|
||||||
"--with-pmix-libdir=${prev.lib.getLib final.pmix}/lib"
|
|
||||||
];
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
|
|
||||||
in bscPkgs // {
|
in bscPkgs // {
|
||||||
@@ -126,21 +114,15 @@ in bscPkgs // {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
pkgs = filterAttrs (_: isDerivation) bscPkgs;
|
pkgs = final.runCommand "ci-pkgs" { }
|
||||||
|
|
||||||
pkgsList = final.runCommand "ci-pkgs" { }
|
|
||||||
"printf '%s\n' ${toString (collect isDerivation bscPkgs)} > $out";
|
"printf '%s\n' ${toString (collect isDerivation bscPkgs)} > $out";
|
||||||
|
|
||||||
tests = final.runCommand "ci-tests" { }
|
tests = final.runCommand "ci-tests" { }
|
||||||
"printf '%s\n' ${toString (collect isDerivation final.bsc-ci.test)} > $out";
|
"printf '%s\n' ${toString (collect isDerivation final.bsc-ci.test)} > $out";
|
||||||
|
|
||||||
cross = prev.lib.genAttrs [ "riscv64" ] (target:
|
|
||||||
final.pkgsCross.${target}.bsc-ci.pkgs
|
|
||||||
);
|
|
||||||
|
|
||||||
all = final.runCommand "ci-all" { }
|
all = final.runCommand "ci-all" { }
|
||||||
''
|
''
|
||||||
deps="${toString [ final.bsc-ci.pkgsList final.bsc-ci.tests ]}"
|
deps="${toString [ final.bsc-ci.pkgs final.bsc-ci.tests ]}"
|
||||||
cat $deps
|
cat $deps
|
||||||
printf '%s\n' $deps > $out
|
printf '%s\n' $deps > $out
|
||||||
'';
|
'';
|
||||||
|
|||||||
@@ -1,53 +0,0 @@
|
|||||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
||||||
index 3d139ed..15ffc14 100644
|
|
||||||
--- a/CMakeLists.txt
|
|
||||||
+++ b/CMakeLists.txt
|
|
||||||
@@ -176,32 +179,22 @@ if( BUILD_clSPARSE OR BUILD_SAMPLES )
|
|
||||||
if( BUILD_clSPARSE )
|
|
||||||
message( STATUS "Setting up clSPARSE external..." )
|
|
||||||
|
|
||||||
- if ( BUILD_SAMPLES )
|
|
||||||
- # If the user elects to build samples, then we must build and install clSPARSE
|
|
||||||
- # The install location is set as a subdirectory of the SuperBuild
|
|
||||||
- ExternalProject_Add(
|
|
||||||
- clSPARSE
|
|
||||||
- DEPENDS ${clSPARSE.Dependencies}
|
|
||||||
- SOURCE_DIR ${PROJECT_SOURCE_DIR}/src
|
|
||||||
- BINARY_DIR clSPARSE-build
|
|
||||||
- INSTALL_DIR clSPARSE-package
|
|
||||||
- CMAKE_ARGS ${clSPARSE.Cmake.Args} -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}
|
|
||||||
- -DBUILD_CLVERSION=${BUILD_CLVERSION} -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
|
|
||||||
- -DUSE_SYSTEM_CL2HPP:BOOL=${USE_SYSTEM_CL2HPP}
|
|
||||||
- )
|
|
||||||
- else( )
|
|
||||||
- # If the user does not want to build samples, then build clSPARSE but don't automatically
|
|
||||||
- # install it
|
|
||||||
- ExternalProject_Add(
|
|
||||||
- clSPARSE
|
|
||||||
- DEPENDS ${clSPARSE.Dependencies}
|
|
||||||
- SOURCE_DIR ${PROJECT_SOURCE_DIR}/src
|
|
||||||
- BINARY_DIR clSPARSE-build
|
|
||||||
- CMAKE_ARGS ${clSPARSE.Cmake.Args} -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}
|
|
||||||
- -DBUILD_CLVERSION=${BUILD_CLVERSION} -DUSE_SYSTEM_CL2HPP:BOOL=${USE_SYSTEM_CL2HPP}
|
|
||||||
- INSTALL_COMMAND ""
|
|
||||||
- )
|
|
||||||
- endif( )
|
|
||||||
+ ExternalProject_Add(
|
|
||||||
+ clSPARSE
|
|
||||||
+ DEPENDS ${clSPARSE.Dependencies}
|
|
||||||
+ SOURCE_DIR ${PROJECT_SOURCE_DIR}/src
|
|
||||||
+ BINARY_DIR clSPARSE-build
|
|
||||||
+ INSTALL_DIR clSPARSE-package
|
|
||||||
+ CMAKE_ARGS ${clSPARSE.Cmake.Args} -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}
|
|
||||||
+ -DBUILD_CLVERSION=${BUILD_CLVERSION} -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
|
|
||||||
+ -DUSE_SYSTEM_CL2HPP:BOOL=${USE_SYSTEM_CL2HPP}
|
|
||||||
+ )
|
|
||||||
+
|
|
||||||
+ install(
|
|
||||||
+ DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/clSPARSE-package/
|
|
||||||
+ DESTINATION ${CMAKE_INSTALL_PREFIX}
|
|
||||||
+ USE_SOURCE_PERMISSIONS
|
|
||||||
+ )
|
|
||||||
|
|
||||||
endif( )
|
|
||||||
|
|
||||||
@@ -1,70 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
stdenv,
|
|
||||||
fetchFromGitHub,
|
|
||||||
fetchpatch,
|
|
||||||
boost,
|
|
||||||
gtest,
|
|
||||||
ocl-icd,
|
|
||||||
opencl-headers,
|
|
||||||
opencl-clhpp,
|
|
||||||
cmake,
|
|
||||||
}:
|
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
|
||||||
pname = "clsparse";
|
|
||||||
version = "0.10.2.0";
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "clMathLibraries";
|
|
||||||
repo = "clSPARSE";
|
|
||||||
rev = "v${version}";
|
|
||||||
hash = "sha256-jIauCtUyPEIx7pFI3qH0WagV+t/fvro0OsGgONBJm0s=";
|
|
||||||
};
|
|
||||||
|
|
||||||
patches = [
|
|
||||||
./pass_include_dir.patch
|
|
||||||
./install_target.patch
|
|
||||||
(fetchpatch {
|
|
||||||
name = "remove-gettypecode.patch";
|
|
||||||
url = "https://patch-diff.githubusercontent.com/raw/clMathLibraries/clSPARSE/pull/210.patch";
|
|
||||||
hash = "sha256-9Q+tk7RMdWE4MCnbvWlsI0MIgBYKIWR2jIC1bICtIjU=";
|
|
||||||
})
|
|
||||||
];
|
|
||||||
|
|
||||||
postInstallPhase = ''
|
|
||||||
mv $installDir/lib64 lib
|
|
||||||
ln -s lib/ lib64
|
|
||||||
'';
|
|
||||||
|
|
||||||
env.NIX_CFLAGS_COMPILE = "-std=c++17";
|
|
||||||
|
|
||||||
nativeBuildInputs = [
|
|
||||||
cmake
|
|
||||||
];
|
|
||||||
|
|
||||||
buildInputs = [
|
|
||||||
boost
|
|
||||||
ocl-icd
|
|
||||||
opencl-headers
|
|
||||||
opencl-clhpp
|
|
||||||
];
|
|
||||||
|
|
||||||
cmakeFlags = [
|
|
||||||
"-DBUILD_Boost=OFF"
|
|
||||||
"-DBUILD_gMock=OFF"
|
|
||||||
"-DBUILD_MTX=OFF"
|
|
||||||
"-DBUILD_SAMPLES=OFF"
|
|
||||||
"-DUSE_SYSTEM_CL2HPP=ON"
|
|
||||||
"-DGMOCK_ROOT=${gtest}"
|
|
||||||
"-DGTEST_INCLUDE_DIR=${gtest.src}/googletest/include"
|
|
||||||
];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "A software library containing Sparse functions written in OpenCL";
|
|
||||||
homepage = "https://github.com/clMathLibraries/clSPARSE";
|
|
||||||
license = lib.licenses.asl20;
|
|
||||||
maintainers = with lib.maintainers; [ leixb ];
|
|
||||||
platforms = lib.platforms.all;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,14 +0,0 @@
|
|||||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
||||||
index 3d139ed..b7ea2d3 100644
|
|
||||||
--- a/CMakeLists.txt
|
|
||||||
+++ b/CMakeLists.txt
|
|
||||||
@@ -132,6 +132,9 @@ else( )
|
|
||||||
set( GMOCK_ROOT "$ENV{GMOCK_ROOT}" )
|
|
||||||
endif( )
|
|
||||||
list( APPEND clSPARSE.Cmake.Args -DGTEST_ROOT=${GMOCK_ROOT} )
|
|
||||||
+ if( DEFINED GTEST_INCLUDE_DIR )
|
|
||||||
+ list( APPEND clSPARSE.Cmake.Args -DGTEST_INCLUDE_DIR=${GTEST_INCLUDE_DIR} )
|
|
||||||
+ endif( )
|
|
||||||
endif( )
|
|
||||||
endif( )
|
|
||||||
|
|
||||||
@@ -20,7 +20,6 @@
|
|||||||
#, python3Packages
|
#, python3Packages
|
||||||
, installShellFiles
|
, installShellFiles
|
||||||
, symlinkJoin
|
, symlinkJoin
|
||||||
, enablePapi ? stdenv.hostPlatform == stdenv.buildPlatform # Disabled when cross-compiling
|
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
@@ -88,7 +87,7 @@ stdenv.mkDerivation rec {
|
|||||||
--enable-sampling
|
--enable-sampling
|
||||||
--with-unwind=${libunwind.dev}
|
--with-unwind=${libunwind.dev}
|
||||||
--with-xml-prefix=${libxml2.dev}
|
--with-xml-prefix=${libxml2.dev}
|
||||||
${lib.optionalString enablePapi "--with-papi=${papi}"}
|
--with-papi=${papi}
|
||||||
${if (mpi != null) then ''--with-mpi=${mpi}''
|
${if (mpi != null) then ''--with-mpi=${mpi}''
|
||||||
else ''--without-mpi''}
|
else ''--without-mpi''}
|
||||||
--without-dyninst)
|
--without-dyninst)
|
||||||
|
|||||||
@@ -34,8 +34,6 @@ stdenv.mkDerivation rec {
|
|||||||
|
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
patches = [ ./rdma-core.patch ./max-mem.patch ];
|
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
patchShebangs autogen.sh
|
patchShebangs autogen.sh
|
||||||
./autogen.sh
|
./autogen.sh
|
||||||
|
|||||||
@@ -1,10 +0,0 @@
|
|||||||
--- a/tests/tests/segments/max_mem.c 2025-09-12 13:30:53.449353591 +0200
|
|
||||||
+++ b/tests/tests/segments/max_mem.c 2025-09-12 13:33:49.750352401 +0200
|
|
||||||
@@ -1,5 +1,7 @@
|
|
||||||
#include <test_utils.h>
|
|
||||||
|
|
||||||
+gaspi_size_t gaspi_get_system_mem (void);
|
|
||||||
+
|
|
||||||
/* Test allocates 45% of system memory and creates a segment that
|
|
||||||
large or if several ranks per node exist, divided among that
|
|
||||||
number */
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
--- a/src/devices/ib/GPI2_IB.h 2025-09-12 13:25:31.564181121 +0200
|
|
||||||
+++ b/src/devices/ib/GPI2_IB.h 2025-09-12 13:24:49.105422150 +0200
|
|
||||||
@@ -26,6 +26,9 @@ along with GPI-2. If not, see <http://ww
|
|
||||||
|
|
||||||
#include "GPI2_Dev.h"
|
|
||||||
|
|
||||||
+/* Missing prototype as driver.h is now private */
|
|
||||||
+int ibv_read_sysfs_file(const char *dir, const char *file, char *buf, size_t size);
|
|
||||||
+
|
|
||||||
#define GASPI_GID_INDEX (0)
|
|
||||||
#define PORT_LINK_UP (5)
|
|
||||||
#define MAX_INLINE_BYTES (128)
|
|
||||||
@@ -2,7 +2,6 @@
|
|||||||
stdenv
|
stdenv
|
||||||
, lib
|
, lib
|
||||||
, gcc
|
, gcc
|
||||||
, gcc13
|
|
||||||
, clangOmpss2Unwrapped
|
, clangOmpss2Unwrapped
|
||||||
, writeShellScript
|
, writeShellScript
|
||||||
, openmp ? null
|
, openmp ? null
|
||||||
@@ -11,9 +10,9 @@
|
|||||||
, ompss2rt ? null
|
, ompss2rt ? null
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
with lib;
|
||||||
inherit (lib) assertMsg optional optionalString;
|
|
||||||
|
|
||||||
|
let
|
||||||
usingNodesAndOmpv = (openmp.pname == "openmp-v" && ompss2rt.pname == "nodes");
|
usingNodesAndOmpv = (openmp.pname == "openmp-v" && ompss2rt.pname == "nodes");
|
||||||
sameNosv = openmp.nosv == ompss2rt.nosv;
|
sameNosv = openmp.nosv == ompss2rt.nosv;
|
||||||
in
|
in
|
||||||
@@ -38,8 +37,7 @@ let
|
|||||||
targetConfig = stdenv.targetPlatform.config;
|
targetConfig = stdenv.targetPlatform.config;
|
||||||
inherit gcc;
|
inherit gcc;
|
||||||
cc = clangOmpss2Unwrapped;
|
cc = clangOmpss2Unwrapped;
|
||||||
|
gccVersion = with versions; let v = gcc.version; in concatStringsSep "." [(major v) (minor v) (patch v)];
|
||||||
gccVersion = with lib.versions; let v = gcc.version; in concatStringsSep "." [(major v) (minor v) (patch v)];
|
|
||||||
|
|
||||||
extraBuildCommands = ''
|
extraBuildCommands = ''
|
||||||
echo "-target ${targetConfig}" >> $out/nix-support/cc-cflags
|
echo "-target ${targetConfig}" >> $out/nix-support/cc-cflags
|
||||||
@@ -94,8 +92,7 @@ let
|
|||||||
'';
|
'';
|
||||||
|
|
||||||
wrappedCCIntel = wrapCCWith {
|
wrappedCCIntel = wrapCCWith {
|
||||||
inherit bintools extraPackages;
|
inherit cc bintools extraPackages;
|
||||||
cc = cc.override { gcc = gcc13; }; # Intel uses gcc13, so we have to match it
|
|
||||||
# extraPackages adds packages to depsTargetTargetPropagated
|
# extraPackages adds packages to depsTargetTargetPropagated
|
||||||
extraBuildCommands = intelExtraBuildCommands + envExports;
|
extraBuildCommands = intelExtraBuildCommands + envExports;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -22,11 +22,7 @@ stdenv.mkDerivation rec {
|
|||||||
'';
|
'';
|
||||||
|
|
||||||
buildInputs = [ libtirpc ];
|
buildInputs = [ libtirpc ];
|
||||||
patches = [
|
patches = [ ./fix-install.patch ./gcc-14.patch ];
|
||||||
./fix-install.patch
|
|
||||||
./gcc-14.patch
|
|
||||||
./fix-cross.patch
|
|
||||||
];
|
|
||||||
|
|
||||||
hardeningDisable = [ "all" ];
|
hardeningDisable = [ "all" ];
|
||||||
|
|
||||||
@@ -39,8 +35,6 @@ stdenv.mkDerivation rec {
|
|||||||
CFLAGS=-Wno-implicit-int
|
CFLAGS=-Wno-implicit-int
|
||||||
CPPFLAGS=-I${libtirpc.dev}/include/tirpc
|
CPPFLAGS=-I${libtirpc.dev}/include/tirpc
|
||||||
LDFLAGS=-ltirpc
|
LDFLAGS=-ltirpc
|
||||||
CC=${stdenv.cc.targetPrefix}cc
|
|
||||||
AR=${stdenv.cc.targetPrefix}ar
|
|
||||||
)
|
)
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
|||||||
@@ -1,13 +0,0 @@
|
|||||||
diff --git a/src/Makefile b/src/Makefile
|
|
||||||
index 2555014..356eeb3 100644
|
|
||||||
--- a/src/Makefile
|
|
||||||
+++ b/src/Makefile
|
|
||||||
@@ -36,7 +36,7 @@ SHELL=/bin/sh
|
|
||||||
|
|
||||||
CC=`../scripts/compiler`
|
|
||||||
MAKE=`../scripts/make`
|
|
||||||
-AR=ar
|
|
||||||
+AR?=ar
|
|
||||||
ARCREATE=cr
|
|
||||||
|
|
||||||
# base of installation location
|
|
||||||
@@ -16,7 +16,6 @@
|
|||||||
, jemallocNanos6 ? null
|
, jemallocNanos6 ? null
|
||||||
, cachelineBytes ? 64
|
, cachelineBytes ? 64
|
||||||
, enableGlibcxxDebug ? false
|
, enableGlibcxxDebug ? false
|
||||||
, enablePapi ? stdenv.hostPlatform == stdenv.buildPlatform # Disabled when cross-compiling
|
|
||||||
, useGit ? false
|
, useGit ? false
|
||||||
, gitUrl ? "ssh://git@bscpm04.bsc.es/nanos6/nanos6"
|
, gitUrl ? "ssh://git@bscpm04.bsc.es/nanos6/nanos6"
|
||||||
, gitBranch ? "master"
|
, gitBranch ? "master"
|
||||||
@@ -48,8 +47,6 @@ let
|
|||||||
};
|
};
|
||||||
|
|
||||||
source = if (useGit) then git else release;
|
source = if (useGit) then git else release;
|
||||||
|
|
||||||
isCross = stdenv.hostPlatform != stdenv.buildPlatform;
|
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation (source // {
|
stdenv.mkDerivation (source // {
|
||||||
pname = "nanos6";
|
pname = "nanos6";
|
||||||
@@ -74,11 +71,9 @@ in
|
|||||||
"--disable-all-instrumentations"
|
"--disable-all-instrumentations"
|
||||||
"--enable-ovni-instrumentation"
|
"--enable-ovni-instrumentation"
|
||||||
"--with-ovni=${ovni}"
|
"--with-ovni=${ovni}"
|
||||||
"--with-boost=${boost.dev}"
|
|
||||||
] ++
|
] ++
|
||||||
(optional enableJemalloc "--with-jemalloc=${jemallocNanos6}") ++
|
(optional enableJemalloc "--with-jemalloc=${jemallocNanos6}") ++
|
||||||
(optional enableGlibcxxDebug "CXXFLAGS=-D_GLIBCXX_DEBUG") ++
|
(optional enableGlibcxxDebug "CXXFLAGS=-D_GLIBCXX_DEBUG");
|
||||||
(optional isCross "--with-symbol-resolution=ifunc");
|
|
||||||
|
|
||||||
postConfigure = lib.optionalString (!enableDebug) ''
|
postConfigure = lib.optionalString (!enableDebug) ''
|
||||||
# Disable debug
|
# Disable debug
|
||||||
@@ -102,14 +97,16 @@ in
|
|||||||
# TODO: papi_version is needed for configure:
|
# TODO: papi_version is needed for configure:
|
||||||
# ./configure: line 27378: papi_version: command not found
|
# ./configure: line 27378: papi_version: command not found
|
||||||
# This probably breaks cross-compilation
|
# This probably breaks cross-compilation
|
||||||
] ++ lib.optionals enablePapi [ papi ];
|
papi
|
||||||
|
];
|
||||||
|
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
boost
|
boost
|
||||||
numactl
|
numactl
|
||||||
hwloc
|
hwloc
|
||||||
|
papi
|
||||||
ovni
|
ovni
|
||||||
] ++ lib.optionals enablePapi [ papi ];
|
];
|
||||||
|
|
||||||
# Create a script that sets NANOS6_HOME
|
# Create a script that sets NANOS6_HOME
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
, numactl
|
, numactl
|
||||||
, hwloc
|
, hwloc
|
||||||
, papi
|
, papi
|
||||||
, enablePapi ? stdenv.hostPlatform == stdenv.buildPlatform # Disabled when cross-compiling
|
, enablePapi ? true
|
||||||
, cacheline ? 64 # bits
|
, cacheline ? 64 # bits
|
||||||
, ovni ? null
|
, ovni ? null
|
||||||
, useGit ? false
|
, useGit ? false
|
||||||
|
|||||||
@@ -44,7 +44,6 @@ in
|
|||||||
patchShebangs --build test/
|
patchShebangs --build test/
|
||||||
'';
|
'';
|
||||||
nativeBuildInputs = [ cmake ] ++ lib.optionals (useMpi) [ mpi ];
|
nativeBuildInputs = [ cmake ] ++ lib.optionals (useMpi) [ mpi ];
|
||||||
buildInputs = lib.optionals (useMpi) [ mpi ];
|
|
||||||
cmakeBuildType = if (enableDebug) then "Debug" else "Release";
|
cmakeBuildType = if (enableDebug) then "Debug" else "Release";
|
||||||
cmakeFlags = [
|
cmakeFlags = [
|
||||||
"-DOVNI_GIT_COMMIT=${src.shortRev}"
|
"-DOVNI_GIT_COMMIT=${src.shortRev}"
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
{ stdenv
|
{
|
||||||
|
stdenv
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, autoreconfHook
|
, autoreconfHook
|
||||||
, boost
|
, boost
|
||||||
@@ -11,17 +12,14 @@
|
|||||||
, openssl
|
, openssl
|
||||||
, glibcLocales
|
, glibcLocales
|
||||||
, wrapGAppsHook
|
, wrapGAppsHook
|
||||||
|
|
||||||
, enableDebug ? false
|
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
wx = wxGTK32;
|
wx = wxGTK32;
|
||||||
version = "4.12.0";
|
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation rec {
|
||||||
pname = "wxparaver";
|
pname = "wxparaver";
|
||||||
inherit version;
|
version = "4.12.0";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "bsc-performance-tools";
|
owner = "bsc-performance-tools";
|
||||||
@@ -38,26 +36,21 @@ stdenv.mkDerivation {
|
|||||||
./fix-boost-87.patch
|
./fix-boost-87.patch
|
||||||
];
|
];
|
||||||
|
|
||||||
|
hardeningDisable = [ "all" ];
|
||||||
|
|
||||||
# Fix the PARAVER_HOME variable
|
# Fix the PARAVER_HOME variable
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
sed -i 's@^PARAVER_HOME=.*$@PARAVER_HOME='$out'@g' docs/wxparaver
|
sed -i 's@^PARAVER_HOME=.*$@PARAVER_HOME='$out'@g' docs/wxparaver
|
||||||
sed -i '1aexport LOCALE_ARCHIVE="${glibcLocales}/lib/locale/locale-archive"' docs/wxparaver
|
sed -i '1aexport LOCALE_ARCHIVE="${glibcLocales}/lib/locale/locale-archive"' docs/wxparaver
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
dontStrip = true;
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
hardeningDisable = [ "all" ];
|
preConfigure = ''
|
||||||
|
export CFLAGS="-O3"
|
||||||
dontStrip = true;
|
export CXXFLAGS="-O3"
|
||||||
|
'';
|
||||||
env =
|
|
||||||
let
|
|
||||||
flags = if enableDebug then "-ggdb -Og" else "-O3";
|
|
||||||
in
|
|
||||||
{
|
|
||||||
CFLAGS = flags;
|
|
||||||
CXXFLAGS = flags;
|
|
||||||
};
|
|
||||||
|
|
||||||
configureFlags = [
|
configureFlags = [
|
||||||
"--with-boost=${boost}"
|
"--with-boost=${boost}"
|
||||||
@@ -75,11 +68,11 @@ stdenv.mkDerivation {
|
|||||||
|
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
boost
|
boost
|
||||||
libxml2
|
libxml2.dev
|
||||||
xml2
|
xml2
|
||||||
wx
|
wx
|
||||||
paraverKernel
|
paraverKernel
|
||||||
openssl
|
openssl.dev
|
||||||
];
|
];
|
||||||
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
{ stdenv
|
{
|
||||||
|
stdenv
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, autoreconfHook
|
, autoreconfHook
|
||||||
, boost
|
, boost
|
||||||
@@ -8,16 +9,11 @@
|
|||||||
, automake
|
, automake
|
||||||
, pkg-config
|
, pkg-config
|
||||||
, zlib
|
, zlib
|
||||||
|
|
||||||
, enableDebug ? false
|
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
stdenv.mkDerivation rec {
|
||||||
version = "4.12.0";
|
|
||||||
in
|
|
||||||
stdenv.mkDerivation {
|
|
||||||
pname = "paraver-kernel";
|
pname = "paraver-kernel";
|
||||||
inherit version;
|
version = "4.12.0";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "bsc-performance-tools";
|
owner = "bsc-performance-tools";
|
||||||
@@ -38,14 +34,10 @@ stdenv.mkDerivation {
|
|||||||
|
|
||||||
dontStrip = true;
|
dontStrip = true;
|
||||||
|
|
||||||
env =
|
preConfigure = ''
|
||||||
let
|
export CFLAGS="-O3 -DPARALLEL_ENABLED"
|
||||||
flags = "-DPARALLEL_ENABLED " + (if enableDebug then "-ggdb -Og" else "-O3");
|
export CXXFLAGS="-O3 -DPARALLEL_ENABLED"
|
||||||
in
|
'';
|
||||||
{
|
|
||||||
CFLAGS = flags;
|
|
||||||
CXXFLAGS = flags;
|
|
||||||
};
|
|
||||||
|
|
||||||
configureFlags = [
|
configureFlags = [
|
||||||
"--with-boost=${boost}"
|
"--with-boost=${boost}"
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
{ stdenv
|
{ stdenv
|
||||||
|
, lib
|
||||||
|
, withCFlags
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, automake
|
, automake
|
||||||
, autoconf
|
, autoconf
|
||||||
@@ -6,24 +8,21 @@
|
|||||||
, gnumake
|
, gnumake
|
||||||
, autoreconfHook
|
, autoreconfHook
|
||||||
, boost
|
, boost
|
||||||
, cudaPackages
|
|
||||||
|
|
||||||
, useGit ? false
|
, useGit ? false
|
||||||
, gitUrl ? "git@gitlab-internal.bsc.es:task-awareness/tacuda/tacuda.git"
|
, gitUrl ? "git@gitlab-internal.bsc.es:task-awareness/tacuda/tacuda.git"
|
||||||
, gitBranch ? "main"
|
, gitBranch ? "main"
|
||||||
, gitCommit ? "35234f9445e6149a2bd38d119841e2485d6ee05e"
|
, gitCommit ? ""
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
let
|
||||||
|
release = rec {
|
||||||
release_ver = "2.1.0";
|
version = "2.1.0";
|
||||||
release = {
|
|
||||||
version = release_ver;
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "bsc-pm";
|
owner = "bsc-pm";
|
||||||
repo = "tacuda";
|
repo = "tacuda";
|
||||||
rev = release_ver;
|
rev = version;
|
||||||
hash = "sha256-Cj3EiLVJSLvRv0ydeg7Vp4SpkniEqHkcWF+YOJQ8EcM=";
|
hash = "";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -55,14 +54,8 @@ stdenv.mkDerivation {
|
|||||||
gnumake
|
gnumake
|
||||||
];
|
];
|
||||||
|
|
||||||
patches = [ ./fix_config.patch ];
|
|
||||||
|
|
||||||
configureFlags = [ "--with-cuda-include=${cudaPackages.cudatoolkit}/include" ];
|
|
||||||
|
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
boost
|
boost
|
||||||
cudaPackages.libcublas
|
|
||||||
cudaPackages.cuda_cudart
|
|
||||||
];
|
];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,13 +0,0 @@
|
|||||||
diff --git a/m4/cuda.m4 b/m4/cuda.m4
|
|
||||||
index 23f5c94..8f9b534 100644
|
|
||||||
--- a/m4/cuda.m4
|
|
||||||
+++ b/m4/cuda.m4
|
|
||||||
@@ -40,7 +40,7 @@ search_libs="cuda cublas cudart"
|
|
||||||
required_libs=""
|
|
||||||
|
|
||||||
m4_foreach([function],
|
|
||||||
- [cuInit,
|
|
||||||
+ [
|
|
||||||
cublasSgemm,
|
|
||||||
cudaStreamCreate,
|
|
||||||
cudaLaunchKernel,
|
|
||||||
@@ -17,7 +17,7 @@ stdenv.mkDerivation (finalAttrs: {
|
|||||||
version = finalAttrs.src.shortRev;
|
version = finalAttrs.src.shortRev;
|
||||||
|
|
||||||
src = builtins.fetchGit {
|
src = builtins.fetchGit {
|
||||||
url = "git@gitlab-internal.bsc.es:task-awareness/taopencl/taopencl.git";
|
url = "git@gitlab-internal.bsc.es:task-awareness/taopencl/taopencl.git";
|
||||||
ref = "master";
|
ref = "master";
|
||||||
rev = "c3b7b32ae8fa4af7ceff598532a881f8f1490aaf";
|
rev = "c3b7b32ae8fa4af7ceff598532a881f8f1490aaf";
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user