From 3784484b1624dbccf0c132474f1f15c9c59824a5 Mon Sep 17 00:00:00 2001 From: Pavel Kirienko Date: Wed, 10 Jun 2015 20:30:10 +0300 Subject: [PATCH] Installation updates --- README.md | 26 +++++++++++++++++++++++++- libuavcan/CMakeLists.txt | 1 - 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index bf00737f61..5bc4f05aa3 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,9 @@ UAVCAN is a lightweight protocol designed for reliable communication in aerospac ### Dependencies * Python 2.7 or 3.2 or newer -* [Pyuavcan](http://uavcan.org/Pyuavcan) + +Note that this reporitory includes [pyuavcan](http://uavcan.org/Pyuavcan) as a submodule. +Such inclusion enables the library to be built even if pyuavcan is not installed in the system. ### Cloning the repository @@ -32,6 +34,28 @@ git submodule update --init If this repository is used as a git submodule in your project, make sure to use `--recursive` when updating it. +### Building and installing + +This is only needed if the library is used in a Linux application. + +```bash +mkdir build +cd build +cmake .. # Default build type is RelWithDebInfo, which can be overriden if needed. +make -j8 +sudo make install +``` + +The following components will be installed into the system: + +* Libuavcan headers and the static library +* Generated DSDL headers +* Libuavcan DSDL compiler (Python script `libuavcan_dsdlc`) +* Libuavcan DSDL compiler's support library (Python package `libuavcan_dsdl_compiler`) + +Pyuavcan will not be installed into the system together with the library; you'll need to install it separately. +The installed DSDL compiler will not function unless pyuavcan is installed. + ## Library development Despite the fact that the library itself can be used on virtually any platform that has a standard-compliant diff --git a/libuavcan/CMakeLists.txt b/libuavcan/CMakeLists.txt index 0c49b5496f..cafb717fca 100644 --- a/libuavcan/CMakeLists.txt +++ b/libuavcan/CMakeLists.txt @@ -68,7 +68,6 @@ add_dependencies(uavcan libuavcan_dsdlc) install(TARGETS uavcan DESTINATION lib) install(DIRECTORY include/uavcan DESTINATION include) install(DIRECTORY include/dsdlc_generated/uavcan DESTINATION include) # Generated and lib's .hpp -install(DIRECTORY src DESTINATION src/uavcan) install(CODE "execute_process(COMMAND ./setup.py install --record installed_files.log WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/dsdl_compiler)")