Personal tools
The Open Lighting Project has moved!

We've launched our new site at www.openlighting.org. This wiki will remain and be updated with more technical information.

OLA on OS X

From wiki.openlighting.org

Revision as of 10:58, 4 February 2011 by 67.218.102.97 (talk) (Optionally install microhttpd and ctemplate)
Jump to: navigation, search

This page describes how to get OLA working on OS X, by downloading and compiling the source code.

If you just want to get OLA working and aren't a developer consider using the Mac Installer (.dmg file) to install a pre-compiled version available here.


Basic setup

Use Mac Ports to install stuff

$ port install pkgconfig cppunit unittest-cpp protobuf-cpp 

Set some env vars

set $PATH to point to something sane:

export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig
export CPPFLAGS="-I/opt/local/include/"
export LDFLAGS="-L/opt/local/lib/"

Optionally install microhttpd

If you want the web interface you need these

sudo port install libgcrypt

or you can disable https support (which works with OLA) by using the configure line "./configure --enable-https=no"

  • Make sure you build AND install this before running "./configure" on OLA otherwise it will not detect the libraries and ignore all the HTTP server code

Checkout OLA or Download the tarball

 git clone http://git.opendmx.net/ola
 cd ola

or

 wget $ola_url
 tar -zxf $ola_file
 cd lla

Run autoreconf

If this is the first time run with -i to install the missing files

autoreconf -i

Do the usual steps

./configure
make
make check
sudo make install


Common Problems

Architectures

Snow Leopard builds binaries as 64bit by default. If you need to build as 32bit use the following to configure:

 CPPFLAGS="-arch i386"  LDFLAGS=" -arch i386" ./configure

Then, build using:

 make CPPFLAGS="-arch i386"  LDFLAGS="-arch i386"

Note you'll need to do the same when you run make check:

 make CPPFLAGS="-arch i386"  LDFLAGS="-arch i386" check

ltdl/libtool

If you get an error like the following:

/bin/sh ./libtool --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.   -I/opt/local/var/macports/software/protobuf-cpp/2.0.3_0/opt/local/include/  -g -O2 -c -o ltdl.lo ltdl.c
./libtool: line 464: CDPATH: command not found
/Users/simonn/lighting/lla/libltdl/libtool: line 464: CDPATH: command not found
/Users/simonn/lighting/lla/libltdl/libtool: line 1142: func_opt_split: command not found
libtool: Version mismatch error.  This is libtool 2.2.6, but the
libtool: definition of this LT_INIT comes from an older release.
libtool: You should recreate aclocal.m4 with macros from libtool 2.2.6
libtool: and run autoconf again.

Your system uses a different version of libtool. Run:

 glibtoolize --ltdl -c -f

and then start from the autoreconf step again. This problem shouldn't in releases >= 0.7.0