Upstream commits: realm/realm-cocoa@cb8e3b6 and realm/realm-cocoa@453e0c1
This self-deletes the script during the build script phase. Does not address the CocoaPods use-case.