Post

Replies

Boosts

Views

Activity

Allow DYLD Environment Variables Entitlement on OSX 10.13.6
I am trying to allow searching and loading libraries from non-standard locations using DYLD_LIBRARY_PATH. This is because of a mysql installation into /opt/mysql (and its libraries go to /opt/mysql/lib). I did not want to link all contents of /opt/mysql/lib into /usr/local/lib and so I tried to set the non-standard library location into DYLD_LIBRARY_PATH. But this fails to be passed on to applications which then fail to find the library, e.g. consider this example (from https://stackoverflow.com/questions/71947188/bash-variable-of-name-starting-with-dyld-is-not-loaded-into-environment-bug-o): export DYLD_VARIABLE=Dd export FYLD_VARIABLE=Ff env | grep VARIABLE (DYLD is not passed on whereas FYLD is) So, I resorted changing the property for this behaviour with this from the Terminal: defaults write com.apple.security.cs.allow-dyld-environment-variables true but it says: Rep argument is not a dictionary Defaults have not been changed. Also: defaults find com.apple.security.cs does not find said key. But this page: https://developer.apple.com/documentation/bundleresources/entitlements/com_apple_security_cs_allow-dyld-environment-variables says that this property list key is there since 10.7+ As I said, I am on OSX 10.13.6. My question is: how to allow DYLD_* env variables to be passed on?
3
0
1.4k
Sep ’22