mirror of
https://github.com/golang/go
synced 2024-11-23 04:00:03 -07:00
c17d09a657
This changes the misc/dist program to generate OS X packages using pkgbuild and productbuild. The productbuild utility makes it easy to generate packages with a custom Distribution file. This allows us to add an installcheck script that presents a friendly message to users who are running on an old version of Mac OS X. The change also fixes a few issues with the postinstall script: - In-repo version of the script has been made executable. Installers generated using the new tools couldn't execute it otherwise. - It now uses -d for checking for the existence of the Xcode specs directory. - The call to sudo.bash has been dropped since cov and prof aren't bundled with the binary distributions. Fixes #3455. Tested on 10.5.8, 10.6.0, 10.6.8 and 10.7.3. R=adg, golang-dev CC=golang-dev https://golang.org/cl/5987044
19 lines
415 B
Bash
Executable File
19 lines
415 B
Bash
Executable File
#!/bin/bash
|
|
|
|
GOROOT=/usr/local/go
|
|
|
|
echo "Fixing permissions"
|
|
cd $GOROOT
|
|
find . -exec chmod ugo+r \{\} \;
|
|
find bin -exec chmod ugo+rx \{\} \;
|
|
find . -type d -exec chmod ugo+rx \{\} \;
|
|
chmod o-w .
|
|
|
|
echo "Installing miscellaneous files:"
|
|
XCODE_MISC_DIR="/Library/Application Support/Developer/Shared/Xcode/Specifications/"
|
|
if [ -d "$XCODE_MISC_DIR" ]; then
|
|
echo " XCode"
|
|
cp $GOROOT/misc/xcode/* $XCODE_MISC_DIR
|
|
fi
|
|
|