Skip to content

Commit c86c90d

Browse files
committed
Attempt at ppc64 CI
This assumes gentoo (which has best ppc64be support of mainstream distributions). (Rebased onto the new workflow_call approach)
1 parent 11937b3 commit c86c90d

File tree

4 files changed

+201
-0
lines changed

4 files changed

+201
-0
lines changed
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
name: ./configure
2+
inputs:
3+
configurationParameters:
4+
default: ''
5+
required: false
6+
skipSlow:
7+
default: false
8+
required: false
9+
runs:
10+
using: composite
11+
steps:
12+
- shell: bash
13+
run: |
14+
set -x
15+
./buildconf --force
16+
./configure \
17+
--enable-option-checking=fatal \
18+
--prefix=/usr \
19+
--enable-phpdbg \
20+
--enable-fpm \
21+
--with-pdo-mysql=mysqlnd \
22+
--with-mysqli=mysqlnd \
23+
${{ inputs.skipSlow == 'false' && '--with-pgsql' || '' }} \
24+
${{ inputs.skipSlow == 'false' && '--with-pdo-pgsql' || '' }} \
25+
${{ inputs.skipSlow == 'false' && '--with-pdo-sqlite' || '' }} \
26+
--enable-intl \
27+
--without-pear \
28+
--enable-gd \
29+
--with-jpeg \
30+
--with-webp \
31+
--with-freetype \
32+
--with-xpm \
33+
--enable-exif \
34+
--with-zip \
35+
--with-zlib \
36+
--enable-soap \
37+
--enable-xmlreader \
38+
--with-xsl \
39+
${{ inputs.skipSlow == 'false' && '--with-tidy' || '' }} \
40+
--enable-sysvsem \
41+
--enable-sysvshm \
42+
--enable-shmop \
43+
--enable-pcntl \
44+
--with-readline \
45+
--enable-mbstring \
46+
--with-iconv=/usr \
47+
--with-curl \
48+
--with-gettext \
49+
--enable-sockets \
50+
--with-bz2 \
51+
--with-openssl \
52+
--with-gmp \
53+
--enable-bcmath \
54+
--enable-calendar \
55+
--enable-ftp \
56+
${{ inputs.skipSlow == 'false' && '--with-enchant=/usr' || '' }} \
57+
--enable-sysvmsg \
58+
--with-ffi \
59+
--enable-zend-test \
60+
${{ inputs.skipSlow == 'false' && '--enable-dl-test=shared' || '' }} \
61+
${{ inputs.skipSlow == 'false' && '--with-ldap' || '' }} \
62+
${{ inputs.skipSlow == 'false' && '--with-ldap-sasl' || '' }} \
63+
--with-password-argon2 \
64+
--with-mhash \
65+
--with-sodium \
66+
--enable-dba \
67+
--with-cdb \
68+
--enable-flatfile \
69+
--enable-inifile \
70+
--with-lmdb \
71+
--with-gdbm \
72+
${{ inputs.skipSlow == 'false' && '--with-snmp' || '' }} \
73+
${{ inputs.skipSlow == 'false' && '--with-unixODBC' || '' }} \
74+
${{ inputs.skipSlow == 'false' && '--with-pdo-odbc=unixODBC,/usr' || '' }} \
75+
--with-config-file-path=/etc \
76+
--with-config-file-scan-dir=/etc/php.d \
77+
${{ inputs.skipSlow == 'false' && '--with-pdo-dblib' || '' }} \
78+
--enable-werror \
79+
${{ inputs.configurationParameters }}

