summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Brandt <mail@cebe.cc>2017-02-20 23:33:50 +0100
committerCarsten Brandt <mail@cebe.cc>2017-03-25 17:22:16 +0100
commita1f9df48d61ccc34e35bf98c3c61ec7861e8e1b6 (patch)
tree08c8404e625c75461fb7a64692712cbb01e1c4be
parent63df16728cd5649b801f8cdcdf06cc76bfb5e450 (diff)
make BUILD_TOXAV and option and fail if dependencies are missing
fixes #482
-rw-r--r--CMakeLists.txt13
-rw-r--r--appveyor.yml2
2 files changed, 10 insertions, 5 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index e7f49313..1f3d77ad 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -170,12 +170,17 @@ if(ASAN)
170 set(CMAKE_REQUIRED_LIBRARIES "${SAFE_CMAKE_REQUIRED_LIBRARIES}") 170 set(CMAKE_REQUIRED_LIBRARIES "${SAFE_CMAKE_REQUIRED_LIBRARIES}")
171endif() 171endif()
172 172
173option(BUILD_TOXAV "Whether to build the tox AV library" ON)
174
173include(Dependencies) 175include(Dependencies)
174 176
175if(OPUS_FOUND AND VPX_FOUND) 177if (BUILD_TOXAV)
176 set(BUILD_TOXAV TRUE) 178 if(NOT OPUS_FOUND)
177else() 179 message(SEND_ERROR "Option BUILD_TOXAV is enabled but required library OPUS was not found.")
178 set(BUILD_TOXAV FALSE) 180 endif()
181 if(NOT VPX_FOUND)
182 message(SEND_ERROR "Option BUILD_TOXAV is enabled but required library VPX was not found.")
183 endif()
179endif() 184endif()
180 185
181################################################################################ 186################################################################################
diff --git a/appveyor.yml b/appveyor.yml
index ec90e428..4b4bfb20 100644
--- a/appveyor.yml
+++ b/appveyor.yml
@@ -13,7 +13,7 @@ install:
13- cd .. 13- cd ..
14 14
15before_build: 15before_build:
16- cmake . -DBOOTSTRAP_DAEMON=OFF -DENABLE_SHARED=OFF 16- cmake . -DBOOTSTRAP_DAEMON=OFF -DENABLE_SHARED=OFF -DBUILD_TOXAV=OFF
17 17
18build: 18build:
19 project: INSTALL.vcxproj 19 project: INSTALL.vcxproj