### Project and Subdirectory Setup Source: https://github.com/szechyjs/mbelib/blob/master/test/CMakeLists.txt Defines the project name and includes subdirectories for Google Test and Google Mock frameworks. ```cmake project(mbetest) add_subdirectory(gtest) add_subdirectory(gmock) ``` -------------------------------- ### Install mbelib Library Source: https://github.com/szechyjs/mbelib/blob/master/README.md Installs the compiled mbelib library onto the system. This command typically requires superuser privileges. ```bash sudo make install ``` -------------------------------- ### Install Build Dependencies on Ubuntu Source: https://github.com/szechyjs/mbelib/blob/master/README.md Installs necessary packages like git, make, and cmake for building the mbelib library. Run this before cloning the repository. ```bash sudo apt-get update sudo apt-get install git make cmake ``` -------------------------------- ### Configure and Build mbelib with CMake Source: https://github.com/szechyjs/mbelib/blob/master/README.md Creates a build directory, configures the build using CMake, and then compiles the mbelib library. This process prepares the library for installation. ```bash cd mbelib mkdir build cd build cmake .. make ``` -------------------------------- ### Executable and Library Linking Source: https://github.com/szechyjs/mbelib/blob/master/test/CMakeLists.txt Creates the main executable 'mbetest' and links it with necessary libraries. ```cmake ADD_EXECUTABLE(mbetest ${SRCS}) TARGET_LINK_LIBRARIES(mbetest mbe gmock gtest) ``` -------------------------------- ### Adding Test Source: https://github.com/szechyjs/mbelib/blob/master/test/CMakeLists.txt Registers the 'mbetest' executable as a test to be run by the testing framework. ```cmake add_test(gtest mbetest) ``` -------------------------------- ### Include and Link Directories Source: https://github.com/szechyjs/mbelib/blob/master/test/CMakeLists.txt Specifies directories for header files and libraries required during the build process. ```cmake include_directories( ${PROJECT_SOURCE_DIR}/gtest/include ${PROJECT_SOURCE_DIR}/gmock/include ${mbe_SOURCE_DIR} ) link_directories( ${mbe_BINARY_DIR} ) ``` -------------------------------- ### Clone mbelib Repository Source: https://github.com/szechyjs/mbelib/blob/master/README.md Clones the mbelib source code from a Git repository. Replace with the actual repository URL. ```bash git clone ``` -------------------------------- ### Source File Globbing Source: https://github.com/szechyjs/mbelib/blob/master/test/CMakeLists.txt Finds all .cpp files in the current directory and adds them to the SRCS variable. ```cmake FILE(GLOB SRCS *.cpp) ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.