nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 19 lines 843 B view raw
1diff --git a/python/triton/runtime/build.py b/python/triton/runtime/build.py 2index 7614fe2ae..203db996b 100644 3--- a/python/triton/runtime/build.py 4+++ b/python/triton/runtime/build.py 5@@ -47,6 +47,14 @@ def _build(name: str, src: str, srcdir: str, library_dirs: list[str], include_di 6 cc_cmd += [f'-l{lib}' for lib in libraries] 7 cc_cmd += [f"-L{dir}" for dir in library_dirs] 8 cc_cmd += [f"-I{dir}" for dir in include_dirs if dir is not None] 9+ 10+ # Nixpkgs support branch 11+ # Allows passing e.g. extra -Wl,-rpath 12+ cc_cmd_extra_flags = "@ccCmdExtraFlags@" 13+ if cc_cmd_extra_flags != ("@" + "ccCmdExtraFlags@"): # substituteAll hack 14+ import shlex 15+ cc_cmd.extend(shlex.split(cc_cmd_extra_flags)) 16+ 17 cc_cmd.extend(ccflags) 18 subprocess.check_call(cc_cmd, stdout=subprocess.DEVNULL) 19 return so