diff options
Diffstat (limited to 'cmake/Modules')
-rw-r--r-- | cmake/Modules/FindSNDFILE.cmake | 2 | ||||
-rw-r--r-- | cmake/Modules/GrPybind.cmake | 5 |
2 files changed, 5 insertions, 2 deletions
diff --git a/cmake/Modules/FindSNDFILE.cmake b/cmake/Modules/FindSNDFILE.cmake index 97d6798ebb..e20a603efe 100644 --- a/cmake/Modules/FindSNDFILE.cmake +++ b/cmake/Modules/FindSNDFILE.cmake @@ -25,7 +25,7 @@ INCLUDE(FindPackageHandleStandardArgs) FIND_PACKAGE_HANDLE_STANDARD_ARGS(SNDFILE DEFAULT_MSG SNDFILE_LIBRARIES SNDFILE_INCLUDE_DIRS) MARK_AS_ADVANCED(SNDFILE_LIBRARIES SNDFILE_INCLUDE_DIRS) -if (SNDFILE_FOUND AND NOT TARGET SNDFILE::SNDFILE) +if (SNDFILE_FOUND AND NOT TARGET sndfile::sndfile) add_library(sndfile::sndfile INTERFACE IMPORTED) set_target_properties(sndfile::sndfile PROPERTIES INTERFACE_INCLUDE_DIRECTORIES "${SNDFILE_INCLUDE_DIRS}" diff --git a/cmake/Modules/GrPybind.cmake b/cmake/Modules/GrPybind.cmake index fd5c9a2511..bf4c9b45cd 100644 --- a/cmake/Modules/GrPybind.cmake +++ b/cmake/Modules/GrPybind.cmake @@ -154,6 +154,9 @@ target_include_directories(${name}_python PUBLIC ) target_link_libraries(${name}_python PUBLIC ${Boost_LIBRARIES} ${PYTHON_LIBRARIES} gnuradio-${MODULE_NAME}) target_compile_options(${name}_python PRIVATE -Wno-unused-variable) # disable warnings for docstring templates +if(NOT SNDFILE_FOUND AND ${name} STREQUAL blocks) + target_compile_options(${name}_python PRIVATE -DNO_WAVFILE) +endif() add_dependencies(${name}_python ${name}_docstrings ${regen_targets}) endmacro(GR_PYBIND_MAKE_CHECK_HASH) @@ -277,4 +280,4 @@ target_link_libraries(${name}_python PUBLIC ${Boost_LIBRARIES} ${PYTHON_LIBRARIE target_compile_options(${name}_python PRIVATE -Wno-unused-variable) # disable warnings for docstring templates add_dependencies(${name}_python ${name}_docstrings ${regen_targets}) -endmacro(GR_PYBIND_MAKE_OOT)
\ No newline at end of file +endmacro(GR_PYBIND_MAKE_OOT) |