While you can shove libraries anywhere you want, and use OS X very similarly to Linux, I suspect you are after information on "the OS X way" of doing things, in which case:
Your question is too broad. While similar in some ways, there are many fundamental differences than between software packaging on OS X and something like Ubuntu - well beyond "stuff goes here on Linux, and here on OS X".
For example, libraries typically live in "bundles" rather than folders like in
/usr/lib - either as
.Framework bundles which live in
~/Library/Frameworks (the framework bundles include headers, support versioning etc). Or shared libraries may live in application bundles... etc - each of these is a big topic by itself.
Without a more specific question, any answer shorter than a small book may not be very informative..
This article explains some of the basic locations, and their Linux-equivalents
Apple's documentation on this kind of stuff is extensive (e.g the intro to Frameworks)