commit 7faa1a1fa53d3599edf179cd41f0a264bd247e58
parent 3fb0c69e6a5461607f336aca335a99607a77df9a
Author: vaplv <vaplv@free.fr>
Date: Tue, 6 Jan 2015 14:59:25 +0100
Change the default library build type from static to shared
Diffstat:
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
@@ -15,5 +15,3 @@ from the cmake/CMakeLists.txt file by appending the RCMake lib/cmake and RSys
install directories to the `CMAKE_PREFIX_PATH` variable. The resulting project
can be edited, built, tested and installed as any CMake project.
-Note that by default the library is built as a static library.
-
diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt
@@ -18,7 +18,7 @@ project(polygon C)
cmake_policy(SET CMP0011 NEW)
enable_testing()
-option(BUILD_STATIC "Build library as static rather than shared" ON)
+option(BUILD_STATIC "Build library as static rather than shared" OFF)
set(POLYGON_SOURCE_DIR ${PROJECT_SOURCE_DIR}/../src)
################################################################################
@@ -53,6 +53,7 @@ else(BUILD_STATIC)
DEFINE_SYMBOL POLYGON_SHARED_BUILD
VERSION ${VERSION}
SOVERSION ${VERSION_MAJOR})
+ target_link_libraries(polygon m)
endif(BUILD_STATIC)
target_link_libraries(polygon RSys)