summaryrefslogtreecommitdiff
path: root/include/git2/common.h
diff options
context:
space:
mode:
authorVicent Martí <tanoku@gmail.com>2011-09-18 19:38:14 -0700
committerVicent Martí <tanoku@gmail.com>2011-09-18 19:38:14 -0700
commite311519dce6c64b9ad5ce4e74a0dcef298d9ece7 (patch)
treeae83aa2dfe7ef8ef8f54f52deeb68a8deb54e3a1 /include/git2/common.h
parent87d9869fc30951cec632e0d6a3d1dd47756d2886 (diff)
parentd2a1861ea1fde6c1f4fe68aa4cc7f3602db92b1f (diff)
downloadlibgit2-e311519dce6c64b9ad5ce4e74a0dcef298d9ece7.tar.gz
Merge pull request #411 from boyski/gcc4
Don't use '__attribute__ visibility' with gcc unless it's at version 4 or better
Diffstat (limited to 'include/git2/common.h')
-rw-r--r--include/git2/common.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/git2/common.h b/include/git2/common.h
index 1a595b05..08498167 100644
--- a/include/git2/common.h
+++ b/include/git2/common.h
@@ -22,7 +22,7 @@
#endif
/** Declare a public function exported for application use. */
-#ifdef __GNUC__
+#if __GNUC__ >= 4
# define GIT_EXTERN(type) extern \
__attribute__((visibility("default"))) \
type
@@ -33,7 +33,7 @@
#endif
/** Declare a public TLS symbol exported for application use. */
-#ifdef __GNUC__
+#if __GNUC__ >= 4
# define GIT_EXTERN_TLS(type) extern \
__attribute__((visibility("default"))) \
GIT_TLS \