-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Mac builds #318
base: master
Are you sure you want to change the base?
Fix Mac builds #318
Conversation
Merging this PR will most probably leave macOS out of future releases, until another maintainer with Xcode10 enabled environment joins the team. For the time being, Travis CI compiling AI.m and OOTrumble.m fails, complaining about OOViewID.tbl file not found. Our .travis.yml file tells Travis CI to use Xcode 7.3 and my understanding is that this PR's changes break compatibility with Xcode versions less than 10.
Could you update this PR with a .travis.yml having a compatible (with the changes committed) osx_image value? |
Not sure why the HeadUpDisplay.m and OOConstToJSString.m files have been included in this PR. They seem to be removing things that are unrelated to any Mac-specific code. Accidental, perhaps? |
@phkb |
Ah, got it. It's still a little confusing, though, because there doesn't appear to be any difference between the lines being removed and similar ones around them. For instance, why would the Mac have a problem with lines 119-123 of OOConstToJSString.m, when they're almost identical to lines 114-117? Why do those lines compile, but lines 119-123 don't? It's also probably worth noting that, by applying the changes to OOConstToJSString.m, commit 835770b would probably need to be reverted as that change relies on the new table. |
I just tried on a freshly setup Xcode 13.4.1 on MacOS 12.5.1 on a MacBook Air with M1: the libstdc++ errors are fixed, but now the libpng build fails with the messages "error: Build input file cannot be found: '/Users/maikschulz/Documents/projects/oolite/deps/libpng/pngwutil.c' (in target 'libpng' from project 'libpng')", and "error: Build input file cannot be found: '/Users/maikschulz/Documents/projects/oolite/deps/libpng/pngwtran.c' (in target 'libpng' from project 'libpng')" Not sure why Xcode complains about those files, both are there... Edit: fixed, the errors disappeared after I made this change: HEADER_SEARCH_PATHS_QUOTED_1 in the "user-defined" section of the Build Settings for the libpng project should read "$(SRCROOT)" without the additional path behind it Now it is trying to run "PhaseScriptExecution" for libjs which looks for the python command which does not exist anymore... I do have python3 available. Edit: fixed, I installed the final Python 2 release for MaxOS 64 bit from https://www.python.org/downloads/macos/ even though it is not supported anymore... Next it complained about the "volatile" keyword after "asm" in libs/js/methodjit/MethodJIT.c in a number of places. I removed it to go on, but I do not know if that will cause trouble. Compilation finished with these changes, now I am getting an error during linking which I have no idea what to do about it: "ld: malformed universal file: slice content is not mach-o or a static library file '/Users/maikschulz/Documents/projects/oolite/deps/Cocoa-deps/Sparkle/Sparkle.framework/Sparkle'" Edit: first tried to work with Sparkle 1.7 (instead of the included Sparkle 1.5b6), no luck or my poor understanding of what I am doing. Then I kicked out Sparkle from Oolite, this allowed to compile and link. Running it gets me as far as the splash screen, then it errors out, see the Trunk nightly builds thread on the Oolite BB here with others' descriptions of the same result but no one able to resolve since January 2022... From the sound of it a larger effort is needed, or deeper understanding. Would be lovely if you could take a look :) Thank you, kind regards |
4d65277
to
be540a2
Compare
These are the changes required to build with Xcode 10, which will bring back nightly builds. It also updates various project files, breaking compatibility with older versions of Xcode.
Done as a PR because merging this will drop support for Mac OS X 10.6 (the 2009–2010 version).