From: Danny Al-Gaaf Date: Sun, 15 Mar 2015 19:11:48 +0000 (+0100) Subject: src/CMakeLists.txt: fix build to work with nss X-Git-Tag: v9.0.2~223^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F4003%2Fhead;p=ceph.git src/CMakeLists.txt: fix build to work with nss Add nss and nspr include dirs to CXX_FLAGS if all dependencies are found. the ceph-authtool target needs also ${CRYPTO_LIBS}. Signed-off-by: Danny Al-Gaaf --- diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index ba52cecf29d..94b08e95bfa 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -25,7 +25,13 @@ if(WITH_CDS) list(APPEND EXTRALIBS ${CDS_LIBS}) endif(WITH_CDS) -set(CRYPTO_LIBS cryptopp) +if(USE_NSS) + if(NSS_FOUND) + if(NSPR_FOUND) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -I${NSS_INCLUDE_DIR} -I${NSPR_INCLUDE_DIR}") + endif(NSPR_FOUND) + endif(NSS_FOUND) +endif(USE_NSS) if(${HAVE_ATOMIC_OPS}) set(EXTRALIBS @@ -550,7 +556,7 @@ install(TARGETS osdmaptool DESTINATION bin) set(ceph_authtool_srcs tools/ceph_authtool.cc) add_executable(ceph-authtool ${ceph_authtool_srcs}) -target_link_libraries(ceph-authtool global ${EXTRALIBS}) +target_link_libraries(ceph-authtool global ${EXTRALIBS} ${CRYPTO_LIBS}) install(TARGETS ceph-authtool DESTINATION bin) configure_file(${CMAKE_SOURCE_DIR}/src/ceph-coverage.in