Commit abfa212
authored
[Build] Allow out-of-tree build with TRITON_BUILD_DIR (#7347)
# Rationale
Current Triton uses a fixed build directory
`f"cmake.{plat_name}-{sys.implementation.name}-{python_version}"` when
installing with `pip install .`, when the same python is used,
regardless of the venv target or source code version. This creates
conflicts when
* Users switches Triton source version but did not clean the build
directory.
+ This is a little hard to notice since most `pip install .` will use a
temporary directory to build
* Users installing Triton into multiple venv at the same time.
With this option, users can specify an out-of-tree build directory to
avoid such conflicts.
# Alternatives
PIP usually uses /tmp/pip-build-env-xxxx/ as the temporary build
directory. However I have not found documentation about how to locate
this directory in `pip/setuptools`.1 parent ddacd46 commit abfa212
1 file changed
+7
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
16 | 21 | | |
17 | 22 | | |
0 commit comments