Add wrong platform error to all built frameworks

If any of these `exit 1` are hit, you would end up having a corrupt file. I'd rather have no file at all, so how about storing the text in a variable before writing it to the file?