summaryrefslogtreecommitdiffstats
path: root/src/platformsupport
diff options
context:
space:
mode:
authorJake Petroules <jake.petroules@qt.io>2016-08-24 16:24:34 -0700
committerJake Petroules <jake.petroules@qt.io>2016-08-25 22:18:01 +0000
commitf607233c7ce899c27034eca01c23b0da2895bf93 (patch)
treefebf0e1c198ad391866107df28b828b3a5e12239 /src/platformsupport
parenta158277f9e7d60e3076bf9fe5912a57b2c297394 (diff)
Don't disable CoreText on watchOS Simulator
Frameworks are not available on Apple platforms on a device vs simulator basis. The documentation states that CoreText is available on watchOS: https://developer.apple.com/reference/coretext?language=objc, as do the watchOS 2.2 release notes. Therefore, work around the problem and note the rdar numbers for the bug report to Apple. Change-Id: I7f8ce830aee7a23d65aaf44072e5294188da5e63 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Diffstat (limited to 'src/platformsupport')
-rw-r--r--src/platformsupport/fontdatabases/fontdatabases.pri2
-rw-r--r--src/platformsupport/fontdatabases/mac/coretext.pri10
2 files changed, 11 insertions, 1 deletions
diff --git a/src/platformsupport/fontdatabases/fontdatabases.pri b/src/platformsupport/fontdatabases/fontdatabases.pri
index f8e51f2a6d..1ea7f42204 100644
--- a/src/platformsupport/fontdatabases/fontdatabases.pri
+++ b/src/platformsupport/fontdatabases/fontdatabases.pri
@@ -1,4 +1,4 @@
-darwin:!if(watchos:CONFIG(simulator, simulator|device)) {
+darwin {
include($$PWD/mac/coretext.pri)
} else {
!win32|qtConfig(freetype) {
diff --git a/src/platformsupport/fontdatabases/mac/coretext.pri b/src/platformsupport/fontdatabases/mac/coretext.pri
index 4d19a59226..e1132cfcbe 100644
--- a/src/platformsupport/fontdatabases/mac/coretext.pri
+++ b/src/platformsupport/fontdatabases/mac/coretext.pri
@@ -14,3 +14,13 @@ else: \
# On Mac OS they are part of the ApplicationServices umbrella framework,
# even in 10.8 where they were also made available stand-alone.
LIBS_PRIVATE += -framework ApplicationServices
+
+# CoreText is documented to be available on watchOS, but the headers aren't present
+# in the watchOS Simulator SDK like they are supposed to be. Work around the problem
+# by adding the device SDK's headers to the search path as a fallback.
+# rdar://25314492, rdar://27844864
+watchos:CONFIG(simulator, simulator|device) {
+ QMAKE_CXXFLAGS += \
+ -F$$xcodeSDKInfo(Path, $${simulator.sdk})/System/Library/Frameworks \
+ -F$$xcodeSDKInfo(Path, $${device.sdk})/System/Library/Frameworks
+}