From: Viktor Szakats Date: Thu, 8 Jan 2026 14:54:17 +0000 (+0100) Subject: build: detect and include `inttypes.h` again (revert) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9552d9c0c03d9c4a813439607201ef76eb750077;p=thirdparty%2Fcurl.git build: detect and include `inttypes.h` again (revert) Since not using `PRI*` macros, it isn't needed. Follow-up to 13c1a934144e98d06214a043ff4538791c7d9583 #20215 Revert 4c9e4e99c107b8d0bda5b204c5b69a50425567b9 #20208 Closes #20225 --- diff --git a/.github/scripts/cmp-config.pl b/.github/scripts/cmp-config.pl index f12022dd5a..e831a97211 100755 --- a/.github/scripts/cmp-config.pl +++ b/.github/scripts/cmp-config.pl @@ -48,6 +48,7 @@ my %remove = ( '#define HAVE_GSSAPI_GSSAPI_GENERIC_H 1' => 1, '#define HAVE_GSSAPI_GSSAPI_H 1' => 1, '#define HAVE_GSSAPI_GSSAPI_KRB5_H 1' => 1, + '#define HAVE_INTTYPES_H 1' => 1, '#define HAVE_LDAP_H 1' => 1, '#define HAVE_LDAP_SSL 1' => 1, '#define HAVE_LIBBROTLIDEC 1' => 1, diff --git a/CMake/unix-cache.cmake b/CMake/unix-cache.cmake index 821349cda3..f3db9f0e97 100644 --- a/CMake/unix-cache.cmake +++ b/CMake/unix-cache.cmake @@ -151,7 +151,6 @@ set(HAVE_IFADDRS_H 1) set(HAVE_IF_NAMETOINDEX 1) set(HAVE_INET_NTOP 1) set(HAVE_INET_PTON 1) -set(HAVE_INTTYPES_H 1) set(HAVE_IOCTLSOCKET 0) set(HAVE_IOCTLSOCKET_CAMEL 0) set(HAVE_IOCTLSOCKET_CAMEL_FIONBIO 0) diff --git a/CMake/win32-cache.cmake b/CMake/win32-cache.cmake index 27cb57057a..e704d2195b 100644 --- a/CMake/win32-cache.cmake +++ b/CMake/win32-cache.cmake @@ -31,7 +31,6 @@ if(MINGW) set(HAVE_DIRENT_H 1) set(HAVE_FTRUNCATE 1) set(HAVE_GETTIMEOFDAY 1) - set(HAVE_INTTYPES_H 1) set(HAVE_LIBGEN_H 1) set(HAVE_OPENDIR 1) set(HAVE_SNPRINTF 1) @@ -56,10 +55,8 @@ else() set(HAVE_STDDEF_H 1) # detected by CMake internally in check_type_size() set(HAVE_STDINT_H 1) # detected by CMake internally in check_type_size() if(MSVC_VERSION GREATER_EQUAL 1800) - set(HAVE_INTTYPES_H 1) set(HAVE_STDBOOL_H 1) else() - set(HAVE_INTTYPES_H 0) set(HAVE_STDBOOL_H 0) endif() set(HAVE_BOOL_T "${HAVE_STDBOOL_H}") diff --git a/CMakeLists.txt b/CMakeLists.txt index 975f7670c7..8e5383ac98 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1461,7 +1461,6 @@ check_include_file_concat_curl("arpa/inet.h" HAVE_ARPA_INET_H) check_include_file("dirent.h" HAVE_DIRENT_H) check_include_file("fcntl.h" HAVE_FCNTL_H) check_include_file_concat_curl("ifaddrs.h" HAVE_IFADDRS_H) -check_include_file("inttypes.h" HAVE_INTTYPES_H) check_include_file("io.h" HAVE_IO_H) check_include_file_concat_curl("libgen.h" HAVE_LIBGEN_H) check_include_file("linux/tcp.h" HAVE_LINUX_TCP_H) diff --git a/lib/config-os400.h b/lib/config-os400.h index 9307b44f51..ec6c002efd 100644 --- a/lib/config-os400.h +++ b/lib/config-os400.h @@ -96,9 +96,6 @@ /* Define if you have the `timeval' struct. */ #define HAVE_STRUCT_TIMEVAL -/* Define if you have the header file. */ -#define HAVE_INTTYPES_H - /* Define if you have the header file. */ #undef HAVE_IO_H diff --git a/lib/config-plan9.h b/lib/config-plan9.h index 5bae684b1e..5303ab3399 100644 --- a/lib/config-plan9.h +++ b/lib/config-plan9.h @@ -83,7 +83,6 @@ #define HAVE_GMTIME_R 1 #define HAVE_INET_NTOP 1 #define HAVE_INET_PTON 1 -#define HAVE_INTTYPES_H 1 #define HAVE_LIBGEN_H 1 #define HAVE_LIBZ 1 #define HAVE_LOCALE_H 1 diff --git a/lib/config-riscos.h b/lib/config-riscos.h index b58b16dc60..3158c984ee 100644 --- a/lib/config-riscos.h +++ b/lib/config-riscos.h @@ -96,9 +96,6 @@ /* Define if you have the `timeval' struct. */ #define HAVE_STRUCT_TIMEVAL -/* Define if you have the header file. */ -#define HAVE_INTTYPES_H - /* Define if you have the header file. */ #undef HAVE_IO_H diff --git a/lib/config-win32.h b/lib/config-win32.h index 6374bd0e98..002782c6ea 100644 --- a/lib/config-win32.h +++ b/lib/config-win32.h @@ -82,11 +82,6 @@ /* Define if you have the header file. */ #define HAVE_FCNTL_H 1 -/* Define to 1 if you have the header file. */ -#if (defined(_MSC_VER) && (_MSC_VER >= 1800)) || defined(__MINGW32__) -#define HAVE_INTTYPES_H 1 -#endif - /* Define if you have the header file. */ #define HAVE_IO_H 1 diff --git a/lib/curl_config-cmake.h.in b/lib/curl_config-cmake.h.in index bde26eb984..d8d9d7ecbe 100644 --- a/lib/curl_config-cmake.h.in +++ b/lib/curl_config-cmake.h.in @@ -336,9 +336,6 @@ /* Define to 1 if symbol `sa_family_t' exists */ #cmakedefine HAVE_SA_FAMILY_T 1 -/* Define to 1 if you have the header file. */ -#cmakedefine HAVE_INTTYPES_H 1 - /* Define to 1 if you have the ioctlsocket function. */ #cmakedefine HAVE_IOCTLSOCKET 1 diff --git a/lib/curl_setup.h b/lib/curl_setup.h index c94dddb2dc..66b46a0749 100644 --- a/lib/curl_setup.h +++ b/lib/curl_setup.h @@ -471,10 +471,6 @@ #include -#ifdef HAVE_INTTYPES_H -#include -#endif - #ifdef _WIN32 # ifdef HAVE_IO_H # include