summaryrefslogtreecommitdiffstats
path: root/mkspecs/features/mac
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@qt.io>2017-09-10 15:50:45 +0200
committerTor Arne Vestbø <tor.arne.vestbo@qt.io>2017-09-29 10:08:08 +0000
commitc3e93391eeb23d575d131d17c5922f9ca6347e1b (patch)
treef1952785df90dc64ca79b1285edb5f67134c41b8 /mkspecs/features/mac
parentb74cdf18e86ebfa0e76fdeb4407f9a347471bd98 (diff)
qmake: Allow non-bundle apps and libs to have an Info.plist
Change-Id: I5fe5c8d3214876520b5259d478ac9ef887c61e95 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Diffstat (limited to 'mkspecs/features/mac')
-rw-r--r--mkspecs/features/mac/mac.prf17
1 files changed, 17 insertions, 0 deletions
diff --git a/mkspecs/features/mac/mac.prf b/mkspecs/features/mac/mac.prf
new file mode 100644
index 0000000000..52f06ef773
--- /dev/null
+++ b/mkspecs/features/mac/mac.prf
@@ -0,0 +1,17 @@
+
+# Embed plist file via linker if we're not building a bundle
+!isEmpty(QMAKE_INFO_PLIST) {
+ add_plist = false
+ equals(TEMPLATE, lib) {
+ plugin:!plugin_bundle: \
+ add_plist = true
+ else: !plugin:!lib_bundle: \
+ add_plist = true
+ } else: equals(TEMPLATE, app) {
+ !app_bundle: \
+ add_plist = true
+ }
+
+ $$add_plist: \
+ QMAKE_LFLAGS += -Wl,-sectcreate,__TEXT,__info_plist,$$shell_quote($$QMAKE_INFO_PLIST)
+}