about summary refs log tree commit diff
path: root/pm_config.in.h
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2023-06-28 17:29:32 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2023-06-28 17:29:32 +0000
commit23ce26f64c34e30951ad9ade2151552ed77e7357 (patch)
treed73b31a0c2f7c7be4a69f8a8e84e00dd39c432b5 /pm_config.in.h
parent1b6e51a266008348ad93ed8b6ac9ec91b5024fea (diff)
downloadnetpbm-mirror-23ce26f64c34e30951ad9ade2151552ed77e7357.tar.gz
netpbm-mirror-23ce26f64c34e30951ad9ade2151552ed77e7357.tar.xz
netpbm-mirror-23ce26f64c34e30951ad9ade2151552ed77e7357.zip
promote Advanced to Stable
git-svn-id: http://svn.code.sf.net/p/netpbm/code/stable@4558 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'pm_config.in.h')
-rw-r--r--pm_config.in.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/pm_config.in.h b/pm_config.in.h
index b30bccfe..7ba51454 100644
--- a/pm_config.in.h
+++ b/pm_config.in.h
@@ -167,6 +167,16 @@
 #define lstat stat
 #endif
 
+/* Mingw provides much of POSIX, but does not provide 'random' (and a
+   discussion on the Mingw mailing list in March 2021 shows that the
+   developers want it that way).  MSVCRT itself has a sufficient 'rand',
+   though, so we use that for 'random'.
+*/
+#if MSVCRT
+#define random rand
+#define srandom srand
+#endif
+
 /*  CONFIGURE: Netpbm uses __inline__ to declare functions that should
     be compiled as inline code.  GNU C recognizes the __inline__ keyword.
     If your compiler recognizes any other keyword for this, you can set