问题
I have several .o files and want to bundle them in a .dylib, how can I do that it Mac OS X using gcc? Thank you very much.
回答1:
Use g++ -dynamiclib -undefined suppress -flat_namespace *.o -o something.dylib
来源:https://stackoverflow.com/questions/3532589/how-to-build-a-dylib-from-several-o-in-mac-os-x-using-gcc