Skip to content

Commit

Permalink
Merge branch 'es/squelch-openssl-warnings-on-macosx'
Browse files Browse the repository at this point in the history
An earlier workaround to squelch unhelpful deprecation warnings
from the complier on Mac OSX unnecessarily set minimum required
version of the OS, which the user might want to raise (or lower)
for other reasons.

* es/squelch-openssl-warnings-on-macosx:
  git-compat-util: do not step on MAC_OS_X_VERSION_MIN_REQUIRED
  • Loading branch information
Junio C Hamano committed Feb 22, 2015
2 parents c0997fe + 88c03eb commit 744ea70
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions git-compat-util.h
Original file line number Diff line number Diff line change
Expand Up @@ -212,12 +212,15 @@ extern char *gitbasename(char *);
#endif

#ifndef NO_OPENSSL
#ifdef __APPLE__
#define __AVAILABILITY_MACROS_USES_AVAILABILITY 0
#define MAC_OS_X_VERSION_MIN_REQUIRED MAC_OS_X_VERSION_10_6
#include <AvailabilityMacros.h>
#undef DEPRECATED_ATTRIBUTE
#define DEPRECATED_ATTRIBUTE
#undef __AVAILABILITY_MACROS_USES_AVAILABILITY
#endif
#include <openssl/ssl.h>
#include <openssl/err.h>
#undef MAC_OS_X_VERSION_MIN_REQUIRED
#undef __AVAILABILITY_MACROS_USES_AVAILABILITY
#ifdef NO_HMAC_CTX_CLEANUP
#define HMAC_CTX_cleanup HMAC_cleanup
#endif
Expand Down

0 comments on commit 744ea70

Please sign in to comment.