From 5f36544d57509fd87ecc6a128fdfe2c119e27748 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20M=C3=B6bius?= Date: Wed, 15 Apr 2009 14:36:44 +0000 Subject: [PATCH] Build OpenMesh static under windows but shared on other platforms git-svn-id: http://www.openmesh.org/svnrepo/OpenMesh/trunk@93 fdac6126-5c0c-442c-9429-916003d36597 --- Core/CMakeLists.txt | 6 +++++- Tools/CMakeLists.txt | 9 +++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/Core/CMakeLists.txt b/Core/CMakeLists.txt index 44570e35..8b7c025c 100644 --- a/Core/CMakeLists.txt +++ b/Core/CMakeLists.txt @@ -22,6 +22,10 @@ set (directories append_files (headers "*.hh" ${directories}) append_files (sources "*.cc" ${directories}) +if (WIN32) add_library (OpenMeshCore STATIC ${sources} ${headers}) +else () +add_library (OpenMeshCore SHARED ${sources} ${headers}) +endif () -set_target_props (OpenMeshCore) \ No newline at end of file +set_target_props (OpenMeshCore) diff --git a/Tools/CMakeLists.txt b/Tools/CMakeLists.txt index e4159b48..6f9443b4 100644 --- a/Tools/CMakeLists.txt +++ b/Tools/CMakeLists.txt @@ -18,7 +18,12 @@ set (directories append_files (headers "*.hh" ${directories}) append_files (sources "*.cc" ${directories}) -add_library (OpenMeshTools STATIC ${sources} ${headers}) +if (WIN32) +add_library (OpenMeshCore STATIC ${sources} ${headers}) +else () +add_library (OpenMeshCore SHARED ${sources} ${headers}) +endif () + target_link_libraries (OpenMeshTools OpenMeshCore) -set_target_props (OpenMeshTools) \ No newline at end of file +set_target_props (OpenMeshTools)