[asl] 21/177: Cmake: portability

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Thu Aug 27 09:22:35 UTC 2015


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch master
in repository asl.

commit d76730de74442d70b65438fd7455841338ed6f82
Author: AvtechScientific <AvtechScientific at users.noreply.github.com>
Date:   Fri Jun 12 12:56:21 2015 +0300

    Cmake: portability
---
 CMakeLists.txt                       | 6 +++++-
 test/testPhysics/flow/CMakeLists.txt | 2 +-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4331acc..f830947 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -10,7 +10,11 @@ set(ASL_VERSION_MINOR 1)
 set(ASL_VERSION_PATCH 3)
 set(ASL_VERSION ${ASL_VERSION_MAJOR}.${ASL_VERSION_MINOR}.${ASL_VERSION_PATCH})
 
-set(CMAKE_CXX_STANDARD 11)
+if (CMAKE_VERSION VERSION_LESS 3.1.0)
+	set(CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}")
+else()
+	set(CMAKE_CXX_STANDARD 11)
+endif()
 
 # Add definitions
 include(DefineOptions.cmake)
diff --git a/test/testPhysics/flow/CMakeLists.txt b/test/testPhysics/flow/CMakeLists.txt
index 90763d9..2bf9e84 100644
--- a/test/testPhysics/flow/CMakeLists.txt
+++ b/test/testPhysics/flow/CMakeLists.txt
@@ -6,7 +6,7 @@ target_link_libraries(flow aslnum aslvtk asl)
 set_property(TARGET flow PROPERTY RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/flow)
 
 add_executable(flow2 flow2.cc)
-target_link_libraries(flow2aslnum aslvtk asl)
+target_link_libraries(flow2 aslnum aslvtk asl)
 set_property(TARGET flow2 PROPERTY RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/flow2)
 
 add_executable(flow3 flow3.cc)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/asl.git



More information about the debian-science-commits mailing list