<commit_before><commit_msg>gcc: add patch for Catalina SDK<commit_after>diff -pur gcc-9.2.0/fixincludes/fixincl.x gcc-9.2.0-fixed/fixincludes/fixincl.x
--- gcc-9.2.0/fixincludes/fixincl.x	2019-08-03 21:21:08.000000000 +0200
+++ gcc-9.2.0-fixed/fixincludes/fixincl.x	2019-10-01 11:43:32.000000000 +0200
@@ -2,11 +2,11 @@
  *
  * DO NOT EDIT THIS FILE   (fixincl.x)
  *
- * It has been AutoGen-ed  July  7, 2019 at 11:43:37 AM by AutoGen 5.17.4
+ * It has been AutoGen-ed  October  1, 2019 at 11:43:32 AM by AutoGen 5.18.16
  * From the definitions    inclhack.def
  * and the template file   fixincl
  */
-/* DO NOT SVN-MERGE THIS FILE, EITHER Sun Jul  7 11:43:37 BST 2019
+/* DO NOT SVN-MERGE THIS FILE, EITHER Tue Oct  1 11:43:32 CEST 2019
  *
  * You must regenerate it.  Use the ./genfixes script.
  *
@@ -15,7 +15,7 @@
  * certain ANSI-incompatible system header files which are fixed to work
  * correctly with ANSI C and placed in a directory that GNU C will search.
  *
- * This file contains 255 fixup descriptions.
+ * This file contains 256 fixup descriptions.
  *
  * See README for more information.
  *
@@ -2636,6 +2636,48 @@ static const char* apzDarwin_Availabilit
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
+ *  Description of Darwin_Availability fix
+ */
+tSCC zDarwin_AvailabilityName[] =
+     "darwin_availability";
+
+/*
+ *  File name selection pattern
+ */
+tSCC zDarwin_AvailabilityList[] =
+  "Availability.h\0";
+/*
+ *  Machine/OS name selection pattern
+ */
+tSCC* apzDarwin_AvailabilityMachs[] = {
+        "*-*-darwin*",
+        (const char*)NULL };
+
+/*
+ *  content selection pattern - do fix if pattern found
+ */
+tSCC zDarwin_AvailabilitySelect0[] =
+       "#endif /\\* __OSX_AVAILABLE_STARTING \\*/";
+
+#define    DARWIN_AVAILABILITY_TEST_CT  1
+static tTestDesc aDarwin_AvailabilityTests[] = {
+  { TT_EGREP,    zDarwin_AvailabilitySelect0, (regex_t*)NULL }, };
+
+/*
+ *  Fix Command Arguments for Darwin_Availability
+ */
+static const char* apzDarwin_AvailabilityPatch[] = {
+    "format",
+    "#endif /* __OSX_AVAILABLE_STARTING */\n\
+#ifndef __OSX_AVAILABLE_STARTING\n\
+  #define __OSX_AVAILABLE_STARTING(_osx, _ios)\n\
+  #define __OSX_AVAILABLE_BUT_DEPRECATED(_osxIntro, _osxDep, _iosIntro, _iosDep)\n\
+  #define __OSX_AVAILABLE_BUT_DEPRECATED_MSG(_osxIntro, _osxDep, _iosIntro, _iosDep, _msg)\n\
+#endif",
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
  *  Description of Darwin_9_Long_Double_Funcs_2 fix
  */
 tSCC zDarwin_9_Long_Double_Funcs_2Name[] =
@@ -10346,9 +10388,9 @@ static const char* apzX11_SprintfPatch[]
  *
  *  List of all fixes
  */
-#define REGEX_COUNT          293
+#define REGEX_COUNT          294
 #define MACH_LIST_SIZE_LIMIT 187
-#define FIX_COUNT            255
+#define FIX_COUNT            256
 
 /*
  *  Enumerate the fixes
@@ -10416,6 +10458,7 @@ typedef enum {
     CTRL_QUOTES_USE_FIXIDX,
     CXX_UNREADY_FIXIDX,
     DARWIN_AVAILABILITYINTERNAL_FIXIDX,
+    DARWIN_AVAILABILITY_FIXIDX,
     DARWIN_9_LONG_DOUBLE_FUNCS_2_FIXIDX,
     DARWIN_EXTERNC_FIXIDX,
     DARWIN_GCC4_BREAKAGE_FIXIDX,
@@ -10922,6 +10965,11 @@ tFixDesc fixDescList[ FIX_COUNT ] = {
      DARWIN_AVAILABILITYINTERNAL_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
      aDarwin_AvailabilityinternalTests,   apzDarwin_AvailabilityinternalPatch, 0 },
 
+  {  zDarwin_AvailabilityName,    zDarwin_AvailabilityList,
+     apzDarwin_AvailabilityMachs,
+     DARWIN_AVAILABILITY_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
+     aDarwin_AvailabilityTests,   apzDarwin_AvailabilityPatch, 0 },
+
   {  zDarwin_9_Long_Double_Funcs_2Name,    zDarwin_9_Long_Double_Funcs_2List,
      apzDarwin_9_Long_Double_Funcs_2Machs,
      DARWIN_9_LONG_DOUBLE_FUNCS_2_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
diff -pur gcc-9.2.0/fixincludes/inclhack.def gcc-9.2.0-fixed/fixincludes/inclhack.def
--- gcc-9.2.0/fixincludes/inclhack.def	2019-08-03 21:21:08.000000000 +0200
+++ gcc-9.2.0-fixed/fixincludes/inclhack.def	2019-10-01 11:43:30.000000000 +0200
@@ -1298,6 +1298,28 @@ fix = {
 };
 
 /*
+ *  macOS 10.15 <Availability.h> does not define __OSX_AVAILABLE_STARTING on
+ *  non-clang compilers.
+ */
+fix = {
+    hackname  = darwin_availability;
+    mach      = "*-*-darwin*";
+    files     = Availability.h;
+    select    = "#endif /\\* __OSX_AVAILABLE_STARTING \\*/";
+    c_fix     = format;
+    c_fix_arg = <<- _EOFix_
+	#endif /* __OSX_AVAILABLE_STARTING */
+	#ifndef __OSX_AVAILABLE_STARTING
+	  #define __OSX_AVAILABLE_STARTING(_osx, _ios)
+	  #define __OSX_AVAILABLE_BUT_DEPRECATED(_osxIntro, _osxDep, _iosIntro, _iosDep)
+	  #define __OSX_AVAILABLE_BUT_DEPRECATED_MSG(_osxIntro, _osxDep, _iosIntro, _iosDep, _msg)
+	#endif
+	_EOFix_;
+
+    test_text = "#endif /* __OSX_AVAILABLE_STARTING */";
+};
+
+/*
  *  For the AAB_darwin7_9_long_double_funcs fix (and later fixes for long long)
  *  to be useful, the main math.h must use <> and not "" includes.
  */
{'fraction_non_alphanumeric': 0.13031161473087818, 'fraction_numerical': 0.06191825171995144, 'mean_word_length': 3.6067101584342964, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 4, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '628176', 'n_tokens_mistral': 2226, 'n_tokens_neox': 1991, 'n_words': 370}