refactor: reformat build configs

This commit is contained in:
saturneric 2024-07-29 03:46:38 +02:00
parent 8cd4441a44
commit 6bde62db4a
4 changed files with 35 additions and 33 deletions

View File

@ -38,6 +38,9 @@ project(GpgFrontendModules
# includes # includes
include(GenerateExportHeader) include(GenerateExportHeader)
# function or mode options
option(GPGFRONTEND_QT5_BUILD "Swith to Qt5 building mode" OFF)
# Using Standard C++-17 (Consider compatibility) # Using Standard C++-17 (Consider compatibility)
set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_CXX_STANDARD_REQUIRED ON)

View File

@ -24,6 +24,7 @@
# SPDX-License-Identifier: GPL-3.0-or-later # SPDX-License-Identifier: GPL-3.0-or-later
# modules # modules
add_subdirectory(m_ver_check) add_subdirectory(m_ver_check)
add_subdirectory(m_gpg_info) add_subdirectory(m_gpg_info)
add_subdirectory(m_pinentry) add_subdirectory(m_pinentry)

View File

@ -27,7 +27,8 @@ aux_source_directory(. INTEGRATED_MODULE_SOURCE)
# capslock # capslock
list(APPEND INTEGRATED_MODULE_SOURCE "capslock/capslock.cpp") list(APPEND INTEGRATED_MODULE_SOURCE "capslock/capslock.cpp")
if (MINGW)
if(MINGW)
list(APPEND INTEGRATED_MODULE_SOURCE "capslock/capslock_win.cpp") list(APPEND INTEGRATED_MODULE_SOURCE "capslock/capslock_win.cpp")
else() else()
list(APPEND INTEGRATED_MODULE_SOURCE "capslock/capslock_unix.cpp") list(APPEND INTEGRATED_MODULE_SOURCE "capslock/capslock_unix.cpp")
@ -42,7 +43,6 @@ add_library(mod_pinentry SHARED ${INTEGRATED_MODULE_SOURCE})
install(TARGETS mod_pinentry install(TARGETS mod_pinentry
LIBRARY DESTINATION "${CMAKE_INSTALL_PREFIX}/modules") LIBRARY DESTINATION "${CMAKE_INSTALL_PREFIX}/modules")
# link options # link options
# link sdk # link sdk
@ -57,7 +57,5 @@ else()
target_link_libraries(mod_pinentry PUBLIC Qt6::Widgets) target_link_libraries(mod_pinentry PUBLIC Qt6::Widgets)
endif() endif()
# using std c++ 17 # using std c++ 17
target_compile_features(mod_pinentry PUBLIC cxx_std_17) target_compile_features(mod_pinentry PUBLIC cxx_std_17)