forked from rarias/jungle
Compare commits
3 Commits
pkgs/aocc
...
97e81b2f91
| Author | SHA1 | Date | |
|---|---|---|---|
|
97e81b2f91
|
|||
|
a13a4e66a6
|
|||
|
9f740ec234
|
10
overlay.nix
10
overlay.nix
@@ -9,9 +9,6 @@ let
|
|||||||
bscPkgs = {
|
bscPkgs = {
|
||||||
agenix = prev.callPackage ./pkgs/agenix/default.nix { };
|
agenix = prev.callPackage ./pkgs/agenix/default.nix { };
|
||||||
amd-uprof = prev.callPackage ./pkgs/amd-uprof/default.nix { };
|
amd-uprof = prev.callPackage ./pkgs/amd-uprof/default.nix { };
|
||||||
aoccUnwrapped = callPackage ./pkgs/aocc/unwrapped.nix { };
|
|
||||||
aocc = callPackage ./pkgs/aocc/default.nix { };
|
|
||||||
stdenvAocc = final.overrideCC final.stdenv final.aocc;
|
|
||||||
bench6 = callPackage ./pkgs/bench6/default.nix { };
|
bench6 = callPackage ./pkgs/bench6/default.nix { };
|
||||||
bigotes = callPackage ./pkgs/bigotes/default.nix { };
|
bigotes = callPackage ./pkgs/bigotes/default.nix { };
|
||||||
clangOmpss2 = callPackage ./pkgs/llvm-ompss2/default.nix { };
|
clangOmpss2 = callPackage ./pkgs/llvm-ompss2/default.nix { };
|
||||||
@@ -110,7 +107,12 @@ let
|
|||||||
(meta.availableOn platform pkg);
|
(meta.availableOn platform pkg);
|
||||||
|
|
||||||
# For now only RISC-V
|
# For now only RISC-V
|
||||||
crossSet = { riscv64 = final.pkgsCross.riscv64.bsc.pkgsTopLevel; };
|
crossSet = genAttrs [ "riscv64" ] genCross;
|
||||||
|
|
||||||
|
genCross = platform:
|
||||||
|
# filter out packages by meta.platforms
|
||||||
|
filterAttrs (_: meta.availableOn final.pkgsCross.${platform}.stdenv.hostPlatform)
|
||||||
|
final.pkgsCross.${platform}.bsc.pkgsTopLevel;
|
||||||
|
|
||||||
buildList = name: paths:
|
buildList = name: paths:
|
||||||
final.runCommandLocal name { } ''
|
final.runCommandLocal name { } ''
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ in
|
|||||||
meta = {
|
meta = {
|
||||||
description = "Performance analysis tool-suite for x86 based applications";
|
description = "Performance analysis tool-suite for x86 based applications";
|
||||||
homepage = "https://www.amd.com/es/developer/uprof.html";
|
homepage = "https://www.amd.com/es/developer/uprof.html";
|
||||||
platforms = lib.platforms.linux;
|
platforms = [ "x86_64-linux" ];
|
||||||
license = lib.licenses.unfree;
|
license = lib.licenses.unfree;
|
||||||
maintainers = with lib.maintainers.bsc; [ rarias varcila ];
|
maintainers = with lib.maintainers.bsc; [ rarias varcila ];
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1,16 +0,0 @@
|
|||||||
{ wrapCCWith
|
|
||||||
, aoccUnwrapped
|
|
||||||
}:
|
|
||||||
|
|
||||||
let
|
|
||||||
cc = aoccUnwrapped;
|
|
||||||
in wrapCCWith {
|
|
||||||
inherit cc;
|
|
||||||
|
|
||||||
extraBuildCommands = ''
|
|
||||||
echo "-isystem ${cc}/include" >> $out/nix-support/cc-cflags
|
|
||||||
|
|
||||||
wrap aocc $wrapper $ccPath/clang
|
|
||||||
wrap aocc++ $wrapper $ccPath/clang++
|
|
||||||
'';
|
|
||||||
}
|
|
||||||
@@ -1,51 +0,0 @@
|
|||||||
{ lib
|
|
||||||
, fetchurl
|
|
||||||
, stdenv
|
|
||||||
, autoPatchelfHook
|
|
||||||
, rocmPackages
|
|
||||||
, zlib
|
|
||||||
, libffi
|
|
||||||
, elfutils
|
|
||||||
}:
|
|
||||||
|
|
||||||
let
|
|
||||||
# in newer nixpkgs the runtime is hsakmt
|
|
||||||
rocmRuntime =
|
|
||||||
if rocmPackages ? hsakmt then
|
|
||||||
rocmPackages.hsakmt
|
|
||||||
else
|
|
||||||
rocmPackages.rocm-runtime;
|
|
||||||
in
|
|
||||||
stdenv.mkDerivation {
|
|
||||||
pname = "aocc-compiler";
|
|
||||||
version = "5.0.0";
|
|
||||||
|
|
||||||
src = fetchurl {
|
|
||||||
url = "https://download.amd.com/developer/eula/aocc/aocc-5-0/aocc-compiler-5.0.0.tar";
|
|
||||||
sha256 = "sha256-lm+sLSx1np3m6WnBCtp6ezBsET9/HgfqN2gp7IY4Dao=";
|
|
||||||
};
|
|
||||||
|
|
||||||
nativeBuildInputs = [ autoPatchelfHook ];
|
|
||||||
buildInputs = [
|
|
||||||
elfutils
|
|
||||||
zlib
|
|
||||||
rocmRuntime
|
|
||||||
stdenv.cc.cc.lib
|
|
||||||
];
|
|
||||||
phases = [ "unpackPhase" "installPhase" "fixupPhase" ];
|
|
||||||
dontStrip = true;
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
mkdir -p $out
|
|
||||||
cp -a . $out/
|
|
||||||
|
|
||||||
ln -s ${lib.getLib libffi}/lib/libffi.so $out/lib/libffi.so.6
|
|
||||||
'';
|
|
||||||
|
|
||||||
passthru = {
|
|
||||||
inherit rocmRuntime;
|
|
||||||
isClang = true; # Needed for wrapCCWith
|
|
||||||
};
|
|
||||||
|
|
||||||
meta.mainProgram = "clang";
|
|
||||||
}
|
|
||||||
@@ -1,5 +1,6 @@
|
|||||||
{
|
{
|
||||||
stdenv
|
stdenv
|
||||||
|
, lib
|
||||||
, cudatoolkit
|
, cudatoolkit
|
||||||
, cudaPackages
|
, cudaPackages
|
||||||
, autoAddDriverRunpath
|
, autoAddDriverRunpath
|
||||||
@@ -40,4 +41,9 @@ stdenv.mkDerivation (finalAttrs: {
|
|||||||
'';
|
'';
|
||||||
installPhase = "touch $out";
|
installPhase = "touch $out";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
platforms = [ "x86_64-linux" ];
|
||||||
|
maintainers = with lib.maintainers.bsc; [ rarias ];
|
||||||
|
};
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user