Commit 11f6646f032c669170453e8e359ac337fa9abbb7

Vicent Marti 2010-12-22T22:51:24

Export TLS symbols properly in Win32 There was no export definition for GIT_EXTERN_TLS() under MSVC. Signed-off-by: Vicent Marti <tanoku@gmail.com>

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/src/git2/common.h b/src/git2/common.h
index 9d014c0..bbeec41 100644
--- a/src/git2/common.h
+++ b/src/git2/common.h
@@ -55,6 +55,8 @@
 			      __attribute__((visibility("default"))) \
 			      GIT_TLS \
 			      type
+#elif defined(_MSC_VER)
+# define GIT_EXTERN_TLS(type) __declspec(dllexport) GIT_TLS type
 #else
 # define GIT_EXTERN_TLS(type) extern GIT_TLS type
 #endif