Skip to content

Commit c4262f1

Browse files
committed
docs: update cross compilation section from autotools to meson
fixes #12934
1 parent 50ab1e3 commit c4262f1

File tree

1 file changed

+2
-16
lines changed

1 file changed

+2
-16
lines changed

doc/manual/source/development/building.md

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -195,28 +195,14 @@ Nix uses a string with the following format to identify the *system type* or *pl
195195
<cpu>-<os>[-<abi>]
196196
```
197197

198-
It is set when Nix is compiled for the given system, and based on the output of [`config.guess`](https://github.com/nixos/nix/blob/master/config/config.guess) ([upstream](https://git.savannah.gnu.org/cgit/config.git/tree/config.guess)):
198+
It is set when Nix is compiled for the given system, and based on the output of meson's [host_machine information](https://mesonbuild.com/Reference-manual_builtin_host_machine.html)>
199199

200200
```
201201
<cpu>-<vendor>-<os>[<version>][-<abi>]
202202
```
203203

204-
When Nix is built such that `./configure` is passed any of the `--host`, `--build`, `--target` options, the value is based on the output of [`config.sub`](https://github.com/nixos/nix/blob/master/config/config.sub) ([upstream](https://git.savannah.gnu.org/cgit/config.git/tree/config.sub)):
204+
When cross-compiling Nix with Meson, you need to specify a [cross-file](https://mesonbuild.com/Cross-compilation.html) using the `--cross-file` option. Cross-files define the target architecture and toolchain.
205205

206-
```
207-
<cpu>-<vendor>[-<kernel>]-<os>
208-
```
209-
210-
For historic reasons and backward-compatibility, some CPU and OS identifiers are translated from the GNU Autotools naming convention in [`configure.ac`](https://github.com/nixos/nix/blob/master/configure.ac) as follows:
211-
212-
| `config.guess` | Nix |
213-
|----------------------------|---------------------|
214-
| `amd64` | `x86_64` |
215-
| `i*86` | `i686` |
216-
| `arm6` | `arm6l` |
217-
| `arm7` | `arm7l` |
218-
| `linux-gnu*` | `linux` |
219-
| `linux-musl*` | `linux` |
220206

221207
## Compilation environments
222208

0 commit comments

Comments
 (0)