tpoechtrager / osxcross

Mac OS X cross toolchain for Linux, FreeBSD, OpenBSD and Android (Termux)
GNU General Public License v2.0
2.92k stars 329 forks source link

Make gen_sdk_package.sh better at finding SDKs #350

Closed DavidEGrayson closed 2 years ago

DavidEGrayson commented 2 years ago

I was using an older version of this script and eventually it stopped working because it was only designed to work for macOS version 10, and didn't anticipate version 11 or 12 being released.

In order to prevent that from happening again in a year or two, this pull request removes the hardcoded version numbers and uses a more general regular expression to find SDKs. Additionally, I fixed it so that an error message is shown if no SDKs are found, which was the original intent of the code.