Make sure libressl is build before h2get if we use it there as well
@@ -561,18 +561,21 @@ ENDIF ()
IF (WITH_BUNDLED_SSL)
SET(H2GET_SSL_ROOT_DIR "${CMAKE_CURRENT_BINARY_DIR}/libressl-build/")
-ELSE (WITH_BUNDLED_SSL)
+ELSE ()
IF (OPENSSL_FOUND)
GET_FILENAME_COMPONENT(H2GET_SSL_ROOT_DIR ${OPENSSL_INCLUDE_DIR} DIRECTORY)
- ENDIF(OPENSSL_FOUND)
-ENDIF (WITH_BUNDLED_SSL)
+ ENDIF ()
+ENDIF ()
ExternalProject_Add(h2get
SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/misc/h2get
BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR}/h2get_bin
BUILD_COMMAND cmake -DH2GET_SSL_ROOT_DIR=${H2GET_SSL_ROOT_DIR} ${H2GET_MRUBY_OPTS} ${CMAKE_CURRENT_SOURCE_DIR}/misc/h2get && make
INSTALL_COMMAND true)
-set_target_properties(h2get PROPERTIES EXCLUDE_FROM_ALL TRUE)
+SET_TARGET_PROPERTIES(h2get PROPERTIES EXCLUDE_FROM_ALL TRUE)
+IF (WITH_BUNDLED_SSL)
+ ADD_DEPENDENCIES(h2get bundled-ssl)
+ENDIF ()
ADD_CUSTOM_TARGET(check env H2O_ROOT=. BINARY_DIR=${CMAKE_CURRENT_BINARY_DIR} prove -v t/*.t
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
