Skip to content

Commit

Permalink
Merge pull request #472 from he-yulong/Fix_cmake_error_for_win10
Browse files Browse the repository at this point in the history
Fix CMake build error on Windows 10 by exporting zlibstatic alongside Ptex_static
  • Loading branch information
mmp authored Jan 30, 2025
2 parents 88645ff + f5767b3 commit fb5988a
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1032,6 +1032,17 @@ add_sanitizers (nanovdb2pbrt)

set_property (TARGET nanovdb2pbrt PROPERTY FOLDER "cmd")

# Only do this if both targets actually exist
if (TARGET Ptex_static AND TARGET zlibstatic)
install(
TARGETS zlibstatic
EXPORT Ptex # Same export set name as used by Ptex
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
)
endif()

######################
# cyhair2pbrt

Expand Down

0 comments on commit fb5988a

Please sign in to comment.