From 17e76c140ba1e3dcd71aa55eeff7037bf3b550f0 Mon Sep 17 00:00:00 2001 From: Horst Schirmeier Date: Tue, 19 Nov 2013 13:37:53 -0800 Subject: [PATCH] cpn: needs comm and MySQL at link time The dependency on fail-comm exists not only at compile time (the latter is due to protobuf header generation). Change-Id: I2bae51e763d9a385bda94e77df3e88619fa28a30 --- src/core/cpn/CMakeLists.txt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/core/cpn/CMakeLists.txt b/src/core/cpn/CMakeLists.txt index 81ac82cf..79fac5ba 100644 --- a/src/core/cpn/CMakeLists.txt +++ b/src/core/cpn/CMakeLists.txt @@ -4,6 +4,11 @@ set(SRCS DatabaseCampaign.cc ) -add_library(fail-cpn ${SRCS}) +find_package(MySQL REQUIRED) +include_directories(${MYSQL_INCLUDE_DIR}) +add_library(fail-cpn ${SRCS}) +target_link_libraries(fail-cpn fail-comm ${MYSQL_LIBRARIES}) + +# make sure protobufs are generated before we include them add_dependencies(fail-cpn fail-comm)