From 387ffe941959ab8fa849e5afbe654b15fa9447fe Mon Sep 17 00:00:00 2001 From: Will Schroeder Date: Thu, 7 Oct 2004 17:17:11 -0400 Subject: [PATCH] FIX: broken sun build --- Source/CTest/Curl/CMake/CurlTests.c | 2 ++ Source/CTest/Curl/CMakeLists.txt | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/Source/CTest/Curl/CMake/CurlTests.c b/Source/CTest/Curl/CMake/CurlTests.c index 52547166d..fba8dc42d 100644 --- a/Source/CTest/Curl/CMake/CurlTests.c +++ b/Source/CTest/Curl/CMake/CurlTests.c @@ -412,8 +412,10 @@ int main(void) { return 0; } #endif +#ifdef HAVE_FILE_OFFSET_BITS #ifdef _FILE_OFFSET_BITS #undef _FILE_OFFSET_BITS +#endif #define _FILE_OFFSET_BITS 64 #include /* Check that off_t can represent 2**63 - 1 correctly. diff --git a/Source/CTest/Curl/CMakeLists.txt b/Source/CTest/Curl/CMakeLists.txt index deadb9609..3d2880c29 100644 --- a/Source/CTest/Curl/CMakeLists.txt +++ b/Source/CTest/Curl/CMakeLists.txt @@ -400,10 +400,13 @@ FOREACH(CURL_TEST HAVE_INET_NTOA_R_DECL HAVE_INET_NTOA_R_DECL_REENTRANT HAVE_GETADDRINFO - _FILE_OFFSET_BITS + HAVE_FILE_OFFSET_BITS ) CURL_INTERNAL_TEST(${CURL_TEST}) ENDFOREACH(CURL_TEST) +IF(HAVE_FILE_OFFSET_BITS) + SET(_FILE_OFFSET_BITS 64) +ENDIF(HAVE_FILE_OFFSET_BITS) # Check for reentrant FOREACH(CURL_TEST