[MacOS] make package cannot complete on Big Sur
The title says what's going wrong. Big Sur (MacOS 11) cannot make a proper make package build. This is for 2 reasons. Detailed below.
rpath being broken causes huge issues. Specifically with libpng, libSDL2, and libgme. The skip rpath flag doesn't work so the user is forced to run a ton of commands with install_name_tool to fix the rpath issues.
But even then it still does not build. It will attempt to package libraries that do not appear to be referenced inside the executable at all.
otool -L output (These are the paths it uses to package these libraries)
resulting error from cpack when running make package
Because these libraries are not actually referenced inside the executable itself this is impossible to fix via install_name_tool because it cannot change what doesn't exist and you cannot add a link to an executable.
symlinking the needed dylib files also does not work
What actually is happening is cpack is trying to grab a library from the current working directory. The only way I could see this being worked around is by placing the build files inside the directory holding the dylib file (being /usr/local/lib in my case)
This is a huge issue and prevents any macOS users running 11.0+ from making an actually sharable build of the game without downgrading their Mac.