aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2018-06-16 21:17:18 +0900
committerKitsune Ral <Kitsune-Ral@users.sf.net>2018-06-16 21:17:18 +0900
commitfe4bedeb349ed867feba7cb3c996a97f726d2083 (patch)
tree8ab73267919f4d354ef30973322ac5e9ef9e0e16
parentf2593ec532311133c51146d1a42faf7e01ea5e86 (diff)
downloadlibquotient-fe4bedeb349ed867feba7cb3c996a97f726d2083.tar.gz
libquotient-fe4bedeb349ed867feba7cb3c996a97f726d2083.zip
CMakeLists.txt: Don't build API files list if not needed
-rw-r--r--CMakeLists.txt10
1 files changed, 5 insertions, 5 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f59dcd41..e5456797 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -96,14 +96,14 @@ set(libqmatrixclient_SRCS
lib/jobs/downloadfilejob.cpp
)
-file(GLOB_RECURSE API_DEFS RELATIVE ${PROJECT_SOURCE_DIR}
- ${ABS_API_DEF_PATH}/*.yaml
- ${ABS_API_DEF_PATH}/definitions/*.yaml
- ${MATRIX_DOC_PATH}/event-schemas/schema/*
-)
set(CSAPI_DIR csapi)
set(FULL_CSAPI_DIR lib/${CSAPI_DIR})
if (MATRIX_DOC_PATH AND GTAD_PATH)
+ file(GLOB_RECURSE API_DEFS RELATIVE ${PROJECT_SOURCE_DIR}
+ ${ABS_API_DEF_PATH}/*.yaml
+ ${ABS_API_DEF_PATH}/definitions/*.yaml
+ ${MATRIX_DOC_PATH}/event-schemas/schema/*
+ )
add_custom_target(update-api
${ABS_GTAD_PATH} --config ${CSAPI_DIR}/gtad.yaml --out ${CSAPI_DIR}
${ABS_API_DEF_PATH}