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.

Difference between revisions of "OLA on Linux"

From wiki.openlighting.org

Jump to: navigation, search
(Added new section about known issues)
Line 64: Line 64:
 
   make
 
   make
  
 +
Run the tests
 +
  make check
 +
 +
And install OLA
 +
  sudo make install
 +
  sudo ldconfig
 +
 +
=Install ola-examples=
 +
 +
The [[OLA Command Line Tools]] come separately. Again either download a tarball or checkout from the git repo:
 +
 +
  git clone http://www.nomis52.net/git/lla-examples
 +
 +
The steps are similar to building the main package.
 +
 +
  autoreconf -i  # if you used the git repo
 +
  ./configure
 +
  make
 +
  sudo make install
 +
 +
Note in order for ola_dmxmonitor and ola_dmxconsole to build you *must* have curses installed.
 +
 +
=Known Issues=
  
 
If you get an error like the following:
 
If you get an error like the following:
Line 82: Line 105:
 
and then start from the autoreconf step again.
 
and then start from the autoreconf step again.
  
Run the tests
+
If you should get the following error try to fix it with one of [http://groups.google.com/group/open-lighting/msg/72060f6327d30df6 two available solutions]:
  make check
 
  
And install OLA
+
Rpc.pb.cc: In copy constructor 'ola::rpc::RpcMessage::RpcMessage(const ola::rpc::RpcMessage&)':
  sudo make install
+
Rpc.pb.cc:143: error: base class 'class google::protobuf::Message' should be explicitly initialized in the copy constructor
  sudo ldconfig
 
  
=Install ola-examples=
+
A similar error can occur when building the ola-examples package:
  
The [[OLA Command Line Tools]] come separately. Again either download a tarball or checkout from the git repo:
+
g++ -DHAVE_CONFIG_H -I. -I..    -Wall -Werror -I/usr/local/include/
 +
libola  -g -O2 -MT ola-dmxconsole.o -MD -MP -MF .deps/ola-
 +
dmxconsole.Tpo -c -o ola-dmxconsole.o ola-dmxconsole.cpp
 +
cc1plus: warnings being treated as errors
 +
ola-dmxconsole.cpp: In function ‘void mask()’:
 +
ola-dmxconsole.cpp:150: error: value computed is not used
 +
ola-dmxconsole.cpp:156: error: value computed is not used
 +
ola-dmxconsole.cpp: In function ‘void values()’:
 +
ola-dmxconsole.cpp:184: error: value computed is not used
 +
ola-dmxconsole.cpp:188: error: value computed is not used
 +
ola-dmxconsole.cpp:190: error: value computed is not used
 +
ola-dmxconsole.cpp:194: error: value computed is not used
 +
ola-dmxconsole.cpp:197: error: value computed is not used
 +
ola-dmxconsole.cpp:202: error: value computed is not used
 +
ola-dmxconsole.cpp:205: error: value computed is not used
 +
ola-dmxconsole.cpp:208: error: value computed is not used
 +
ola-dmxconsole.cpp:215: error: value computed is not used
 +
ola-dmxconsole.cpp:225: error: value computed is not used
 +
ola-dmxconsole.cpp:226: error: value computed is not used
 +
ola-dmxconsole.cpp:227: error: value computed is not used
 +
make[2]: *** [ola-dmxconsole.o] Error 1
  
  git clone http://www.nomis52.net/git/lla-examples
+
You should be able to prevent this by [http://groups.google.com/group/open-lighting/msg/c6d86d03dd74ed5b editing <code>./src/Makefile.am</code>], removing <code>-Werror</code> and then start from the autoreconfig step again.
 
 
The steps are similar to building the main package.
 
 
 
  autoreconf -i  # if you used the git repo
 
  ./configure
 
  make
 
  sudo make install
 
 
 
Note in order for ola_dmxmonitor and ola_dmxconsole to build you *must* have curses installed.
 

Revision as of 13:17, 1 July 2011

This describes how to get OLA working on a Linux system either from the git repo or by using a released tarball.

Checkout or Download an Archive

Either download a tarball from the releases page, or check out the git repo with the following command:

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

If you don't have git yet, you'll need to install it with your distro's package manager.

Install libraries

You need a couple of libraries installed for everything to work correctly. Some of these are available as packages in distros but others need to be downloaded and built manually.

First up you'll need the following:

  • cppunit
  • uuid or ossp uuid
  • pkg-config
  • curses


Debian/Ubuntu users can install them with apt:

 apt-get install libcppunit-dev libcppunit-1.12-1 uuid-dev pkg-config libncurses5-dev  zlib1g-dev

If you're building from git you'll also need the following:

  • libtool
  • automake
  • autoconf
 apt-get install libtool autoconf automake


Next, you need Protocol Buffers http://code.google.com/p/protobuf/ version 2.3.0 from Google (BSD license). Most likely, you'll need to download and build them yourself. Note that 2.4.0 won't work yet as some of the functionality has changed.

Debian (and Ubuntu) users can, in some cases, use the following packages (not yet in stable): libprotobuf2 (libprotobuf3), libprotobuf-dev, protobuf-compiler


Finally, if you want to use the built in webserver, you'll need microhttpd. Note: you'll need version >= 0.4.0 of microhttpd else you will get errors:


Once everything is installed, run ldconfig as root to pick up the new libraries

 sudo  ldconfig

Configure

If you checked out the sources from git, you'll need to run

 autoreconf -i

After that run

 ./configure

Building & Testing

Build

 make

Run the tests

 make check

And install OLA

 sudo make install
 sudo ldconfig

Install ola-examples

The OLA Command Line Tools come separately. Again either download a tarball or checkout from the git repo:

 git clone http://www.nomis52.net/git/lla-examples

The steps are similar to building the main package.

  autoreconf -i   # if you used the git repo
  ./configure
  make
  sudo make install

Note in order for ola_dmxmonitor and ola_dmxconsole to build you *must* have curses installed.

Known Issues

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:

 libtoolize --ltdl -c -f

and then start from the autoreconf step again.

If you should get the following error try to fix it with one of two available solutions:

Rpc.pb.cc: In copy constructor 'ola::rpc::RpcMessage::RpcMessage(const ola::rpc::RpcMessage&)': 
Rpc.pb.cc:143: error: base class 'class google::protobuf::Message' should be explicitly initialized in the copy constructor 

A similar error can occur when building the ola-examples package:

g++ -DHAVE_CONFIG_H -I. -I..    -Wall -Werror -I/usr/local/include/ 
libola   -g -O2 -MT ola-dmxconsole.o -MD -MP -MF .deps/ola- 
dmxconsole.Tpo -c -o ola-dmxconsole.o ola-dmxconsole.cpp 
cc1plus: warnings being treated as errors 
ola-dmxconsole.cpp: In function ‘void mask()’: 
ola-dmxconsole.cpp:150: error: value computed is not used 
ola-dmxconsole.cpp:156: error: value computed is not used 
ola-dmxconsole.cpp: In function ‘void values()’: 
ola-dmxconsole.cpp:184: error: value computed is not used 
ola-dmxconsole.cpp:188: error: value computed is not used 
ola-dmxconsole.cpp:190: error: value computed is not used 
ola-dmxconsole.cpp:194: error: value computed is not used 
ola-dmxconsole.cpp:197: error: value computed is not used 
ola-dmxconsole.cpp:202: error: value computed is not used 
ola-dmxconsole.cpp:205: error: value computed is not used 
ola-dmxconsole.cpp:208: error: value computed is not used 
ola-dmxconsole.cpp:215: error: value computed is not used 
ola-dmxconsole.cpp:225: error: value computed is not used 
ola-dmxconsole.cpp:226: error: value computed is not used 
ola-dmxconsole.cpp:227: error: value computed is not used 
make[2]: *** [ola-dmxconsole.o] Error 1 

You should be able to prevent this by editing ./src/Makefile.am, removing -Werror and then start from the autoreconfig step again.