summaryrefslogtreecommitdiff
path: root/qmake/CMakeLists.txt
diff options
context:
space:
mode:
authorAlexey Edelev <alexey.edelev@qt.io>2021-01-28 16:06:26 +0100
committerAlexey Edelev <alexey.edelev@qt.io>2021-02-25 16:08:43 +0100
commit43c28aa9046967abeb4ad042c8be1aa23a19c282 (patch)
treeb8f4a53cd9aaaa819c853ee51e66ea100c1ae3d5 /qmake/CMakeLists.txt
parent5a3bbb55851b84aa6a46c23e5a6fb33b4860edc6 (diff)
downloadqtbase-43c28aa9046967abeb4ad042c8be1aa23a19c282.tar.gz
Use Core library for qmake instead of the Bootstrap library
Move the qmake-specific logic of the QLibraryInfo class to qmake internals. 'qconfig.cpp.in' now stores information about the library info entries to keep them consistent between qmake and the Core library. qmake requires specific features enabled in the Core library, so building qmake will be skipped if the features are not enabled. All flags directly related to the qmake have been removed from Core lib. Remove all bootstrap related sections from qmake CMakeLists.txt Task-number: QTBUG-89369 Change-Id: I26de157d3bfd4a5526699296e9d46e1c180b89ae Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Diffstat (limited to 'qmake/CMakeLists.txt')
-rw-r--r--qmake/CMakeLists.txt215
1 files changed, 25 insertions, 190 deletions
diff --git a/qmake/CMakeLists.txt b/qmake/CMakeLists.txt
index 3897ea192c..08b23df587 100644
--- a/qmake/CMakeLists.txt
+++ b/qmake/CMakeLists.txt
@@ -4,131 +4,27 @@
## qmake Tool:
#####################################################################
+# TODO: Probably it's time to introduce QT_FEATURE_qmake?
+if(NOT (QT_FEATURE_settings AND QT_FEATURE_alloca AND (QT_FEATURE_alloca_malloc_h OR NOT WIN32) AND
+ QT_FEATURE_cborstreamwriter AND QT_FEATURE_datestring AND QT_FEATURE_regularexpression AND
+ QT_FEATURE_temporaryfile))
+ message(WARNING "Skip building qmake in specified configuration.\
+Required features:
+ QT_FEATURE_settings ${QT_FEATURE_settings}
+ QT_FEATURE_alloca ${QT_FEATURE_alloca}
+ QT_FEATURE_cborstreamwriter ${QT_FEATURE_cborstreamwriter}
+ QT_FEATURE_datestring ${QT_FEATURE_datestring}
+ QT_FEATURE_getauxval ${QT_FEATURE_getauxval}
+ QT_FEATURE_regularexpression ${QT_FEATURE_regularexpression}
+ QT_FEATURE_temporaryfile ${QT_FEATURE_temporaryfile}
+")
+ return()
+endif()
+
qt_get_tool_target_name(target_name qmake)
qt_internal_add_tool(${target_name}
- NO_QT # special case
TOOLS_TARGET Core # special case
- # GUI # special case: remove this
SOURCES
- ../src/3rdparty/pcre2/src/config.h
- ../src/3rdparty/pcre2/src/pcre2.h
- ../src/3rdparty/pcre2/src/pcre2_auto_possess.c
- ../src/3rdparty/pcre2/src/pcre2_chartables.c
- ../src/3rdparty/pcre2/src/pcre2_compile.c
- ../src/3rdparty/pcre2/src/pcre2_config.c
- ../src/3rdparty/pcre2/src/pcre2_context.c
- ../src/3rdparty/pcre2/src/pcre2_dfa_match.c
- ../src/3rdparty/pcre2/src/pcre2_error.c
- ../src/3rdparty/pcre2/src/pcre2_extuni.c
- ../src/3rdparty/pcre2/src/pcre2_find_bracket.c
- ../src/3rdparty/pcre2/src/pcre2_internal.h
- ../src/3rdparty/pcre2/src/pcre2_intmodedep.h
- ../src/3rdparty/pcre2/src/pcre2_jit_compile.c
- ../src/3rdparty/pcre2/src/pcre2_maketables.c
- ../src/3rdparty/pcre2/src/pcre2_match.c
- ../src/3rdparty/pcre2/src/pcre2_match_data.c
- ../src/3rdparty/pcre2/src/pcre2_newline.c
- ../src/3rdparty/pcre2/src/pcre2_ord2utf.c
- ../src/3rdparty/pcre2/src/pcre2_pattern_info.c
- ../src/3rdparty/pcre2/src/pcre2_script_run.c
- ../src/3rdparty/pcre2/src/pcre2_serialize.c
- ../src/3rdparty/pcre2/src/pcre2_string_utils.c
- ../src/3rdparty/pcre2/src/pcre2_study.c
- ../src/3rdparty/pcre2/src/pcre2_substitute.c
- ../src/3rdparty/pcre2/src/pcre2_substring.c
- ../src/3rdparty/pcre2/src/pcre2_tables.c
- ../src/3rdparty/pcre2/src/pcre2_ucd.c
- ../src/3rdparty/pcre2/src/pcre2_ucp.h
- ../src/3rdparty/pcre2/src/pcre2_valid_utf.c
- ../src/3rdparty/pcre2/src/pcre2_xclass.c
- ../src/corelib/global/qcontainerinfo.h
- ../src/corelib/global/qendian.cpp # special case
- ../src/corelib/global/qglobal.cpp ../src/corelib/global/qglobal.h
- ../src/corelib/global/qlibraryinfo.cpp
- ../src/corelib/global/qlogging.cpp
- ../src/corelib/global/qmalloc.cpp
- ../src/corelib/global/qnumeric.cpp ../src/corelib/global/qnumeric.h
- ../src/corelib/global/qoperatingsystemversion.cpp # special case
- ../src/corelib/global/qrandom.cpp # special case
- ../src/corelib/io/qabstractfileengine.cpp ../src/corelib/io/qabstractfileengine_p.h
- ../src/corelib/io/qbuffer.cpp ../src/corelib/io/qbuffer.h
- ../src/corelib/io/qdebug.cpp # special case
- ../src/corelib/io/qdir.cpp ../src/corelib/io/qdir.h ../src/corelib/io/qdir_p.h
- ../src/corelib/io/qdiriterator.cpp ../src/corelib/io/qdiriterator.h
- ../src/corelib/io/qfile.cpp ../src/corelib/io/qfile.h
- ../src/corelib/io/qfiledevice.cpp
- ../src/corelib/io/qfileinfo.cpp ../src/corelib/io/qfileinfo.h
- ../src/corelib/io/qfilesystemengine.cpp
- ../src/corelib/io/qfilesystementry.cpp
- ../src/corelib/io/qfsfileengine.cpp
- ../src/corelib/io/qfsfileengine_iterator.cpp
- ../src/corelib/io/qiodevicebase.h
- ../src/corelib/io/qiodevice.cpp ../src/corelib/io/qiodevice.h
- ../src/corelib/io/qsettings.cpp
- ../src/corelib/io/qtemporaryfile.cpp ../src/corelib/io/qtemporaryfile.h
- ../src/corelib/kernel/qiterable.cpp ../src/corelib/kernel/qiterable.h
- ../src/corelib/kernel/qmetacontainer.cpp ../src/corelib/kernel/qmetacontainer.h
- ../src/corelib/kernel/qmetatype.cpp ../src/corelib/kernel/qmetatype.h
- ../src/corelib/kernel/qsystemerror.cpp ../src/corelib/kernel/qsystemerror_p.h
- ../src/corelib/kernel/qvariant.cpp
- ../src/corelib/plugin/quuid.cpp ../src/corelib/plugin/quuid.h
- ../src/corelib/serialization/qcborstreamwriter.cpp ../src/corelib/serialization/qcborstreamwriter.h
- ../src/corelib/serialization/qcborvalue.cpp ../src/corelib/serialization/qcborvalue.h ../src/corelib/serialization/qcborvalue_p.h
- ../src/corelib/serialization/qdatastream.cpp ../src/corelib/serialization/qdatastream.h
- ../src/corelib/serialization/qjson_p.h
- ../src/corelib/serialization/qjsonarray.cpp ../src/corelib/serialization/qjsonarray.h
- ../src/corelib/serialization/qjsoncbor.cpp
- ../src/corelib/serialization/qjsondocument.cpp ../src/corelib/serialization/qjsondocument.h
- ../src/corelib/serialization/qjsonobject.cpp ../src/corelib/serialization/qjsonobject.h
- ../src/corelib/serialization/qjsonparser.cpp ../src/corelib/serialization/qjsonparser_p.h
- ../src/corelib/serialization/qjsonvalue.cpp ../src/corelib/serialization/qjsonvalue.h
- ../src/corelib/serialization/qjsonwriter_p.h
- ../src/corelib/serialization/qtextstream.cpp ../src/corelib/serialization/qtextstream.h
- ../src/corelib/text/qbytearray.cpp ../src/corelib/text/qbytearray.h
- ../src/corelib/text/qbytearraylist.cpp ../src/corelib/text/qbytearraylist.h # special case
- ../src/corelib/text/qbytearraymatcher.cpp ../src/corelib/text/qbytearraymatcher.h
- ../src/corelib/text/qchar.h
- ../src/corelib/text/qlocale.cpp ../src/corelib/text/qlocale.h
- ../src/corelib/text/qlocale_tools.cpp ../src/corelib/text/qlocale_tools_p.h
- ../src/corelib/text/qregularexpression.cpp ../src/corelib/text/qregularexpression.h
- ../src/corelib/text/qstring.cpp ../src/corelib/text/qstring.h
- ../src/corelib/text/qstringbuilder.cpp ../src/corelib/text/qstringbuilder.h
- ../src/corelib/text/qstringconverter.cpp ../src/corelib/text/qstringconverter.h ../src/corelib/text/qstringconverter_p.h
- ../src/corelib/text/qstringlist.cpp ../src/corelib/text/qstringlist.h
- ../src/corelib/text/qstringmatcher.h
- ../src/corelib/text/qvsnprintf.cpp
- ../src/corelib/time/qcalendar.cpp ../src/corelib/time/qcalendar.h
- ../src/corelib/time/qcalendarbackend_p.h
- ../src/corelib/time/qcalendarmath_p.h
- ../src/corelib/time/qdatetime.cpp ../src/corelib/time/qdatetime.h ../src/corelib/time/qdatetime_p.h
- ../src/corelib/time/qgregoriancalendar.cpp ../src/corelib/time/qgregoriancalendar_p.h
- ../src/corelib/time/qromancalendar.cpp ../src/corelib/time/qromancalendar_p.h
- ../src/corelib/tools/qarraydata.cpp ../src/corelib/tools/qarraydata.h
- ../src/corelib/tools/qarraydataops.h
- ../src/corelib/tools/qarraydatapointer.h
- ../src/corelib/tools/qbitarray.cpp ../src/corelib/tools/qbitarray.h
- ../src/corelib/tools/qcryptographichash.cpp ../src/corelib/tools/qcryptographichash.h
- ../src/corelib/time/qcalendar.cpp ../src/corelib/time/qcalendar.h # special case
- ../src/corelib/time/qcalendarbackend_p.h ../src/corelib/time/qcalendarmath_p.h # special case
- ../src/corelib/time/qgregoriancalendar.cpp ../src/corelib/time/qgregoriancalendar_p.h # special case
- ../src/corelib/time/qromancalendar.cpp ../src/corelib/time/qromancalendar_p.h # special case
- ../src/corelib/time/qdatetime.cpp ../src/corelib/time/qdatetime.h ../src/corelib/time/qdatetime_p.h # special case
- ../src/corelib/tools/qduplicatetracker_p.h
- ../src/corelib/tools/qhash.cpp ../src/corelib/tools/qhash.h
- ../src/corelib/tools/qlist.h
- ../src/corelib/tools/qmap.h
- ../src/corelib/text/qlocale.cpp ../src/corelib/text/qlocale.h
- ../src/corelib/text/qlocale_tools.cpp ../src/corelib/text/qlocale_tools_p.h
- ../src/corelib/text/qregularexpression.cpp ../src/corelib/text/qregularexpression.h
- ../src/corelib/tools/qringbuffer.cpp # special case
- ../src/corelib/text/qstring.cpp ../src/corelib/text/qstring.h
- ../src/corelib/text/qstringbuilder.cpp ../src/corelib/text/qstringbuilder.h
- ../src/corelib/text/qstringconverter.cpp ../src/corelib/text/qstringconverter.h ../src/corelib/text/qstringconverter_p.h
- ../src/corelib/text/qstringlist.cpp ../src/corelib/text/qstringlist.h
- ../src/corelib/text/qstringmatcher.h
- ../src/corelib/tools/qvector.h
- ../src/corelib/tools/qversionnumber.cpp ../src/corelib/tools/qversionnumber.h
- ../src/corelib/text/qvsnprintf.cpp
cachekeys.h
generators/mac/pbuilder_pbx.cpp generators/mac/pbuilder_pbx.h
generators/makefile.cpp generators/makefile.h
@@ -153,6 +49,7 @@ qt_internal_add_tool(${target_name}
library/qmakeglobals.cpp library/qmakeglobals.h
library/qmakeparser.cpp library/qmakeparser.h
library/qmakevfs.cpp library/qmakevfs.h
+ qmakelibraryinfo.cpp qmakelibraryinfo.h
main.cpp
meta.cpp meta.h
option.cpp option.h
@@ -160,9 +57,7 @@ qt_internal_add_tool(${target_name}
property.cpp property.h
DEFINES
HAVE_CONFIG_H
- PCRE2_DISABLE_JIT
PROEVALUATOR_FULL
- QT_BOOTSTRAPPED
QT_BUILD_QMAKE
QT_USE_QSTRINGBUILDER
QT_NO_FOREACH
@@ -170,95 +65,38 @@ qt_internal_add_tool(${target_name}
QT_VERSION_MAJOR=${PROJECT_VERSION_MAJOR} # special case
QT_VERSION_MINOR=${PROJECT_VERSION_MINOR} # special case
QT_VERSION_PATCH=${PROJECT_VERSION_PATCH} # special case
- PCRE2_CODE_UNIT_WIDTH=16
- PCRE2_DISABLE_JIT
- HAVE_CONFIG_H
INCLUDE_DIRECTORIES
- # . # special case remove
generators
generators/mac
generators/unix
generators/win32
library
- $<TARGET_PROPERTY:Qt::Core,INCLUDE_DIRECTORIES> # special case
- "${PROJECT_BINARY_DIR}/src/corelib/global" # special case: for qconfig.cpp
+ "${CMAKE_CURRENT_BINARY_DIR}/library" # for qmakeconfig.cpp
PRECOMPILED_HEADER
"qmake_pch.h"
+ LIBRARIES
+ Qt::CorePrivate
)
+qt_generate_qconfig_cpp(../src/corelib/global/qconfig.cpp.in library/qmakeconfig.cpp)
+
#### Keys ignored in scope 1:.:.:qmake.pro:<TRUE>:
# _OPTION = "host_build"
## Scopes:
#####################################################################
-qt_internal_extend_target(${target_name} CONDITION WIN32
- SOURCES
- ../src/corelib/global/qoperatingsystemversion_win.cpp
- ../src/corelib/io/qfilesystemengine_win.cpp
- ../src/corelib/io/qfilesystemiterator_win.cpp
- ../src/corelib/io/qfsfileengine_win.cpp
- ../src/corelib/io/qsettings_win.cpp
- ../src/corelib/plugin/qsystemlibrary.cpp
- ../src/corelib/text/qlocale_win.cpp
- library/registry.cpp
- DEFINES
- UNICODE
- _CRT_SECURE_NO_WARNINGS
- _ENABLE_EXTENDED_ALIGNED_STORAGE
- _SCL_SECURE_NO_WARNINGS
- PUBLIC_DEFINES
- PCRE2_STATIC
- PUBLIC_LIBRARIES
- advapi32
- kernel32
- netapi32
- ole32
-)
-
-qt_internal_extend_target(${target_name} CONDITION UNIX
- SOURCES
- ../src/corelib/io/qfilesystemengine_unix.cpp
- ../src/corelib/io/qfilesystemiterator_unix.cpp
- ../src/corelib/io/qfsfileengine_unix.cpp
- ../src/corelib/kernel/qcore_unix.cpp
- ../src/corelib/text/qlocale_unix.cpp
-)
-
qt_internal_extend_target(${target_name} CONDITION MACOS
- SOURCES
- ../src/corelib/kernel/qcore_foundation.mm # special case
- ../src/corelib/kernel/qcore_mac.mm # special case
- ../src/corelib/global/qoperatingsystemversion_darwin.mm # special case
- ../src/corelib/io/qsettings_mac.cpp # special case
- PUBLIC_LIBRARIES
- ${FWApplicationServices}
- ${FWCoreServices}
- ${FWFoundation}
COMPILE_OPTIONS
"-fconstant-cfstrings"
)
# special case big
-qt_internal_extend_target(qmake CONDITION WIN32
+qt_internal_extend_target(${target_name} CONDITION WIN32
SOURCES
- ../src/corelib/io/qfilesystemengine_win.cpp
- ../src/corelib/io/qfilesystemiterator_win.cpp
- ../src/corelib/io/qfsfileengine_win.cpp
- ../src/corelib/text/qlocale_win.cpp
- ../src/corelib/io/qsettings_win.cpp
- # ../src/corelib/global/qoperatingsystemversion.cpp special case: remove this
- ../src/corelib/plugin/qsystemlibrary.cpp
library/registry.cpp
DEFINES
- UNICODE _ENABLE_EXTENDED_ALIGNED_STORAGE _CRT_SECURE_NO_WARNINGS _SCL_SECURE_NO_WARNINGS
- LIBRARIES
- ole32 advapi32 kernel32 netapi32
-)
-
-qt_internal_extend_target(${target_name} CONDITION MINGW AND WIN32
- PUBLIC_LIBRARIES
- uuid
+ _SCL_SECURE_NO_WARNINGS
)
qt_internal_extend_target(${target_name} CONDITION CLANG AND WIN32
@@ -275,10 +113,7 @@ set_target_properties(${target_name} PROPERTIES
)
qt_internal_apply_gc_binaries(${target_name} PRIVATE) # special case
-
-qt_set_msvc_cplusplus_options(${target_name} PUBLIC) # special case
qt_skip_warnings_are_errors(${target_name}) # special case
-qt_internal_apply_intel_cet(Bootstrap PUBLIC) # special case
# special case begin
qt_internal_add_docs(${target_name}