From 194a40449039a1e1dad2f370255698172bf5e7f7 Mon Sep 17 00:00:00 2001 From: Mikhail Svetkin Date: Tue, 10 Apr 2018 15:03:11 +0200 Subject: Make the use of -fdata-sections and --gc-sections more generic in Qt Add qmake feature and configure option, which optimze the size of static exectuable. Use for static build. Enabled via configure --gc-binaries, or CONFIG += gc-binaries in 3rd party projects. Change-Id: I3c25b02caaef6a4afc6019afc9c67122dd11696d Reviewed-by: Oswald Buddenhagen --- src/corelib/corelib.pro | 1 + 1 file changed, 1 insertion(+) (limited to 'src/corelib/corelib.pro') diff --git a/src/corelib/corelib.pro b/src/corelib/corelib.pro index 7f62a6f1b0..2244020795 100644 --- a/src/corelib/corelib.pro +++ b/src/corelib/corelib.pro @@ -4,6 +4,7 @@ CONFIG += exceptions MODULE = core # not corelib, as per project file MODULE_CONFIG = moc resources +qtConfig(gc_binaries): MODULE_CONFIG += gc_binaries !isEmpty(QT_NAMESPACE): MODULE_DEFINES = QT_NAMESPACE=$$QT_NAMESPACE TRACEPOINT_PROVIDER = $$PWD/qtcore.tracepoints -- cgit v1.2.3