summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorAdam Mitz <mitza@objectcomputing.com>2021-12-21 08:31:23 -0600
committerAdam Mitz <mitza@objectcomputing.com>2021-12-21 08:31:23 -0600
commit1774ba134d1f9c56cb65663d94ff966ecfe058fc (patch)
tree009872f29c8e18ec4e1e75a17f49c0fb689c48ac /config
parent652cd975e71b6a1ec1f4526daa76264ca7e2f152 (diff)
downloadMPC-1774ba134d1f9c56cb65663d94ff966ecfe058fc.tar.gz
Updated Qt5 base projects for -static builds
Diffstat (limited to 'config')
-rw-r--r--config/qt5_core.mpb12
-rw-r--r--config/qt5_gui.mpb2
-rw-r--r--config/qt5_network.mpb2
-rw-r--r--config/qt5_opengl.mpb2
-rw-r--r--config/qt5_sql.mpb2
-rw-r--r--config/qt5_test.mpb2
-rw-r--r--config/qt5_widgets.mpb2
-rw-r--r--config/qt5_xml.mpb2
8 files changed, 18 insertions, 8 deletions
diff --git a/config/qt5_core.mpb b/config/qt5_core.mpb
index 2f8aca74..288ab1aa 100644
--- a/config/qt5_core.mpb
+++ b/config/qt5_core.mpb
@@ -22,7 +22,16 @@ project {
requires += qt5
includes += $(QT5_INCDIR)
libpaths += $(QT5_LIBDIR)
- libs += Qt5Core
+
+ // Use lit_libs instead of libs for qt5's libraries.
+ // When generating -static projects of a type that uses lib_modifier,
+ // the lib_modifier will have an "s" in it (s for Release, sd for Debug).
+ // However, the libraries produced by the Qt project never have an "s" suffix.
+ // When MPC generates -static projects, the Qt being used may or may not be
+ // static (it doesn't matter for project generation).
+ // Since the Qt projects do use a "d" suffix for Debug whether or not the
+ // libs are static, we need to account for that with $(QT5_LIBSUFFIX).
+ lit_libs += Qt5Core$(QT5_LIBSUFFIX)
// On Linux at least, Qt5 by default requires position independent code
specific (gnuace) {
@@ -34,6 +43,7 @@ project {
// which will conflict with winsock2.h. This makes windows.h not include
// winsock.h
macros += WIN32_LEAN_AND_MEAN
+ Debug::QT5_LIBSUFFIX = d
}
Define_Custom(UIC) {
diff --git a/config/qt5_gui.mpb b/config/qt5_gui.mpb
index 8ad05d63..ee431ff2 100644
--- a/config/qt5_gui.mpb
+++ b/config/qt5_gui.mpb
@@ -1,4 +1,4 @@
project: qt5_core {
- libs += Qt5Gui
+ lit_libs += Qt5Gui$(QT5_LIBSUFFIX)
}
diff --git a/config/qt5_network.mpb b/config/qt5_network.mpb
index 25093423..a7e3e3cc 100644
--- a/config/qt5_network.mpb
+++ b/config/qt5_network.mpb
@@ -1,4 +1,4 @@
project: qt5_core {
- libs += Qt5Network
+ lit_libs += Qt5Network$(QT5_LIBSUFFIX)
}
diff --git a/config/qt5_opengl.mpb b/config/qt5_opengl.mpb
index ba8bdb59..00276362 100644
--- a/config/qt5_opengl.mpb
+++ b/config/qt5_opengl.mpb
@@ -1,4 +1,4 @@
project: qt5_widgets {
- libs += Qt5OpenGL
+ lit_libs += Qt5OpenGL$(QT5_LIBSUFFIX)
}
diff --git a/config/qt5_sql.mpb b/config/qt5_sql.mpb
index 6d027206..77db90a4 100644
--- a/config/qt5_sql.mpb
+++ b/config/qt5_sql.mpb
@@ -1,4 +1,4 @@
project: qt5_core {
- libs += Qt5Sql
+ lit_libs += Qt5Sql$(QT5_LIBSUFFIX)
}
diff --git a/config/qt5_test.mpb b/config/qt5_test.mpb
index b925b377..3cd72d59 100644
--- a/config/qt5_test.mpb
+++ b/config/qt5_test.mpb
@@ -1,4 +1,4 @@
project: qt5_core {
- libs += Qt5Test
+ lit_libs += Qt5Test$(QT5_LIBSUFFIX)
}
diff --git a/config/qt5_widgets.mpb b/config/qt5_widgets.mpb
index a50b0ce4..c248e09c 100644
--- a/config/qt5_widgets.mpb
+++ b/config/qt5_widgets.mpb
@@ -1,4 +1,4 @@
project: qt5_gui {
- libs += Qt5Widgets
+ lit_libs += Qt5Widgets$(QT5_LIBSUFFIX)
}
diff --git a/config/qt5_xml.mpb b/config/qt5_xml.mpb
index a9f4d2b8..9c1d4791 100644
--- a/config/qt5_xml.mpb
+++ b/config/qt5_xml.mpb
@@ -1,4 +1,4 @@
project: qt5_core {
- libs += Qt5Xml
+ lit_libs += Qt5Xml$(QT5_LIBSUFFIX)
}