Skip to content

Commit 94f568b

Browse files
authored
Add OpenBSD and very old RHEL autoconf 2.69 CI builds (#822)
Also raise minimum Autoconf requirement to 2.69 to match what we test.
1 parent 2ff92d7 commit 94f568b

File tree

6 files changed

+112
-4
lines changed

6 files changed

+112
-4
lines changed

.github/workflows/build.yml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ on:
1414
- macos
1515
- windows
1616
- freebsd
17+
- openbsd
1718
- solaris
1819
- zos
1920
- distcheck
@@ -343,6 +344,63 @@ jobs:
343344
../maint/RunManifestTest install-dir ../maint/manifest-cmakeinstall-freebsd
344345
../maint/RunSymbolTest install-dir/lib/ ../maint/
345346
347+
openbsd:
348+
name: OpenBSD
349+
runs-on: ubuntu-latest
350+
if: |
351+
(github.event_name == 'workflow_dispatch' && (inputs.job_id == 'all' || inputs.job_id == 'openbsd')) ||
352+
github.event_name == 'push'
353+
steps:
354+
- name: Checkout
355+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
356+
with:
357+
submodules: true
358+
359+
- name: Prepare
360+
run: ./autogen.sh
361+
362+
- name: Build & test
363+
uses: vmactions/openbsd-vm@1e7cc4fa7727646d3cf5921289b1f5c9d1a88f3c # v1.2.0
364+
with:
365+
envs: 'CFLAGS_GCC_STYLE CMAKE_FLAGS'
366+
usesh: true
367+
prepare: |
368+
set -e
369+
pkg_add cmake
370+
371+
run: |
372+
set -e
373+
374+
export MALLOC_OPTIONS="USRJGFC>>"
375+
EXTRA_CFLAGS="-DSLJIT_WX_EXECUTABLE_ALLOCATOR"
376+
377+
cp -rp . ../build-autoconf
378+
cp -rp . ../build-cmake
379+
380+
echo "== Autoconf =="
381+
cd ../build-autoconf
382+
383+
./configure CFLAGS="$CFLAGS_GCC_STYLE $EXTRA_CFLAGS" --enable-jit --enable-pcre2-16 --enable-pcre2-32 --enable-Werror
384+
make -j3
385+
(make check; rc=$?; for i in test-suite.log Run*Test.log pcre2*_test.log; do echo "== $i =="; cat $i; done; exit $rc)
386+
387+
make install "DESTDIR=`pwd`/install-dir"
388+
# I don't really know enough about OpenBSD to say whether the unusually-numbered .so files
389+
# with no symlinks are correct or not.
390+
# maint/RunManifestTest install-dir maint/manifest-makeinstall-openbsd
391+
# maint/RunSymbolTest install-dir/usr/local/lib/ maint/
392+
393+
echo "== CMake =="
394+
cd ../build-cmake
395+
396+
cmake $CMAKE_FLAGS -DPCRE2_SUPPORT_JIT=ON -DPCRE2_BUILD_PCRE2_16=ON -DPCRE2_BUILD_PCRE2_32=ON -DBUILD_SHARED_LIBS=ON -DBUILD_STATIC_LIBS=ON -DPCRE2_DEBUG=ON -DCMAKE_C_FLAGS="$CFLAGS_GCC_STYLE $EXTRA_CFLAGS" -DCMAKE_COMPILE_WARNING_AS_ERROR=ON -DCMAKE_BUILD_TYPE=Release -B build
397+
cd build
398+
make -j3
399+
ctest -j3 --output-on-failure && (cat ./Testing/Temporary/LastTest.log || true)
400+
cmake --install . --prefix install-dir
401+
# ../maint/RunManifestTest install-dir ../maint/manifest-cmakeinstall-openbsd
402+
# ../maint/RunSymbolTest install-dir/lib/ ../maint/
403+
346404
solaris:
347405
name: Solaris
348406
runs-on: ubuntu-latest

.github/workflows/dev.yml

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ on:
1313
- dragon
1414
- greatawk
1515
- dodo
16+
- passenger
1617
- wasp
1718
- bat
1819
- pterodactyl
@@ -176,7 +177,7 @@ jobs:
176177
done
177178
178179
dodo:
179-
# Tests with: Autconf on oldest supported Ubuntu (in non-extended support)
180+
# Tests with: Autoconf on oldest supported Ubuntu (in non-extended support)
180181
name: GCC -Os, old Autotools
181182
runs-on: ubuntu-latest
182183
container: ubuntu:22.04
@@ -212,6 +213,44 @@ jobs:
212213
maint/RunManifestTest install-dir maint/manifest-makeinstall-linux
213214
maint/RunSymbolTest install-dir/usr/local/lib/ maint/
214215
216+
passenger:
217+
# Tests with: Autoconf on oldest RHEL (in extended support).
218+
# That's the absolute limit to how old a Linux version I'll tolerate regular testing on.
219+
name: GCC, very old Autotools
220+
runs-on: ubuntu-latest
221+
container: redhat/ubi8:8.6
222+
if: github.event_name != 'workflow_dispatch' || (inputs.job_id == 'all' || inputs.job_id == 'passenger')
223+
steps:
224+
- name: Setup
225+
run: |
226+
yum -q makecache
227+
yum -q install -y gcc git make automake autoconf libtool diffutils file glibc-langpack-en
228+
yum -q update -y glibc-common
229+
230+
- name: Checkout
231+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
232+
with:
233+
submodules: true
234+
235+
- name: Prepare
236+
run: ./autogen.sh
237+
238+
- name: Configure
239+
run: ./configure CFLAGS="-O0 $CFLAGS_GCC_STYLE" --enable-jit --enable-pcre2-16 --enable-pcre2-32 --enable-debug --enable-Werror
240+
241+
- name: Build
242+
run: make -j3
243+
244+
- name: Test
245+
run: (make check; rc=$?; for i in test-suite.log Run*Test.log pcre2*_test.log; do echo "== $i =="; cat $i; done; exit $rc)
246+
247+
248+
- name: Install
249+
run: |
250+
make install "DESTDIR=`pwd`/install-dir"
251+
maint/RunManifestTest install-dir maint/manifest-makeinstall-linux
252+
maint/RunSymbolTest install-dir/usr/local/lib/ maint/
253+
215254
wasp:
216255
# Tests with: French locale; oldest supported CMake; no JIT; -Os; libreadline
217256
name: GCC -Os, CMake+ninja, no JIT

RunGrepTest

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -859,8 +859,13 @@ if [ $? -ne 0 ]; then
859859
echo "RC=2" >>testtrygrep
860860
else
861861

862-
(cd $srcdir; unset LC_ALL; LC_CTYPE=locale.bad $valgrind $vjs $pcre2grep abc /dev/null) >>testtrygrep 2>&1
862+
(cd $srcdir; unset LC_ALL; LC_CTYPE=locale.bad; export LC_CTYPE; $valgrind $vjs $pcre2grep abc /dev/null >>$builddir/testtrygrep 2>&1) >testtemp1grep 2>&1
863863
echo "RC=$?" >>testtrygrep
864+
shell_errors=`cat testtemp1grep`
865+
if [ x"$shell_errors" != x ] ; then
866+
printf "shell errors during locale test: "
867+
echo "$shell_errors"
868+
fi
864869
fi
865870

866871
echo "---------------------------- Test 151 -----------------------------" >>testtrygrep

autogen.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
# variants like glibtoolize (MacOSX) and libtoolize1x (FreeBSD)
1111

1212
set +ex
13+
1314
echo "Looking for a version of libtoolize (which can have different names)..."
1415
libtoolize=""
1516
for l in glibtoolize libtoolize15 libtoolize14 libtoolize ; do
@@ -27,7 +28,12 @@ if [ "x$libtoolize" = "x" ]; then
2728
exit 1
2829
fi
2930

31+
$libtoolize --version | head -n1
32+
autoconf --version | head -n1
33+
automake --version | head -n1
34+
3035
set -ex
36+
3137
$libtoolize -c -f
3238
rm -rf autom4te.cache Makefile.in aclocal.m4
3339
aclocal --force -I m4

configure.ac

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ m4_define(libpcre2_posix_version, [3:6:0])
2222
# NOTE: The CMakeLists.txt file searches for the above variables in the first
2323
# 50 lines of this file. Please update that if the variables above are moved.
2424

25-
AC_PREREQ([2.62])
25+
AC_PREREQ([2.69])
2626
AC_INIT([PCRE2],pcre2_major.pcre2_minor[]pcre2_prerelease,[],[pcre2])
2727
AC_CONFIG_SRCDIR([src/pcre2.h.in])
2828
AM_INIT_AUTOMAKE([dist-bzip2 dist-zip foreign])

maint/RunSymbolTest

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ for so_name in "libpcre2-8" "libpcre2-16" "libpcre2-32" "libpcre2-posix"; do
8787
$grep -E -v '^[Uw] ' | \
8888
$grep -E -v '^A PCRE2_' | \
8989
$grep -E -v ' (_init|_fini)($|@)' | \
90-
$grep -E -v ' (_end|_DYNAMIC|_GLOBAL_OFFSET_TABLE_|_PROCEDURE_LINKAGE_TABLE_|_edata|_etext)($|@)' | \
90+
$grep -E -v ' (__bss_start|_end|_DYNAMIC|_GLOBAL_OFFSET_TABLE_|_PROCEDURE_LINKAGE_TABLE_|_edata|_etext)($|@)' | \
9191
so_mangling | \
9292
sort \
9393
> "$base.actual"

0 commit comments

Comments
 (0)