Skip to content

Commit ef8aa03

Browse files
author
Julian Brown
committed
ZC-12579: Build on AlmaLinux 10
1 parent 6ba3e61 commit ef8aa03

File tree

1 file changed

+52
-8
lines changed

1 file changed

+52
-8
lines changed

SPECS/ea-apache24.spec

Lines changed: 52 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@
2020
%global with_http2 0
2121
%endif
2222

23+
%if 0%{?rhel} >= 10
24+
%global __brp_check_rpaths %{nil}
25+
%endif
26+
2327
Summary: Apache HTTP Server
2428
Name: ea-apache24
2529
Version: 2.4.63
@@ -113,10 +117,21 @@ Requires: openssl
113117
BuildRequires: autoconf, perl, pkgconfig, findutils, xmlto
114118
BuildRequires: zlib-devel, libselinux-devel, lua-devel
115119
BuildRequires: ea-apr-devel >= 1.6.3-1, ea-apr-util-devel >= 1.6.1-1
116-
BuildRequires: pcre-devel >= 5.0
120+
121+
%if 0%{?rhel} >= 10
122+
BuildRequires: libxml2 libxml2-devel
123+
BuildRequires: pcre2-devel
124+
%else
117125
BuildRequires: ea-libxml2 ea-libxml2-devel
126+
BuildRequires: pcre-devel >= 5.0
127+
%endif
128+
118129
%if %{with_http2}
130+
%if 0%{?rhel} >= 10
131+
BuildRequires: nghttp2 libnghttp2
132+
%else
119133
BuildRequires: ea-nghttp2 ea-libnghttp2
134+
%endif
120135
%endif
121136

122137
%if 0%{?rhel} >=7
@@ -199,7 +214,11 @@ also be found at http://httpd.apache.org/docs/2.4/.
199214
%package -n ea-apache24-mod_http2
200215
Group: System Environment/Daemons
201216
Summary: HTTP2 module for Apache HTTP Server
217+
%if 0%{?rhel} >= 10
218+
BuildRequires: libnghttp2-devel
219+
%else
202220
BuildRequires: ea-libnghttp2-devel
221+
%endif
203222

204223
%if 0%{?rhel} < 8
205224
BuildRequires: ea-openssl11 >= %{ea_openssl_ver}, ea-openssl11-devel >= %{ea_openssl_ver}
@@ -210,7 +229,12 @@ BuildRequires: openssl, openssl-devel
210229
Requires: openssl
211230
%endif
212231

232+
%if 0%{?rhel} >= 10
233+
Requires: nghttp2
234+
%else
213235
Requires: ea-nghttp2
236+
%endif
237+
214238
Requires: ea-apache24 = 0:%{version}-%{release}, ea-apache24-mmn = %{mmnisa}
215239
Conflicts: ea-apache24-mod_mpm_itk, ea-apache24-mod_mpm_prefork
216240

@@ -412,8 +436,13 @@ authentication module, such as mod_auth_basic or mod_auth_digest.
412436
Group: System Environment/Daemons
413437
Summary: Compress content via Brotli before it is delivered to the client
414438
Requires: ea-apache24 = 0:%{version}-%{release}, ea-apache24-mmn = %{mmnisa}
439+
%if 0%{?rhel} >= 10
440+
Requires: brotli
441+
BuildRequires: brotli-devel
442+
%else
415443
Requires: ea-brotli
416444
BuildRequires: ea-brotli-devel
445+
%endif
417446

418447
%description -n ea-apache24-mod_brotli
419448
The mod_brotli module provides the BROTLI_COMPRESS output filter that allows
@@ -1030,7 +1059,11 @@ Group: System Environment/Daemons
10301059
Summary: HTML and XML content filters for the Apache HTTP Server
10311060
Requires: ea-apache24 = 0:%{version}-%{release}, ea-apache24-mmn = %{mmnisa}
10321061
Requires: ea-apache24-mod_proxy = 0:%{version}-%{release}
1062+
%if 0%{?rhel} >= 10
1063+
BuildRequires: libxml2 libxml2-devel
1064+
%else
10331065
BuildRequires: ea-libxml2 ea-libxml2-devel
1066+
%endif
10341067
Obsoletes: mod_proxy_html
10351068

