Closed bucanero closed 4 years ago
I will look at this when I get home. Thanks for the PR.
I'm not comfortable reviewing/merging this one myself personally. I don't use osx and this makes changes that are not backwards-compat, as well as changing sdk target arch.
Maybe one of the Mac guys can chime in and check this out.
I'm not comfortable reviewing/merging this one myself personally. I don't use osx and this makes changes that are not backwards-compat, as well as changing sdk target arch.
Maybe one of the Mac guys can chime in and check this out.
yes, I wasn't thinking about backwards compat, I mostly wanted to get my ps3 dev environment working. I tested the changes with Mojave and Catalina versions of macOS and it worked fine.
I guess that any recent mac user now will be using x64 arch in their computer, but lets see if the mac users can share some feedback too.
Ok, I have looked into this a bit.
I wonder if you can just use $(xcrun --show-sdk-path)
in case the path ever changes.
The path to the SDK apparently changed after snow leopard, so your -mmacosx-version-min=10.14
should be -mmacosx-version-min=10.7
or get this info from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Info.plist
:
Something like:
SDK := $(xcrun --show-sdk-path)
OSX_MIN := $(defaults read /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Info MinimumSDKVersion 2> /dev/null || 10.4)
OSXCFLAGS := -mmacosx-version-min=$(OSX_MIN) -arch x86_64 -arch i386 -arch ppc
Maybe the -arch
can stay -arch x86_64 -arch i386 -arch ppc
, I think it was set to i386 and ppc before because one of those will always run on a mac, whether it is x64 or not.
thanks @miigotu for your research and tips 👍
I'll test on my end changing the Makefiles with these options and confirm everything compiles and runs properly.
I'll update the PR with my results
I've updated the makefiles, now there's no longer hard-coded parameters (sdk path, min version)
I also removed any reference to the -arch
. (works just fine without any specific arch)
This PR updates the Makefiles to support macOS Mojave/Catalina
After installing the required libs/tools using
brew
in a macOS environment, some outdated Makefile parameters required a fix to compile properly.