To build libyarn, the following libraries are needed.
cmake (2.8+) http://www.cmake.org/ boost (tested on 1.53+) http://www.boost.org/ google protobuf http://code.google.com/p/protobuf/ libxml2 http://www.xmlsoft.org/ kerberos http://web.mit.edu/kerberos/ libuuid http://sourceforge.net/projects/libuuid/
To run tests, the following library is needed.
gtest (tested on 1.7.0) already integrated in the source code gmock (tested on 1.7.0) already integrated in the source code
To run code coverage test, the following tools are needed.
gcov (included in gcc distribution) lcov (tested on 1.9) http://ltp.sourceforge.net/coverage/lcov.php
Assume libyarn home directory is LIBYARN_HOME.
cd LIBYARN_HOME mkdir build cd build ../bootstrap
Environment variable CC and CXX can be used to setup the compiler. Script “bootstrap” is basically a wrapper of cmake command, user can use cmake directly to turn the configuration.
Run command “../bootstrap --help” for more configuration.
Run command to build
To build concurrently, rum make with -j option.
To do unit test, run command
To do function test, first start YARN, and create the function test configure file at LIBYARN_HOME/test/data/function-test.xml, an example can be found at LIBYARN_HOME/test/data/function-test.xml.example. And run command.
To show code coverage result, run command. Code coverage result can be found at BUILD_DIR/CodeCoverageReport/index.html
To install libyarn, run command