How do I avoid this multiple-implementation warning with a symlinked executable?

I'm working on a simple command line applicaition using Swift Package Manager, and to get the executable into my $PATH I created a symlink from the build directory to /usr/local/bin. However, when executing the application using the symlink, I get this warning about one of the classes in my project being implemented twice:

objc[60807]: Class _TtC8CLIMyClass is implemented in both /path/to/.build/x86_64-apple-macosx/debug/libMyLib.dylib (0x109070610) and /usr/local/bin/my-app (0x1081c0f80). One of the two will be used. Which one is undefined.

The class in question is implemented in another local package which is used as a dependency by the application package. There are other classes used in this project, so it's not clear to me why this one results in this warning while others don't.

Is there any way to silence or avoid this warning?

2 Likes