mirror of
https://github.com/silverqx/TinyORM.git
synced 2026-05-07 17:19:37 -05:00
4f86615642
Rec was OK, it means recommended 🤔.
56 lines
2.3 KiB
Plaintext
56 lines
2.3 KiB
Plaintext
# Some compilers simulate other compilers to serve as drop-in replacements
|
|
# Eg. clang-cl simulates MSVC compiler
|
|
TINY_SIMULATED_VERSION =
|
|
|
|
if(gcc|clang):!win32-clang-msvc: \
|
|
TINY_COMPILER_VERSION = $$system("$${QMAKE_CXX} -dumpversion")
|
|
|
|
else:win32-msvc|win32-clang-msvc {
|
|
TINY_MSVC_COMPILER_VERSION = $$QMAKE_MSC_VER
|
|
|
|
win32-clang-msvc {
|
|
TINY_CLANG_CL_COMPILER_VERSION = $$system("$${QMAKE_CXX} --version")
|
|
TINY_CLANG_CL_COMPILER_VERSION = $$member(TINY_CLANG_CL_COMPILER_VERSION, 2)
|
|
# Ok, to be absolutely correct 😎
|
|
TINY_COMPILER_VERSION = $$TINY_CLANG_CL_COMPILER_VERSION
|
|
TINY_SIMULATED_VERSION = $$TINY_MSVC_COMPILER_VERSION
|
|
}
|
|
else: \
|
|
TINY_COMPILER_VERSION = $$TINY_MSVC_COMPILER_VERSION
|
|
}
|
|
|
|
else: \
|
|
error( "Unknown compiler '$$QMAKE_COMPILER'" )
|
|
|
|
!build_pass: \
|
|
if(win32-msvc|win32-clang-msvc): \
|
|
!versionAtLeast(TINY_MSVC_COMPILER_VERSION, $$replace(tinyMinReqMsvc, \., "")): \
|
|
error( "Minimum required MSVC version was not satisfied, required version\
|
|
>=$${tinyMinReqMsvc}, your version is $${TINY_MSVC_COMPILER_VERSION},\
|
|
upgrade Visual Studio." )
|
|
|
|
!build_pass: \
|
|
win32-clang-msvc: \
|
|
!versionAtLeast(TINY_CLANG_CL_COMPILER_VERSION, $$tinyMinReqClangCl): \
|
|
error( "Minimum required clang-cl version was not satisfied, required version\
|
|
>=$${tinyMinReqClangCl}, your version is\
|
|
$${TINY_CLANG_CL_COMPILER_VERSION}, upgrade LLVM." )
|
|
|
|
!build_pass: \
|
|
!versionAtLeast(QT_VERSION, $$tinyMinRecQt): \
|
|
message( "Minimum recommended Qt Framework version was not satisfied, recommended\
|
|
version >=$${tinyMinRecQt}, your version is $${QT_VERSION}, upgrade\
|
|
Qt Framework.")
|
|
|
|
!build_pass:!win32-clang-msvc:if(gcc|clang) {
|
|
clang:!versionAtLeast(TINY_COMPILER_VERSION, $$tinyMinRecClang): \
|
|
message( "Minimum recommended Clang compiler version was not satisfied,\
|
|
recommended version >=$${tinyMinRecClang}, your version is\
|
|
$${TINY_COMPILER_VERSION}, upgrade Clang compiler.")
|
|
|
|
gcc:!versionAtLeast(TINY_COMPILER_VERSION, $$tinyMinRecGCC): \
|
|
message( "Minimum recommended GCC compiler version was not satisfied,\
|
|
recommended version >=$${tinyMinRecGCC}, your version is\
|
|
$${TINY_COMPILER_VERSION}, upgrade GCC compiler.")
|
|
}
|