[Interest] Qt4.8.5 redefining MAC_OS_X_VERSION_MIN_REQUIRED
Thiago Macieira
thiago.macieira at intel.com
Sun Dec 22 19:46:05 CET 2013
On domingo, 22 de dezembro de 2013 18:05:35, Cotton Seed wrote:
> I'm trying to build an application which uses Qt and, elsewhere, requires
> OSX features from 10.7 and beyond. I'm compiling with
> -mmacosx-version-min=10.7. However, qglobal.h redefines
> MAC_OS_X_VERSION_MIN_REQUIRED:
>
> #ifdef Q_OS_DARWIN
> # ifdef MAC_OS_X_VERSION_MIN_REQUIRED
> # undef MAC_OS_X_VERSION_MIN_REQUIRED
> # endif
> # define MAC_OS_X_VERSION_MIN_REQUIRED MAC_OS_X_VERSION_10_4
> # include <AvailabilityMacros.h>
> ...
>
> and this wreaks havoc elsewhere in the application. Can anyone explain how
> this is supposed to work? How does one compile an application on OSX 4.8.5
> for 4.7+? Thanks!
This was fixed for 5.1 with the following commit:
commit 193e3ba32e0c808b48216d9d96aa88e591dd189f
Author: Tor Arne Vestbø <torarnv at gmail.com>
Date: Sat Feb 16 15:03:33 2013 +0100
Don't override OS X deployment target unconditionally in
qsystemdetection.h
AvailabilityMacros.h will pick up the MACOSX_DEPLOYMENT_TARGET environment
variable, as well as the -mmacosx-min-version= command line flag, and
set the MAC_OS_X_VERSION_MIN_REQUIRED based on that. By setting the
define before including AvailabilityMacros.h we essentially skipped
that whole logic and always set it to 10.6.
Only in the case where there's no deployment target specified on the
command line do we want to ensure that it's at least 10.6
Change-Id: Ic558ff4deb77937ea805b048d83949815b273bcc
Reviewed-by: Thiago Macieira <thiago.macieira at intel.com>
The change looks correct to me, so you may want to backport it or just remove
the check entirely.
--
Thiago Macieira - thiago.macieira (AT) intel.com
Software Architect - Intel Open Source Technology Center
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20131222/7e2a6434/attachment.sig>
More information about the Interest
mailing list