THRIFT-2850 CMake: Fixed Java lib build enable - Ant required to build java part of Thrift
This closes: #365
diff --git a/cmake/DefineOptions.cmake b/cmake/DefineOptions.cmake
index 391247e..457deb6 100644
--- a/cmake/DefineOptions.cmake
+++ b/cmake/DefineOptions.cmake
@@ -69,8 +69,9 @@
"BUILD_LIBRARIES;GLIB_FOUND" OFF)
# Java
find_package(Java QUIET)
+find_package(Ant QUIET)
CMAKE_DEPENDENT_OPTION(WITH_JAVA "Build Java library" ON
- "BUILD_LIBRARIES;JAVA_FOUND" OFF)
+ "BUILD_LIBRARIES;JAVA_FOUND;Ant_FOUND" OFF)
# Common library options
option(WITH_SHARED_LIB "Build shared libraries" ON)