Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

packaging shared ressources

I am trying to include LibreSSL in my project.

I have successfully built the necessary LibreSSL header and library files, but my binaries depend on .dylib files.

My question is where do I store this files properly?(Should I put them in my working folder or in /usr/lib)

and in term of compatibility if new version of libssl come, how avoid conflict?

Any help would be greatly appreciated.

Mac Pro, OS X Yosemite (10.10.2)

Posted on Apr 27, 2015 5:48 AM

Reply
Question marked as Best reply

Posted on Apr 27, 2015 6:13 AM

Hello ZzZdestrifZzZ,

I wouldn't use /usr/lib. That is for system files. They could get blown away in an OS update or conflict with something else. /usr/local/lib is a little bit better, but still problematic if you want to install other open source packages. I suggest creating a folder at the top-level of your main programming folder for such things. Then, any open source package that you want to use to incorporate into your own software should be build using this folder as a prefix. Since this folder isn't in your path, if any of the 3rd party software fails to run, you will discover that before your users do.


Finally, you should link and security libraries statically. Otherwise the hackers can swap it out for stubs and run your software for free.

2 replies
Question marked as Best reply

Apr 27, 2015 6:13 AM in response to ZzZdestrifZzZ

Hello ZzZdestrifZzZ,

I wouldn't use /usr/lib. That is for system files. They could get blown away in an OS update or conflict with something else. /usr/local/lib is a little bit better, but still problematic if you want to install other open source packages. I suggest creating a folder at the top-level of your main programming folder for such things. Then, any open source package that you want to use to incorporate into your own software should be build using this folder as a prefix. Since this folder isn't in your path, if any of the 3rd party software fails to run, you will discover that before your users do.


Finally, you should link and security libraries statically. Otherwise the hackers can swap it out for stubs and run your software for free.

packaging shared ressources

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.