Skip to content

Commit

Permalink
windows-cmake: better BUILD_SHARED_LIBS default
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Hirsch <michael@scivision.dev>
  • Loading branch information
scivision committed Nov 8, 2021
1 parent 0ff77aa commit 3fa9157
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion contrib/windows-cmake/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ option(HWLOC_WITH_OPENCL "enable OpenCL support")
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.17)
option(HWLOC_WITH_CUDA "enable CUDA support")
endif()
option(HWLOC_BUILD_SHARED_LIBS "build shared libraries" ${BUILD_SHARED_LIBS})

set(TOPDIR ${PROJECT_SOURCE_DIR}/../..)

Expand Down Expand Up @@ -133,7 +134,7 @@ target_link_libraries(hwloc PRIVATE
"$<$<BOOL:${HAVE_CUDA}>:CUDA::cudart;CUDA::cuda_driver>"
)

if(BUILD_SHARED_LIBS)
if(HWLOC_BUILD_SHARED_LIBS)
target_compile_definitions(hwloc PRIVATE $<$<BOOL:${MSVC}>:_USRDLL>)
endif()

Expand Down

0 comments on commit 3fa9157

Please sign in to comment.