Does CodeWarrior Pro9 correctly support the availablity macros
MAC_OS_X_VERSION_MIN_REQUIRED and MAC_OS_X_VERSION_MAX_ALLOWED as
described in Technote 2064 for MachO targets? (see
http://developer.apple.com/technotes/tn2002/tn2064.html)
Looking at the header /usr/include/AvailabilityMacros.h it seems that
the the necessary definitions of WEAK_IMPORT_ATTRIBUTE,
DEPRECATED_ATTRIBUTE, ... are only set up correctly for gcc but to for
mwcc.
Thanks,
Sascha
MW Ron - 03 Feb 2004 03:29 GMT
>Does CodeWarrior Pro9 correctly support the availablity macros
>MAC_OS_X_VERSION_MIN_REQUIRED and MAC_OS_X_VERSION_MAX_ALLOWED as
[quoted text clipped - 5 lines]
>DEPRECATED_ATTRIBUTE, ... are only set up correctly for gcc but to for
>mwcc.
We are aware of little differences like this in the header and
implementation. We usually work with Apple to fix them in a short time
frame. I don't specifically know of any 10.3 features which require
setting the MAC_OS_X_VERSION_MIN_REQUIRED and
MAC_OS_X_VERSION_MAX_ALLOWED flags but it may be necessary with ld and
not mwld.
May I ask what are you trying to get done, that you think you will need
the MAC_OS_X_VERSION_MIN_REQUIRED and MAC_OS_X_VERSION_MAX_ALLOWED? It
may be that we have a more direct way or better way to make it work.
Contact me in e-mail with what you need and I'll consult with
engineering.
Ron

Signature
Metrowerks, maker of CodeWarrior - "Software Starts Here"
Ron Liechty - MWRon@metrowerks.com - <http://www.metrowerks.com>
Paul Lalonde - 03 Feb 2004 08:20 GMT
> Does CodeWarrior Pro9 correctly support the availablity macros
> MAC_OS_X_VERSION_MIN_REQUIRED and MAC_OS_X_VERSION_MAX_ALLOWED as
> described in Technote 2064 for MachO targets? (see
> http://developer.apple.com/technotes/tn2002/tn2064.html)
AFAIK, no they aren't supported, at least not in 8.3 which is what I
use. CodeWarrior does have an alternate means of specifying weak-linked
functions, though. It involves adding to your project a text file with
an extension of ".wke", containing the symbols to weak-link against.
This file has the same syntax as a .exp file. For example:
# Drag Mgr functions added in MacOS X 10.3
_NewDragWithPasteboard
_GetDragPasteboard
BTW, the MAC_OS_X_VERSION_MIN_REQUIRED and MAC_OS_X_VERSION_MAX_ALLOWED
macros are used inconsistently in Apple's headers. Some headers bracket
10.3-specific routines inside an #ifdef, in others the XXX_ATTRIBUTE
macros are used, and in others still there's no marking at all of
10.3-specific functions.
Hope this helps,
Paul