2023-07-15 22:02:40 +08:00
|
|
|
{
|
2023-07-18 20:17:38 +08:00
|
|
|
lib, stdenv, fetchurl, autoPatchelfHook,
|
|
|
|
ncurses, xorg
|
2023-07-15 22:02:40 +08:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec
|
|
|
|
{
|
|
|
|
version = "2023.1";
|
2023-07-18 20:17:38 +08:00
|
|
|
pname = "oneapi";
|
2023-07-15 22:02:40 +08:00
|
|
|
|
|
|
|
sourceRoot = ".";
|
2023-07-18 20:17:38 +08:00
|
|
|
src = [
|
2023-07-15 22:02:40 +08:00
|
|
|
(fetchurl {
|
|
|
|
url = "https://registrationcenter-download.intel.com/akdlm/IRC_NAS/7deeaac4-f605-4bcf-a81b-ea7531577c61/l_BaseKit_p_2023.1.0.46401_offline.sh";
|
2023-07-16 14:07:59 +08:00
|
|
|
sha256 = "0cn32zqfbjv0vq43g6ap10crnsyk7nldyqpyyzn6g52j5h45g93l";
|
2023-07-15 22:02:40 +08:00
|
|
|
})
|
|
|
|
(fetchurl {
|
|
|
|
url = "https://registrationcenter-download.intel.com/akdlm/IRC_NAS/1ff1b38a-8218-4c53-9956-f0b264de35a4/l_HPCKit_p_2023.1.0.46346_offline.sh";
|
2023-07-16 14:07:59 +08:00
|
|
|
sha256 = "0wfya02lljq4iid0nc5sn4055dkvgxwrc40x7qbgpdprzqx4a8l8";
|
2023-07-15 22:02:40 +08:00
|
|
|
})
|
|
|
|
];
|
2023-07-18 20:17:38 +08:00
|
|
|
basekit = "${builtins.elemAt src 0}";
|
|
|
|
hpckit = "${builtins.elemAt src 1}";
|
2023-07-15 22:02:40 +08:00
|
|
|
|
2023-07-18 20:17:38 +08:00
|
|
|
nativeBuildInputs = [ autoPatchelfHook ];
|
|
|
|
propagatedBuildInputs = [ ncurses stdenv.cc.cc.lib xorg.libXau ];
|
2023-07-15 22:02:40 +08:00
|
|
|
|
2023-07-16 14:07:59 +08:00
|
|
|
# propagatedBuildInputs =
|
|
|
|
# [
|
|
|
|
# glibc glib libnotify xdg-utils ncurses nss
|
|
|
|
# at-spi2-core libxcb libdrm gtk3 mesa qt515.full
|
|
|
|
# zlib freetype fontconfig xorg.xorgproto xorg.libX11 xorg.libXt
|
|
|
|
# xorg.libXft xorg.libXext xorg.libSM xorg.libICE
|
|
|
|
# ];
|
2023-07-15 22:02:40 +08:00
|
|
|
|
2023-07-16 14:07:59 +08:00
|
|
|
# libPath = lib.makeLibraryPath
|
|
|
|
# [
|
|
|
|
# stdenv.cc.cc libX11 glib libnotify xdg-utils
|
|
|
|
# ncurses nss at-spi2-core libxcb libdrm gtk3
|
|
|
|
# mesa qt515.full zlib atk nspr dbus pango cairo
|
|
|
|
# gdk-pixbuf cups expat libxkbcommon alsaLib
|
|
|
|
# at-spi2-atk xorg.libXcomposite xorg.libxshmfence
|
|
|
|
# xorg.libXdamage xorg.libXext xorg.libXfixes
|
|
|
|
# xorg.libXrandr
|
|
|
|
# ];
|
2023-07-15 22:02:40 +08:00
|
|
|
|
2023-07-18 20:17:38 +08:00
|
|
|
unpackPhase =
|
|
|
|
let
|
|
|
|
unpack = toolkit: "bash ${toolkit} --extract-only --extract-folder $TMP";
|
|
|
|
in
|
|
|
|
"
|
|
|
|
${unpack basekit}
|
|
|
|
${unpack hpckit}
|
|
|
|
";
|
|
|
|
patchPhase =
|
|
|
|
"
|
|
|
|
patchShebangs $TMP
|
|
|
|
autoPatchelf $TMP
|
|
|
|
";
|
2023-07-15 22:02:40 +08:00
|
|
|
installPhase =
|
2023-07-18 20:17:38 +08:00
|
|
|
let
|
|
|
|
install = toolkit:
|
|
|
|
"
|
|
|
|
export HOME=$TMP
|
|
|
|
toolkit_name=$(basename ${toolkit} | sed -e 's/\.sh//g' | sed -e 's/.*-//g')
|
|
|
|
$TMP/\${toolkit_name}/install.sh --install-dir $out --eula accept -s
|
|
|
|
";
|
|
|
|
in
|
|
|
|
"
|
|
|
|
runHook preInstall
|
|
|
|
${install basekit}
|
|
|
|
${install hpckit}
|
|
|
|
runHook postInstall
|
|
|
|
";
|
2023-07-15 22:02:40 +08:00
|
|
|
}
|