[MacPorts] #43978: libgcc: error: unknown value '10.10' of -mmacosx-version-min

MacPorts noreply at macports.org
Sun Jul 27 14:25:13 PDT 2014


#43978: libgcc: error: unknown value '10.10' of -mmacosx-version-min
-----------------------+----------------------
  Reporter:  arthur@…  |      Owner:  mww@…
      Type:  defect    |     Status:  new
  Priority:  Normal    |  Milestone:
 Component:  ports     |    Version:  2.3.0
Resolution:            |   Keywords:  yosemite
      Port:  libgcc    |
-----------------------+----------------------

Comment (by ab@…):

 As far as I can understand, this file (at least) has to be patched:

 gcc-4.8.2/gcc/config/darwin-c.c, arounf lines 573-597:

 {{{
 /* Return the value of darwin_macosx_version_min suitable for the
    __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ macro,
    so '10.4.2' becomes 1040.  The lowest digit is always zero.
    Print a warning if the version number can't be understood.  */
 static const char *
 version_as_macro (void)
 {
   static char result[] = "1000";

   if (strncmp (darwin_macosx_version_min, "10.", 3) != 0)
     goto fail;
   if (! ISDIGIT (darwin_macosx_version_min[3]))
     goto fail;
   result[2] = darwin_macosx_version_min[3];
   if (darwin_macosx_version_min[4] != '\0'    //  <--- This is the
 problem. The code does not expect minor version to be 2-chars, rather only
 one-char.
       && darwin_macosx_version_min[4] != '.') //  <---  So for 10.X it
 works, bit for 10.XX it gives an error
     goto fail;

   return result;

  fail:
   error ("unknown value %qs of -mmacosx-version-min",
          darwin_macosx_version_min);
   return "1000";
 }

 }}}

-- 
Ticket URL: <https://trac.macports.org/ticket/43978#comment:7>
MacPorts <http://www.macports.org/>
Ports system for OS X


More information about the macports-tickets mailing list