-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathbuild_mac_universal_binary.sh
More file actions
executable file
·25 lines (22 loc) · 1.06 KB
/
build_mac_universal_binary.sh
File metadata and controls
executable file
·25 lines (22 loc) · 1.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/sh
# hgdc-x Mac build script
# Generates universal binary to target Tiger 10.4 and above, Intel and PPC
#
# Assumes all build tools are setup the way I set them up, which did require some
# symlinks and copying of SDKs from Leopard into a Lion install, and concurrent
# installations of XCode 4 and 3.
#
# Copyright Tristan Linnell 2012
#
echo "Building Hgdc-X for Mac OS X..."
echo "Building for Intel..."
lazbuild --build-all --build-mode="Release Mac OS X" hgdcx.lpi &&
echo "Building for PowerPC..." &&
lazbuild --compiler="/usr/local/bin/ppcppc" --cpu=powerpc --build-all --build-mode="Release Mac OS X" hgdcx.lpi &&
echo "Stripping binaries..." &&
strip ./build/release/powerpc-darwin-carbon/hgdcx &&
strip ./build/release/i386-darwin-carbon/hgdcx &&
echo "Making Universal Binary..." &&
lipo -create ./build/release/powerpc-darwin-carbon/hgdcx ./build/release/i386-darwin-carbon/hgdcx -output ./build/release/universal-darwin-carbon/Hgdc-X.app/Contents/MacOS/hgdcx &&
touch ./build/release/universal-darwin-carbon/Hgdc-X.app &&
echo "Build Succeeded!"