summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-misc/sphinx/files/sphinx-1.10_beta-libsphinxclient-darwin.patch')
-rw-r--r--app-misc/sphinx/files/sphinx-1.10_beta-libsphinxclient-darwin.patch22
1 files changed, 22 insertions, 0 deletions
diff --git a/app-misc/sphinx/files/sphinx-1.10_beta-libsphinxclient-darwin.patch b/app-misc/sphinx/files/sphinx-1.10_beta-libsphinxclient-darwin.patch
new file mode 100644
index 000000000000..594b7351e121
--- /dev/null
+++ b/app-misc/sphinx/files/sphinx-1.10_beta-libsphinxclient-darwin.patch
@@ -0,0 +1,22 @@
+On Darwin, the linker doesn't like it when vsnprintf is prefixed by an
+underscore. This obviously is an error, since it's only necessary for
+Windows. Add an extra guard, such that vsnprintf is left alone.
+
+--- api/libsphinxclient/sphinxclient.c
++++ api/libsphinxclient/sphinxclient.c
+@@ -13,6 +13,7 @@
+ // did not, you can find it at http://www.gnu.org/
+ //
+
++#if defined(_MSC_VER)
+ #if _MSC_VER>=1400
+ // VS 2005 and above
+ #define _CRT_SECURE_NO_DEPRECATE 1
+@@ -21,6 +22,7 @@
+ // VS 2003 and below
+ #define vsnprintf _vsnprintf
+ #endif
++#endif
+
+ #include <stdlib.h>
+ #include <stdarg.h>