CMake installation¶
This section explains how to compile eProsima Fast DDS Spy with CMake, either locally or globally.
Local installation¶
Open a command prompt, and create a
fastdds-spy
directory where to download and build eProsima Fast DDS Spy and its dependencies:mkdir <path\to\user\workspace>\fastdds-spy mkdir <path\to\user\workspace>\fastdds-spy\src mkdir <path\to\user\workspace>\fastdds-spy\build cd <path\to\user\workspace>\fastdds-spy wget https://raw.githubusercontent.com/eProsima/Fast-DDS-Spy/main/fastddsspy.repos vcs import src < fastddsspy.repos
Compile all dependencies using CMake.
-
cd <path\to\user\workspace>\fastdds-spy mkdir build\foonathan_memory_vendor cd build\foonathan_memory_vendor cmake <path\to\user\workspace>\fastdds-spy\src\foonathan_memory_vendor -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install ^ -DBUILD_SHARED_LIBS=ON cmake --build . --config Release --target install
-
cd <path\to\user\workspace>\fastdds-spy mkdir build\fastcdr cd build\fastcdr cmake <path\to\user\workspace>\fastdds-spy\src\fastcdr -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install cmake --build . --config Release --target install
-
cd <path\to\user\workspace>\fastdds-spy mkdir build\fastdds cd build\fastdds cmake <path\to\user\workspace>\fastdds-spy\src\fastdds -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install ^ -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --config Release --target install
-
# CMake Utils cd <path\to\user\workspace>\fastdds-spy mkdir build\cmake_utils cd build\cmake_utils cmake <path\to\user\workspace>\fastdds-spy\src\dev-utils\cmake_utils -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install ^ -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --config Release --target install # C++ Utils cd <path\to\user\workspace>\fastdds-spy mkdir build\cpp_utils cd build\cpp_utils cmake <path\to\user\workspace>\fastdds-spy\src\dev-utils\cpp_utils -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install ^ -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --config Release --target install
-
# ddspipe_core cd <path\to\user\workspace>\fastdds-spy mkdir build\ddspipe_core cd build\ddspipe_core cmake cd <path\to\user\workspace>\fastdds-spy\src\ddspipe\ddspipe_core -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --target install # ddspipe_yaml cd <path\to\user\workspace>\fastdds-spy mkdir build\ddspipe_yaml cd build\ddspipe_yaml cmake <path\to\user\workspace>\fastdds-spy\src\ddspipe\ddspipe_yaml -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --target install # ddspipe_participants cd <path\to\user\workspace>\fastdds-spy mkdir build\ddspipe_participants cd build\ddspipe_participants cmake <path\to\user\workspace>\fastdds-spy\src\ddspipe\ddspipe_participants -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --target install
-
Once all dependencies are installed, install eProsima Fast DDS Spy:
# fastddsspy_participants cd <path\to\user\workspace>\fastdds-spy mkdir build\fastddsspy_participants cd build\fastddsspy_participants cmake <path\to\user\workspace>\fastdds-spy\src\fastddsspy\fastddsspy_participants ^ -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --config Release --target install # fastddsspy_yaml cd <path\to\user\workspace>\fastdds-spy mkdir build\fastddsspy_yaml cd build\fastddsspy_yaml cmake <path\to\user\workspace>\fastdds-spy\src\fastddsspy\fastddsspy_yaml -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install ^ -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --config Release --target install # fastddsspy_tool cd <path\to\user\workspace>\fastdds-spy mkdir build\fastddsspy cd build\fastddsspy cmake <path\to\user\workspace>\fastdds-spy\src\fastddsspy\fastddsspy_tool -DCMAKE_INSTALL_PREFIX=<path\to\user\workspace>\fastdds-spy\install ^ -DCMAKE_PREFIX_PATH=<path\to\user\workspace>\fastdds-spy\install cmake --build . --config Release --target install
Note
By default, eProsima Fast DDS Spy does not compile tests.
However, they can be activated by downloading and installing Gtest
and building with CMake option -DBUILD_TESTS=ON
.
Global installation¶
To install eProsima Fast DDS Spy system-wide instead of locally, remove all the flags that appear in the configuration steps of Fast-CDR
, Fast-DDS
, Dev-Utils
, DDS-Pipe
, and fastdds-spy