Just out of curiosity: this is what I do in my packages.

Fridrich
--- jpeg-6b/jconfig.cfg	1994-12-06 17:43:15.000000000 +0100
+++ jpeg-6b/jconfig.cfg	2009-04-24 07:45:05.000000000 +0200
@@ -26,6 +26,12 @@
 
 #endif /* JPEG_INTERNALS */
 
+/* Define "boolean" as unsigned char, not int, per Windows custom */
+#ifndef __RPCNDR_H__ 	/* don't conflict if rpcndr.h already read */
+typedef unsigned char boolean;
+#endif
+#define HAVE_BOOLEAN	/* prevent jmorecfg.h from redefining it */
+
 #ifdef JPEG_CJPEG_DJPEG
 
 #define BMP_SUPPORTED		/* BMP image file format */
--- jpeg-6b/jmorecfg.h	1997-08-10 01:58:56.000000000 +0200
+++ jpeg-6b/jmorecfg.h	2009-01-21 22:17:20.000000000 +0100
@@ -157,9 +157,12 @@
 
 /* INT32 must hold at least signed 32-bit values. */
 
-#ifndef XMD_H			/* X11/xmd.h correctly defines INT32 */
+#if !defined(XMD_H) && !defined(_WIN32)			/* X11/xmd.h correctly defines INT32 */
 typedef long INT32;
 #endif
+#if defined(_WIN32) && !defined(_BASETSD_H)
+typedef int INT32;
+#endif
 
 /* Datatype used for image dimensions.  The JPEG standard only supports
  * images up to 64K*64K due to 16-bit fields in SOF markers.  Therefore
@@ -212,8 +215,10 @@
 #ifdef NEED_FAR_POINTERS
 #define FAR  far
 #else
+#ifndef FAR
 #define FAR
 #endif
+#endif
 
 
 /*
@@ -223,7 +228,7 @@
  * Defining HAVE_BOOLEAN before including jpeglib.h should make it work.
  */
 
-#ifndef HAVE_BOOLEAN
+#if !defined(HAVE_BOOLEAN) && !defined(__RPCNDR_H__)
 typedef int boolean;
 #endif
 #ifndef FALSE			/* in case these macros already exist */
_______________________________________________
fedora-mingw mailing list
[email protected]
https://admin.fedoraproject.org/mailman/listinfo/fedora-mingw

Reply via email to