Merge pull request #30002 from taosdata/refactor/TD-33926
refactor: do not compile test-related files when BUILD_TEST=OFF
This commit is contained in:
commit
6c88048f77
|
@ -162,10 +162,10 @@ make
|
||||||
可以使用Jemalloc作为内存分配器,而不是使用glibc:
|
可以使用Jemalloc作为内存分配器,而不是使用glibc:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cmake .. -DJEMALLOC_ENABLED=true
|
cmake .. -DJEMALLOC_ENABLED=ON
|
||||||
```
|
```
|
||||||
TDengine构建脚本可以自动检测x86、x86-64、arm64平台上主机的体系结构。
|
TDengine构建脚本可以自动检测 x86、x86-64、arm64 平台上主机的体系结构。
|
||||||
您也可以通过CPUTYPE选项手动指定架构:
|
您也可以通过 CPUTYPE 选项手动指定架构:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cmake .. -DCPUTYPE=aarch64 && cmake --build .
|
cmake .. -DCPUTYPE=aarch64 && cmake --build .
|
||||||
|
|
|
@ -177,7 +177,7 @@ If you want to compile taosKeeper, you need to add the `--DBUILD_KEEPER=true` op
|
||||||
You can use Jemalloc as memory allocator instead of glibc:
|
You can use Jemalloc as memory allocator instead of glibc:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cmake .. -DJEMALLOC_ENABLED=true
|
cmake .. -DJEMALLOC_ENABLED=ON
|
||||||
```
|
```
|
||||||
|
|
||||||
TDengine build script can auto-detect the host machine's architecture on x86, x86-64, arm64 platform.
|
TDengine build script can auto-detect the host machine's architecture on x86, x86-64, arm64 platform.
|
||||||
|
|
|
@ -116,7 +116,6 @@ ELSE()
|
||||||
set(VAR_TSZ "TSZ" CACHE INTERNAL "global variant tsz")
|
set(VAR_TSZ "TSZ" CACHE INTERNAL "global variant tsz")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
# force set all platform to JEMALLOC_ENABLED = false
|
|
||||||
# SET(JEMALLOC_ENABLED OFF)
|
# SET(JEMALLOC_ENABLED OFF)
|
||||||
|
|
||||||
IF(TD_WINDOWS)
|
IF(TD_WINDOWS)
|
||||||
|
@ -262,10 +261,10 @@ ENDIF()
|
||||||
|
|
||||||
IF(TD_LINUX)
|
IF(TD_LINUX)
|
||||||
IF(${JEMALLOC_ENABLED})
|
IF(${JEMALLOC_ENABLED})
|
||||||
MESSAGE(STATUS "JEMALLOC_ENABLED Enabled")
|
MESSAGE(STATUS "JEMALLOC Enabled")
|
||||||
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-error=attributes")
|
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-error=attributes")
|
||||||
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-error=attributes")
|
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-error=attributes")
|
||||||
ELSE()
|
ELSE()
|
||||||
MESSAGE(STATUS "JEMALLOC_ENABLED Disabled")
|
MESSAGE(STATUS "JEMALLOC Disabled")
|
||||||
ENDIF()
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
|
@ -124,7 +124,7 @@ enum {
|
||||||
TMQ_MSG_TYPE__POLL_RAW_DATA_RSP,
|
TMQ_MSG_TYPE__POLL_RAW_DATA_RSP,
|
||||||
};
|
};
|
||||||
|
|
||||||
static char* tmqMsgTypeStr[] = {
|
static const char* tmqMsgTypeStr[] = {
|
||||||
"data", "meta", "ask ep", "meta data", "wal info", "batch meta", "raw data"
|
"data", "meta", "ask ep", "meta data", "wal info", "batch meta", "raw data"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1,11 +1,14 @@
|
||||||
aux_source_directory(src FUNCTION_SRC)
|
aux_source_directory(src FUNCTION_SRC)
|
||||||
aux_source_directory(src/detail FUNCTION_SRC_DETAIL)
|
aux_source_directory(src/detail FUNCTION_SRC_DETAIL)
|
||||||
list(REMOVE_ITEM FUNCTION_SRC src/udfd.c)
|
list(REMOVE_ITEM FUNCTION_SRC src/udfd.c)
|
||||||
IF(COMPILER_SUPPORT_AVX2)
|
|
||||||
|
if(COMPILER_SUPPORT_AVX2)
|
||||||
MESSAGE(STATUS "AVX2 instructions is ACTIVATED")
|
MESSAGE(STATUS "AVX2 instructions is ACTIVATED")
|
||||||
set_source_files_properties(src/detail/tminmaxavx.c PROPERTIES COMPILE_FLAGS -mavx2)
|
set_source_files_properties(src/detail/tminmaxavx.c PROPERTIES COMPILE_FLAGS -mavx2)
|
||||||
ENDIF()
|
endif()
|
||||||
|
|
||||||
add_library(function STATIC ${FUNCTION_SRC} ${FUNCTION_SRC_DETAIL})
|
add_library(function STATIC ${FUNCTION_SRC} ${FUNCTION_SRC_DETAIL})
|
||||||
|
|
||||||
target_include_directories(
|
target_include_directories(
|
||||||
function
|
function
|
||||||
PUBLIC
|
PUBLIC
|
||||||
|
@ -17,17 +20,6 @@ target_include_directories(
|
||||||
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
||||||
)
|
)
|
||||||
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEFINITIONS(-DTD_JEMALLOC_ENABLED -I${CMAKE_BINARY_DIR}/build/include -L${CMAKE_BINARY_DIR}/build/lib -Wl,-rpath,${CMAKE_BINARY_DIR}/build/lib -ljemalloc)
|
|
||||||
SET(LINK_JEMALLOC "-L${CMAKE_BINARY_DIR}/build/lib -ljemalloc")
|
|
||||||
ELSE()
|
|
||||||
SET(LINK_JEMALLOC "")
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEPENDENCIES(function jemalloc)
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
target_link_libraries(
|
target_link_libraries(
|
||||||
function
|
function
|
||||||
PRIVATE os
|
PRIVATE os
|
||||||
|
@ -41,152 +33,6 @@ target_link_libraries(
|
||||||
PUBLIC uv_a
|
PUBLIC uv_a
|
||||||
)
|
)
|
||||||
|
|
||||||
add_executable(runUdf test/runUdf.c)
|
|
||||||
target_include_directories(
|
|
||||||
runUdf
|
|
||||||
PUBLIC
|
|
||||||
"${TD_SOURCE_DIR}/include/libs/function"
|
|
||||||
"${TD_SOURCE_DIR}/contrib/libuv/include"
|
|
||||||
"${TD_SOURCE_DIR}/include/util"
|
|
||||||
"${TD_SOURCE_DIR}/include/common"
|
|
||||||
"${TD_SOURCE_DIR}/include/client"
|
|
||||||
"${TD_SOURCE_DIR}/include/os"
|
|
||||||
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
|
||||||
)
|
|
||||||
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEPENDENCIES(runUdf jemalloc)
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
target_link_libraries(
|
|
||||||
runUdf
|
|
||||||
PUBLIC uv_a
|
|
||||||
PRIVATE os util common nodes function ${LINK_JEMALLOC}
|
|
||||||
)
|
|
||||||
|
|
||||||
add_library(udf1 STATIC MODULE test/udf1.c)
|
|
||||||
target_include_directories(
|
|
||||||
udf1
|
|
||||||
PUBLIC
|
|
||||||
"${TD_SOURCE_DIR}/include/libs/function"
|
|
||||||
"${TD_SOURCE_DIR}/include/util"
|
|
||||||
"${TD_SOURCE_DIR}/include/common"
|
|
||||||
"${TD_SOURCE_DIR}/include/client"
|
|
||||||
"${TD_SOURCE_DIR}/include/os"
|
|
||||||
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
|
||||||
)
|
|
||||||
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEPENDENCIES(udf1 jemalloc)
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
target_link_libraries(
|
|
||||||
udf1 PUBLIC os ${LINK_JEMALLOC})
|
|
||||||
|
|
||||||
add_library(udf1_dup STATIC MODULE test/udf1_dup.c)
|
|
||||||
target_include_directories(
|
|
||||||
udf1_dup
|
|
||||||
PUBLIC
|
|
||||||
"${TD_SOURCE_DIR}/include/libs/function"
|
|
||||||
"${TD_SOURCE_DIR}/include/util"
|
|
||||||
"${TD_SOURCE_DIR}/include/common"
|
|
||||||
"${TD_SOURCE_DIR}/include/client"
|
|
||||||
"${TD_SOURCE_DIR}/include/os"
|
|
||||||
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
|
||||||
)
|
|
||||||
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEPENDENCIES(udf1_dup jemalloc)
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
target_link_libraries(
|
|
||||||
udf1_dup PUBLIC os ${LINK_JEMALLOC})
|
|
||||||
|
|
||||||
add_library(udf2 STATIC MODULE test/udf2.c)
|
|
||||||
target_include_directories(
|
|
||||||
udf2
|
|
||||||
PUBLIC
|
|
||||||
"${TD_SOURCE_DIR}/include/libs/function"
|
|
||||||
"${TD_SOURCE_DIR}/include/util"
|
|
||||||
"${TD_SOURCE_DIR}/include/common"
|
|
||||||
"${TD_SOURCE_DIR}/include/client"
|
|
||||||
"${TD_SOURCE_DIR}/include/os"
|
|
||||||
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
|
||||||
)
|
|
||||||
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEPENDENCIES(udf2 jemalloc)
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
target_link_libraries(
|
|
||||||
udf2 PUBLIC os ${LINK_JEMALLOC}
|
|
||||||
)
|
|
||||||
|
|
||||||
add_library(udf2_dup STATIC MODULE test/udf2_dup.c)
|
|
||||||
target_include_directories(
|
|
||||||
udf2_dup
|
|
||||||
PUBLIC
|
|
||||||
"${TD_SOURCE_DIR}/include/libs/function"
|
|
||||||
"${TD_SOURCE_DIR}/include/util"
|
|
||||||
"${TD_SOURCE_DIR}/include/common"
|
|
||||||
"${TD_SOURCE_DIR}/include/client"
|
|
||||||
"${TD_SOURCE_DIR}/include/os"
|
|
||||||
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
|
||||||
)
|
|
||||||
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEPENDENCIES(udf2_dup jemalloc)
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
target_link_libraries(
|
|
||||||
udf2_dup PUBLIC os ${LINK_JEMALLOC}
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TARGET_NAMES
|
|
||||||
change_udf_normal
|
|
||||||
change_udf_no_init
|
|
||||||
change_udf_no_process
|
|
||||||
change_udf_no_destroy
|
|
||||||
change_udf_init_failed
|
|
||||||
change_udf_process_failed
|
|
||||||
change_udf_destory_failed
|
|
||||||
)
|
|
||||||
|
|
||||||
set(COMPILE_DEFINITIONS
|
|
||||||
CHANGE_UDF_NORMAL
|
|
||||||
CHANGE_UDF_NO_INIT
|
|
||||||
CHANGE_UDF_NO_PROCESS
|
|
||||||
CHANGE_UDF_NO_DESTROY
|
|
||||||
CHANGE_UDF_INIT_FAILED
|
|
||||||
CHANGE_UDF_PROCESS_FAILED
|
|
||||||
CHANGE_UDF_DESTORY_FAILED
|
|
||||||
)
|
|
||||||
|
|
||||||
foreach(index RANGE 0 6)
|
|
||||||
list(GET TARGET_NAMES ${index} target_name)
|
|
||||||
list(GET COMPILE_DEFINITIONS ${index} compile_def)
|
|
||||||
|
|
||||||
add_library(${target_name} STATIC MODULE test/change_udf.c)
|
|
||||||
target_include_directories(
|
|
||||||
${target_name}
|
|
||||||
PUBLIC
|
|
||||||
"${TD_SOURCE_DIR}/include/libs/function"
|
|
||||||
"${TD_SOURCE_DIR}/include/util"
|
|
||||||
"${TD_SOURCE_DIR}/include/common"
|
|
||||||
"${TD_SOURCE_DIR}/include/client"
|
|
||||||
"${TD_SOURCE_DIR}/include/os"
|
|
||||||
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
|
||||||
)
|
|
||||||
target_compile_definitions(${target_name} PRIVATE ${compile_def})
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEPENDENCIES(${target_name} jemalloc)
|
|
||||||
ENDIF()
|
|
||||||
target_link_libraries(
|
|
||||||
${target_name} PUBLIC os ${LINK_JEMALLOC}
|
|
||||||
)
|
|
||||||
endforeach()
|
|
||||||
|
|
||||||
# SET(EXECUTABLE_OUTPUT_PATH ${CMAKE_BINARY_DIR}/build/bin)
|
|
||||||
add_executable(udfd src/udfd.c)
|
add_executable(udfd src/udfd.c)
|
||||||
|
|
||||||
if(${TD_DARWIN})
|
if(${TD_DARWIN})
|
||||||
|
@ -205,12 +51,12 @@ target_include_directories(
|
||||||
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/inc"
|
||||||
)
|
)
|
||||||
|
|
||||||
IF(TD_LINUX_64 AND JEMALLOC_ENABLED)
|
|
||||||
ADD_DEPENDENCIES(udfd jemalloc)
|
|
||||||
ENDIF()
|
|
||||||
|
|
||||||
target_link_libraries(
|
target_link_libraries(
|
||||||
udfd
|
udfd
|
||||||
PUBLIC uv_a
|
PUBLIC uv_a
|
||||||
PRIVATE os util common nodes function ${LINK_JEMALLOC}
|
PRIVATE os util common nodes function
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if(${BUILD_TEST})
|
||||||
|
add_subdirectory(test)
|
||||||
|
endif()
|
||||||
|
|
|
@ -0,0 +1,54 @@
|
||||||
|
include_directories("${TD_SOURCE_DIR}/include/libs/function")
|
||||||
|
include_directories("${TD_SOURCE_DIR}/contrib/libuv/include")
|
||||||
|
include_directories("${TD_SOURCE_DIR}/include/util")
|
||||||
|
include_directories("${TD_SOURCE_DIR}/include/common")
|
||||||
|
include_directories("${TD_SOURCE_DIR}/include/client")
|
||||||
|
include_directories("${TD_SOURCE_DIR}/include/os")
|
||||||
|
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/../inc")
|
||||||
|
|
||||||
|
add_executable(runUdf runUdf.c)
|
||||||
|
target_link_libraries(
|
||||||
|
runUdf
|
||||||
|
PUBLIC uv_a
|
||||||
|
PRIVATE os util common nodes function
|
||||||
|
)
|
||||||
|
|
||||||
|
add_library(udf1 STATIC MODULE udf1.c)
|
||||||
|
target_link_libraries(udf1 PUBLIC os)
|
||||||
|
|
||||||
|
add_library(udf2 STATIC MODULE udf2.c)
|
||||||
|
target_link_libraries(udf2 PUBLIC os)
|
||||||
|
|
||||||
|
add_library(udf1_dup STATIC MODULE udf1_dup.c)
|
||||||
|
target_link_libraries(udf1_dup PUBLIC os)
|
||||||
|
|
||||||
|
add_library(udf2_dup STATIC MODULE udf2_dup.c)
|
||||||
|
target_link_libraries(udf2_dup PUBLIC os)
|
||||||
|
|
||||||
|
set(TARGET_NAMES
|
||||||
|
change_udf_normal
|
||||||
|
change_udf_no_init
|
||||||
|
change_udf_no_process
|
||||||
|
change_udf_no_destroy
|
||||||
|
change_udf_init_failed
|
||||||
|
change_udf_process_failed
|
||||||
|
change_udf_destory_failed
|
||||||
|
)
|
||||||
|
|
||||||
|
set(COMPILE_DEFINITIONS
|
||||||
|
CHANGE_UDF_NORMAL
|
||||||
|
CHANGE_UDF_NO_INIT
|
||||||
|
CHANGE_UDF_NO_PROCESS
|
||||||
|
CHANGE_UDF_NO_DESTROY
|
||||||
|
CHANGE_UDF_INIT_FAILED
|
||||||
|
CHANGE_UDF_PROCESS_FAILED
|
||||||
|
CHANGE_UDF_DESTORY_FAILED
|
||||||
|
)
|
||||||
|
|
||||||
|
foreach(index RANGE 0 6)
|
||||||
|
list(GET TARGET_NAMES ${index} target_name)
|
||||||
|
list(GET COMPILE_DEFINITIONS ${index} compile_def)
|
||||||
|
add_library(${target_name} STATIC MODULE change_udf.c)
|
||||||
|
target_compile_definitions(${target_name} PRIVATE ${compile_def})
|
||||||
|
target_link_libraries(${target_name} PUBLIC os)
|
||||||
|
endforeach()
|
|
@ -1,6 +1,3 @@
|
||||||
#include <stdio.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
#include <string.h>
|
|
||||||
#include "uv.h"
|
#include "uv.h"
|
||||||
|
|
||||||
#include "fnLog.h"
|
#include "fnLog.h"
|
||||||
|
@ -218,4 +215,4 @@ int main(int argc, char *argv[]) {
|
||||||
fnError("failed to close udfc");
|
fnError("failed to close udfc");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -61,7 +61,7 @@ docker run \
|
||||||
-v /root/go/pkg/mod:/root/go/pkg/mod \
|
-v /root/go/pkg/mod:/root/go/pkg/mod \
|
||||||
-v /root/.cache/go-build:/root/.cache/go-build \
|
-v /root/.cache/go-build:/root/.cache/go-build \
|
||||||
-v /root/.cos-local.1:/root/.cos-local.2 \
|
-v /root/.cos-local.1:/root/.cos-local.2 \
|
||||||
--rm --ulimit core=-1 taos_test:v1.0 sh -c "pip uninstall taospy -y;pip3 install taospy==2.7.2;cd $REP_DIR;rm -rf debug;mkdir -p debug;cd debug;cmake .. -DBUILD_HTTP=false -DBUILD_TOOLS=true -DBUILD_TEST=true -DWEBSOCKET=true -DBUILD_SANITIZER=1 -DTOOLS_SANITIZE=true $CMAKE_BUILD_TYPE -DTOOLS_BUILD_TYPE=Debug -DBUILD_TAOSX=false -DJEMALLOC_ENABLED=0;make -j 10|| exit 1 "
|
--rm --ulimit core=-1 taos_test:v1.0 sh -c "pip uninstall taospy -y; pip3 install taospy==2.7.2; cd $REP_DIR; rm -rf debug ;mkdir -p debug; cd debug; cmake .. -DBUILD_HTTP=false -DBUILD_TOOLS=true -DBUILD_TEST=ON -DWEBSOCKET=true -DBUILD_SANITIZER=1 -DTOOLS_SANITIZE=true $CMAKE_BUILD_TYPE -DTOOLS_BUILD_TYPE=Debug -DBUILD_TAOSX=false -DJEMALLOC_ENABLED=OFF; make -j 10|| exit 1 "
|
||||||
# -v ${REP_REAL_PATH}/community/contrib/jemalloc/:${REP_DIR}/community/contrib/jemalloc \
|
# -v ${REP_REAL_PATH}/community/contrib/jemalloc/:${REP_DIR}/community/contrib/jemalloc \
|
||||||
|
|
||||||
if [[ -d ${WORKDIR}/debugNoSan ]] ;then
|
if [[ -d ${WORKDIR}/debugNoSan ]] ;then
|
||||||
|
|
|
@ -81,7 +81,7 @@ docker run \
|
||||||
-v ${REP_REAL_PATH}/community/contrib/pcre2/:${REP_DIR}/community/contrib/pcre2 \
|
-v ${REP_REAL_PATH}/community/contrib/pcre2/:${REP_DIR}/community/contrib/pcre2 \
|
||||||
-v ${REP_REAL_PATH}/community/contrib/zlib/:${REP_DIR}/community/contrib/zlib \
|
-v ${REP_REAL_PATH}/community/contrib/zlib/:${REP_DIR}/community/contrib/zlib \
|
||||||
-v ${REP_REAL_PATH}/community/contrib/zstd/:${REP_DIR}/community/contrib/zstd \
|
-v ${REP_REAL_PATH}/community/contrib/zstd/:${REP_DIR}/community/contrib/zstd \
|
||||||
--rm --ulimit core=-1 taos_test:v1.0 sh -c "cd $REP_DIR;rm -rf debug;mkdir -p debug;cd debug;cmake .. -DBUILD_HTTP=false -DBUILD_TOOLS=true -DBUILD_TEST=true -DWEBSOCKET=true -DBUILD_TAOSX=false -DJEMALLOC_ENABLED=0 -DCMAKE_EXPORT_COMPILE_COMMANDS=1 ;make -j|| exit 1"
|
--rm --ulimit core=-1 taos_test:v1.0 sh -c "cd $REP_DIR; rm -rf debug; mkdir -p debug; cd debug; cmake .. -DBUILD_HTTP=false -DBUILD_TOOLS=true -DBUILD_TEST=ON -DWEBSOCKET=true -DBUILD_TAOSX=false -DJEMALLOC_ENABLED=OFF -DCMAKE_EXPORT_COMPILE_COMMANDS=1 ;make -j|| exit 1"
|
||||||
# -v ${REP_REAL_PATH}/community/contrib/jemalloc/:${REP_DIR}/community/contrib/jemalloc \
|
# -v ${REP_REAL_PATH}/community/contrib/jemalloc/:${REP_DIR}/community/contrib/jemalloc \
|
||||||
|
|
||||||
if [[ -d ${WORKDIR}/debugNoSan ]] ;then
|
if [[ -d ${WORKDIR}/debugNoSan ]] ;then
|
||||||
|
@ -133,7 +133,7 @@ docker run \
|
||||||
-v ${REP_REAL_PATH}/community/contrib/pcre2/:${REP_DIR}/community/contrib/pcre2 \
|
-v ${REP_REAL_PATH}/community/contrib/pcre2/:${REP_DIR}/community/contrib/pcre2 \
|
||||||
-v ${REP_REAL_PATH}/community/contrib/zlib/:${REP_DIR}/community/contrib/zlib \
|
-v ${REP_REAL_PATH}/community/contrib/zlib/:${REP_DIR}/community/contrib/zlib \
|
||||||
-v ${REP_REAL_PATH}/community/contrib/zstd/:${REP_DIR}/community/contrib/zstd \
|
-v ${REP_REAL_PATH}/community/contrib/zstd/:${REP_DIR}/community/contrib/zstd \
|
||||||
--rm --ulimit core=-1 taos_test:v1.0 sh -c "cd $REP_DIR;rm -rf debug;mkdir -p debug;cd debug;cmake .. -DBUILD_HTTP=false -DBUILD_TOOLS=true -DBUILD_TEST=false -DWEBSOCKET=true -DBUILD_SANITIZER=1 -DTOOLS_SANITIZE=true -DCMAKE_BUILD_TYPE=Debug -DTOOLS_BUILD_TYPE=Debug -DBUILD_TAOSX=false -DJEMALLOC_ENABLED=0;make -j|| exit 1 "
|
--rm --ulimit core=-1 taos_test:v1.0 sh -c "cd $REP_DIR; rm -rf debug; mkdir -p debug; cd debug; cmake .. -DBUILD_HTTP=false -DBUILD_TOOLS=true -DBUILD_TEST=ON -DWEBSOCKET=true -DBUILD_SANITIZER=1 -DTOOLS_SANITIZE=true -DCMAKE_BUILD_TYPE=Debug -DTOOLS_BUILD_TYPE=Debug -DBUILD_TAOSX=false -DJEMALLOC_ENABLED=OFF; make -j|| exit 1 "
|
||||||
|
|
||||||
mv ${REP_REAL_PATH}/debug ${WORKDIR}/debugSan
|
mv ${REP_REAL_PATH}/debug ${WORKDIR}/debugSan
|
||||||
|
|
||||||
|
@ -168,7 +168,7 @@ date
|
||||||
# -v ${REP_REAL_PATH}/community/contrib/xml2/:${REP_DIR}/community/contrib/xml2 \
|
# -v ${REP_REAL_PATH}/community/contrib/xml2/:${REP_DIR}/community/contrib/xml2 \
|
||||||
# -v ${REP_REAL_PATH}/community/contrib/zlib/:${REP_DIR}/community/contrib/zlib \
|
# -v ${REP_REAL_PATH}/community/contrib/zlib/:${REP_DIR}/community/contrib/zlib \
|
||||||
# -v ${REP_REAL_PATH}/community/contrib/zstd/:${REP_DIR}/community/contrib/zstd \
|
# -v ${REP_REAL_PATH}/community/contrib/zstd/:${REP_DIR}/community/contrib/zstd \
|
||||||
# --rm --ulimit core=-1 taos_test:v1.0 sh -c "pip uninstall taospy -y;pip3 install taospy==2.7.2;cd $REP_DIR;rm -rf debug;mkdir -p debug;cd debug;cmake .. -DBUILD_HTTP=false -DBUILD_TOOLS=true -DBUILD_TEST=false -DWEBSOCKET=true -DCMAKE_BUILD_TYPE=Release -DBUILD_TAOSX=false -DJEMALLOC_ENABLED=0;make -j || exit 1 "
|
# --rm --ulimit core=-1 taos_test:v1.0 sh -c "pip uninstall taospy -y; pip3 install taospy==2.7.2; cd $REP_DIR; rm -rf debug; mkdir -p debug; cd debug; cmake .. -DBUILD_HTTP=false -DBUILD_TOOLS=true -DBUILD_TEST=ON -DWEBSOCKET=true -DCMAKE_BUILD_TYPE=Release -DBUILD_TAOSX=false -DJEMALLOC_ENABLED=OFF; make -j || exit 1 "
|
||||||
|
|
||||||
# mv ${REP_REAL_PATH}/debug ${WORKDIR}/debugRelease
|
# mv ${REP_REAL_PATH}/debug ${WORKDIR}/debugRelease
|
||||||
|
|
||||||
|
|
|
@ -91,19 +91,19 @@ endi
|
||||||
if $data[0][4] == leader then
|
if $data[0][4] == leader then
|
||||||
if $data[0][7] == follower then
|
if $data[0][7] == follower then
|
||||||
if $data[0][10] == follower then
|
if $data[0][10] == follower then
|
||||||
print ---- vgroup $data[0][0] leader locate on dnode $data[0][3]
|
print ---- vgroup $data[0][0] leader locate on dnode $data[0][4]
|
||||||
endi
|
endi
|
||||||
endi
|
endi
|
||||||
elif $data[0][6] == leader then
|
elif $data[0][7] == leader then
|
||||||
if $data[0][7] == follower then
|
if $data[0][10] == follower then
|
||||||
if $data[0][10] == follower then
|
if $data[0][4] == follower then
|
||||||
print ---- vgroup $data[0][0] leader locate on dnode $data[0][5]
|
print ---- vgroup $data[0][0] leader locate on dnode $data[0][7]
|
||||||
endi
|
endi
|
||||||
endi
|
endi
|
||||||
elif $data[0][10] == leader then
|
elif $data[0][10] == leader then
|
||||||
if $data[0][4] == follower then
|
if $data[0][4] == follower then
|
||||||
if $data[0][7] == follower then
|
if $data[0][7] == follower then
|
||||||
print ---- vgroup $data[0][0] leader locate on dnode $data[0][7]
|
print ---- vgroup $data[0][0] leader locate on dnode $data[0][10]
|
||||||
endi
|
endi
|
||||||
endi
|
endi
|
||||||
else
|
else
|
||||||
|
@ -461,7 +461,4 @@ endi
|
||||||
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
system sh/exec.sh -n dnode1 -s stop -x SIGINT
|
||||||
system sh/exec.sh -n dnode2 -s stop -x SIGINT
|
system sh/exec.sh -n dnode2 -s stop -x SIGINT
|
||||||
system sh/exec.sh -n dnode3 -s stop -x SIGINT
|
system sh/exec.sh -n dnode3 -s stop -x SIGINT
|
||||||
system sh/exec.sh -n dnode4 -s stop -x SIGINT
|
system sh/exec.sh -n dnode4 -s stop -x SIGINT
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,9 @@
|
||||||
# ADD_SUBDIRECTORY(examples/c)
|
# ADD_SUBDIRECTORY(examples/c)
|
||||||
ADD_SUBDIRECTORY(tsim)
|
ADD_SUBDIRECTORY(tsim)
|
||||||
ADD_SUBDIRECTORY(test/c)
|
|
||||||
|
IF(${BUILD_TEST})
|
||||||
|
ADD_SUBDIRECTORY(test/c)
|
||||||
|
ENDIF(${BUILD_TEST})
|
||||||
|
|
||||||
# ADD_SUBDIRECTORY(comparisonTest/tdengine)
|
# ADD_SUBDIRECTORY(comparisonTest/tdengine)
|
||||||
IF(NOT "${TSZ_ENABLED}" MATCHES "false")
|
IF(NOT "${TSZ_ENABLED}" MATCHES "false")
|
||||||
|
|
Loading…
Reference in New Issue