Skip to content

Commit

Permalink
Codegen skips bindings if Python module not found
Browse files Browse the repository at this point in the history
  • Loading branch information
kvankooten authored and jeffamstutz committed Nov 12, 2024
1 parent c8461bd commit d09c315
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions code_gen/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,11 @@ add_custom_target(generate_headers DEPENDS

add_dependencies(generate_all generate_headers)

if (NOT TARGET Python3::Module)
message(WARNING "Unable to find python Module, skipping python bindings")
return()
endif()

if (INSTALL_PYTHON_BINDINGS)
set(BUILD_PYTHON_BINDINGS_BY_DEFAULT ALL)
endif()
Expand Down

0 comments on commit d09c315

Please sign in to comment.