Skip to content

Commit 8a7a03a

Browse files
committed
add clarity for custom path installation
install.sysconfdir is another value, in addition to install.prefix, that could be set for custom path installation. Signed-off-by: Naveen R. Iyer <[email protected]>
1 parent ed04567 commit 8a7a03a

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

INSTALL.md

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,22 @@ See [the rustc-dev-guide for more info][sysllvm].
7979
./configure
8080
```
8181

82-
If you plan to use `x.py install` to create an installation, it is
83-
recommended that you set the `prefix` value in the `[install]` section to a
84-
directory: `./configure --set install.prefix=<path>`
82+
If you plan to use `x.py install` to create an installation, you can either
83+
set `DESTDIR` environment variable to your custom path or you can specify
84+
separate paths for each of the `prefix` and `sysconfdir` values in the
85+
`[install]` section:
86+
`./configure --set install.prefix=<path1> --set install.sysconfdir=<path2>`
87+
88+
When the `DESTDIR` environment variable is present, the `prefix` and
89+
`sysconfdir` values are combined with the path from the `DESTDIR`
90+
environment variable.
91+
92+
More information on the `DESTDIR` environment variable is available here:
93+
https://www.gnu.org/prep/standards/html_node/DESTDIR.html
94+
https://rustc-dev-guide.rust-lang.org/building/new-target.html?highlight=DESTDIR#cross-compiling
95+
96+
More information on the `prefix` and `sysconfdir` values is available here:
97+
https://www.gnu.org/prep/standards/html_node/Directory-Variables.html
8598

8699
3. Build and install:
87100

0 commit comments

Comments
 (0)