[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ft-devel] freetype 2.3.6 compile error on Mac 10.4
From: |
mpsuzuki |
Subject: |
Re: [ft-devel] freetype 2.3.6 compile error on Mac 10.4 |
Date: |
Fri, 27 Jun 2008 01:35:05 +0900 |
Dear Sir,
Before all, thank you very much for writing a patch very quickly.
On Wed, 25 Jun 2008 15:14:10 -0400
"Sean McBride" <address@hidden> wrote:
>So we could simplify:
>
>#if defined( MAC_OS_X_VERSION_10_5 ) && \
> ( MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5 )
>
>to:
>
>#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1050
>
>I think it is still very readable and it has the advantage of working
>with any SDK, even back to 10.0.
Umm, I can understand some people it's readable than original,
but I feel it's halfway - 1050 looks like a magic number.
In all previously released SDKs, the values of each
MAC_OS_X_VERSION_x_y are kept as same. But I don't know if the
numbering scheme of MAC_OS_X_VERSION_x_y is published and declared
as stable, so I think the value of MAC_OS_X_VERSION_x_y should not
be compared with numerical constant (the situation is slightly
different from "__LP64__" which is evaluated as boolean, and
which is used in various platforms & compilers). If you know
any documentation which describes the numbering scheme, please
let me know. For example, ISO C99 defines a macro __STDC_VERSION__
= 199901L. For such macros that the value is well specified,
I have no objection to compare with numerical constant, at all.
>To check for the 10.5 SDK use:
>#if MAC_OS_X_VERSION_MAX_ALLOWED
>
>So the previous conditional declaration of ResourceIndex was wrong, but
>adding something to the configure script is not the ideal solution in my
>option. For example, it breaks VTK which uses freetype but does not use
>freetype's configure stuff (it uses CMake). A better solution is to
>just test the SDK version.
Thank you for information. Taking a glance on AvailabilityMacros.h,
it seems that an user cannot set MAC_OS_X_VERSION_MAX_ALLOWED explicitly
(an user can set MAC_OS_X_VERSION_MIN_REQUIRED, but!), so it would
be useful to guess SDK version.
As I've written in above, I don't want to compare the macro with
numerical constant. I want to use following conditional (if the
numbering scheme is not published).
#if !defined( MAC_OS_X_VERSION_10_5 ) && \
( MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5 )
...
#endif
Is it acceptable?
To Apple people: if the numbering scheme of MAC_OS_X_VERSION_x_y
is stable, please let me know.
Regards,
mpsuzuki