Author: mattip <[email protected]>
Branch:
Changeset: r56729:dcf93174e81d
Date: 2012-08-15 18:17 +0300
http://bitbucket.org/pypy/pypy/changeset/dcf93174e81d/
Log: fix function export for visual studio
diff --git a/pypy/module/_cffi_backend/test/_test_lib.c
b/pypy/module/_cffi_backend/test/_test_lib.c
--- a/pypy/module/_cffi_backend/test/_test_lib.c
+++ b/pypy/module/_cffi_backend/test/_test_lib.c
@@ -2,6 +2,12 @@
#include <stdarg.h>
#include <errno.h>
+#ifdef _WIN32
+#define DLLEXPORT __declspec(dllexport)
+#else
+#define DLLEXPORT
+#endif
+
static char _testfunc0(char a, char b)
{
return a + b;
@@ -140,7 +146,7 @@
return ptr->a1 + ptr->a2;
}
-void *gettestfunc(int num)
+DLLEXPORT void *gettestfunc(int num)
{
void *f;
switch (num) {
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit