3 Fix build errors on Mac OS XLion
.
5 --- Mac
/Modules
/qd
/_Qdmodule
.c
.orig
2010-05-09 15:15:40.000000000 +0000
6 +++ Mac
/Modules
/qd
/_Qdmodule
.c
11 +#include <AvailabilityMacros.h>
12 +#if (__MAC_OS_X_VERSION_MAX_ALLOWED >= 1070) || defined(__LP64__)
21 #include "pymactoolbox.h"
23 @@
-6545,10 +6551,10 @@
static PyObject
*Qd_RawBitMap(PyObject
*
27 -#endif /* __LP64__ */
28 +#endif /* HAVE_CARBON */
30 static PyMethodDef Qd_methods
[] = {
33 {"GetPort", (PyCFunction
)Qd_GetPort
, 1,
34 PyDoc_STR("() -> (GrafPtr port)")},
35 {"GrafDevice", (PyCFunction
)Qd_GrafDevice
, 1,
36 @@
-7083,12 +7089,12 @@
static PyMethodDef Qd_methods
[] = {
37 PyDoc_STR("Take (string, int, Rect) argument and create BitMap")},
38 {"RawBitMap", (PyCFunction
)Qd_RawBitMap
, 1,
39 PyDoc_STR("Take string BitMap and turn into BitMap object")},
40 -#endif /* __LP64__ */
41 +#endif /* HAVE_CARBON */
49 /* Like BMObj_New, but the original bitmap data structure is copied (and
50 ** released when the object is released)
51 @@ -7106,13 +7112,13 @@ PyObject *BMObj_NewCopied(BitMapPtr itse
52 return (PyObject *)it;
55 -#endif /* __LP64__ */
56 +#endif /* HAVE_CARBON */
67 @@
-7124,10 +7130,10 @@
void init_Qd(void)
68 PyMac_INIT_TOOLBOX_OBJECT_NEW(RGBColorPtr
, QdRGB_New
);
69 PyMac_INIT_TOOLBOX_OBJECT_CONVERT(RGBColor
, QdRGB_Convert
);
71 -#endif /* __LP64__ */
72 +#endif /* HAVE_CARBON */
74 m
= Py_InitModule("_Qd", Qd_methods
);
77 d
= PyModule_GetDict(m
);
78 Qd_Error
= PyMac_GetOSErrException();
79 if (Qd_Error
== NULL
||
80 @@
-7147,7 +7153,7 @@
void init_Qd(void)
81 /* Backward-compatible name */
82 Py_INCREF(&BitMap_Type
);
83 PyModule_AddObject(m
, "BitMapType", (PyObject
*)&BitMap_Type
);
84 -#endif /* __LP64__ */
85 +#endif /* HAVE_CARBON */
88 /* ========================= End module _Qd ========================= */