This week's book giveaway is in the OCAJP forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide 1Z0-808 and have Jeanne Boyarsky & Scott Selikoff on-line! See this thread for details.
Actually, OS X is not Linux-based, but it is a UNIX variant (based upon FreeBSD code if I understand correctly). The only environment variable I recall setting up was JAVA_HOME which was set to /Library/Java/Home.