Here's something that might work:
1. Create a new folder where you extracted the 40d18 archive.
2. Name it "Dwarf Fortress.app", the .app part is the really important thing, and you need to confirm that one.
3. Right-click your new, still empty application bundle, and select Open Package Contents, it'll open a new Finder window.
4. Create a folder inside that named "Contents" and open that one.
5. Create a folder inside Contents named "MacOS"
6. Move "dwarfort.exe" into the MacOS folder you just made
7. Inside the Contents folder (next to the Mac OS folder), create a folder named Frameworks
8. From the "libs" folder from the original archive, move the two folders named something with SDL into the new Frameworks folder
9. Move the entire libs folder, now containing just one file, into the MacOS folder
10. Start Text Edit, make sure you have a blank file, and select Plain Text from the Edit menu.
11. Paste this into Text Edit:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
<string>dwarfort.exe</string>
<key>CFBundleIdentifier</key>
<string>com.bay12games.dwarffortress</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>Dwarf Fortress</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>CSResourcesFileMapped</key>
<true/>
</dict>
</plist>
12. Save the file somewhere, like on the desktop. Name it "Info.plist", you'll need to confirm that too.
13. Move the Info.plist file into the Contents folder in the Dwarf Fortress application bundle
14. Check you have the correct file structure:
Dwarf Fortress.app
+ Contents
+ Frameworks
+ SDL_image.framework
+ SDL.framework
Info.plist
+ MacOS
dwarfort.exe
+ libs
libfmodex.dylib
15. You should now be able to double-click your Dwarf Fortress.app in Finder and start the game.
At least this worked for me. You don't need the "df" script at all for this, and can delete it.