diff --git a/include/git2/oid.h b/include/git2/oid.h index 566d13ac1..87efbab2f 100644 --- a/include/git2/oid.h +++ b/include/git2/oid.h @@ -183,7 +183,7 @@ typedef struct git_oid_shorten git_oid_shorten; * be unique. * @return a `git_oid_shorten` instance, NULL if OOM */ -git_oid_shorten *git_oid_shorten_new(size_t min_length); +GIT_EXTERN(git_oid_shorten *) git_oid_shorten_new(size_t min_length); /** * Add a new OID to set of shortened OIDs and calculate @@ -209,14 +209,14 @@ git_oid_shorten *git_oid_shorten_new(size_t min_length); * added so far to the set; or an error code (<0) if an * error occurs. */ -int git_oid_shorten_add(git_oid_shorten *os, const char *text_oid); +GIT_EXTERN(int) git_oid_shorten_add(git_oid_shorten *os, const char *text_oid); /** * Free an OID shortener instance * * @param os a `git_oid_shorten` instance */ -void git_oid_shorten_free(git_oid_shorten *os); +GIT_EXTERN(void) git_oid_shorten_free(git_oid_shorten *os); /** @} */ GIT_END_DECL diff --git a/include/git2/refspec.h b/include/git2/refspec.h index 28afe652d..50aa596f9 100644 --- a/include/git2/refspec.h +++ b/include/git2/refspec.h @@ -25,7 +25,7 @@ GIT_BEGIN_DECL * @param refspec the refspec * @return the refspec's source specifier */ -const char *git_refspec_src(const git_refspec *refspec); +GIT_EXTERN(const char *) git_refspec_src(const git_refspec *refspec); /** * Get the destination specifier @@ -33,7 +33,7 @@ const char *git_refspec_src(const git_refspec *refspec); * @param refspec the refspec * @return the refspec's destination specifier */ -const char *git_refspec_dst(const git_refspec *refspec); +GIT_EXTERN(const char *) git_refspec_dst(const git_refspec *refspec); /** * Check if a refspec's source descriptor matches a reference @@ -42,7 +42,7 @@ const char *git_refspec_dst(const git_refspec *refspec); * @param refname the name of the reference to check * @return 1 if the refspec matches, 0 otherwise */ -int git_refspec_src_matches(const git_refspec *refspec, const char *refname); +GIT_EXTERN(int) git_refspec_src_matches(const git_refspec *refspec, const char *refname); /** * Transform a reference to its target following the refspec's rules @@ -53,7 +53,7 @@ int git_refspec_src_matches(const git_refspec *refspec, const char *refname); * @param name the name of the reference to transform * @return GIT_SUCCESS, GIT_ESHORTBUFFER or another error */ -int git_refspec_transform(char *out, size_t outlen, const git_refspec *spec, const char *name); +GIT_EXTERN(int) git_refspec_transform(char *out, size_t outlen, const git_refspec *spec, const char *name); GIT_END_DECL diff --git a/include/git2/tree.h b/include/git2/tree.h index 972c3795c..f75cc1cbb 100644 --- a/include/git2/tree.h +++ b/include/git2/tree.h @@ -343,9 +343,9 @@ typedef int (*git_tree_diff_cb)(const git_tree_diff_data *ptr, void *data); * @param data data to give to the callback * @return GIT_SUCCESS or an error code */ -int git_tree_diff(git_tree *old, git_tree *newer, git_tree_diff_cb cb, void *data); +GIT_EXTERN(int) git_tree_diff(git_tree *old, git_tree *newer, git_tree_diff_cb cb, void *data); -int git_tree_diff_index_recursive(git_tree *tree, git_index *index, git_tree_diff_cb cb, void *data); +GIT_EXTERN(int) git_tree_diff_index_recursive(git_tree *tree, git_index *index, git_tree_diff_cb cb, void *data); /** @} */