DISCLAIMER: This is a continuing series detailing the painful story of a DIY render farm build. It is terribly technics and
somewhat frustrating. Those who are unprepared for such “entertainment” are advised to ignore these posts.
PDC on the Office iMac
To prepare the office iMac to be the PDC, I needed to establish the environment for building software. Some tools already exist on the Mac, but quite a few must be installed. That’s because most folks don’t build software, thus they don’t have to ship a Mac with everything required to do software development already on it – that would be superfluous for most people. But the development tools are all free, and always have been, so there’s no worry getting what you need. The same is true of Windows, of course. Linux distributions always have everything already built-in, which is why the real Linux-heads are always bragging that everyone else’s OS is a toy. Mac OS is, of course, just BSD Unix under the hood, and it takes no real effort to set up for building sources, so the Linux-head’s brag is a bit dumb.
First I installed MacPorts software for 10.7, the operating system I have on the office iMac. MacPorts is a project for helping with command-line Open Source projects. Though Open Source stuff tends to work for everyone, it needs little tweaks here and there for the various flavors of Linux. MacPorts keeps track of all the software that works with the Mac kernel, which is also called “Darwin.”
Then I installed Xcode command line tools for 10.7. This is free development software available from Apple.
Then the Dr. Queue install instructions told me to install “scons.” I had no idea what Scons is. It seems to stand for “S Construct” and is integral to building Dr. Queue. This is another port, and can be had by opening up the Mac “terminal” application and typing the following:
sudo port install scons
“Sudo” stands for “Super User Do,” and is the way to tell Unix that you mean business, that you are an administrator, you have a password, and it needs to do as you say regardless of permissions. This is, essentially, a command to “port,” (the MacPorts software) to install scons.
This worked fine, except one of the dependencies of scons is GTK2, and so the scons install failed. GTK2 stands for “Graphics Tool Kit 2.” It is a set of software tools to get a command line program working with an X11 environment. And what is X11? X11 is another name for the X Window System, which is a framework for a GUI environment. It’s the way Unix and Linux command line programs use a graphical interface. Why did I need it? Because Dr. Queue can be run either as a command-line program (lots of typing, black and white windows of text) or as a Graphic User Interface (GUI), i.e., pretty window with buttons.
Ordinarily these terminal programs run as lines of text on the screen, which is very 1970s. It’s fast, and it’s bare-bones, but I’m probably going to want something friendlier. I’m not comfortable running the whole render farm through the command line. Why can’t the command-line program use the normal OSX GUI, like all the windows and buttons and everything we’re used to? Well, if the program was designed to work with Mac-only stuff, you’d have Windows and Linux people complaining. So apparently coding for X11 means that everyone can run it with the least number of changes.
This is changing as software authors code to use a web interface, which is even easier.
So, in order to get GTK2 running, I must do a wget for the latest binary. Wget is a command line routine to “get” a needed file. If you know where the source is stored (called a “repository”) you can retrieve it. Wget is not the only method, there’s another one called “curl.” Typing in “wget” and the URL of the source is all it takes.
So this is all a command-line cool guy way of doing what we’d normally do by downloading a file through a web browser. Even though it was getting complicated, I had to admit that this was also quite elegant.
GTK2 takes forever to build, though, and I was going to have some down time. So I set it up to do what it was supposed to, hit the return button, and waited.