From 9fe658232b6eaac85a385a0f4b78029a262ed4e7 Mon Sep 17 00:00:00 2001 From: brarcher Date: Wed, 25 Dec 2013 03:05:04 +0000 Subject: [PATCH] libcompat: remove read() and write() checks read() and write() are now unnecessary, as all pipe IO is done using FILE APIs. git-svn-id: svn+ssh://svn.code.sf.net/p/check/code/trunk@967 64e312b2-a51f-0410-8e61-82d0ca0eb02a --- CMakeLists.txt | 5 ----- lib/libcompat.h | 8 -------- 2 files changed, 13 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index bdf9cd6..1e787f2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -145,7 +145,6 @@ check_function_exists(mkstemp HAVE_MKSTEMP) check_function_exists(poll HAVE_POLL) check_function_exists(putenv HAVE_DECL_PUTENV) check_function_exists(realloc HAVE_REALLOC) -check_function_exists(read HAVE_READ) check_function_exists(select HAVE_SELECT) check_function_exists(setenv HAVE_DECL_SETENV) check_function_exists(setlocale HAVE_SETLOCALE) @@ -174,7 +173,6 @@ check_function_exists(wcsnrtombs HAVE_WCSNRTOMBS) check_function_exists(wctomb HAVE_WCTOMB) check_function_exists(wmemcmp HAVE_WMEMCMP) check_function_exists(wmemcpy HAVE_WMEMCPY) -check_function_exists(write HAVE_WRITE) check_function_exists(_ctime64_s HAVE__CTIME64_S) check_function_exists(_fileno HAVE__FILENO) check_function_exists(_fseeki64 HAVE__FSEEKI64) @@ -183,10 +181,7 @@ check_function_exists(_getpid HAVE__GETPID) check_function_exists(_localtime64_s HAVE__LOCALTIME64_S) check_function_exists(_mkgmtime64 HAVE__MKGMTIME64) check_function_exists(_putenv HAVE__PUTENV) -check_function_exists(_read HAVE__READ) -check_function_exists(_snprintf HAVE__SNPRINTF) check_function_exists(_strdup HAVE__STRDUP) -check_function_exists(_write HAVE__WRITE) if(HAVE_FORK) add_definitions(-DHAVE_FORK=1) diff --git a/lib/libcompat.h b/lib/libcompat.h index 8742870..ee8a7a3 100644 --- a/lib/libcompat.h +++ b/lib/libcompat.h @@ -110,10 +110,6 @@ struct tm *localtime_r (const time_t *clock, struct tm *result); #define putenv _putenv; #endif /* HAVE_DECL_PUTENV && !HAVE__PUTENV */ -#if !HAVE_READ && HAVE__READ -#define read _read -#endif /* !HAVE_READ && HAVE__READ */ - #if !HAVE_DECL_SETENV int setenv (const char *name, const char *value, int overwrite); #endif /* !HAVE_DECL_SETENV */ @@ -143,10 +139,6 @@ const char *strsignal (int sig); int unsetenv (const char *name); #endif /* !HAVE_DECL_UNSETENV */ -#if !HAVE_WRITE && HAVE_WRITE -#define write _write -#endif /* !HAVE_WRITE && HAVE__WRITE */ - /* * On systems where clock_gettime() is not available, or * on systems where some clocks may not be supported, the -- 2.40.0