Skip to content

Commit f77b833

Browse files
author
Roberto Di Remigio
committed
Do not compile Boost when not needed
1 parent 427559b commit f77b833

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

cmake/autocmake.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ source: https://github.com/scisoft/autocmake/raw/master/modules/python_interpret
4848
source: custom/pcmsolver.cmake
4949

5050
[boost]
51-
override: {'major': 1, 'minor': 54, 'patch': 0, 'components': 'chrono;timer;system'}
51+
override: {'major': 1, 'minor': 54, 'patch': 0}
5252
source: https://github.com/scisoft/autocmake/raw/master/modules/boost/boost.cmake
5353

5454
[general]

cmake/custom/pcmsolver.cmake

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ if(NOT DEFINED SUBMODULES_INSTALL_PREFIX)
1010
endif()
1111

1212
set(BOOST_MINIMUM_REQUIRED 1.54.0)
13-
set(BOOST_COMPONENTS_REQUIRED "chrono;timer;system")
13+
if(BUILD_STANDALONE OR ENABLE_TIMER)
14+
set(BOOST_COMPONENTS_REQUIRED "chrono;timer;system")
15+
endif()
1416

1517
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib)
1618
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib)

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def gen_cmake_command(options, arguments):
6464
command.append('-DBOOST_LIBRARYDIR="{0}"'.format(arguments['--boost-libraries']))
6565
command.append('-DFORCE_CUSTOM_BOOST="{0}"'.format(arguments['--build-boost']))
6666
command.append('-DBOOST_MINIMUM_REQUIRED="1.54.0"')
67-
command.append('-DBOOST_COMPONENTS_REQUIRED="chrono;timer;system"')
67+
command.append('-DBOOST_COMPONENTS_REQUIRED="''"')
6868
command.append('-DCMAKE_BUILD_TYPE=%s' % arguments['--type'])
6969
command.append('-G "%s"' % arguments['--generator'])
7070
if arguments['--cmake-options'] != "''":

0 commit comments

Comments
 (0)