### Install CMake Search Helper Source: https://github.com/geontech/gr-redhawk_integration/blob/master/CMakeLists.txt Installs a CMake configuration helper file for the redhawk_integration library. It ensures that CMake can find the installed package by placing the `redhawk_integrationConfig.cmake` file in the appropriate CMake modules directory. ```cmake if(NOT CMAKE_MODULES_DIR) set(CMAKE_MODULES_DIR lib${LIB_SUFFIX}/cmake) endif(NOT CMAKE_MODULES_DIR) install(FILES cmake/Modules/redhawk_integrationConfig.cmake DESTINATION ${CMAKE_MODULES_DIR}/redhawk_integration ) ``` -------------------------------- ### Installation Instructions Source: https://github.com/geontech/gr-redhawk_integration/blob/master/README.md Provides instructions for installing the REDHAWK Integration Package via source or package manager installations, and through Pybombs. It involves configuring CMake, building, and installing the module. ```bash # Source or Package Manager Installations mkdir build && cd build cmake gr-redhawk_integration [sudo] make install # Pybombs Installations mkdir build && cd build cmake gr-redhawk_integration source /setup_env.sh make install ``` -------------------------------- ### Doxygen Option Setup Source: https://github.com/geontech/gr-redhawk_integration/blob/master/CMakeLists.txt Sets up the ENABLE_DOXYGEN option based on whether Doxygen was found during the configuration process. If Doxygen is found, the option is enabled; otherwise, it is disabled. ```cmake if(DOXYGEN_FOUND) option(ENABLE_DOXYGEN "Build docs using Doxygen" ON) else(DOXYGEN_FOUND) option(ENABLE_DOXYGEN "Build docs using Doxygen" OFF) endif(DOXYGEN_FOUND) ``` -------------------------------- ### Project Setup and Configuration Source: https://github.com/geontech/gr-redhawk_integration/blob/master/CMakeLists.txt Configures the CMake build system for the gr-redhawk_integration project. It sets the minimum required CMake version, project name, enables testing, defines the build type, configures the module path, sets version information, applies CMake policies, and handles compiler-specific settings. ```cmake cmake_minimum_required(VERSION 2.6) project(gr-redhawk_integration CXX C) enable_testing() #install to PyBOMBS target prefix if defined if(DEFINED ENV{PYBOMBS_PREFIX}) set(CMAKE_INSTALL_PREFIX $ENV{PYBOMBS_PREFIX}) message(STATUS "PyBOMBS installed GNU Radio. Setting CMAKE_INSTALL_PREFIX to $ENV{PYBOMBS_PREFIX}") endif() #select the release build type by default to get optimization flags if(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE "Release") message(STATUS "Build type not specified: defaulting to release.") endif(NOT CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE ${CMAKE_BUILD_TYPE} CACHE STRING "") #make sure our local CMake Modules path comes first list(INSERT CMAKE_MODULE_PATH 0 ${CMAKE_SOURCE_DIR}/cmake/Modules) # Set the version information here set(VERSION_INFO_MAJOR_VERSION 1) set(VERSION_INFO_API_COMPAT 0) set(VERSION_INFO_MINOR_VERSION 0) set(VERSION_INFO_MAINT_VERSION git) # Set cmake policies. # This will suppress developer warnings during the cmake process that can occur # if a newer cmake version than the minimum is used. if(POLICY CMP0026) cmake_policy(SET CMP0026 OLD) endif() if(POLICY CMP0043) cmake_policy(SET CMP0043 OLD) endif() if(POLICY CMP0045) cmake_policy(SET CMP0045 OLD) endif() if(POLICY CMP0046) cmake_policy(SET CMP0046 OLD) endif() ######################################################################## # Compiler specific setup ######################################################################## if(CMAKE_COMPILER_IS_GNUCXX AND NOT WIN32) #http://gcc.gnu.org/wiki/Visibility add_definitions(-fvisibility=hidden) endif() ######################################################################## # Find boost ######################################################################## if(UNIX AND EXISTS "/usr/lib64") list(APPEND BOOST_LIBRARYDIR "/usr/lib64") #fedora 64-bit fix endif(UNIX AND EXISTS "/usr/lib64") set(Boost_ADDITIONAL_VERSIONS "1.35.0" "1.35" "1.36.0" "1.36" "1.37.0" "1.37" "1.38.0" "1.38" "1.39.0" "1.39" "1.40.0" "1.40" "1.41.0" "1.41" "1.42.0" "1.42" "1.43.0" "1.43" "1.44.0" "1.44" "1.45.0" "1.45" "1.46.0" "1.46" "1.47.0" "1.47" "1.48.0" "1.48" "1.49.0" "1.49" "1.50.0" "1.50" "1.51.0" "1.51" "1.52.0" "1.52" "1.53.0" "1.53" "1.54.0" "1.54" "1.55.0" "1.55" "1.56.0" "1.56" "1.57.0" "1.57" "1.58.0" "1.58" "1.59.0" "1.59" "1.60.0" "1.60" "1.61.0" "1.61" "1.62.0" "1.62" "1.63.0" "1.63" "1.64.0" "1.64" "1.65.0" "1.65" "1.66.0" "1.66" "1.67.0" "1.67" "1.68.0" "1.68" "1.69.0" "1.69" ) find_package(Boost "1.35" COMPONENTS filesystem system) if(NOT Boost_FOUND) message(FATAL_ERROR "Boost required to compile redhawk_integration") endif() ######################################################################## # Install directories ######################################################################## include(GrPlatform) #define LIB_SUFFIX set(GR_RUNTIME_DIR bin) set(GR_LIBRARY_DIR lib${LIB_SUFFIX}) set(GR_INCLUDE_DIR include/redhawk_integration) set(GR_DATA_DIR share) set(GR_PKG_DATA_DIR ${GR_DATA_DIR}/${CMAKE_PROJECT_NAME}) set(GR_DOC_DIR ${GR_DATA_DIR}/doc) set(GR_PKG_DOC_DIR ${GR_DOC_DIR}/${CMAKE_PROJECT_NAME}) set(GR_CONF_DIR etc) set(GR_PKG_CONF_DIR ${GR_CONF_DIR}/${CMAKE_PROJECT_NAME}/conf.d) set(GR_LIBEXEC_DIR libexec) set(GR_PKG_LIBEXEC_DIR ${GR_LIBEXEC_DIR}/${CMAKE_PROJECT_NAME}) set(GRC_BLOCKS_DIR ${GR_PKG_DATA_DIR}/grc/blocks) ``` -------------------------------- ### SWIG Interface File Installation Source: https://github.com/geontech/gr-redhawk_integration/blob/master/swig/CMakeLists.txt This snippet installs the SWIG interface files (.i) to the project's include directory. This is useful for development and for other projects that might depend on these interfaces. ```cmake install( FILES redhawk_integration_swig.i ${CMAKE_CURRENT_BINARY_DIR}/redhawk_integration_swig_doc.i DESTINATION ${GR_INCLUDE_DIR}/redhawk_integration/swig ) ``` -------------------------------- ### CMake Build Setup for Redhawk Integration Source: https://github.com/geontech/gr-redhawk_integration/blob/master/lib/CMakeLists.txt Configures the build environment for the GNU Radio Redhawk integration module. It includes setting up include and link directories, generating C++ sources using GR_EXPAND_X_CC_H, defining the shared library, linking dependencies, and setting installation properties. ```cmake # Copyright 2011,2012,2016 Free Software Foundation, Inc. # # This file was generated by gr_modtool, a tool from the GNU Radio framework # This file is a part of gr-redhawk_integration # # GNU Radio is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3, or (at your option) # any later version. # # GNU Radio is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with GNU Radio; see the file COPYING. If not, write to # the Free Software Foundation, Inc., 51 Franklin Street, # Boston, MA 02110-1301, USA. ######################################################################## # Setup library ######################################################################## include(GrPlatform) #define LIB_SUFFIX include_directories( ${CMAKE_CURRENT_BINARY_DIR}/../include ${Boost_INCLUDE_DIR} ${REDHAWK_INCLUDE_DIRS} ) link_directories( ${Boost_LIBRARY_DIRS} ${REDHAWK_LIBRARY_DIRS} ) ######################################################################## # Invoke macro to generate various sources and headers ######################################################################## include(GrMiscUtils) GR_EXPAND_X_CC_H(redhawk_integration rh_sink_bulkio_X_impl c f i b s) GR_EXPAND_X_CC_H(redhawk_integration rh_source_bulkio_X_impl c f i b s) list(APPEND redhawk_integration_sources ${generated_sources}) set(redhawk_integration_sources "${redhawk_integration_sources}" PARENT_SCOPE) if(NOT redhawk_integration_sources) MESSAGE(STATUS "No C++ sources... skipping lib/") return() endif(NOT redhawk_integration_sources) add_library(gnuradio-redhawk_integration SHARED ${redhawk_integration_sources}) target_link_libraries(gnuradio-redhawk_integration ${Boost_LIBRARIES} ${GNURADIO_ALL_LIBRARIES} ${REDHAWK_LIBRARIES}) set_target_properties(gnuradio-redhawk_integration PROPERTIES DEFINE_SYMBOL "gnuradio_redhawk_integration_EXPORTS") add_dependencies(gnuradio-redhawk_integration redhawk_integration_generated_includes) if(APPLE) set_target_properties(gnuradio-redhawk_integration PROPERTIES INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib" ) endif(APPLE) ######################################################################## # Install built library files ######################################################################## include(GrMiscUtils) GR_LIBRARY_FOO(gnuradio-redhawk_integration RUNTIME_COMPONENT "redhawk_integration_runtime" DEVEL_COMPONENT "redhawk_integration_devel") ######################################################################## # Build and register unit test ######################################################################## include(GrTest) include_directories(${CPPUNIT_INCLUDE_DIRS}) list(APPEND test_redhawk_integration_sources ${CMAKE_CURRENT_SOURCE_DIR}/test_redhawk_integration.cc ${CMAKE_CURRENT_SOURCE_DIR}/qa_redhawk_integration.cc ) add_executable(test-redhawk_integration ${test_redhawk_integration_sources}) target_link_libraries( test-redhawk_integration ${GNURADIO_RUNTIME_LIBRARIES} ${Boost_LIBRARIES} ${CPPUNIT_LIBRARIES} gnuradio-redhawk_integration ) GR_ADD_TEST(test_redhawk_integration test-redhawk_integration) ######################################################################## # Print summary ######################################################################## message(STATUS "Using install prefix: ${CMAKE_INSTALL_PREFIX}") message(STATUS "Building for version: ${VERSION} / ${LIBVER}") ``` -------------------------------- ### macOS Specific Install Name and RPATH Configuration Source: https://github.com/geontech/gr-redhawk_integration/blob/master/CMakeLists.txt Configures installation name directory and rpath for macOS builds to ensure correct library linking. It sets CMAKE_INSTALL_NAME_DIR, CMAKE_INSTALL_RPATH, and CMAKE_BUILD_WITH_INSTALL_RPATH if they are not already defined, ensuring proper library path resolution on Apple platforms. ```cmake if(APPLE) if(NOT CMAKE_INSTALL_NAME_DIR) set(CMAKE_INSTALL_NAME_DIR ${CMAKE_INSTALL_PREFIX}/${GR_LIBRARY_DIR} CACHE PATH "Library Install Name Destination Directory" FORCE) endif(NOT CMAKE_INSTALL_NAME_DIR) if(NOT CMAKE_INSTALL_RPATH) set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${GR_LIBRARY_DIR} CACHE PATH "Library Install RPath" FORCE) endif(NOT CMAKE_INSTALL_RPATH) if(NOT CMAKE_BUILD_WITH_INSTALL_RPATH) set(CMAKE_BUILD_WITH_INSTALL_RPATH ON CACHE BOOL "Do Build Using Library Install RPath" FORCE) endif(NOT CMAKE_BUILD_WITH_INSTALL_RPATH) endif(APPLE) ``` -------------------------------- ### Handle Unit Tests for gr-redhawk_integration Source: https://github.com/geontech/gr-redhawk_integration/blob/master/python/CMakeLists.txt This section details the setup for handling unit tests within the gr-redhawk_integration project. It includes setting dependencies for the test target and specifying directories for Python test files. ```cmake include(GrTest) set(GR_TEST_TARGET_DEPS gnuradio-redhawk_integration) set(GR_TEST_PYTHON_DIRS ${CMAKE_BINARY_DIR}/swig) ``` -------------------------------- ### Setting Include and Linker Paths Source: https://github.com/geontech/gr-redhawk_integration/blob/master/CMakeLists.txt Configures include and linker directories for the project. It includes paths from environment variables (OSSIEHOME), Boost, CppUnit, Gnuradio, and local project directories. It also defines REDHAWK_INCLUDE_DIRS and REDHAWK_LIBRARY_DIRS and sets necessary include directories and library paths. ```cmake MESSAGE(STATUS "OSSIEHOME: $ENV{OSSIEHOME}") set(REDHAWK_INCLUDE_DIRS $ENV{OSSIEHOME}/include) list(APPEND REDHAWK_INCLUDE_DIRS $ENV{OSSIEHOME}/include/bulkio) list(APPEND REDHAWK_INCLUDE_DIRS $ENV{OSSIEHOME}/include/ossie) list(APPEND REDHAWK_INCLUDE_DIRS $ENV{OSSIEHOME}/share/idl) list(APPEND REDHAWK_INCLUDE_DIRS /usr/include/omniORB4) list(APPEND REDHAWK_INCLUDE_DIRS /usr/include/omnithread) set(REDHAWK_LIBRARY_DIRS $ENV{OSSIEHOME}/lib${LIB_SUFFIX}) set(REDHAWK_LIBRARIES bulkio-2.2) list(APPEND REDHAWK_LIBRARIES bulkioInterfaces) list(APPEND REDHAWK_LIBRARIES ossiecf) list(APPEND REDHAWK_LIBRARIES ossieidl) list(APPEND REDHAWK_LIBRARIES COS4) list(APPEND REDHAWK_LIBRARIES omniDynamic4) list(APPEND REDHAWK_LIBRARIES omniORB4) list(APPEND REDHAWK_LIBRARIES omnithread) add_definitions(-DHAVE_OMNIORB4) include_directories( ${CMAKE_SOURCE_DIR}/lib ${CMAKE_SOURCE_DIR}/include ${CMAKE_BINARY_DIR}/lib ${CMAKE_BINARY_DIR}/include ${Boost_INCLUDE_DIRS} ${CPPUNIT_INCLUDE_DIRS} ${GNURADIO_ALL_INCLUDE_DIRS} ${REDHAWK_INCLUDE_DIRS} ) link_directories( ${Boost_LIBRARY_DIRS} ${CPPUNIT_LIBRARY_DIRS} ${GNURADIO_RUNTIME_LIBRARY_DIRS} ${REDHAWK_LIBRARY_DIRS} ) # Set component parameters set(GR_REDHAWK_INTEGRATION_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/include CACHE INTERNAL "" FORCE) set(GR_REDHAWK_INTEGRATION_SWIG_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/swig CACHE INTERNAL "" FORCE) ``` -------------------------------- ### SWIG Module Installation Source: https://github.com/geontech/gr-redhawk_integration/blob/master/swig/CMakeLists.txt This snippet handles the installation of the SWIG-generated Python module for gr-redhawk_integration. It specifies the target to install and the destination directory within the Python site-packages. ```cmake GR_SWIG_INSTALL(TARGETS redhawk_integration_swig DESTINATION ${GR_PYTHON_DIR}/redhawk_integration) ``` -------------------------------- ### Install Python Sources for redhawk_integration Source: https://github.com/geontech/gr-redhawk_integration/blob/master/python/CMakeLists.txt This snippet demonstrates how to install Python source files for the redhawk_integration module. It utilizes the GR_PYTHON_INSTALL macro provided by the GNU Radio framework to copy the `__init__.py` file to the appropriate Python directory. ```cmake include(GrPython) if(NOT PYTHONINTERP_FOUND) return() endif() GR_PYTHON_INSTALL( FILES __init__.py DESTINATION ${GR_PYTHON_DIR}/redhawk_integration ) ``` -------------------------------- ### Install GRC Blocks Source: https://github.com/geontech/gr-redhawk_integration/blob/master/grc/CMakeLists.txt Installs Redhawk integration blocks for GNU Radio Companion (GRC). These blocks are placed in the share/gnuradio/grc/blocks directory. ```cmake install(FILES redhawk_integration_rh_sink_bulkio.xml redhawk_integration_rh_source_bulkio.xml DESTINATION share/gnuradio/grc/blocks ) ``` -------------------------------- ### Doxygen Setup and Conditional Configuration Source: https://github.com/geontech/gr-redhawk_integration/blob/master/docs/CMakeLists.txt This snippet demonstrates how to find the Doxygen package and conditionally add the doxygen subdirectory if Doxygen is enabled. It's a common pattern for managing documentation generation in C++ projects using CMake. ```cmake find_package(Doxygen) if(ENABLE_DOXYGEN) add_subdirectory(doxygen) endif(ENABLE_DOXYGEN) ``` -------------------------------- ### SWIG and Python Integration Setup Source: https://github.com/geontech/gr-redhawk_integration/blob/master/swig/CMakeLists.txt This snippet configures the build process to use SWIG for generating Python bindings for the gr-redhawk_integration project. It includes finding SWIG and Python libraries, setting up include paths for GNU Radio's SWIG, and defining the SWIG interface file. ```cmake find_package(SWIG) find_package(PythonLibs 2) if(NOT SWIG_FOUND OR NOT PYTHONLIBS_FOUND) return() endif() include(GrSwig) include(GrPython) foreach(incdir ${GNURADIO_RUNTIME_INCLUDE_DIRS}) list(APPEND GR_SWIG_INCLUDE_DIRS ${incdir}/gnuradio/swig) endforeach(incdir) set(GR_SWIG_LIBRARIES gnuradio-redhawk_integration) set(GR_SWIG_DOC_FILE ${CMAKE_CURRENT_BINARY_DIR}/redhawk_integration_swig_doc.i) set(GR_SWIG_DOC_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/../include) GR_SWIG_MAKE(redhawk_integration_swig redhawk_integration_swig.i) ``` -------------------------------- ### GNU Radio Python Module Installation Source: https://github.com/geontech/gr-redhawk_integration/blob/master/apps/CMakeLists.txt Installs GNU Radio Python modules to the bin directory. This is a standard procedure for integrating Python components within the GNU Radio framework. ```Shell # Copyright 2011 Free Software Foundation, Inc. # # This file was generated by gr_modtool, a tool from the GNU Radio framework # This file is a part of gr-redhawk_integration # # GNU Radio is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3, or (at your option) # any later version. # # GNU Radio is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with GNU Radio; see the file COPYING. If not, write to # the Free Software Foundation, Inc., 51 Franklin Street, # Boston, MA 02110-1301, USA. include(GrPython) GR_PYTHON_INSTALL( PROGRAMS DESTINATION bin ) ``` -------------------------------- ### Uninstall Target Creation Source: https://github.com/geontech/gr-redhawk_integration/blob/master/CMakeLists.txt Creates a custom uninstall target for the project. It configures an uninstall script using a template file (`cmake_uninstall.cmake.in`) and then adds a custom target named 'uninstall' that executes this script. ```cmake configure_file( ${CMAKE_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake @ONLY) add_custom_target(uninstall ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake ) ``` -------------------------------- ### Install Public Header Files Source: https://github.com/geontech/gr-redhawk_integration/blob/master/include/redhawk_integration/CMakeLists.txt This snippet details the installation process for public header files within the gr-redhawk_integration project. It utilizes GNU Radio's utility functions to expand header files for various data types (complex, float, integer, boolean, string) for both sink and source components. The generated headers and the main API header are installed into the development component of the package. ```cmake ######################################################################## # Install public header files ######################################################################## include(GrMiscUtils) GR_EXPAND_X_H(redhawk_integration rh_sink_bulkio_X c f i b s) GR_EXPAND_X_H(redhawk_integration rh_source_bulkio_X c f i b s) add_custom_target(redhawk_integration_generated_includes DEPENDS ${generated_includes} ) install( FILES ${generated_includes} api.h DESTINATION include/redhawk_integration COMPONENT "redhawk_integration_devel" ) ``` -------------------------------- ### Adding Subdirectories Source: https://github.com/geontech/gr-redhawk_integration/blob/master/CMakeLists.txt Includes various subdirectories into the build process. This command tells CMake to process the CMakeLists.txt files in the specified subdirectories, allowing for modular build configurations for different parts of the project like libraries, SWIG interfaces, Python bindings, GRC blocks, applications, and documentation. ```cmake add_subdirectory(include/redhawk_integration) add_subdirectory(lib) add_subdirectory(swig) add_subdirectory(python) add_subdirectory(grc) add_subdirectory(apps) add_subdirectory(docs) ``` -------------------------------- ### Finding GNU Radio and Dependencies Source: https://github.com/geontech/gr-redhawk_integration/blob/master/CMakeLists.txt Finds necessary build dependencies like CppUnit and Doxygen. It searches for the Gnuradio package with a minimum version of 3.7.2 and adds a custom CMake module path. It also checks if CppUnit was found, failing the build if it's required. ```cmake find_package(CppUnit) find_package(Doxygen) # Search for GNU Radio and its components and versions. Add any # components required to the list of GR_REQUIRED_COMPONENTS (in all # caps such as FILTER or FFT) and change the version to the minimum # API compatible version required. set(GR_REQUIRED_COMPONENTS RUNTIME) find_package(Gnuradio "3.7.2" REQUIRED) list(INSERT CMAKE_MODULE_PATH 0 ${CMAKE_SOURCE_DIR}/cmake/Modules) include(GrVersion) if(NOT CPPUNIT_FOUND) message(FATAL_ERROR "CppUnit required to compile redhawk_integration") endif() ``` -------------------------------- ### Doxygen Configuration and Generation Source: https://github.com/geontech/gr-redhawk_integration/blob/master/docs/doxygen/CMakeLists.txt This snippet demonstrates how to configure Doxygen within a CMake project. It sets up paths, enables specific output formats (HTML, XML), and defines a custom command to run Doxygen. A custom target is created to depend on the generated documentation, and the output is installed. ```cmake file(TO_NATIVE_PATH ${CMAKE_SOURCE_DIR} top_srcdir) file(TO_NATIVE_PATH ${CMAKE_BINARY_DIR} top_builddir) file(TO_NATIVE_PATH ${CMAKE_SOURCE_DIR} abs_top_srcdir) file(TO_NATIVE_PATH ${CMAKE_BINARY_DIR} abs_top_builddir) set(HAVE_DOT ${DOXYGEN_DOT_FOUND}) set(enable_html_docs YES) set(enable_latex_docs NO) set(enable_xml_docs YES) configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY) set(BUILT_DIRS ${CMAKE_CURRENT_BINARY_DIR}/xml ${CMAKE_CURRENT_BINARY_DIR}/html) add_custom_command( OUTPUT ${BUILT_DIRS} COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMENT "Generating documentation with doxygen" ) add_custom_target(doxygen_target ALL DEPENDS ${BUILT_DIRS}) install(DIRECTORY ${BUILT_DIRS} DESTINATION ${GR_PKG_DOC_DIR}) ``` -------------------------------- ### REDHAWK Source Block (rh_source_bulkio) Source: https://github.com/geontech/gr-redhawk_integration/blob/master/README.md The rh_source_bulkio block acts as an input (Provides) port in REDHAWK, receiving data from a REDHAWK Component's BULKIO port. It translates incoming SRI, acquisition timestamp, and other details into stream tags, pushing them only when the SRI changes. It requires a BULKIO::InNumericPort and optionally accepts a packet_depth for queuing. ```c++ // Example usage within a GNURadio flow graph: // rh_source_bulkio_instance = gr.rh_source_bulkio(port=redhawk_input_port, packet_depth=1024); // Parameters: // port: A BULKIO::InNumericPort from the parent Component (Required) // packet_depth: Number of BulkIO packets to allow to queue (Optional) ``` -------------------------------- ### REDHAWK Sink Block (rh_sink_bulkio) Source: https://github.com/geontech/gr-redhawk_integration/blob/master/README.md The rh_sink_bulkio block functions as an output (Uses) port in REDHAWK, sending data to a REDHAWK Component's BULKIO port. It requires at least one stream tag to define packet size; otherwise, the buffer will not empty. It accepts a BULKIO::OutNumericPort and SRI parameters to define the Signal Related Information. ```c++ // Example usage within a GNURadio flow graph: // rh_sink_bulkio_instance = gr.rh_sink_bulkio(port=redhawk_output_port, sri={'sample_rate': 1e6, 'bandwidth': 1e5}); // Parameters: // port: A BULKIO::OutNumericPort from the parent Component (Required) // sri: The Signal Related Information (SRI) with multiple parameters (Optional) ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.