[Webkit-unassigned] [Bug 92821] New: [chromium mac] Chromium compile fails in debug with 10.7sdk in Source/WebCore/platform/graphics/mac/SimpleFontDataMac.mm due to bad #if guards

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jul 31 18:41:49 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=92821

           Summary: [chromium mac] Chromium compile fails in debug with
                    10.7sdk in
                    Source/WebCore/platform/graphics/mac/SimpleFontDataMac
                    .mm due to bad #if guards
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Unspecified
        OS/Version: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: New Bugs
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: jamesr at chromium.org
                CC: mitz at webkit.org, thakis at chromium.org


Chromium mac fails to compile with xcode 4.4 / mac10.7sdk in Source/WebCore/platform/graphics/mac/SimpleFontDataMac.mm with this error:

Source/WebCore/platform/graphics/mac/SimpleFontDataMac.mm:95:26: error: use of undeclared identifier 'FMGetATSFontRefFromFont'
    ATSFontRef atsFont = FMGetATSFontRefFromFont(CTFontGetPlatformFont(toCTFontRef(font), 0));

Looking at the code:

#if !ERROR_DISABLED
#if defined(__LP64__) || PLATFORM(IOS) || __MAC_OS_X_VERSION_MIN_REQUIRED >= 1070
static NSString* pathFromFont(NSFont*)
{
    // FMGetATSFontRefFromFont is not available. As pathFromFont is only used for debugging purposes,
    // returning nil is acceptable.
    return nil;
}
#else
static NSString* pathFromFont(NSFont *font)
{
    ATSFontRef atsFont = FMGetATSFontRefFromFont(CTFontGetPlatformFont(toCTFontRef(font), 0));
...


the intention is to not compile this function in when using the 10.7 sdk. However, since the chromium port doesn't set OS_X_VERSION_MIN_REQUIRED we do try to compile in the actual impl.  We should probably just not compile this function in ever in the chromium port, or at least not when using a 10.7+ sdk

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list