diff --git a/Analyser/CMakeLists.txt b/Analyser/CMakeLists.txt index 66c7783..9aadf13 100644 --- a/Analyser/CMakeLists.txt +++ b/Analyser/CMakeLists.txt @@ -1,4 +1,4 @@ -project(Analyser VERSION 0.3 LANGUAGES C CXX) +project(Analyser VERSION 0.4 LANGUAGES C CXX) set(APPLICATION_NAME "掌静脉测试工具") find_package(Boost REQUIRED COMPONENTS json) diff --git a/CMakeLists.txt b/CMakeLists.txt index d3b3a64..608675c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required(VERSION 3.28) -project(SmartLockerTools VERSION 0.3 LANGUAGES C CXX) +project(SmartLockerTools VERSION 0.4 LANGUAGES C CXX) set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD_REQUIRED ON) @@ -12,7 +12,12 @@ if(WIN32) add_compile_definitions( BOOST_USE_WINAPI_VERSION=BOOST_WINAPI_VERSION_WIN10 ) - set(MBEDTLS_ROOT ${Libraries_ROOT}/mbedtls-3.6.2_msvc2022_64bit_debug) + if(CMAKE_BUILD_TYPE STREQUAL "Release") + set(MBEDTLS_ROOT ${Libraries_ROOT}/mbedtls-3.6.2_msvc2022_64bit_release) + else() + set(MBEDTLS_ROOT ${Libraries_ROOT}/mbedtls-3.6.2_msvc2022_64bit_debug) + endif() + else() execute_process( COMMAND sh -c "echo $HOME" @@ -22,6 +27,7 @@ else() set(Libraries_ROOT /opt/Libraries) set(BOOST_ROOT ${Libraries_ROOT}/boost_1_86_0) set(Boost_INCLUDE_DIR ${BOOST_ROOT}/include) + set(MBEDTLS_ROOT ${Libraries_ROOT}/mbedtls-3.6.2) endif() option(Boost_USE_STATIC_LIBS OFF) diff --git a/resources/build.sh b/resources/build.sh index 84c5dfd..5707e22 100755 --- a/resources/build.sh +++ b/resources/build.sh @@ -1,7 +1,11 @@ #!/bin/bash base_path=$(pwd) -build_path=${base_path}/build +if [ $base_path == /home/* ]; then + build_path=${base_path}/build +else + build_path=/tmp/build +fi qt_prefix_path="/opt/Qt/6.8.0/gcc_64" debug_deploy=false @@ -70,6 +74,10 @@ function build() { fi } +function clean(){ + rm -fr ${build_path} +} + function deploy() { if [ -d ${build_path}/lib ]; then rm -fr ${build_path}/lib