chore: update files of project

This commit is contained in:
Qsaker 2023-11-20 18:12:56 +08:00
parent fa3958bb85
commit f256d7b6dd
3 changed files with 23 additions and 23 deletions

View File

@ -52,13 +52,13 @@ macro(sak_import_assistant assistant_dir_name)
endif() endif()
endmacro() endmacro()
sak_import_assistant("asciiassistant") sak_import_assistant("AsciiAssistant")
sak_import_assistant("base64assistant") sak_import_assistant("Base64Assistant")
sak_import_assistant("broadcastassistant") sak_import_assistant("BroadcastAssistant")
sak_import_assistant("crcassistant") sak_import_assistant("CrcAssistant")
sak_import_assistant("filecheckassistant") sak_import_assistant("FileCheckAssistant")
sak_import_assistant("numberassistant") sak_import_assistant("NumberAssistant")
sak_import_assistant("stringassistant") sak_import_assistant("StringAssistant")
# QtSwissArmyKnife src files # QtSwissArmyKnife src files
macro(sak_add_src src_dir_name) macro(sak_add_src src_dir_name)
@ -134,8 +134,8 @@ install(
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
# Custom build target. # Custom build target.
option(APP_EABLE_ASSISTANTS "Enable to build Assistants." ON) option(SAK_EABLE_APP_ASSISTANTS "Enable to build Assistants." ON)
if(APP_EABLE_ASSISTANTS) if(SAK_EABLE_APP_ASSISTANTS)
add_subdirectory(${CMAKE_SOURCE_DIR}/src/Assistants) add_subdirectory(${CMAKE_SOURCE_DIR}/src/Assistants)
endif() endif()

View File

@ -1,15 +1,15 @@
macro(sak_add_assistant app_name) macro(sak_add_assistant app_name)
string(TOLOWER ${app_name} lower_app_name) string(TOLOWER ${app_name} lower_app_name)
string(TOUPPER ${app_name} upper_app_name) string(TOUPPER ${app_name} upper_app_name)
option(APP_${upper_app_name} "" ON) option(SAK_ENABLE_APP_${upper_app_name} "" ON)
if(APP_${upper_app_name}) if(SAK_ENABLE_APP_${upper_app_name})
file( file(
GLOB_RECURSE GLOB_RECURSE
ASSISTANT_SOURCES ASSISTANT_SOURCES
"${CMAKE_SOURCE_DIR}/src/Assistants/${lower_app_name}/*.h" "${CMAKE_SOURCE_DIR}/src/Assistants/${app_name}/*.h"
"${CMAKE_SOURCE_DIR}/src/Assistants/${lower_app_name}/*.cc" "${CMAKE_SOURCE_DIR}/src/Assistants/${app_name}/*.cc"
"${CMAKE_SOURCE_DIR}/src/Assistants/${lower_app_name}/*.ui" "${CMAKE_SOURCE_DIR}/src/Assistants/${app_name}/*.ui"
"${CMAKE_SOURCE_DIR}/src/Assistants/${lower_app_name}/*.qrc") "${CMAKE_SOURCE_DIR}/src/Assistants/${app_name}/*.qrc")
set(APP_ASSISTANT_SOURCES set(APP_ASSISTANT_SOURCES
${CMAKE_SOURCE_DIR}/src/common/common/sakinterface.h ${CMAKE_SOURCE_DIR}/src/common/common/sakinterface.h
${CMAKE_SOURCE_DIR}/src/common/common/sakinterface.cc ${CMAKE_SOURCE_DIR}/src/common/common/sakinterface.cc
@ -29,10 +29,10 @@ macro(sak_add_assistant app_name)
endif() endif()
endmacro() endmacro()
add_subdirectory(asciiassistant) add_subdirectory(AsciiAssistant)
add_subdirectory(base64assistant) add_subdirectory(Base64Assistant)
add_subdirectory(broadcastassistant) add_subdirectory(BroadcastAssistant)
add_subdirectory(crcassistant) add_subdirectory(CrcAssistant)
add_subdirectory(filecheckassistant) add_subdirectory(FileCheckAssistant)
add_subdirectory(numberassistant) add_subdirectory(NumberAssistant)
add_subdirectory(stringassistant) add_subdirectory(StringAssistant)

View File

@ -3,4 +3,4 @@
${CMAKE_SOURCE_DIR}/src/common/common/sakcommoncrcinterface.cc) ${CMAKE_SOURCE_DIR}/src/common/common/sakcommoncrcinterface.cc)
set(APP_ASSISITANT_OWN_LIBS Qt${QT_VERSION_MAJOR}::Widgets) set(APP_ASSISITANT_OWN_LIBS Qt${QT_VERSION_MAJOR}::Widgets)
sak_add_assistant("CRCAssistant") sak_add_assistant("CrcAssistant")