Change 27555 by [EMAIL PROTECTED] on 2006/03/20 17:21:15
Merge some changes from ActivePerl 5.8.8.816
See:
http://downloads.activestate.com/ActivePerl/src/5.8/AP816_diff.txt
These changes provide better support for building XS extension modules
using VC++ or MinGW when perl itself was built with the opposite of
those two compilers.
Affected files ...
... //depot/perl/win32/config_H.gc#156 edit
... //depot/perl/win32/config_H.vc#157 edit
Differences ...
==== //depot/perl/win32/config_H.gc#156 (text+w) ====
Index: perl/win32/config_H.gc
--- perl/win32/config_H.gc#155~27412~ 2006-03-08 00:42:44.000000000 -0800
+++ perl/win32/config_H.gc 2006-03-20 09:21:15.000000000 -0800
@@ -1093,9 +1093,15 @@
* This symbol is intended to be used along with CPPRUN in the same manner
* symbol CPPMINUS is used with CPPSTDIN. It contains either "-" or "".
*/
-#define CPPSTDIN "gcc -E"
-#define CPPMINUS "-"
-#define CPPRUN "gcc -E"
+#ifndef _MSC_VER
+# define CPPSTDIN "gcc -E"
+# define CPPMINUS "-"
+# define CPPRUN "gcc -E"
+#else
+# define CPPSTDIN "cppstdin"
+# define CPPMINUS ""
+# define CPPRUN "cl -nologo -E"
+#endif
#define CPPLAST ""
/* HAS__FWALK:
@@ -1128,7 +1134,9 @@
* This symbol is defined if the C compiler can cast negative
* or large floating point numbers to 32-bit ints.
*/
-#define CASTI32 /**/
+#ifndef _MSC_VER
+# define CASTI32 /**/
+#endif
/* CASTNEGFLOAT:
* This symbol is defined if the C compiler can cast negative
@@ -1900,7 +1908,11 @@
*/
#define HAS_LONG_DOUBLE /**/
#ifdef HAS_LONG_DOUBLE
-#define LONG_DOUBLESIZE 12 /**/
+# ifndef _MSC_VER
+# define LONG_DOUBLESIZE 12 /**/
+# else
+# define LONG_DOUBLESIZE 10 /**/
+# endif
#endif
/* HAS_LONG_LONG:
@@ -3055,7 +3067,11 @@
/* Off_t_size:
* This symbol holds the number of bytes used by the Off_t.
*/
-#define Off_t long long /* <offset> type */
+#ifndef _MSC_VER
+# define Off_t long long /* <offset> type */
+#else
+# define Off_t __int64 /* <offset> type */
+#endif
#define LSEEKSIZE 8 /* <offset> size */
#define Off_t_size 8 /* <offset> size */
@@ -3163,8 +3179,13 @@
*/
/*#define HAS_QUAD /**/
#ifdef HAS_QUAD
-# define Quad_t long long /**/
-# define Uquad_t unsigned long long /**/
+# ifndef _MSC_VER
+# define Quad_t long long /**/
+# define Uquad_t unsigned long long /**/
+# else
+# define Quad_t __int64 /**/
+# define Uquad_t unsigned __int64 /**/
+# endif
# define QUADKIND 5 /**/
# define QUAD_IS_INT 1
# define QUAD_IS_LONG 2
@@ -3259,8 +3280,13 @@
#define I32TYPE long /**/
#define U32TYPE unsigned long /**/
#ifdef HAS_QUAD
-#define I64TYPE long long /**/
-#define U64TYPE unsigned long long /**/
+# ifndef _MSC_VER
+# define I64TYPE long long /**/
+# define U64TYPE unsigned long long /**/
+# else
+# define I64TYPE __int64 /**/
+# define U64TYPE unsigned __int64 /**/
+# endif
#endif
#define NVTYPE double /**/
#define IVSIZE 4 /**/
==== //depot/perl/win32/config_H.vc#157 (text+w) ====
Index: perl/win32/config_H.vc
--- perl/win32/config_H.vc#156~27412~ 2006-03-08 00:42:44.000000000 -0800
+++ perl/win32/config_H.vc 2006-03-20 09:21:15.000000000 -0800
@@ -1093,9 +1093,16 @@
* This symbol is intended to be used along with CPPRUN in the same manner
* symbol CPPMINUS is used with CPPSTDIN. It contains either "-" or "".
*/
-#define CPPSTDIN "cppstdin"
-#define CPPMINUS ""
-#define CPPRUN "cl -nologo -E"
+
+#ifndef __GNUC__
+# define CPPSTDIN "cppstdin"
+# define CPPMINUS ""
+# define CPPRUN "cl -nologo -E"
+#else
+# define CPPSTDIN "gcc -E"
+# define CPPMINUS "-"
+# define CPPRUN "gcc -E"
+#endif
#define CPPLAST ""
/* HAS__FWALK:
@@ -1128,7 +1135,9 @@
* This symbol is defined if the C compiler can cast negative
* or large floating point numbers to 32-bit ints.
*/
-/*#define CASTI32 /**/
+#ifdef __GNUC__
+# define CASTI32 /**/
+#endif
/* CASTNEGFLOAT:
* This symbol is defined if the C compiler can cast negative
@@ -1900,7 +1909,11 @@
*/
#define HAS_LONG_DOUBLE /**/
#ifdef HAS_LONG_DOUBLE
-#define LONG_DOUBLESIZE 10 /**/
+# ifndef __GNUC__
+# define LONG_DOUBLESIZE 10 /**/
+# else
+# define LONG_DOUBLESIZE 12 /**/
+# endif
#endif
/* HAS_LONG_LONG:
@@ -3055,7 +3068,11 @@
/* Off_t_size:
* This symbol holds the number of bytes used by the Off_t.
*/
-#define Off_t __int64 /* <offset> type */
+#ifndef __GNUC__
+# define Off_t __int64 /* <offset> type */
+#else
+# define Off_t long long /* <offset> type */
+#endif
#define LSEEKSIZE 8 /* <offset> size */
#define Off_t_size 8 /* <offset> size */
@@ -3163,8 +3180,13 @@
*/
/*#define HAS_QUAD /**/
#ifdef HAS_QUAD
-# define Quad_t __int64 /**/
-# define Uquad_t unsigned __int64 /**/
+# ifndef __GNUC__
+# define Quad_t __int64 /**/
+# define Uquad_t unsigned __int64 /**/
+# else
+# define Quad_t long long /**/
+# define Uquad_t unsigned long long /**/
+# endif
# define QUADKIND 5 /**/
# define QUAD_IS_INT 1
# define QUAD_IS_LONG 2
@@ -3259,8 +3281,13 @@
#define I32TYPE long /**/
#define U32TYPE unsigned long /**/
#ifdef HAS_QUAD
-#define I64TYPE __int64 /**/
-#define U64TYPE unsigned __int64 /**/
+# ifndef __GNUC__
+# define I64TYPE __int64 /**/
+# define U64TYPE unsigned __int64 /**/
+# else
+# define I64TYPE long long /**/
+# define U64TYPE unsigned long long /**/
+# endif
#endif
#define NVTYPE double /**/
#define IVSIZE 4 /**/
End of Patch.