about summary refs log tree commit diff
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2012-02-11 23:39:15 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2012-02-11 23:39:15 +0000
commitfc187c9cadaa462f306ed211ca90573411d78247 (patch)
tree009b3e28707d769f503fc791c6a2450d547ab5a7
parent32f528452ca3932a91639e49284a7c72ea3d759f (diff)
downloadnetpbm-mirror-fc187c9cadaa462f306ed211ca90573411d78247.tar.gz
netpbm-mirror-fc187c9cadaa462f306ed211ca90573411d78247.tar.xz
netpbm-mirror-fc187c9cadaa462f306ed211ca90573411d78247.zip
Set binary mode on files with Mingw
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@1637 9d0c8265-081b-0410-96cb-a4ca84ce46f8
-rw-r--r--doc/HISTORY2
-rw-r--r--pm_config.in.h5
2 files changed, 4 insertions, 3 deletions
diff --git a/doc/HISTORY b/doc/HISTORY
index 520c7f18..cdba5fed 100644
--- a/doc/HISTORY
+++ b/doc/HISTORY
@@ -15,6 +15,8 @@ not yet  BJH  Release 10.58.00
               Windows/Mingw: fix bug: temporary file creation fails
               consistently.  Broken in 10.34.
 
+              Windows/Mingw: set binary mode on files.
+
               Windows: compute program name correctly.
 
               xpmtoppm: Make it work on XPM with zero characters per pixel.
diff --git a/pm_config.in.h b/pm_config.in.h
index 63b58feb..b7243786 100644
--- a/pm_config.in.h
+++ b/pm_config.in.h
@@ -130,7 +130,7 @@
 ** of stdin and stdout to binary for all Netpbm programs.
 ** You need this with Cygwin (Windows).
 */
-#ifdef __CYGWIN__
+#if defined(WIN32) || defined(__CYGWIN__) || defined(DJGPP)
 #define HAVE_SETMODE
 #endif
 
@@ -142,9 +142,8 @@
 #endif
 
 #ifdef DJGPP
-#define HAVE_SETMODE
 #define lstat stat
-#endif /* DJGPP */
+#endif
 
 /*  CONFIGURE: Netpbm uses __inline__ to declare functions that should
     be compiled as inline code.  GNU C recognizes the __inline__ keyword.