Delete load command (install name) from dylib?

Matthew Brett <[email protected]>
Newsgroups gmane.comp.python.apple
Message-ID <CAH6Pt5osmymw-h9rSu44y1m=HTnvr4eho0UOtkFP2trffvx+Xg@mail.gmail.com>
Hi,

I'm sorry if this is an easy question to which I have missed an
obvious answer, but

Is there any way (using macholib or otherwise) to delete a library
dependency?  Specifically, let's say I have a library with
dependencies like this:

$ otool -L libdlib.19.0.99.dylib

libdlib.19.0.99.dylib:
/Users/mb312/dev_trees/dlib-wheels/dlib/dlib/libdlib.19.0.99.dylib
(compatibility version 0.0.0, current version 19.0.99)
/opt/X11/lib/libSM.6.dylib (compatibility version 7.0.0, current version 7.1.0)
/usr/lib/libc++.1.dylib (compatibility version 1.0.0, current version 120.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current
version 1197.1.1)

and I want to delete the dependency on /opt/X11/lib/libSM.6.dylib - is
there a way do this?  As in something like:

delete_install_name /opt/X11/lib/libSM.6.dylib libdlib.19.0.99.dylib

Thanks for any insights,

Matthew
_______________________________________________
Pythonmac-SIG maillist  -  [email protected]
https://mail.python.org/mailman/listinfo/pythonmac-sig
unsubscribe: https://mail.python.org/mailman/options/Pythonmac-SIG
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.