If you conveniently edit files, you can set the library path in the script's internal launch. I edited this via Terminal.app and vim, going to:
cd <wherever SQL Developer was installed/unzipped> cd SQLDeveloper.app/Contents/MacOS cp -p sqldeveloper.sh sqldeveloper.sh.backup chmod o+w sqldeveloper.sh vim sqldeveloper.sh
The file is protected by default, so I change it to write access (and first make a backup, just in case). If you skip this step, using vim you can save it with :w! to save it anyway.
Alternatively, locate the SQLDeveloper application in Finder, right-click and select “Show Package Contents”, then expand it to “Contents”> “MacOS”, right-click the sqldeveloper.sh file and select “Open With” and your favorite text editor - TextEdit will do. When the file is locked, you will be prompted to unlock it at some point - perhaps during open or first editing, but TextEdit will ask you if you want to unlock it when saving.
However, you get to the file, then you can specify the addition of a line to set / export DYLD_LIBRARY_PATH :
#!/bin/bash # Next line added for TNS connections export DYLD_LIBRARY_PATH=/path/to/instantclient export JAVA_HOME=`/usr/libexec/java_home -v 1.7` here="${0%/*}" cd "${here}" cd ../Resources/sqldeveloper/sqldeveloper/bin bash ./sqldeveloper -clean >>/dev/null
... where /path/to/instantclient is your unpacked directory; in the example above, it would be /bin/oracle/instantclient_11_2 . Also note that this must be a 64-bit instant client; he will complain about the wrong architecture if you try to use the 32-bit version.
Once the modified file has been saved, restart SQL Developer and your TNS connection should now work. If you want to use the TNS alias, you can also set / export the TNS_ADMIN variable, which points to the directory containing the tnsnames.ora file.