I need to create a Mac version of our libraries for one of our customers. I am not so familiar with dynamic libraries on Mac, but from what I understand, I have 2 options: .dylib or frameworks. What would be the best option? Why?
Few related questions:
Any constructive criticisms/comments/ideas more than welcome. Thanks in advance.
Alex
.dylib
is similar to .so
on Linux.
Frameworks are basically just the OSX way of distributing libraries and headers together. They are the Application Bundle equivalent for library distribution.
With either method if you want to ensure other people don't use them you should be using static libraries (.a
files) and getting your customer to statically link them into their application.
Otherwise there isn't really much difference between Frameworks and .dylib
except the prior is nicer for OSX developers.
Either can be embedded inside a customers Application bundle, otool/install_name_tool
handle them both fine.