summaryrefslogtreecommitdiffstats
path: root/src/gui/dialogs
diff options
context:
space:
mode:
authorMorten Johan Sørvig <morten.sorvig@nokia.com>2009-12-08 13:30:38 (GMT)
committerMorten Johan Sørvig <morten.sorvig@nokia.com>2009-12-08 13:50:03 (GMT)
commit971acc6d34559a2c5035888a5891ea29ad8628af (patch)
tree3db75eb996c46bd64012b132415262b86be4033f /src/gui/dialogs
parent3f5e4ed4d2b110f4c6e952b74c9f852a2dc14a54 (diff)
downloadQt-971acc6d34559a2c5035888a5891ea29ad8628af.zip
Qt-971acc6d34559a2c5035888a5891ea29ad8628af.tar.gz
Qt-971acc6d34559a2c5035888a5891ea29ad8628af.tar.bz2
Compile with -no-exceptions on Mac.
qfontdialog_mac.mm needs to handle exceptions thrown by Cocoa, even if Qt is configured with if -no-exceptions. This ads a bit of qmake logic for the benefit of a single file, but I would like to keep -no-exceptions working. The savings are significant (around 10-15%). Revby: Richard Moe Gustavsen
Diffstat (limited to 'src/gui/dialogs')
-rw-r--r--src/gui/dialogs/dialogs.pri18
1 files changed, 16 insertions, 2 deletions
diff --git a/src/gui/dialogs/dialogs.pri b/src/gui/dialogs/dialogs.pri
index b9fad41..63f64a2 100644
--- a/src/gui/dialogs/dialogs.pri
+++ b/src/gui/dialogs/dialogs.pri
@@ -28,13 +28,27 @@ HEADERS += \
dialogs/qprintpreviewdialog.h
!embedded:mac {
- OBJECTIVE_SOURCES += dialogs/qcolordialog_mac.mm \
- dialogs/qfiledialog_mac.mm \
+ OBJECTIVE_SOURCES += dialogs/qfiledialog_mac.mm \
dialogs/qfontdialog_mac.mm \
dialogs/qnspanelproxy_mac.mm \
dialogs/qpagesetupdialog_mac.mm \
dialogs/qprintdialog_mac.mm
+
+# Compile qcolordialog_mac.mm with exception support, disregarding the -no-exceptions
+# configure option. (qcolordialog_mac needs to catch exceptions thrown by cocoa)
+ EXCEPTION_SOURCES = dialogs/qcolordialog_mac.mm
+ exceptions_compiler.commands = $$QMAKE_CXX -c
+ exceptions_compiler.commands += $(CXXFLAGS) $(INCPATH) ${QMAKE_FILE_IN} -o ${QMAKE_FILE_OUT}
+ exceptions_compiler.commands += -fexceptions
+ exceptions_compiler.dependency_type = TYPE_C
+ exceptions_compiler.output = ${QMAKE_VAR_OBJECTS_DIR}${QMAKE_FILE_BASE}$${first(QMAKE_EXT_OBJ)}
+ exceptions_compiler.input = EXCEPTION_SOURCES
+ exceptions_compiler.variable_out = OBJECTS
+ exceptions_compiler.name = compiling[exceptopns] ${QMAKE_FILE_IN}
+ silent:exceptions_compiler.commands = @echo compiling[exceptopns] ${QMAKE_FILE_IN} && $$exceptions_compiler.commands
+ QMAKE_EXTRA_COMPILERS += exceptions_compiler
}
+
win32 {
HEADERS += dialogs/qwizard_win_p.h
SOURCES += dialogs/qdialogsbinarycompat_win.cpp \