diff --git a/gitian-building.md b/gitian-building.md index 72259f9..d794501 100644 --- a/gitian-building.md +++ b/gitian-building.md @@ -48,10 +48,6 @@ Non-Debian / Ubuntu, Manual and Offline Building ------------------------------------------------ The instructions below use the automated script [gitian-build.py](https://github.com/bitcoin/bitcoin/blob/master/contrib/gitian-build.py) which only works in Debian/Ubuntu. For manual steps and instructions for fully offline signing, see [this guide](./gitian-building/gitian-building-manual.md). -MacOS code signing ------------------- -In order to sign builds for macOS, you need to download the free SDK and extract a file. The steps are described [here](./gitian-building/gitian-building-mac-os-sdk.md). Alternatively, you can skip the macOS build by adding `--os=lw` below. - Initial Gitian Setup -------------------- The `gitian-build.py` script will checkout different release tags, so it's best to copy it: @@ -76,6 +72,18 @@ git remote add $NAME git@github.com:$NAME/gitian.sigs.git Where `satoshi` is your GitHub name. +macOS code signing +------------------ +In order to sign builds for macOS, you need to download the free SDK and extract a file. +The steps are described [here](https://github.com/bitcoin/bitcoin/blob/master/contrib/macdeploy/README.md#sdk-extraction). +Copy the extracted SDK file into the `gitian-builder/inputs` directory: +```bash +mkdir -p gitian-builder/inputs +cp 'path/to/extracted-SDK-file' gitian-builder/inputs +``` + +Alternatively, you can skip the macOS build by adding `--os=lw` below. + Build binaries ----------------------------- Windows and macOS have code signed binaries, but those won't be available until a few developers have gitian signed the non-codesigned binaries. diff --git a/gitian-building/gitian-building-mac-os-sdk.md b/gitian-building/gitian-building-mac-os-sdk.md deleted file mode 100644 index fb2463b..0000000 --- a/gitian-building/gitian-building-mac-os-sdk.md +++ /dev/null @@ -1,56 +0,0 @@ -Gitian building Mac OS SDK -========================== - -On the host machine, register for a free Apple [developer account](https://developer.apple.com/register/), then download the SDK [here](https://developer.apple.com/devcenter/download.action?path=/Developer_Tools/Xcode_7.3.1/Xcode_7.3.1.dmg). - -MacOS host --------- - -Using macOS, you can mount the dmg, and then extract the SDK with: -``` - $ hdiutil attach Xcode_7.3.1.dmg - $ tar -C /Volumes/Xcode/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/ -czf MacOSX10.11.sdk.tar.gz MacOSX10.11.sdk -``` - -Clean up the files you don't need: - -```sh -diskutil unmount /Volumes/Xcode -rm Xcode_7.3.1.dmg -``` - -Non-MacOS host: --------- - -Alternatively, you can use 7zip and SleuthKit to extract the files one by one. -The script [extract-osx-sdk.sh](https://github.com/bitcoin/bitcoin/blob/master/contrib/macdeploy/extract-osx-sdk.sh) automates this. First ensure -the dmg file is in the current directory, and then run the script. - -You may wish to delete the intermediate 5.hfs file and MacOSX10.11.sdk (the directory) when -you've confirmed the extraction succeeded. - -```bash -apt-get install p7zip-full sleuthkit -contrib/macdeploy/extract-osx-sdk.sh -rm -rf 5.hfs MacOSX10.11.sdk -``` - -Copy SDK to Gitian VM: ----------------------- -Copy it to the Gitian VM and clean up, e.g.: - -```bash -scp MacOSX10.11.sdk.tar.gz gitian: -rm MacOSX10.11.sdk.tar.gz -``` - -Login to the VM and: - -```bash -mkdir -p gitian-builder/inputs -mv MacOSX10.11.sdk.tar.gz gitian-builder/inputs -``` - -Troubleshooting ---------------- -See [build-osx.md](https://github.com/bitcoin/bitcoin/blob/master/doc/build-osx.md#deterministic-macos-dmg-notes) for troubleshooting tips.