.github/actions/emerge/action.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: emerge
2+
runs:
3+
using: composite
4+
steps:
5+
- shell: sh
6+
# Omitting libiconv from glibc system
7+
# XXX: mysql-client needed? IMAP i don't think so anymore either
8+
# XXX: Set USE flags appropriately to i.e. avoid installing servers
9+
# (though if they're masked it doesn't matter)
10+
# XXX: For now this is nopped out since it doesn't run in a container yet
11+
run: |
12+
emerge --noreplace \
13+
sys-apps/util-linux \
14+
app-shells/bash \
15+
app-admin/sudo \
16+
dev-build/autoconf \
17+
app-arch/unzip \
18+
app-arch/tar \
19+
sys-devel/bison \
20+
dev-util/re2c \
21+
dev-util/pkgconf \
22+
app-arch/bzip2 \
23+
net-misc/curl \
24+
media-libs/freetype \
25+
sys-devel/gettext \
26+
dev-libs/gmp \
27+
dev-libs/icu \
28+
media-libs/libjpeg-turbo \
29+
dev-libs/libffi \
30+
media-libs/libpng \
31+
dev-libs/libsodium \
32+
media-libs/libwebp \
33+
dev-libs/libxml2 \
34+
x11-libs/libXpm \
35+
dev-libs/libxslt \
36+
dev-libs/libzip \
37+
dev-libs/oniguruma \
38+
dev-libs/openssl \
39+
dev-libs/libedit \
40+
dev-db/sqlite \
41+
app-text/htmltidy \
42+
sys-libs/gdbm \
43+
dev-db/lmdb \
44+
app-crypt/argon2 \
45+
app-text/enchant \
46+
dev-db/freetds \
47+
net-analyzer/net-snmp \
48+
net-nds/openldap \
49+
dev-db/unixODBC \
50+
dev-db/postgresql
51+
|| true
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Test
2+
inputs:
3+
runTestsParameters:
4+
default: ''
5+
required: false
6+
runs:
7+
using: composite
8+
steps:
9+
- shell: bash
10+
run: |
11+
set -x
12+
# XXX: Set up database tests?
13+
export SKIP_IO_CAPTURE_TESTS=1
14+
export STACK_LIMIT_DEFAULTS_CHECK=1
15+
sapi/cli/php run-tests.php -P -q ${{ inputs.runTestsParameters }} \
16+
-j$(nproc) \
17+
-g FAIL,BORK,LEAK,XLEAK \
18+
--no-progress \
19+
--show-diff \
20+
--show-slow 1000 \
21+
--set-timeout 120

.github/workflows/nightly.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@ on:
1717
run_alpine:
1818
required: true
1919
type: boolean
20+
run_linux_ppc64:
21+
required: true
22+
type: boolean
2023
run_macos_arm64:
2124
required: true
2225
type: boolean
@@ -29,6 +32,53 @@ on:
2932
permissions:
3033
contents: read
3134
jobs:
35+
LINUX_PPC64:
36+
needs: GENERATE_MATRIX
37+
if: inputs.run_linux_ppc64
38+
strategy:
39+
fail-fast: false
40+
matrix:
41+
include: ${{ fromJson(needs.GENERATE_MATRIX.outputs.alpine-matrix-include) }}
42+
name: LINUX_PPC64_ASAN_UBSAN_DEBUG_ZTS
43+
runs-on: [self-hosted, gentoo, ppc64]
44+
steps:
45+
- name: git checkout
46+
uses: actions/checkout@v4
47+
with:
48+
ref: ${{ matrix.branch.ref }}
49+
- name: emerge
50+
uses: ./.github/actions/emerge
51+
- name: System info
52+
run: |
53+
echo "::group::Show host CPU info"
54+
lscpu
55+
echo "::endgroup::"
56+
echo "::group::Show installed packages"
57+
cat /var/lib/portage/world
58+
echo "::endgroup::"
59+
- name: ./configure
60+
uses: ./.github/actions/configure-gentoo
61+
with:
62+
configurationParameters: >-
63+
CFLAGS="-fsanitize=undefined,address -fno-sanitize=function -DZEND_TRACK_ARENA_ALLOC"
64+
LDFLAGS="-fsanitize=undefined,address -fno-sanitize=function"
65+
--enable-debug
66+
--enable-zts
67+
skipSlow: true # FIXME: This should likely include slow extensions
68+
- name: make
69+
run: make -j$(/usr/bin/nproc) >/dev/null
70+
# Skip an install action for now
71+
- name: Tests
72+
uses: ./.github/actions/test-gentoo
73+
# There is no PPC JIT, so rip this out
74+
with:
75+
runTestsParameters: >-
76+
--asan -x
77+
- name: Notify Slack
78+
if: failure()
79+
uses: ./.github/actions/notify-slack
80+
with:
81+
token: ${{ secrets.ACTION_MONITORING_SLACK }}
3282
ALPINE:
3383
if: inputs.run_alpine
3484
name: ALPINE_X64_ASAN_UBSAN_DEBUG_ZTS

0 commit comments

Comments
 (0)