From cec5c56ca640b1cb7470ca4eb68e40c56b5e20b0 Mon Sep 17 00:00:00 2001 From: Marek Kotewicz Date: Thu, 6 Nov 2014 12:26:21 +0100 Subject: [PATCH] jsonrpc is building properly to intall folder --- extdep/CMakeLists.txt | 1 + extdep/FindCURL.cmake | 9 +++++++++ extdep/json-rpc-cpp.cmake | 11 +++++++++++ 3 files changed, 21 insertions(+) create mode 100644 extdep/FindCURL.cmake create mode 100644 extdep/json-rpc-cpp.cmake diff --git a/extdep/CMakeLists.txt b/extdep/CMakeLists.txt index c89457f01..f28ad1c8e 100644 --- a/extdep/CMakeLists.txt +++ b/extdep/CMakeLists.txt @@ -9,5 +9,6 @@ file(MAKE_DIRECTORY ${ETH_DEPENDENCY_INSTALL_DIR}) include(cryptopp.cmake) include(curl.cmake) +include(json-rpc-cpp.cmake) #include(miniupnpc.cmake) diff --git a/extdep/FindCURL.cmake b/extdep/FindCURL.cmake new file mode 100644 index 000000000..6a82ebb22 --- /dev/null +++ b/extdep/FindCURL.cmake @@ -0,0 +1,9 @@ +# hacky way to resolve nested dependencies +find_library(CURL_LIBRARY NAMES curl + PATHS + ${ETH_DEPENDENCY_INSTALL_DIR}/lib + ) + +set(CURL_LIBRARIES ${CURL_LIBRARY}) +set(CURL_INCLUDE_DIRS ${ETH_DEPENDENCY_INSTALL_DIR}/include) + diff --git a/extdep/json-rpc-cpp.cmake b/extdep/json-rpc-cpp.cmake new file mode 100644 index 000000000..28c5f7cf1 --- /dev/null +++ b/extdep/json-rpc-cpp.cmake @@ -0,0 +1,11 @@ +ExternalProject_Add(json-rpc-cpp + DEPENDS curl + GIT_REPOSITORY https://github.com/cinemast/libjson-rpc-cpp.git + GIT_TAG eaca2481e2889d5a5b748383fb02b1d395969cd4 + BINARY_DIR json-rpc-cpp-prefix/src/json-rpc-cpp + CONFIGURE_COMMAND cmake -DCMAKE_INSTALL_PREFIX=${ETH_DEPENDENCY_INSTALL_DIR} -DCMAKE_MODULE_PATH:PATH=${CMAKE_CURRENT_SOURCE_DIR} -DETH_DEPENDENCY_INSTALL_DIR:PATH=${ETH_DEPENDENCY_INSTALL_DIR} -DCMAKE_BUILD_TYPE=None -DCMAKE_FIND_FRAMEWORK=LAST -Wno-dev . + BUILD_COMMAND make jsonrpc -j 3 + INSTALL_COMMAND make install + ) + +