Skip to content

Commit

Permalink
Adding build option for C++11 variadic template compiler support
Browse files Browse the repository at this point in the history
  • Loading branch information
hkaiser committed Jul 11, 2013
1 parent a80ba13 commit f4c250a
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 13 deletions.
10 changes: 10 additions & 0 deletions CMakeLists.txt
Expand Up @@ -821,6 +821,16 @@ if(MSVC)
hpx_add_definitions(-DBOOST_RESULT_OF_USE_DECLTYPE)
endif()

if(MSVC12)
hpx_option(HPX_HAVE_CXX11_VARIADIC_TEMPLATES BOOL "Compiler supports C++11 variadic templates (default: ON)." ON ADVANCED)
else()
hpx_option(HPX_HAVE_CXX11_VARIADIC_TEMPLATES BOOL "Compiler supports C++11 variadic templates (default: OFF)." OFF ADVANCED)
endif()

if(HPX_HAVE_CXX11_VARIADIC_TEMPLATES)
hpx_add_definitions(-DHPX_HAVE_CXX11_VARIADIC_TEMPLATES)
endif()

hpx_option(HPX_HAVE_CXX11_UNIQUE_PTR BOOL "Compiler supports C++11 std::unique_ptr (default: ON)." ON ADVANCED)
if(HPX_HAVE_CXX11_UNIQUE_PTR)
hpx_add_definitions(-DHPX_HAVE_CXX11_STD_UNIQUE_PTR)
Expand Down
22 changes: 9 additions & 13 deletions examples/hpxla/CMakeLists.txt
@@ -1,16 +1,18 @@
# Copyright (c) 2007-2012 Hartmut Kaiser
# Copyright (c) 2007-2013 Hartmut Kaiser
# Copyright (c) 2011 Bryce Adelstein-Lelbach
#
# Distributed under the Boost Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

set(example_programs
blocked_matrix_multiply
householder_qr_factorization
explicit_qr_algorithm
)
set(example_programs)

#set(blocked_matrix_multiply_FLAGS DEPENDENCIES dataflow_component)
if(HPX_HAVE_CXX11_VARIADIC_TEMPLATES)
set(example_programs
blocked_matrix_multiply
householder_qr_factorization
explicit_qr_algorithm
)
endif()

foreach(example_program ${example_programs})
set(sources
Expand All @@ -35,9 +37,3 @@ foreach(example_program ${example_programs})
${example_program}_exe)
endforeach()

#set_property(TARGET blocked_matrix_multiply_exe APPEND
# PROPERTY COMPILE_DEFINITIONS
# "HPX_ACTION_ARGUMENT_LIMIT=10"
# "HPX_COMPONENT_CREATE_ARGUMENT_LIMIT=10"
# "HPX_FUNCTION_ARGUMENT_LIMIT=13")

0 comments on commit f4c250a

Please sign in to comment.