Skip to content

Commit

Permalink
Unrolled build for rust-lang#132477
Browse files Browse the repository at this point in the history
Rollup merge of rust-lang#132477 - Noratrieb:illumos-oxide, r=workingjubilee

Add illumos target documentation

Fixes rust-lang#130132 (comment)

`@jclulow` `@pfmooney` I'm adding you as requested.

The page is very barebones (as I do not know illumos well) and could use some improvements (for example in the "Cross-compilation toolchains and C code" section).
Feel free to suggest improvements (or rewrite it from scratch) if you find something.
  • Loading branch information
rust-timer authored Dec 30, 2024
2 parents 2061630 + ac3ffcc commit 26899ec
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/doc/rustc/src/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
- [csky-unknown-linux-gnuabiv2\*](platform-support/csky-unknown-linux-gnuabiv2.md)
- [hexagon-unknown-linux-musl](platform-support/hexagon-unknown-linux-musl.md)
- [hexagon-unknown-none-elf](platform-support/hexagon-unknown-none-elf.md)
- [illumos](platform-support/illumos.md)
- [loongarch\*-unknown-linux-\*](platform-support/loongarch-linux.md)
- [loongarch\*-unknown-none\*](platform-support/loongarch-none.md)
- [m68k-unknown-linux-gnu](platform-support/m68k-unknown-linux-gnu.md)
Expand Down
4 changes: 2 additions & 2 deletions src/doc/rustc/src/platform-support.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ target | notes
[`riscv64gc-unknown-linux-musl`](platform-support/riscv64gc-unknown-linux-musl.md) | RISC-V Linux (kernel 4.20, musl 1.2.3)
[`s390x-unknown-linux-gnu`](platform-support/s390x-unknown-linux-gnu.md) | S390x Linux (kernel 3.2, glibc 2.17)
[`x86_64-unknown-freebsd`](platform-support/freebsd.md) | 64-bit amd64 FreeBSD
`x86_64-unknown-illumos` | illumos
[`x86_64-unknown-illumos`](platform-support/illumos.md) | illumos
`x86_64-unknown-linux-musl` | 64-bit Linux with musl 1.2.3
[`x86_64-unknown-netbsd`](platform-support/netbsd.md) | NetBSD/amd64

Expand Down Expand Up @@ -255,7 +255,7 @@ target | std | host | notes
[`aarch64-nintendo-switch-freestanding`](platform-support/aarch64-nintendo-switch-freestanding.md) | * | | ARM64 Nintendo Switch, Horizon
[`aarch64-unknown-freebsd`](platform-support/freebsd.md) | ✓ | ✓ | ARM64 FreeBSD
[`aarch64-unknown-hermit`](platform-support/hermit.md) | ✓ | | ARM64 Hermit
`aarch64-unknown-illumos` | ✓ | ✓ | ARM64 illumos
[`aarch64-unknown-illumos`](platform-support/illumos.md) | ✓ | ✓ | ARM64 illumos
`aarch64-unknown-linux-gnu_ilp32` | ✓ | ✓ | ARM64 Linux (ILP32 ABI)
[`aarch64-unknown-netbsd`](platform-support/netbsd.md) | ✓ | ✓ | ARM64 NetBSD
[`aarch64-unknown-nto-qnx700`](platform-support/nto-qnx.md) | ? | | ARM64 QNX Neutrino 7.0 RTOS |
Expand Down
42 changes: 42 additions & 0 deletions src/doc/rustc/src/platform-support/illumos.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# `aarch64-unknown-illumos` and `x86_64-unknown-illumos`

**Tier: 2/3**

[illumos](https://www.illumos.org/), is a Unix operating system which provides next-generation features for downstream distributions,
including advanced system debugging, next generation filesystem, networking, and virtualization options.

## Target maintainers

- Joshua M. Clulow ([@jclulow](https://github.com/jclulow))
- Patrick Mooney ([@pfmooney](https://github.com/pfmooney))

## Requirements

The target supports host tools.

The illumos target supports `std` and uses the standard ELF file format.

`x86_64-unknown-illumos` is a tier 2 target with host tools.
`aarch64-unknown-illumos` is a tier 3 target.

## Building the target

These targets can be built by adding `aarch64-unknown-illumos` and
`x86_64-unknown-illumos` as targets in the rustc list.

## Building Rust programs

Rust ships pre-compiled artifacts for the `x86_64-unknown-illumos` target.
Rust does not ship pre-compiled artifacts for `aarch64-unknown-illumos`,
it requires building the target either as shown above or using `-Zbuild-std`.

## Testing

Tests can be run in the same way as a regular binary.

## Cross-compilation toolchains and C code

The target supports C code.

The illumos project makes available [prebuilt sysroot artefacts](https://github.com/illumos/sysroot) which can be used for cross compilation.
The official Rust binaries are cross-compiled using these artefacts.

0 comments on commit 26899ec

Please sign in to comment.