There have been some troubles with compiling the Blinkenlights toolkit on Mac OS X and other BSD UNIX operating systems due to the heritage of the code (our production system is running on Debian Linux) but most of these issues have been ironed out and the current release of
blinkentools can be brought to OS X quite easily. Well, I say „quite“ as compiling UNIX software is not for everybody. So I‘ll go ahead and describe a viable procedure that involves Darwin Ports, the upcoming package standard for Mac OS X.
Readers of this blog might wonder now because I have referred to the rival system fink quite often recently. I have been using fink for a long time and it somehow worked. I had trouble with early versions of Darwin Ports instead so I put it on hold. Running into troubles with fink‘s package dependencies I decided to give Darwin Ports another try. And, surprise! Its not only working, it is a damn good tool right now.
Here are the steps you have to take in an overview. I‘ll describe each step afterwards in detail. If you have already installed Darwin Ports, you can skip the first two steps. If you have installed glib2 and gtk2 by means of other tools like fink (or no tools at all) you can skip to step four.
- Make sure you have installed the Mac OS X Developer Tools and Apple‘s X11
- Get the Darwin Ports base package and ports collection via CVS
- Compile and install the Darwin Ports base package
- Install glib2 and gtk2 via Darwin Ports
- Download and install
- Run X11 and
X11 – the UNIX windowing system – is part of CD 3 of Mac OS X. If you haven‘t explicitly selected it when you installed MAc OS X you might have to reinstall it from that CD. That is easy.
The Developer Tools are a part of the Mac OS X distribution. Install the default system plus the X11 SDK. Don‘t uncheck the BSD subsystem.
Follow the instructions on the Get DarwinPorts page to extract the files from CVS. This will result in a directory tree at the place where you execute the commands.
Change into the „darwinports/base“ directory and type ./configure then make and finally sudo make install to configure, build and install the base package. This makes the
port command available to your system.
The DarwinPorts get installed into
/opt/local by default. Add
/usr/local/sbin to your
PATH environment variable so that you can actually use it without typing the full path all the time.
Install these modules by simply typing
"sudo port install gtk2". This will install glib2 as well, as gtk2 depends on it. The DarwinPorts system manages all the dependencies for you and will install a couple of other packages as well. Don‘t bother. Most of them are needed for many other packages as well and can be considered to be a basic building block of your UNIX subsystem.
Compiling and installing all these packages takes a while. Get a coffee.
Get the three tarballs from http://sven.gimp.org/blinkenlights/. Then, extract the files.
blib first: enter the unpacked directory, type ./configure --prefix=/opt/local then make and finally sudo make install. This will place blib in the
/opt/local/lib directory. Then add the environment variable
/opt/local/lib/pkgconfig. When this is done, repeat the above procedure with
The compilation of the packages has created the
blinkensim-gtk command. This is blinkensim running on top of GTK. For Linux, there is a second option for DirectFB which is not available on Mac OS X yet.
Everything should be fine now. To run the Blinkenlights simulator start the X11 application residing in /Applications/Utilities. This brings up a
xterm terminal window. From within this terminal window type:
/opt/local/bin/blinkensim-gtk hdl-640x480 proxy.blinkenlights.de
You should now see the current data stream of the building on your screen in full glory. If only the simulator appears but no images, the stream is either down or your firewall or router does not allow UDP traffic to your computer.
There are other resolutions and themes available. You can view the other installed themes by invoking blinkensim-gtk --list.