input.inc 2.8 KB
Newer Older
1
CMAKE_MINIMUM_REQUIRED(VERSION 3.0...3.20)
S
[TD-58]  
slguan 已提交
2 3 4 5 6 7 8 9 10 11
PROJECT(TDengine)

IF (${ACCOUNT} MATCHES "true")
  SET(TD_ACCOUNT TRUE)
  MESSAGE(STATUS "Build with account plugins")
ELSEIF (${ACCOUNT} MATCHES "false")
  SET(TD_ACCOUNT FALSE)
  MESSAGE(STATUS "Build without account plugins")
ENDIF ()

S
Shengliang Guan 已提交
12 13 14 15 16 17 18 19
IF (${TOPIC} MATCHES "true")
  SET(TD_TOPIC TRUE)
  MESSAGE(STATUS "Build with topic plugins")
ELSEIF (${TOPIC} MATCHES "false")
  SET(TD_TOPIC FALSE)
  MESSAGE(STATUS "Build without topic plugins")
ENDIF ()

S
TD-3246  
Shengliang Guan 已提交
20 21 22 23 24 25 26 27
IF (${TD_MODULE} MATCHES "true")
  SET(TD_MODULE TRUE)
  MESSAGE(STATUS "Build with module plugins")
ELSEIF (${TOPIC} MATCHES "false")
  SET(TD_MODULE FALSE)
  MESSAGE(STATUS "Build without module plugins")
ENDIF ()

S
[TD-58]  
slguan 已提交
28 29 30 31 32 33 34 35 36 37 38 39 40
IF (${COVER} MATCHES "true")
  SET(TD_COVER TRUE)
  MESSAGE(STATUS "Build with test coverage")
ELSEIF (${COVER} MATCHES "false")
  SET(TD_COVER FALSE)
  MESSAGE(STATUS "Build without test coverage")
ENDIF ()

IF (${PAGMODE} MATCHES "lite")
  SET(TD_PAGMODE_LITE TRUE)
  MESSAGE(STATUS "Build with pagmode lite")
ENDIF ()

H
Hui Li 已提交
41 42 43 44 45
IF (${SOMODE} MATCHES "static")
  SET(TD_SOMODE_STATIC TRUE)
  MESSAGE(STATUS "Link so using static mode")
ENDIF ()

H
Hui Li 已提交
46
IF (${DBNAME} MATCHES "power")
H
Hui Li 已提交
47 48
  SET(TD_POWER TRUE)
  MESSAGE(STATUS "power is true")
49 50 51
ELSEIF (${DBNAME} MATCHES "tq")
  SET(TD_TQ TRUE)
  MESSAGE(STATUS "tq is true")
52 53 54
ELSEIF (${DBNAME} MATCHES "pro")
  SET(TD_PRO TRUE)
  MESSAGE(STATUS "pro is true")
55 56 57
ELSEIF (${DBNAME} MATCHES "kh")
  SET(TD_KH TRUE)
  MESSAGE(STATUS "kh is true")
H
Hui Li 已提交
58 59
ENDIF ()

S
[TD-58]  
slguan 已提交
60 61 62 63 64 65 66 67
IF (${DLLTYPE} MATCHES "go")
  SET(TD_GODLL TRUE)
  MESSAGE(STATUS "input dll type: " ${DLLTYPE})
ENDIF ()

IF (${MEM_CHECK} MATCHES "true")
  SET(TD_MEM_CHECK TRUE)
  MESSAGE(STATUS "build with memory check")
68 69
ENDIF ()

70 71 72 73 74
IF (${MQTT} MATCHES "false")
  SET(TD_MQTT FALSE)
  MESSAGE(STATUS "build without mqtt module")
ENDIF ()

75 76 77 78
IF (${RANDOM_FILE_FAIL} MATCHES "true")
  SET(TD_RANDOM_FILE_FAIL TRUE)
  MESSAGE(STATUS "build with random-file-fail enabled")
ENDIF ()
79 80 81 82 83

IF (${RANDOM_NETWORK_FAIL} MATCHES "true")
  SET(TD_RANDOM_NETWORK_FAIL TRUE)
  MESSAGE(STATUS "build with random-network-fail enabled")
ENDIF ()
84 85 86 87 88

IF (${JEMALLOC_ENABLED} MATCHES "true")
  SET(TD_JEMALLOC_ENABLED TRUE)
  MESSAGE(STATUS "build with jemalloc enabled")
ENDIF ()
89 90 91 92 93 94

SET(TD_BUILD_JDBC TRUE)

IF (${BUILD_JDBC} MATCHES "false")
  SET(TD_BUILD_JDBC FALSE)
ENDIF ()
95

96
SET(TD_BUILD_HTTP FALSE)
97

98 99
SET(TD_BUILD_LUA TRUE)

100 101
SET(TD_AVRO_SUPPORT FALSE)

102 103 104 105
SET(TD_MEMORY_SANITIZER FALSE)
IF (${MEMORY_SANITIZER} MATCHES "true")
  SET(TD_MEMORY_SANITIZER TRUE)
ENDIF ()
T
tickduan 已提交
106

107 108 109 110 111 112
SET(TD_BUILD_VERBOSE FALSE)
IF (${VERBOSE} MATCHES "true")
  SET(CMAKE_VERBOSE_MAKEFILE ON)
  SET(TD_BUILD_VERBOSE TRUE)
ENDIF ()

113
IF (${TSZ_ENABLED} MATCHES "true")
114
  # define add
115
  MESSAGE(STATUS "build with TSZ enabled")
T
tickduan 已提交
116
  ADD_DEFINITIONS(-DTD_TSZ)
117 118
  set(VAR_TSZ "TSZ" CACHE INTERNAL "global variant tsz" )
ELSE()
T
tickduan 已提交
119
  set(VAR_TSZ "" CACHE INTERNAL "global variant empty" )
120
ENDIF()