summaryrefslogtreecommitdiffstats
path: root/PC/os2emx/pyconfig.h
diff options
context:
space:
mode:
authorAndrew MacIntyre <andymac@bullseye.apana.org.au>2003-07-13 13:41:59 (GMT)
committerAndrew MacIntyre <andymac@bullseye.apana.org.au>2003-07-13 13:41:59 (GMT)
commit4ee893fe39f11aca1cfcf7472c95c10e61d4aedd (patch)
tree089c7001a6a17428885304665d30e574534f5148 /PC/os2emx/pyconfig.h
parentf9ce67d65fc86e1efee60a960e15eea27c6ab108 (diff)
downloadcpython-4ee893fe39f11aca1cfcf7472c95c10e61d4aedd.zip
cpython-4ee893fe39f11aca1cfcf7472c95c10e61d4aedd.tar.gz
cpython-4ee893fe39f11aca1cfcf7472c95c10e61d4aedd.tar.bz2
More pre-2.3 build tweaks for the OS/2 EMX port:
- separate the building of the core from the wrapper executables and the external modules (.PYDs), based on the Py_BUILD_CORE define; - clean up the generated import library definiton (.DEF file) to remove references to a number of non-static symbols that aren't part of the Python API and which shouldn't be exported by the core DLL; - compile the release build with -fomit-frame-pointer, for a small performance gain; - make "make clean" remove byte compiled Python library files.
Diffstat (limited to 'PC/os2emx/pyconfig.h')
-rw-r--r--PC/os2emx/pyconfig.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/PC/os2emx/pyconfig.h b/PC/os2emx/pyconfig.h
index 209d161..206223f 100644
--- a/PC/os2emx/pyconfig.h
+++ b/PC/os2emx/pyconfig.h
@@ -26,6 +26,18 @@
/*#define Py_DEBUG 1*/
#endif
+/* if building an extension or wrapper executable,
+ * mark Python API symbols "extern" so that symbols
+ * imported from the Python core DLL aren't duplicated.
+ */
+#ifdef Py_BUILD_CORE
+# define PyAPI_FUNC(RTYPE) RTYPE
+#else
+# define PyAPI_FUNC(RTYPE) extern RTYPE
+#endif
+#define PyAPI_DATA(RTYPE) extern RTYPE
+#define PyMODINIT_FUNC void
+
/* Use OS/2 flavour of threads */
#define WITH_THREAD 1
#define OS2_THREADS 1