I'm compiling OCaml bindings for a C++ library (https://github.com/grain-lang/binaryen.ml). We previously hit a problem where the macOS compiled version wasn't capturing exceptions from the C++ library and was causing SIGABRT instead, as someone else demonstrates well here (https://github.com/vaivaswatha/OCamlCppExn) which was resolved by using keep_dwarf_unwind at the linking stage (issue #9026)
I'm now building an M1/arm64 native version, which compiles and builds fine but tests are failing because an exception thrown in the library is again aborting the program rather than being caught in the OCaml program. Compiling and running https://github.com/vaivaswatha/OCamlCppExn but with keep_dwarf_unwind defined fails with the same problem as before:
libc++abi: terminating with uncaught exception of type std::runtime_error: This is not caught on macOS, why?
when it should hopefully have worked.
It may also be referenced here: https://git.brettgilio.com/ocaml/commit/482b7feb3743e140fd79c2b1bf929f2b738d42eb.html
Has anyone had success in getting arm64 compiled code to capture c++ exceptions?
This is on 4.12.0
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4