summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2018-05-03 23:09:42 +0200
committerBruno Haible <bruno@clisp.org>2018-05-03 23:10:51 +0200
commit44b65c481f32b785ef75a55533437c3b46bed352 (patch)
tree5adc8a76243b6884bb532fbea6fc0d28de8027f3 /m4
parent9d0f7475720ea1690c5e87571e7b10ce771ef735 (diff)
downloadgnulib-44b65c481f32b785ef75a55533437c3b46bed352.tar.gz
Simplify code. Drop support for Borland C++ on Windows.
Reported by Gisle Vanem <gisle.vanem@gmail.com>. * lib/accept4.c: Simplify 'defined _WIN32 || defined __WIN32__' to just 'defined _WIN32'. * lib/canonicalize-lgpl.c: Likewise. * lib/classpath.c: Likewise. * lib/clean-temp.c: Likewise. * lib/csharpexec.c: Likewise. * lib/ctime.c: Likewise. * lib/dosname.h: Likewise. * lib/dup2.c: Likewise. * lib/errno.in.h: Likewise. * lib/error.c: Likewise. * lib/euidaccess.c: Likewise. * lib/execute.c: Likewise. * lib/fcntl.in.h: Likewise. * lib/fcntl.c: Likewise. * lib/filename.h: Likewise. * lib/findprog.c: Likewise. * lib/flock.c: Likewise. * lib/fopen.c: Likewise. * lib/freopen.c: Likewise. * lib/fstat.c: Likewise. * lib/fsync.c: Likewise. * lib/gc-gnulib.c: Likewise. * lib/get-rusage-data.c: Likewise. * lib/getaddrinfo.c: Likewise. * lib/getdelim.c: Likewise. * lib/getdtablesize.c: Likewise. * lib/gethostname.c: Likewise. * lib/getlogin.c: Likewise. * lib/getlogin_r.c: Likewise. * lib/getopt.c: Likewise. * lib/getpagesize.c: Likewise. * lib/getpass.c: Likewise. * lib/getrusage.c: Likewise. * lib/gettimeofday.c: Likewise. * lib/glob.c: Likewise. * lib/inttypes.in.h: Likewise. * lib/isapipe.c: Likewise. * lib/javaexec.c: Likewise. * lib/link.c: Likewise. * lib/localcharset.c: Likewise. * lib/localename.h: Likewise. * lib/localename.c: Likewise. * lib/localtime.c: Likewise. * lib/lseek.c: Likewise. * lib/mbsinit.c: Likewise. * lib/mkdir.c: Likewise. * lib/msvc-nothrow.h: Likewise. * lib/nanosleep.c: Likewise. * lib/nl_langinfo.c: Likewise. * lib/nonblocking.c: Likewise. * lib/nproc.c: Likewise. * lib/open.c: Likewise. * lib/openpty.c: Likewise. * lib/pathmax.h: Likewise. * lib/pipe-filter-aux.c: Likewise. * lib/pipe-filter-gi.c: Likewise. * lib/pipe-filter-ii.c: Likewise. * lib/pipe.c: Likewise. * lib/pipe2.c: Likewise. * lib/poll.c: Likewise. * lib/popen.c: Likewise. * lib/posix_openpt.c: Likewise. * lib/printf-parse.c: Likewise. * lib/progreloc.c: Likewise. * lib/putenv.c: Likewise. * lib/read.c: Likewise. * lib/relocatable.c: Likewise. * lib/rename.c: Likewise. * lib/same-inode.h: Likewise. * lib/secure_getenv.c: Likewise. * lib/select.c: Likewise. * lib/sethostname.c: Likewise. * lib/setlocale.c: Likewise. * lib/sigaction.c: Likewise. * lib/sigprocmask.c: Likewise. * lib/sleep.c: Likewise. * lib/spawn-pipe.h: Likewise. * lib/spawn-pipe.c: Likewise. * lib/spawni.c: Likewise. * lib/stat-time.h: Likewise. * lib/stat-w32.c: Likewise. * lib/stat.c: Likewise. * lib/stdio.in.h: Likewise. * lib/stdio-impl.h: Likewise. * lib/stdio-read.c: Likewise. * lib/stdio-write.c: Likewise. * lib/stdlib.in.h: Likewise. * lib/strerror_r.c: Likewise. * lib/strftime-fixes.c: Likewise. * lib/sys_stat.in.h: Likewise. * lib/sys_types.in.h: Likewise. * lib/sys_wait.in.h : Likewise. * lib/system-quote.h: Likewise. * lib/system-quote.c: Likewise. * lib/tmpdir.c: Likewise. * lib/tzset.c: Likewise. * lib/uname.c: Likewise. * lib/unistd.in.h: Likewise. * lib/utime.in.h: Likewise. * lib/utime.c: Likewise. * lib/utimecmp.c: Likewise. * lib/utimens.c: Likewise. * lib/vasnprintf.c: Likewise. * lib/vma-iter.h: Likewise. * lib/vma-iter.c: Likewise. * lib/wait-process.c: Likewise. * lib/wcsftime.c: Likewise. * lib/wctype.in.h: Likewise. * lib/write.c: Likewise. * tests/nap.h: Likewise. * tests/test-cloexec.c: Likewise. * tests/test-dup-safer.c: Likewise. * tests/test-dup2.c: Likewise. * tests/test-dup3.c: Likewise. * tests/test-fcntl.c: Likewise. * tests/test-get-rusage-data.c: Likewise. * tests/test-getaddrinfo.c: Likewise. * tests/test-getlogin.h: Likewise. * tests/test-isatty.c: Likewise. * tests/test-localename.c: Likewise. * tests/test-mbrtowc-w32.c: Likewise. * tests/test-nonblocking.c: Likewise. * tests/test-nonblocking-pipe-main.c: Likewise. * tests/test-nonblocking-socket-main.c: Likewise. * tests/test-nonblocking-socket.h: Likewise. * tests/test-pipe.c: Likewise. * tests/test-pipe2.c: Likewise. * tests/test-poll.c: Likewise. * tests/test-pthread_sigmask1.c: Likewise. * tests/test-select.h: Likewise. * tests/test-sethostname2.c: Likewise. * tests/test-sigprocmask.c: Likewise. * tests/test-spawn-pipe-child.c: Likewise. * tests/test-stat-time.c: Likewise. * tests/test-system-quote-main.c: Likewise. * tests/test-utimens-common.h: Likewise. * tests/test-wcrtomb-w32.c: Likewise. * m4/csharpexec.m4 (gt_CSHARPEXEC): Likewise. * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise. * m4/javacomp.m4 (gt_JAVACOMP): Likewise. * m4/javaexec.m4 (gt_JAVAEXEC): Likewise. * m4/locale-ar.m4 (gt_LOCALE_AR): Likewise. * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise. * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise. * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise. * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise. * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Likewise. * m4/nocrash.m4 (GL_NOCRASH): Likewise. * m4/pathmax.m4 (gl_PATHMAX_SNIPPET): Likewise. * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Likewise. * m4/stdio_h.m4 (gl_STDIO_H): Likewise. * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Likewise. * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
Diffstat (limited to 'm4')
-rw-r--r--m4/csharpexec.m44
-rw-r--r--m4/getcwd.m44
-rw-r--r--m4/javacomp.m44
-rw-r--r--m4/javaexec.m44
-rw-r--r--m4/locale-ar.m44
-rw-r--r--m4/locale-fr.m46
-rw-r--r--m4/locale-ja.m44
-rw-r--r--m4/locale-tr.m44
-rw-r--r--m4/locale-zh.m44
-rw-r--r--m4/malloc.m44
-rw-r--r--m4/nocrash.m44
-rw-r--r--m4/pathmax.m44
-rw-r--r--m4/ptsname_r.m44
-rw-r--r--m4/stdio_h.m44
-rw-r--r--m4/tmpfile.m44
-rw-r--r--m4/unistd_h.m44
16 files changed, 33 insertions, 33 deletions
diff --git a/m4/csharpexec.m4 b/m4/csharpexec.m4
index 2e5fbcfdf7..f645ffdc47 100644
--- a/m4/csharpexec.m4
+++ b/m4/csharpexec.m4
@@ -1,4 +1,4 @@
-# csharpexec.m4 serial 5
+# csharpexec.m4 serial 6
dnl Copyright (C) 2003-2005, 2009-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -15,7 +15,7 @@ AC_DEFUN([gt_CSHARPEXEC],
AC_REQUIRE([AC_CANONICAL_HOST]) dnl for cross-compiles
AC_MSG_CHECKING([for C[#] program execution engine])
AC_EGREP_CPP([yes], [
-#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
+#if defined _WIN32 || defined __EMX__ || defined __DJGPP__
yes
#endif
], MONO_PATH_SEPARATOR=';', MONO_PATH_SEPARATOR=':')
diff --git a/m4/getcwd.m4 b/m4/getcwd.m4
index 2875fe590b..019934d580 100644
--- a/m4/getcwd.m4
+++ b/m4/getcwd.m4
@@ -6,7 +6,7 @@
# with or without modifications, as long as this notice is preserved.
# Written by Paul Eggert.
-# serial 15
+# serial 16
AC_DEFUN([gl_FUNC_GETCWD_NULL],
[
@@ -25,7 +25,7 @@ AC_DEFUN([gl_FUNC_GETCWD_NULL],
char *getcwd ();
# endif
]], [[
-#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+#if defined _WIN32 && ! defined __CYGWIN__
/* mingw cwd does not start with '/', but getcwd does allocate.
However, mingw fails to honor non-zero size. */
#else
diff --git a/m4/javacomp.m4 b/m4/javacomp.m4
index c4d650bfdc..bee333ea7b 100644
--- a/m4/javacomp.m4
+++ b/m4/javacomp.m4
@@ -1,4 +1,4 @@
-# javacomp.m4 serial 15
+# javacomp.m4 serial 16
dnl Copyright (C) 2001-2003, 2006-2007, 2009-2018 Free Software Foundation,
dnl Inc.
dnl This file is free software; the Free Software Foundation
@@ -83,7 +83,7 @@ AC_DEFUN([gt_JAVACOMP],
[
ifelse([$2], [], [AC_REQUIRE([gt_JAVAEXEC])], [])
AC_EGREP_CPP([yes], [
-#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+#if defined _WIN32 || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
yes
#endif
], CLASSPATH_SEPARATOR=';', CLASSPATH_SEPARATOR=':')
diff --git a/m4/javaexec.m4 b/m4/javaexec.m4
index 1dcf005e53..aefe2bce4b 100644
--- a/m4/javaexec.m4
+++ b/m4/javaexec.m4
@@ -1,4 +1,4 @@
-# javaexec.m4 serial 5
+# javaexec.m4 serial 6
dnl Copyright (C) 2001-2003, 2006, 2009-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -12,7 +12,7 @@ AC_DEFUN([gt_JAVAEXEC],
[
AC_MSG_CHECKING([for Java virtual machine])
AC_EGREP_CPP([yes], [
-#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+#if defined _WIN32 || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
yes
#endif
], CLASSPATH_SEPARATOR=';', CLASSPATH_SEPARATOR=':')
diff --git a/m4/locale-ar.m4 b/m4/locale-ar.m4
index 3024441546..ee386b9adc 100644
--- a/m4/locale-ar.m4
+++ b/m4/locale-ar.m4
@@ -1,4 +1,4 @@
-# locale-ar.m4 serial 7
+# locale-ar.m4 serial 8
dnl Copyright (C) 2003, 2005-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -31,7 +31,7 @@ int main () {
return 1;
#else
/* Check whether the given locale name is recognized by the system. */
-# if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
+# if defined _WIN32 && !defined __CYGWIN__
/* On native Windows, setlocale(category, "") looks at the system settings,
not at the environment variables. Also, when an encoding suffix such
as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
diff --git a/m4/locale-fr.m4 b/m4/locale-fr.m4
index 30a1d94bdc..a37a0d2024 100644
--- a/m4/locale-fr.m4
+++ b/m4/locale-fr.m4
@@ -1,4 +1,4 @@
-# locale-fr.m4 serial 18
+# locale-fr.m4 serial 19
dnl Copyright (C) 2003, 2005-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -31,7 +31,7 @@ int main () {
return 1;
#else
/* Check whether the given locale name is recognized by the system. */
-# if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
+# if defined _WIN32 && !defined __CYGWIN__
/* On native Windows, setlocale(category, "") looks at the system settings,
not at the environment variables. Also, when an encoding suffix such
as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
@@ -160,7 +160,7 @@ int main () {
variables, and all locales use the UTF-8 encoding. */
#if !(defined __BEOS__ || defined __HAIKU__)
/* Check whether the given locale name is recognized by the system. */
-# if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
+# if defined _WIN32 && !defined __CYGWIN__
/* On native Windows, setlocale(category, "") looks at the system settings,
not at the environment variables. Also, when an encoding suffix such
as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
diff --git a/m4/locale-ja.m4 b/m4/locale-ja.m4
index 2c34006296..9f1623191d 100644
--- a/m4/locale-ja.m4
+++ b/m4/locale-ja.m4
@@ -1,4 +1,4 @@
-# locale-ja.m4 serial 13
+# locale-ja.m4 serial 14
dnl Copyright (C) 2003, 2005-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -32,7 +32,7 @@ int main ()
return 1;
#else
/* Check whether the given locale name is recognized by the system. */
-# if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
+# if defined _WIN32 && !defined __CYGWIN__
/* On native Windows, setlocale(category, "") looks at the system settings,
not at the environment variables. Also, when an encoding suffix such
as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
diff --git a/m4/locale-tr.m4 b/m4/locale-tr.m4
index 441cae6817..2f2cf47892 100644
--- a/m4/locale-tr.m4
+++ b/m4/locale-tr.m4
@@ -1,4 +1,4 @@
-# locale-tr.m4 serial 10
+# locale-tr.m4 serial 11
dnl Copyright (C) 2003, 2005-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -30,7 +30,7 @@ int main () {
implement the Turkish upper-/lowercase mappings. Therefore, let this
program return 1 on BeOS. */
/* Check whether the given locale name is recognized by the system. */
-#if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
+#if defined _WIN32 && !defined __CYGWIN__
/* On native Windows, setlocale(category, "") looks at the system settings,
not at the environment variables. Also, when an encoding suffix such
as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
diff --git a/m4/locale-zh.m4 b/m4/locale-zh.m4
index f7e1901d0d..cfb447f08d 100644
--- a/m4/locale-zh.m4
+++ b/m4/locale-zh.m4
@@ -1,4 +1,4 @@
-# locale-zh.m4 serial 13
+# locale-zh.m4 serial 14
dnl Copyright (C) 2003, 2005-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -33,7 +33,7 @@ int main ()
return 1;
#else
/* Check whether the given locale name is recognized by the system. */
-# if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
+# if defined _WIN32 && !defined __CYGWIN__
/* On native Windows, setlocale(category, "") looks at the system settings,
not at the environment variables. Also, when an encoding suffix such
as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
diff --git a/m4/malloc.m4 b/m4/malloc.m4
index 0ded9ba219..4c182b4140 100644
--- a/m4/malloc.m4
+++ b/m4/malloc.m4
@@ -1,4 +1,4 @@
-# malloc.m4 serial 16
+# malloc.m4 serial 17
dnl Copyright (C) 2007, 2009-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -91,7 +91,7 @@ AC_DEFUN([gl_CHECK_MALLOC_POSIX],
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM(
[[]],
- [[#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+ [[#if defined _WIN32 && ! defined __CYGWIN__
choke me
#endif
]])],
diff --git a/m4/nocrash.m4 b/m4/nocrash.m4
index 87b2d4cbf6..49140074d0 100644
--- a/m4/nocrash.m4
+++ b/m4/nocrash.m4
@@ -1,4 +1,4 @@
-# nocrash.m4 serial 4
+# nocrash.m4 serial 5
dnl Copyright (C) 2005, 2009-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -79,7 +79,7 @@ nocrash_init (void)
}
}
}
-#elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+#elif defined _WIN32 && ! defined __CYGWIN__
/* Avoid a crash on native Windows. */
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
diff --git a/m4/pathmax.m4 b/m4/pathmax.m4
index 403a37534d..292a256971 100644
--- a/m4/pathmax.m4
+++ b/m4/pathmax.m4
@@ -1,4 +1,4 @@
-# pathmax.m4 serial 10
+# pathmax.m4 serial 11
dnl Copyright (C) 2002-2003, 2005-2006, 2009-2018 Free Software Foundation,
dnl Inc.
dnl This file is free software; the Free Software Foundation
@@ -29,7 +29,7 @@ AC_DEFUN([gl_PATHMAX_SNIPPET], [[
# undef PATH_MAX
# define PATH_MAX 1024
#endif
-#if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+#if defined _WIN32 && ! defined __CYGWIN__
# undef PATH_MAX
# define PATH_MAX 260
#endif
diff --git a/m4/ptsname_r.m4 b/m4/ptsname_r.m4
index 879b833372..10b4dff509 100644
--- a/m4/ptsname_r.m4
+++ b/m4/ptsname_r.m4
@@ -1,4 +1,4 @@
-# ptsname_r.m4 serial 4
+# ptsname_r.m4 serial 5
dnl Copyright (C) 2010-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -54,7 +54,7 @@ AC_DEFUN([gl_PREREQ_PTSNAME_R], [
[AC_RUN_IFELSE(
[AC_LANG_PROGRAM(
[[#include <errno.h>
- #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+ #if defined _WIN32 && ! defined __CYGWIN__
# include <io.h>
#else
# include <unistd.h>
diff --git a/m4/stdio_h.m4 b/m4/stdio_h.m4
index e06461e693..0debe69e92 100644
--- a/m4/stdio_h.m4
+++ b/m4/stdio_h.m4
@@ -1,4 +1,4 @@
-# stdio_h.m4 serial 48
+# stdio_h.m4 serial 49
dnl Copyright (C) 2007-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -28,7 +28,7 @@ AC_DEFUN([gl_STDIO_H],
/* For non-mingw systems, compilation will trivially succeed.
For mingw, compilation will succeed for older mingw (system
printf, "I64d") and fail for newer mingw (gnu printf, "lld"). */
- #if ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__) && \
+ #if (defined _WIN32 && ! defined __CYGWIN__) && \
(__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
extern char PRIdMAX_probe[sizeof PRIdMAX == sizeof "I64d" ? 1 : -1];
#endif
diff --git a/m4/tmpfile.m4 b/m4/tmpfile.m4
index 0735feb7b3..043dd38ac0 100644
--- a/m4/tmpfile.m4
+++ b/m4/tmpfile.m4
@@ -1,4 +1,4 @@
-# tmpfile.m4 serial 2
+# tmpfile.m4 serial 3
# Copyright (C) 2007, 2009-2018 Free Software Foundation, Inc.
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
@@ -23,7 +23,7 @@ AC_DEFUN([gl_FUNC_TMPFILE], [
AC_CACHE_CHECK([whether tmpfile should be overridden],
[gl_cv_func_tmpfile_unusable],
[AC_EGREP_CPP([choke me], [
-#if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
+#if defined _WIN32 && !defined __CYGWIN__
choke me
#endif
],
diff --git a/m4/unistd_h.m4 b/m4/unistd_h.m4
index b3b71ec270..77110a93dd 100644
--- a/m4/unistd_h.m4
+++ b/m4/unistd_h.m4
@@ -1,4 +1,4 @@
-# unistd_h.m4 serial 71
+# unistd_h.m4 serial 72
dnl Copyright (C) 2006-2018 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
@@ -37,7 +37,7 @@ AC_DEFUN([gl_UNISTD_H],
# include <fcntl.h>
# include <stdio.h>
# include <stdlib.h>
-# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
+# if defined _WIN32 && ! defined __CYGWIN__
# include <io.h>
# endif
#endif