git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Deprecation warnings under XCode

From
Eric Sunshine <sunshine@sunshineco.com>
Date
Dec 3, 2014, 18:16 UTC
Message-ID
<CAPig+cQHjAtBBGMJGFj6YH1dmW+akY0eg_i+jbOz-khirwa2bA@mail.gmail.com>
In-Reply-To
<20141203100415.GA4893@gmail.com>
On Wed, Dec 3, 2014 at 5:04 AM, David Aguilar <davvid@gmail.com> wrote:
Show 32 quoted lines
> On Tue, Dec 02, 2014 at 10:09:35PM -0500, Eric Sunshine wrote:
>> The potentially lesser evil would be this small patch (minus Gmail
>> whitespace damage) which disables the deprecation warnings only for
>> Apple's headers:
>>
>> ----- >8 -----
>> diff --git a/git-compat-util.h b/git-compat-util.h
>> index 400e921..709e84f 100644
>> --- a/git-compat-util.h
>> +++ b/git-compat-util.h
>> @@ -211,6 +211,8 @@ extern char *gitbasename(char *);
>>  #endif
>>
>>  #ifndef NO_OPENSSL
>> +#define __AVAILABILITY_MACROS_USES_AVAILABILITY 0
>> +#define MAC_OS_X_VERSION_MIN_REQUIRED MAC_OS_X_VERSION_10_6
>>  #include <openssl/ssl.h>
>>  #include <openssl/err.h>
>>  #endif
>> ----- >8 -----
>>
>> Considering that Mac OS X is now at 10.10 and these deprecations
>> commenced with Mac OS X 10.7 in July 2011 (3.5 years ago), and Apple
>> still has not provided drop-in CommonCrypto equivalents, it seems
>> unlikely that they will do so any time soon. Consequently, suppressing
>> these otherwise unavoidable warnings may be the best we can do.
>>
>> I'm willing to formalize and submit this as a proper patch if it's not
>> considered too disgusting by the powers-that-be.
>
> Tweaking those internal #defines can only come back to bite us
> in the future when the functions are finally ripped out.

If Apple ever does remove those deprecated functions, the build will break badly regardless of whether or not the Apple-specific deprecation warnings are suppressed. This patch does not make the situation any worse, so I don't understand the argument.

If a full set of drop-in equivalents was available, on the other hand, then your argument would make perfect sense, but it does not seem apply to the current situation since there is no evidence that Apple will be providing those replacements any time soon (or ever).

Previous: David Aguilar
Message 11 of 11 in “Deprecation warnings under XCode”
  1. Michael BlumeDec 1, 2014
  2. Torsten BögershausenDec 1, 2014
  3. Kyle J. McKayDec 1, 2014
  4. Junio C HamanoDec 1, 2014
  5. Eric SunshineDec 3, 2014
  6. Michael BlumeDec 3, 2014
  7. Eric SunshineDec 3, 2014
  8. David AguilarDec 3, 2014
  9. Torsten BögershausenDec 3, 2014
  10. David AguilarDec 4, 2014
  11. Eric SunshineDec 3, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.