I am trying to follow this advice from stackoverflow and copy some library files from /usr/local/Cellar/openssl/1.0.1c to /usr/lib/.
I have tried cp, ln -s and even touch, but they all fail. I am using the root credentials:
joyce# whoami
root
In the right directory:
joyce# pwd
/usr/lib
But no write operation is permitted:
joyce# cp /usr/local/Cellar/openssl/1.0.2e_1/lib/libssl.1.0.0.dylib .
cp: ./libssl.1.0.0.dylib: Operation not permitted
joyce# ln -s /usr/local/Cellar/openssl/1.0.2e_1/lib/libssl.1.0.0.dylib .
ln: ./libssl.1.0.0.dylib: Operation not permitted
joyce# touch blah
touch: blah: Operation not permitted
Any idea how can I write to /usr/lib as root?
/usr/libis protected by SIP, can't you add it to/usr/local/liband pass appropriate flags to the linker? – nohillside May 19 '16 at 08:49export DYLD_LIBRARY_PATH=/usr/local/Cellar/openssl/1.0.2e_1/lib. Would you like to make it an answer so I can accept and upvote? – Adam Matan May 19 '16 at 09:16