From 814245121b35c615c42ad7fd7d69c2f1bdfdadc9 Mon Sep 17 00:00:00 2001 From: Bertrand Jacquin Date: Tue, 9 Apr 2024 23:21:29 +0100 Subject: net-p2p/monero: monero-0.18.3.3-build-remove-mcpu-march-mtune.patch --- ...ro-0.18.3.3-build-remove-mcpu-march-mtune.patch | 61 ++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 net-p2p/monero/files/monero-0.18.3.3-build-remove-mcpu-march-mtune.patch (limited to 'net-p2p/monero/files') diff --git a/net-p2p/monero/files/monero-0.18.3.3-build-remove-mcpu-march-mtune.patch b/net-p2p/monero/files/monero-0.18.3.3-build-remove-mcpu-march-mtune.patch new file mode 100644 index 00000000..93e43f91 --- /dev/null +++ b/net-p2p/monero/files/monero-0.18.3.3-build-remove-mcpu-march-mtune.patch @@ -0,0 +1,61 @@ +From 50254221d25cf7d9cd90d314d75c5d0ac732f704 Mon Sep 17 00:00:00 2001 +From: Bertrand Jacquin +Date: Tue, 9 Apr 2024 21:47:47 +0100 +Subject: [PATCH] build: remove mcpu/march/mtune + +cc1plus: warning: switch '-mcpu=neoverse-n1+crc+crypto+ssbs' conflicts with '-march=armv8-a+crypto' switch +--- + CMakeLists.txt | 33 +-------------------------------- + 1 file changed, 1 insertion(+), 32 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 8fb03ba1ff02..d70d2dc8e098 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -716,32 +716,6 @@ if(MSVC) + else() + include(TestCXXAcceptsFlag) + message(STATUS "Building on ${CMAKE_SYSTEM_PROCESSOR} for ${ARCH}") +- if(ARCH STREQUAL "default") +- set(ARCH_FLAG "") +- elseif(PPC64LE) +- set(ARCH_FLAG "-mcpu=power8") +- elseif(PPC64) +- set(ARCH_FLAG "-mcpu=970") +- elseif(PPC) +- set(ARCH_FLAG "-mcpu=7400") +- elseif(IOS AND ARCH STREQUAL "arm64") +- message(STATUS "IOS: Changing arch from arm64 to armv8") +- set(ARCH_FLAG "-march=armv8") +- else() +- set(ARCH_FLAG "-march=${ARCH}") +- if(ARCH STREQUAL "native") +- check_c_compiler_flag(-march=native CC_SUPPORTS_MARCH_NATIVE) +- if (NOT CC_SUPPORTS_MARCH_NATIVE) +- check_c_compiler_flag(-mtune=native CC_SUPPORTS_MTUNE_NATIVE) +- if (CC_SUPPORTS_MTUNE_NATIVE) +- set(ARCH_FLAG "-mtune=${ARCH}") +- else() +- set(ARCH_FLAG "") +- endif() +- endif() +- endif() +- endif() +- + option(NO_AES "Explicitly disable AES support" ${NO_AES}) + + if(NO_AES) +@@ -764,12 +738,7 @@ else() + message(STATUS "AES support not available on ARMv7") + elseif(ARM8) + CHECK_CXX_ACCEPTS_FLAG("-march=${ARCH}+crypto" ARCH_PLUS_CRYPTO) +- if(ARCH_PLUS_CRYPTO) +- message(STATUS "Crypto extensions enabled for ARMv8") +- set(ARCH_FLAG "-march=${ARCH}+crypto") +- else() +- message(STATUS "Crypto extensions unavailable on your ARMv8 device") +- endif() ++ message(STATUS "${ARCH_PLUS_CRYPTO}") + else() + message(STATUS "AES support disabled") + endif() -- cgit v1.2.3