From 286cbc87fff9344ff85db0efd54c41f619509c74 Mon Sep 17 00:00:00 2001 From: Dmitry Kozlov Date: Wed, 30 Oct 2013 16:19:33 +0400 Subject: fix build with internal & tomcrypt crypto libraries Signed-off-by: Vladislav Grishenko --- crypto/CMakeLists.txt | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) (limited to 'crypto/CMakeLists.txt') diff --git a/crypto/CMakeLists.txt b/crypto/CMakeLists.txt index f741311..6df9fa7 100644 --- a/crypto/CMakeLists.txt +++ b/crypto/CMakeLists.txt @@ -1,17 +1,21 @@ -IF (CRYPTO STREQUAL INTERNAL) +INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}) + +SET(sources crypto.c) +IF (CRYPTO STREQUAL INTERNAL) SET(sources + ${sources} crypto.c md4.c md5.c sha1.c des.c ) +ENDIF(CRYPTO STREQUAL INTERNAL) - ADD_LIBRARY(internal-crypto SHARED ${sources}) - - INSTALL(TARGETS internal-crypto - LIBRARY DESTINATION lib/accel-ppp - ) +ADD_LIBRARY(internal-crypto SHARED ${sources}) +IF (CRYPTO STREQUAL TOMCRYPT) + TARGET_LINK_LIBRARIES(internal-crypto tomcrypt) +ENDIF(CRYPTO STREQUAL TOMCRYPT) -ENDIF (CRYPTO STREQUAL INTERNAL) +INSTALL(TARGETS internal-crypto LIBRARY DESTINATION lib${LIB_SUFFIX}/accel-ppp ) -- cgit v1.2.3