diff --git a/CMakeLists.txt b/CMakeLists.txt index 8573ec3..d99ae2f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -15,7 +15,7 @@ SET(CMAKE_PREFIX_PATH "${PYTORCH_DIR}") FIND_PACKAGE(Torch REQUIRED) # Specify the C++ version we are building for. -SET (CMAKE_CXX_STANDARD 14) +SET (CMAKE_CXX_STANDARD 17) # Set flags for linking on mac IF(APPLE) diff --git a/python/setup.py b/python/setup.py index 4d03efe..8b7c8ea 100644 --- a/python/setup.py +++ b/python/setup.py @@ -9,12 +9,12 @@ torch_dir, _ = os.path.split('@TORCH_LIBRARY@') # setup extra compile and link arguments on Mac -extra_compile_args = ['-std=c++14'] +extra_compile_args = ['-std=c++17'] extra_link_args = [] if platform.system() == 'Darwin': - extra_compile_args += ['-stdlib=libc++', '-mmacosx-version-min=10.7'] - extra_link_args += ['-stdlib=libc++', '-mmacosx-version-min=10.7', '-Wl', '-rpath', openmm_dir+'/lib', '-rpath', torch_dir] + extra_compile_args += ['-stdlib=libc++', '-mmacosx-version-min=10.13'] + extra_link_args += ['-stdlib=libc++', '-mmacosx-version-min=10.13', '-Wl', '-rpath', openmm_dir+'/lib', '-rpath', torch_dir] extension = Extension(name='_openmmtorch', sources=['TorchPluginWrapper.cpp'],