From: Remi Gacogne Date: Thu, 27 Mar 2025 09:41:19 +0000 (+0100) Subject: dnsdist: Fix build on amazonlinux 2023 X-Git-Tag: dnsdist-2.0.0-alpha2~108^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=52f4a9e6d4085f6db86d0ddbb4eaa47ea934a107;p=thirdparty%2Fpdns.git dnsdist: Fix build on amazonlinux 2023 --- diff --git a/builder-support/specs/dnsdist.spec b/builder-support/specs/dnsdist.spec index 056d3b733d..b50b7e1f96 100644 --- a/builder-support/specs/dnsdist.spec +++ b/builder-support/specs/dnsdist.spec @@ -82,8 +82,13 @@ export LDFLAGS="-fuse-ld=lld -Wl,--build-id=sha1" %else %define cf_protection -fcf-protection %endif -export CFLAGS="-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection %{cf_protection} -gdwarf-4" -export CXXFLAGS="-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection %{cf_protection} -gdwarf-4" +%if "%{_arch}" == "aarch64" && 0%{?amzn2023} +%define stack_clash_protection %{nil} +%else +%define stack_clash_protection -fstack-clash-protection +%endif +export CFLAGS="-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -m64 -mtune=generic -fasynchronous-unwind-tables %{stack_clash_protection} %{cf_protection} -gdwarf-4" +export CXXFLAGS="-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -m64 -mtune=generic -fasynchronous-unwind-tables %{stack_clash_protection} %{cf_protection} -gdwarf-4" %endif #export AR=gcc-ar @@ -114,7 +119,7 @@ export PKG_CONFIG_PATH=/usr/lib/pkgconfig:/opt/lib64/pkgconfig -Dre2=enabled \ -Ddns-over-quic=enabled \ -Ddns-over-http3=enabled \ -%ifarch aarch64 +%if "%{_arch}" == "aarch64" || 0%{?amzn2023} -Dxsk=disabled \ %endif -Dyaml=enabled