Skip to content

Commit

Permalink
Merge pull request #3895 from opensim-org/update_spdlog
Browse files Browse the repository at this point in the history
Ignore warnings related to deprecated `stdext::checked_array_iterator` on MSVC
  • Loading branch information
adamkewley authored Aug 31, 2024
2 parents 43e2c6b + d2d22ad commit 7466c6d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions cmake/OpenSimMacros.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,12 @@ function(OpenSimAddLibrary)
# This target links to the libraries provided as arguments to this func.
target_link_libraries(${OSIMADDLIB_LIBRARY_NAME} ${OSIMADDLIB_LINKLIBS})

target_compile_options(${OSIMADDLIB_LIBRARY_NAME} PUBLIC
# disable warning 4996 on Windows: `spdlog` transitively
# uses a deprecated `stdext::checked_array_iterator`
$<$<CXX_COMPILER_ID:MSVC>:/wd4996>
)

# This is for exporting classes on Windows.
if(OSIMADDLIB_VENDORLIB)
set(OSIMADDLIB_FOLDER "Vendor Libraries")
Expand Down

0 comments on commit 7466c6d

Please sign in to comment.