Skip to content

Commit

Permalink
Disable certain warnings in the XS file as it is generated by xsubpp
Browse files Browse the repository at this point in the history
We cannot fix the warnings in this generated file and they look harmless.
  • Loading branch information
Martchus committed Aug 9, 2021
1 parent 44fb3f2 commit 2043eff
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ppmclibs/CMakeLists.txt
Expand Up @@ -78,6 +78,10 @@ target_link_libraries(tinycv PRIVATE opencv_core opencv_imgcodecs)
target_include_directories(tinycv PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}" "${PERL_INCLUDE_DIRECTORY}")
target_compile_definitions(tinycv PRIVATE "-DVERSION=\"1.0\"" "-DXS_VERSION=\"1.0\"" "-D_LARGEFILE_SOURCE" "-D_FILE_OFFSET_BITS=64")
target_compile_options(tinycv PRIVATE ${PRIVATE_COMPILE_OPTIONS})
if (ENABLE_WARNINGS)
# disable certain warnings in the XS file as it is generated by xsubpp (and hence we have no way of fixing these)
set_source_files_properties("${PREPROCESSED_XS_FILE}" PROPERTIES COMPILE_OPTIONS "-Wno-old-style-cast;-Wno-sign-conversion;-Wno-conversion")
endif ()
set_target_properties(tinycv PROPERTIES PREFIX "") # remove lib prefix (library is *not* supposed to be called libtinycv.so)

# install the native library and Perl code
Expand Down

0 comments on commit 2043eff

Please sign in to comment.