]> granicus.if.org Git - graphviz/commitdiff
CMake: remove checking and fallback for 'ssize_t'
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Thu, 8 Sep 2022 00:27:49 +0000 (17:27 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Wed, 23 Nov 2022 15:00:59 +0000 (07:00 -0800)
It seems all contemporary supported platforms except Windows have `ssize_t`.
Furthermore, `int` is not a suitable fallback for a platform that does not have
`ssize_t`.

CHANGELOG.md
cmake/config_checks.cmake
config-cmake.h.in

index 7a63d78e3a3f8120f0ee30a44e48fdc38f051d36..aa7afc9896fe3ae67cf67117820a9d68d7bdb18d 100644 (file)
@@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
 
 * Support for the Intel C Compiler in the Autotools build system has been
   removed. #2298
+* Fallback typedefs for `ssize_t` have been removed from the CMake build system.
 
 ### Fixed
 
index 337af26d089765d401e8901517fb296a72775b90..8046df3e3bd6d5e8f09b20941596fe3665841d84 100644 (file)
@@ -26,13 +26,6 @@ check_function_exists( setmode          HAVE_SETMODE         )
 check_function_exists( sincos           HAVE_SINCOS          )
 check_function_exists( srand48          HAVE_SRAND48         )
 
-# Type checks
-# The function check_size_type also checks if the type exists
-# and sets HAVE_${VARIABLE} accordingly.
-include(CheckTypeSize)
-
-check_type_size( ssize_t     SSIZE_T     )
-
 # Library checks
 set( HAVE_ANN       ${ANN_FOUND}        )
 if(with_expat AND EXPAT_FOUND)
index 5d17cc5c59f54845ccc470ea4e1c569d7151f080..c850d221b9f138c94474a11748c40b7d84034387 100644 (file)
 #cmakedefine HAVE_SINCOS
 #cmakedefine HAVE_SRAND48
 
-// Types
-#cmakedefine HAVE_SSIZE_T
-
 // Typedefs for missing types
-#ifndef HAVE_SSIZE_T
 #ifdef _MSC_VER
 #include <BaseTsd.h>
 typedef SSIZE_T ssize_t;
-#else
-typedef int ssize_t;
-#endif
 #endif
 
 // Libraries