Imprudence talk:Compiling

I just bought a Mac Mini for the purposes of compiling Imprudence releases on it, and to help testing out Mac specific issues. Here I'll keep track of progress so that I can update the Mac building instructions.

goals
There are two goals. The first is to figure out how to produce a proper Mac OSX package. The second is to figure out how to script the entire process. The scripted version will be added to my release building script that already knows how to build releases for Linux and Windows. Hopefully the script can drive the Mac build process via ssh. At the moment the Mac build instructions are largely GUI driven, so this might be a challenge. On the other hand, the Windows build script makes use of my Linux build system, oddly enough, so there's hope, since Mac OSX is Unix at heart.

side goals
Mac OSX seems to have some sort of remote desktop thingy. See if I can send that to my Linux main box. See if it's good enough for 3D. Apparently it's some variation of VNC, some people report good and bad results using standard VNC clients. Ordinary VNC works fine so far. I can get rid of my second mouse and keyboard. Though a proper HDMI KVM would be better, but that's for next time I have some spare cash.

See if I can get mc running without too much trouble, coz I use it for everything. Seems it's not in homebrew. I managed to get it running under Win XP. B-)

Mac OSX has some system for installing and running Windows. See if it's good enough for 3D. And building the Impy release. B-)

the build box
This is a 2012 unibody Mac Mini 2.3GHz quad core i7, with 4GB of RAM and a 1TB hard drive. The graphics is Intel HD 4000 with 512MB shared memory. Apparently this is not so good for 3D graphics and video. It comes installed with Mac OSX 10.8.3 Mountain Lion. It was chosen coz it's cheap, and I can hook it up to existing monitor, keyboard, and mouse. Building viewers tends to be RAM intensive, 4GB should be enough for a decent build speed. I expect maybe 15 to 30 minutes based on previous experience.

I don't know off the top of my head which version of Mac OSX is the minimum that should be supported. The release building script uses Ubuntu 10.04 LTS and Windows XP as the minimum supported versions. I'll try to keep the OS as virgin as possible, only adding and tweaking as needed to actually do the build.

It seems that just owning a Mac these days means you need an Apple ID, but you need an Apple Developer ID to get the quicktime stuff for building on Windows, and it seems that ID can be reused. Also helps to get XCode it seems.

requisites
The original page says XCode 4.1 or greater for this version of OSX, latest is 5.0.2. Python 2.5, though claims this OSX should have one (2.7.6 or 3.3.3 latest). Perhaps git, though my release build scripts do the git part on the host, which for me is Linux. Cmake 2.4.8 (2.8.12.1 is latest). Apparently some versions of XCode install cmake, some don't. If not, we can use homebrew. Homebrew is git+ruby scripts from what I can tell. So git might be needed after all, which apparently is in XCode anyway. Ruby 1.8.7 is installed.

Ssh server side naturally, it's installed already, disabled by default. From what I understand the components for Mac OSX server are all installed in ordinary OSX.

the procedure

 * Turn on ssh server. System preferences -> Internet & Wireless -> Sharing -> tick "Remote Login" on the left hand side, setup users as you wish.
 * Install XCode 4.6.3 from https://developer.apple.com/downloads/ or the Mac App Store if you prefer.
 * Install command line tools from Xcode menu -> Preferences -> Downloads.
 * Install homebrew
 * ruby -e "$(curl -fsSL https://raw.github.com/mxcl/homebrew/go/install)"