find_package(GnuTLS REQUIRED)
if(GNUTLS_FOUND)
set(USE_GNUTLS ON)
- set(SSLIMP_LIBRARIES "${GNUTLS_LIBRARIES} crypto") # FIXME: port AES128-OCB
+ set(SSLIMP_LIBRARIES ${GNUTLS_LIBRARIES})
set(SSLIMP_INCLUDE_DIR ${GNUTLS_INCLUDE_DIR})
set(SSLIMP_LIBRARY_DIR ${GNUTLS_LIB_DIR})
endif(GNUTLS_FOUND)
endif(NOT OLD_CONFIG_FILE)
add_definitions(${SSLIMP_CFLAGS})
-target_link_libraries(umurmurd ${LIBCONFIG_LIBRARIES} ${PROTOBUFC_LIBRARIES} ${SSLIMP_LIBRARIES} ${LIBRT})
+
+if(USE_GNUTLS)
+# FIXME: port AES128-OCB
+ target_link_libraries(umurmurd ${LIBCONFIG_LIBRARIES} ${PROTOBUFC_LIBRARIES} ${SSLIMP_LIBRARIES} ${LIBRT} crypto)
+else()
+ target_link_libraries(umurmurd ${LIBCONFIG_LIBRARIES} ${PROTOBUFC_LIBRARIES} ${SSLIMP_LIBRARIES} ${LIBRT})
+endif(USE_GNUTLS)