bugThe FreeType Project - Bugs: bug #31321, current freetype2 cannot be built...

 
 

bug #31321: current freetype2 cannot be built on Mac OS X 10.0 - 10.1

Submitted by:  suzuki toshiya <mpsuzuki>
Submitted on:  Wed 13 Oct 2010 09:11:28 AM UTC  
 
Severity: 1 - WishItem Group: None
Status: FixedPrivacy: Public
Assigned to: suzuki toshiya <mpsuzuki>Open/Closed: Closed
Planned Release: None

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sat 28 May 2011 05:01:27 PM UTC, comment #3:

Revised version of the first patch is applied to GIT head.
The headers in the third party SDK, Metrowerks CodeWarrior
version 9, is checked too. It includes its own errno.h, but
its definition is synchronized with native SDK, but ELAST
is not defined. In addition, recent Mac OS X hides some
errno if _POSIX_C_SOURCE is defined. I used ECANCELED
as a portable marker for Mac OS X 10.2 (it is not disabled
by _POSIX_C_SOURCE).

suzuki toshiya <mpsuzuki>
Project AdministratorIn charge of this item.
Sat 28 May 2011 03:06:28 PM UTC, comment #2:

In addition, putting such C preprocessor hook to ftconfig.h
would be bad idea. ftconfig.h seems to be a collection of
C preprocessor hook dealing with the size of integer types
and not library dependencies. I think FT_MACINTOSH and
DARWIN_NO_CARBON are not for FT2 client but FT2 internal
code in compilation time, but, at least, separating such hook
out of ftconfig.h would be easier to maintain.

In freetype (not freetype-devel) mailing list, I proposed to
hide FT_MACINTOSH and DARWIN_NO_CARBON from public
header file and move to a header in base module sources.

Attached is a patch (designed to be applied after previous
patch) to do that.

(file #23459)

suzuki toshiya <mpsuzuki>
Project AdministratorIn charge of this item.
Sat 28 May 2011 02:59:37 PM UTC, comment #1:

Carbon header files for higher level interface (like MacTypes.h)
can include AvailabilityMacros.h automatically if it is available.
But inclusion of higher level interfaces by ftconfig.h makes the
namespace polluted broadly. For example, "Byte" type is defined
by MacTypes.h and cannot be used by ftraster module.

Checking C89 and POSIX.1 (1988) header files in Mac OS X,
I found 2 files useful to distinguish the earliest systems
without AvailabilityMacros.h and the later systems with it.

1) locale.h (C89 header)
_LC_LAST, the macro to indicate the number of locale dependent
properties is changed from 6 (Mac OS X 10.0-10.1) to 7
(10.2-), because LC_MESSAGES was introduced since 10.2.

2) errno.h (POSIX.1 header)
The number of predefined errors are changed from 88 (10.0-10.1),
89 (10.2), 93 (10.3), 102 (10.4), 103 (10.5-6).

Maybe the namespace pollution by errno.h (of course, only on
Mac OS X) would be more acceptable than locale.h, because
locale related header of poorly internationalized system is
sometimes hijacked by external locale libraries.

Attached file is a patch to conditionalize AvailabilityMacros.h
inclusion by errno.h.

(file #23458)

suzuki toshiya <mpsuzuki>
Project AdministratorIn charge of this item.
Wed 13 Oct 2010 09:11:28 AM UTC, original submission:

Current freetype2 ftconfig.h expects as Mac OS X has
"AvailabilityMacros.h" always. This was introduced to
handle the piggy-back progress of the features and the
incompatibilities among various Mac OS X revisions since
10.2 or 10.3.

In the earlier revisions, the linear progress of the features
might be assumed, so no AvailabilityMacros.h was not
included. The header files in back-compatible SDKs are
not exactly same with the native header files in the legacy
systems, they include "AvailabilityMacros.h". So the
building test by back-compatible SDKs is not perfect.
The native building test is required.

suzuki toshiya <mpsuzuki>
Project AdministratorIn charge of this item.

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #23459:  mps20110528c.diff added by mpsuzuki (10KiB - text/x-patch)
file #23458:  mps20110528b.diff added by mpsuzuki (3KiB - text/x-patch)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by mpsuzuki (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 28 May 2011 05:05:56 PM UTCmpsuzukiOpen/ClosedOpen=>Closed
    Sat 28 May 2011 05:01:27 PM UTCmpsuzukiStatusNone=>Fixed
    Sat 28 May 2011 03:06:28 PM UTCmpsuzukiAttached File-=>Added mps20110528c.diff, #23459
    Sat 28 May 2011 02:59:37 PM UTCmpsuzukiAttached File-=>Added mps20110528b.diff, #23458

    Back to the top


    Powered by Savane 3.1-cleanup1