Skip to content

Commit 869667a

Browse files
WorksButNotTestedYour Name
andauthored
Add powerpc32 be support (#1337)
* Add powerpc32 be support * Fix clock_gettime * Bump linux-raw-sys and re-instate test * Fix test_vdso to use __kernel_clock_gettime64 * Don't check for availability of __kernel_clock_gettime64 on powerpc since the CI host may not have Linux 5.11 * Fix unused in test --------- Co-authored-by: Your Name <you@example.com>
1 parent 3b0e286 commit 869667a

14 files changed

Lines changed: 647 additions & 31 deletions

File tree

.github/workflows/main.yml

Lines changed: 53 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ jobs:
7272
riscv64gc-unknown-linux-gnu
7373
aarch64-unknown-linux-gnu
7474
aarch64-unknown-linux-musl
75+
powerpc-unknown-linux-gnu
7576
powerpc64le-unknown-linux-gnu
7677
armv5te-unknown-linux-gnueabi
7778
s390x-unknown-linux-gnu
@@ -121,6 +122,7 @@ jobs:
121122
- run: cargo check --workspace --release -vv --target=aarch64-unknown-linux-gnu --features=linux_latest,all-apis --all-targets
122123
- run: cargo check --workspace --release -vv --target=aarch64-unknown-linux-musl --features=all-apis --all-targets
123124
- run: cargo check --workspace --release -vv --target=aarch64-unknown-linux-musl --features=use-libc,all-apis --all-targets
125+
- run: cargo check --workspace --release -vv --target=powerpc-unknown-linux-gnu --features=all-apis --all-targets
124126
- run: cargo check --workspace --release -vv --target=powerpc64le-unknown-linux-gnu --features=all-apis --all-targets
125127
- run: cargo check --workspace --release -vv --target=armv5te-unknown-linux-gnueabi --features=all-apis --all-targets
126128
- run: cargo check --workspace --release -vv --target=s390x-unknown-linux-gnu --features=all-apis --all-targets
@@ -227,6 +229,7 @@ jobs:
227229
- run: cargo check -Z build-std --target=powerpc64-ibm-aix --features=all-apis
228230
- run: cargo check -Z build-std --target=mipsel-unknown-linux-gnu --features=all-apis
229231
- run: cargo check -Z build-std --target=mips64el-unknown-linux-gnuabi64 --features=all-apis
232+
- run: cargo check -Z build-std --target=powerpc-unknown-linux-musl --features=all-apis
230233
- run: cargo check -Z build-std --target=powerpc64le-unknown-linux-musl --features=all-apis
231234

232235

@@ -239,7 +242,7 @@ jobs:
239242
RUSTFLAGS: --cfg rustix_use_experimental_features
240243
strategy:
241244
matrix:
242-
build: [ubuntu, ubuntu-20.04, i686-linux, aarch64-linux, powerpc64le-linux, riscv64-linux, s390x-linux, arm-linux, ubuntu-stable, i686-linux-stable, aarch64-linux-stable, riscv64-linux-stable, s390x-linux-stable, powerpc64le-linux-stable, arm-linux-stable, ubuntu-1.63, i686-linux-1.63, aarch64-linux-1.63, riscv64-linux-1.63, s390x-linux-1.63, powerpc64le-linux-1.63, arm-linux-1.63, macos-latest, macos-13, windows, windows-2019, musl]
245+
build: [ubuntu, ubuntu-20.04, i686-linux, aarch64-linux, powerpc-linux, powerpc64le-linux, riscv64-linux, s390x-linux, arm-linux, ubuntu-stable, i686-linux-stable, aarch64-linux-stable, riscv64-linux-stable, s390x-linux-stable, powerpc-linux-stable, powerpc64le-linux-stable, arm-linux-stable, ubuntu-1.63, i686-linux-1.63, aarch64-linux-1.63, riscv64-linux-1.63, s390x-linux-1.63, powerpc64le-linux, powerpc64le-linux-1.63, arm-linux-1.63, macos-latest, macos-13, windows, windows-2019, musl]
243246
include:
244247
- build: ubuntu
245248
os: ubuntu-latest
@@ -263,6 +266,15 @@ jobs:
263266
qemu: qemu-aarch64
264267
qemu_args: -L /usr/aarch64-linux-gnu
265268
qemu_target: aarch64-linux-user
269+
- build: powerpc-linux
270+
os: ubuntu-latest
271+
rust: nightly
272+
target: powerpc-unknown-linux-gnu
273+
gcc_package: gcc-powerpc-linux-gnu
274+
gcc: powerpc-linux-gnu-gcc
275+
qemu: qemu-ppc
276+
qemu_args: -L /usr/powerpc-linux-gnu
277+
qemu_target: ppc-linux-user
266278
- build: powerpc64le-linux
267279
os: ubuntu-latest
268280
rust: nightly
@@ -336,6 +348,15 @@ jobs:
336348
qemu: qemu-s390x
337349
qemu_args: -L /usr/s390x-linux-gnu
338350
qemu_target: s390x-linux-user
351+
- build: powerpc-linux-stable
352+
os: ubuntu-latest
353+
rust: stable
354+
target: powerpc-unknown-linux-gnu
355+
gcc_package: gcc-powerpc-linux-gnu
356+
gcc: powerpc-linux-gnu-gcc
357+
qemu: qemu-ppc
358+
qemu_args: -L /usr/powerpc-linux-gnu
359+
qemu_target: ppc-linux-user
339360
- build: powerpc64le-linux-stable
340361
os: ubuntu-latest
341362
rust: stable
@@ -391,6 +412,15 @@ jobs:
391412
qemu: qemu-s390x
392413
qemu_args: -L /usr/s390x-linux-gnu
393414
qemu_target: s390x-linux-user
415+
- build: powerpc-linux-1.63
416+
os: ubuntu-latest
417+
rust: 1.63
418+
target: powerpc-unknown-linux-gnu
419+
gcc_package: gcc-powerpc-linux-gnu
420+
gcc: powerpc-linux-gnu-gcc
421+
qemu: qemu-ppc
422+
qemu_args: -L /usr/powerpc-linux-gnu
423+
qemu_target: ppc-linux-user
394424
- build: powerpc64le-linux-1.63
395425
os: ubuntu-latest
396426
rust: 1.63
@@ -513,7 +543,7 @@ jobs:
513543
runs-on: ${{ matrix.os }}
514544
strategy:
515545
matrix:
516-
build: [ubuntu, i686-linux, aarch64-linux, powerpc64le-linux, riscv64-linux, s390x-linux, arm-linux]
546+
build: [ubuntu, i686-linux, aarch64-linux, powerpc-linux, powerpc64le-linux, riscv64-linux, s390x-linux, arm-linux]
517547
include:
518548
- build: ubuntu
519549
os: ubuntu-latest
@@ -534,7 +564,16 @@ jobs:
534564
qemu: qemu-aarch64
535565
qemu_args: -L /usr/aarch64-linux-gnu
536566
qemu_target: aarch64-linux-user
537-
- build: powerpc64le-linux
567+
- build: powerpc-linux
568+
os: ubuntu-latest
569+
rust: stable
570+
target: powerpc-unknown-linux-gnu
571+
gcc_package: gcc-powerpc-linux-gnu
572+
gcc: powerpc-linux-gnu-gcc
573+
qemu: qemu-ppc
574+
qemu_args: -L /usr/powerpc-linux-gnu
575+
qemu_target: ppc-linux-user
576+
- build: powerpc-linux
538577
os: ubuntu-latest
539578
rust: stable
540579
target: powerpc64le-unknown-linux-gnu
@@ -652,8 +691,17 @@ jobs:
652691
runs-on: ${{ matrix.os }}
653692
strategy:
654693
matrix:
655-
build: [powerpc64le-linux, s390x-linux]
694+
build: [powerpc-linux, powerpc64le-linux, s390x-linux]
656695
include:
696+
- build: powerpc-linux
697+
os: ubuntu-latest
698+
rust: nightly
699+
target: powerpc-unknown-linux-gnu
700+
gcc_package: gcc-powerpc-linux-gnu
701+
gcc: powerpc-linux-gnu-gcc
702+
qemu: qemu-ppc
703+
qemu_args: -L /usr/powerpc-linux-gnu
704+
qemu_target: ppc-linux-user
657705
- build: powerpc64le-linux
658706
os: ubuntu-latest
659707
rust: nightly
@@ -676,6 +724,7 @@ jobs:
676724
# -D warnings is commented out in our install-rust action; re-add it here.
677725
RUSTFLAGS: --cfg rustix_use_experimental_asm -D warnings -D elided-lifetimes-in-paths
678726
RUSTDOCFLAGS: --cfg rustix_use_experimental_asm
727+
CARGO_TARGET_POWERPC_UNKNOWN_LINUX_GNU_RUSTFLAGS: --cfg rustix_use_experimental_asm
679728
CARGO_TARGET_POWERPC64LE_UNKNOWN_LINUX_GNU_RUSTFLAGS: --cfg rustix_use_experimental_asm
680729
CARGO_TARGET_S390X_UNKNOWN_LINUX_GNU_RUSTFLAGS: --cfg rustix_use_experimental_asm
681730
QEMU_BUILD_VERSION: 9.2.0

0 commit comments

Comments
 (0)