Fix MinGW stack flag syntax and Python binding crashes
- Detect linker type (lld-link vs ld) and use the appropriate stack flag: /STACK:16777216 for lld-link, --stack,16777216 for MinGW ld - Filter out stack-related flags from Python binding modules to prevent crashes when loading MuJoCo as a DLL in Python Fixes #3011
This commit is contained in:
@@ -51,6 +51,8 @@ endif()
|
||||
|
||||
include(MujocoLinkOptions)
|
||||
get_mujoco_extra_link_options(EXTRA_LINK_OPTIONS)
|
||||
list(FILTER EXTRA_LINK_OPTIONS EXCLUDE REGEX "STACK")
|
||||
list(FILTER EXTRA_LINK_OPTIONS EXCLUDE REGEX "stack")
|
||||
add_link_options(${EXTRA_LINK_OPTIONS})
|
||||
|
||||
include(MujocoMacOS)
|
||||
|
||||
Reference in New Issue
Block a user