summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2025-04-20 17:57:02 +0800
committerErik Kundiman <erik@megapahit.org>2025-04-20 17:57:02 +0800
commita5677bc0390e2c0db0c0b8d4353b7423c555894b (patch)
tree98aeb4a8c511beb1bf9bd11ed2275a6167d75f8c
parentad9c801edb13568657c0964ebfb74257da6d9e00 (diff)
Get the custom cURL compiled on Fedora Asahi RemixHEADmain
getpwuid_r, which is declared in /usr/include/pwd.h, somehow is always missed by, at least the custom, libcurl compiling process. I tried defining __USE_POSIX so the getpwuid_r part in pwd.h is included, I also tried undefining HAVE_GETPWUID_R so the getpwuid_r part in curl/lib/netrc.c is skipped (respectively using -D and -U CPPFLAGS ENV setting in indra/cmake/CURL.cmake), with no success. So just force the getpwuid_r part in netrc.c to be skipped by substituting defined(HAVE_GETPWUID_R) with 0.
-rw-r--r--indra/cmake/CURL.cmake6
1 files changed, 6 insertions, 0 deletions
diff --git a/indra/cmake/CURL.cmake b/indra/cmake/CURL.cmake
index 8407aa1f1d..00173e5418 100644
--- a/indra/cmake/CURL.cmake
+++ b/indra/cmake/CURL.cmake
@@ -38,6 +38,12 @@ elseif (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRA
INPUT ${CMAKE_BINARY_DIR}/3p-curl-7.54.1-r1.tar.gz
DESTINATION ${CMAKE_BINARY_DIR}
)
+ if (CMAKE_SYSTEM_PROCESSOR MATCHES aarch64 AND (${LINUX_DISTRO} MATCHES fedora))
+ execute_process(
+ COMMAND sed -i netrc.c -e "s/defined(HAVE_GETPWUID_R)/0/g" netrc.c
+ WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/3p-curl-7.54.1-r1/curl/lib
+ )
+ endif ()
file(
COPY
${CMAKE_BINARY_DIR}/3p-curl-7.54.1-r1/curl/include/curl/curl.h