Skip to content

Commit

Permalink
Added library versioning
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrea Barberio committed Jun 19, 2016
1 parent c15b388 commit 90e762e
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ project (dublin-traceroute)
set (dublin-traceroute_VERSION_MAJOR_0)
set (dublin-traceroute_VERSION_MINOR_2)

# ensure that /usr/local is used to find dependencies. This is especially
# necessary for brew on OSX and for libraries installed manually under
# /usr/local
list(APPEND CMAKE_PREFIX_PATH /usr/local)

include_directories("${PROJECT_SOURCE_DIR}/include")

add_library(dublintraceroute SHARED
Expand All @@ -13,6 +18,12 @@ add_library(dublintraceroute SHARED
src/traceroute_results.cc
)

# Set the shared library version
set_target_properties(dublintraceroute
PROPERTIES
SOVERSION 0.0.0
)

find_package(PkgConfig)
find_package(Threads REQUIRED)
find_package(libtins 3.4)
Expand All @@ -26,7 +37,7 @@ endif (${libtins_FOUND})
pkg_search_module(JSONCPP REQUIRED jsoncpp)

add_executable(dublin-traceroute src/main.cc)
target_link_libraries (dublintraceroute ${CMAKE_THREAD_LIBS_INIT})
target_link_libraries(dublintraceroute ${CMAKE_THREAD_LIBS_INIT})
target_link_libraries(dublin-traceroute dublintraceroute)
target_link_libraries(dublintraceroute tins)

Expand Down

0 comments on commit 90e762e

Please sign in to comment.