mirror of
https://github.com/nix-community/dream2nix.git
synced 2024-12-22 22:11:50 +03:00
fix: torch for mac - no cuda on mac
This commit is contained in:
parent
3fd4c14d36
commit
217de5cf91
@ -9,12 +9,14 @@
|
|||||||
# use the autoAddOpenGLRunpathHook to add /run/opengl-driver/lib to the RPATH
|
# use the autoAddOpenGLRunpathHook to add /run/opengl-driver/lib to the RPATH
|
||||||
# of all ELF files
|
# of all ELF files
|
||||||
deps = {nixpkgs, ...}: {
|
deps = {nixpkgs, ...}: {
|
||||||
inherit (nixpkgs.cudaPackages) autoAddOpenGLRunpathHook;
|
inherit (nixpkgs.stdenv) isLinux;
|
||||||
|
autoAddOpenGLRunpathHook = lib.optionalAttribute nixpkgs.stdenv.isLinux nixpkgs.cudaPackages.autoAddOpenGLRunpathHook;
|
||||||
};
|
};
|
||||||
mkDerivation.nativeBuildInputs = [
|
|
||||||
|
mkDerivation.nativeBuildInputs = lib.mkIf config.deps.isLinux [
|
||||||
config.deps.autoAddOpenGLRunpathHook
|
config.deps.autoAddOpenGLRunpathHook
|
||||||
];
|
];
|
||||||
|
|
||||||
# this file is patched manually, so ignore it in autoPatchelf
|
# this file is patched manually, so ignore it in autoPatchelf
|
||||||
env.autoPatchelfIgnoreMissingDeps = ["libcuda.so.1"];
|
env.autoPatchelfIgnoreMissingDeps = lib.mkIf config.deps.isLinux ["libcuda.so.1"];
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user