-
Notifications
You must be signed in to change notification settings - Fork 61
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
Extract 10.12 SDK from Xcode 8.3.3 (to do before release of macOS 10.13/Xcode 9) #37
Comments
My findings were similar. The script would have to supply a tool that can decode pbzx streams, since macOS doesn't provide one. Besides pbzx.c, another option is parse_pbzx2.py, which works with the system's Python. This successfully extracted the entire archive:
Ideally the script would extract just the path we need, and both |
Solved it: as confirmed by
(see also this Q&A) |
This version of parse_pbzx.py supports decompression and pipes, allowing the final command sequence to be:
resulting in a 9GB package from which the SDK can be extracted. Since it takes a while to perform the extraction, even on a modern SSD-equipped system, it might be smart to wrap the command in a function that provides a progress bar or spinner in the terminal output. |
Any further progress or comment on this issue, or is this a showstopper? |
You can still download it from https://github.com/phracker/MacOSX-SDKs/releases . |
I've had success elsewhere with live-downloading-and-patching another tool within a script to accomplish a similar task. I can attempt to put a PR together. |
@devernay I can manually download the SDK, no problem. I guess I'm questioning what to do WITH the SDK once I have it...will the existing script patch everything in Xcode 9.x with the exception of the 10.12 SDK and I just copy that into Xcode after patching? |
use the latest github version. 6956e79 installs the file at the right place |
temporary fix in XcodeLegacy 2.1 |
Evidently you also need to re-download 10.7-10.11 from the same github link above - the current XcodeLegacy.sh won't recognize the SDKs already extracted from older Xcode versions (due to naming, likely). Was that intended? |
no it wasn't, it should check for both |
I re-ran the -buildpackages section, and the XcodeSDK* files are there, but -install would not use them. Downloading the SDKs from the github site and placing the .xz files in the same folder did work, however. |
juste fixed it. re-download and execute XcodeLegacy install, it should recognize the old packages again |
Xcode 8.3.3 is distributed as a xip archive.
I managed to extract something from it by:
There seems to be errors during the extraction. Are these fatal?
That also means XcodeLegacy.sh has to rely on the pbzx tool (if not available, the script could give the recipe to compile and install it in /usr/local/bin - it does not seem to be available from MacPorts or homebrew)
As noted in #24 (comment) we cannot distribute the SDKs. They are available here but this infringes the Xcode licence. Maybe we could just let the user download the SDK from that source?
see also:
https://stackoverflow.com/questions/40414645/how-to-extract-xip-archive-using-command-line
The text was updated successfully, but these errors were encountered: