diff options
author | Vicent Martà <vicent@github.com> | 2013-03-07 12:06:18 -0800 |
---|---|---|
committer | Vicent Martà <vicent@github.com> | 2013-03-07 12:06:18 -0800 |
commit | 92ebbe99c9b557aee3382f51ddf6dd6637ee2fe4 (patch) | |
tree | 9514c42011f62f225c8eda62b576ba96614decad | |
parent | 6f83a7813310766325ae14f6ac7591dc56341fc5 (diff) | |
parent | e7da9acdcddd163d4a1e42f51a5f794e168bfd44 (diff) | |
download | libgit2-92ebbe99c9b557aee3382f51ddf6dd6637ee2fe4.tar.gz |
Merge pull request #1399 from nathan-osman/development
Add SONAME build option to facilitate building for Android.
-rw-r--r-- | CMakeLists.txt | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 7f2e293d1..037754321 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -16,6 +16,7 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.6) # Build options # +OPTION( SONAME "Set the (SO)VERSION of the target" ON ) OPTION( BUILD_SHARED_LIBS "Build Shared Library (OFF for Static)" ON ) OPTION( THREADSAFE "Build libgit2 as threadsafe" OFF ) OPTION( BUILD_CLAR "Build Tests using the Clar suite" ON ) @@ -264,8 +265,10 @@ TARGET_OS_LIBRARIES(git2) MSVC_SPLIT_SOURCES(git2) -SET_TARGET_PROPERTIES(git2 PROPERTIES VERSION ${LIBGIT2_VERSION_STRING}) -SET_TARGET_PROPERTIES(git2 PROPERTIES SOVERSION ${LIBGIT2_VERSION_MAJOR}) +IF (SONAME) + SET_TARGET_PROPERTIES(git2 PROPERTIES VERSION ${LIBGIT2_VERSION_STRING}) + SET_TARGET_PROPERTIES(git2 PROPERTIES SOVERSION ${LIBGIT2_VERSION_MAJOR}) +ENDIF() CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/libgit2.pc.in ${CMAKE_CURRENT_BINARY_DIR}/libgit2.pc @ONLY) IF (MSVC_IDE) |