mctools / simplebuild

A very simple to use build system for projects with primarily C++/Python code, intended for usage by scientific developers without a strong SW-engineering background.
https://mctools.github.io/simplebuild/
Apache License 2.0
3 stars 1 forks source link

Revisit workaround for pybind11 issue #76

Open tkittel opened 3 months ago

tkittel commented 3 months ago

Adding a workaround for pybind bug: https://github.com/pybind/pybind11/issues/5224

Opening this issue here to ensure we remember to remove the workaround again after the issue is hopefully fixed upstream.

--- a/src/_simple_build_system/data/cmake/ExtDep_pybind11.cmake
+++ b/src/_simple_build_system/data/cmake/ExtDep_pybind11.cmake
@@ -51,6 +51,10 @@ function( detect_system_pybind11
   strip_cpp_version_flags( module_cflags )
   strip_cpp_version_flags( embed_cflags )

+  #Temporary workaround (see https://github.com/pybind/pybind11/issues/5224):
+  list(APPEND embed_cflags "-Wno-array-bounds -Wno-stringop-overread")
+  list(APPEND module_cflags "-Wno-array-bounds -Wno-stringop-overread")