10361069
%description -n ea-apache24-mod_proxy_html
@@ -1432,7 +1465,11 @@ export LYNX_PATH=/usr/bin/links
14321465
--enable-ssl --with-ssl \
14331466
%endif
14341467
--enable-ssl-staticlib-deps \
1468+
%if 0%{?rhel} >= 10
1469+
--with-nghttp2 \
1470+
%else
14351471
--with-nghttp2=/opt/cpanel/nghttp2/ \
1472+
%endif
14361473
--enable-nghttp2-staticlib-deps \
14371474
%else
14381475
--enable-ssl --with-ssl \
@@ -1449,10 +1486,16 @@ export LYNX_PATH=/usr/bin/links
14491486
--enable-authn-alias \
14501487
--enable-imagemap \
14511488
--disable-echo \
1452-
--with-libxml2=/opt/cpanel/ea-libxml2/include/libxml2 \
1453-
--disable-v4-mapped \
14541489
--enable-brotli \
1490+
%if 0%{?rhel} >= 10
1491+
--enable-libxml2 \
1492+
%else
1493+
--with-libxml2=/opt/cpanel/ea-libxml2/include/libxml2 \
14551494
--with-brotli=/opt/cpanel/ea-brotli \
1495+
%endif
1496+
--disable-v4-mapped \
1497+
%if 0%{?rhel} >= 10
1498+
%else
14561499
MOD_PROXY_HTML_LDADD="-L/opt/cpanel/ea-libxml2/%{_lib} -R/opt/cpanel/ea-libxml2/%{_lib}" \
14571500
MOD_XML2ENC_LDADD="-L/opt/cpanel/ea-libxml2/%{_lib} -R/opt/cpanel/ea-libxml2/%{_lib}" \
14581501
MOD_BROTLI_LDADD="-L/opt/cpanel/ea-brotli/lib -R/opt/cpanel/ea-brotli/lib" \
@@ -1462,10 +1505,12 @@ export LYNX_PATH=/usr/bin/links
14621505
%if %{with_http2}
14631506
MOD_HTTP2_LDADD="-L/opt/cpanel/ea-openssl11/%{_lib} -R/opt/cpanel/ea-openssl11/%{_lib}" \
14641507
%endif
1508+
%endif
14651509
%endif
14661510
$*
14671511

14681512
%if 0%{?rhel} >= 8
1513+
%if 0%{?rhel} < 10
14691514
# This is ugly, very ugly.
14701515
# ZC-6833 was created to eventually come up with a proper solution for these
14711516
# linking issues.
@@ -1475,11 +1520,6 @@ export LYNX_PATH=/usr/bin/links
14751520
# link against the system directory, then -l:libcrypto.so.1.1 I am telling it
14761521
# to link that particular library in.
14771522

1478-
# I need to prepend this for later "sed"ing
1479-
%if 0%{?rhel} < 8
1480-
echo 'SYS_OPENSSL = -Wl,-rpath=/opt/cpanel/ea-openssl11/lib -Wl,-rpath-link=/lib64 -L/lib64 -l:libcrypto.so.1.1' > support/Makefile.tmp
1481-
%endif
1482-
14831523
cat support/Makefile >> support/Makefile.tmp
14841524
cp -f support/Makefile.tmp support/Makefile
14851525

@@ -1489,6 +1529,7 @@ sed -i '/^.*PROGRAM_LDADD[ \t]*=.*$/ s/$/ $(SYS_OPENSSL)/' support/Makefile
14891529
# ab, does it's own thing so I need to do our thing
14901530
sed -i '/^.*$(LT_LDFLAGS) $(ALL_LDFLAGS) -o $@ $(ab_LTFLAGS) $(ab_OBJECTS) $(ab_LDADD).*$/ s/$/ $(SYS_OPENSSL)/' support/Makefile
14911531
%endif
1532+
%endif
14921533

14931534
make %{?_smp_mflags}
14941535

@@ -1820,6 +1861,9 @@ for fd in httpd-dav.conf httpd-default.conf httpd-languages.conf httpd-manual.co
18201861
cp docs/conf/extra/$fd $RPM_BUILD_ROOT/usr/share/doc/ea-apache24/docs/conf/extra/$fd
18211862
done
18221863

1864+
echo "APACHEMODULES" $RPM_BUILD_ROOT $RPM_BUILD_ROOT/%{_libdir} $RPM_BUILD_ROOT/%{_libdir}/apache2/modules
1865+
ls -ld $RPM_BUILD_ROOT/%{_libdir}/apache2/modules/* || /bin/true
1866+
18231867
%pre
18241868
%include %{SOURCE46}
18251869

0 commit comments

Comments
 (0)