diff options
4 files changed, 15 insertions, 2 deletions
diff --git a/gnuradio-runtime/apps/gnuradio-config-info.cc b/gnuradio-runtime/apps/gnuradio-config-info.cc index 3c8778987f..f2dd563edb 100644 --- a/gnuradio-runtime/apps/gnuradio-config-info.cc +++ b/gnuradio-runtime/apps/gnuradio-config-info.cc @@ -41,7 +41,8 @@ int main(int argc, char** argv) "enabled-components", "print GNU Radio build time enabled components")( "cc", "print GNU Radio C compiler version")( "cxx", "print GNU Radio C++ compiler version")( - "cflags", "print GNU Radio CFLAGS")("version,v", "print GNU Radio version"); + "cflags", "print GNU Radio CFLAGS")("version,v", "print GNU Radio version")( + "pybind", "print pybind11 version used in this build"); // clang-format on try { @@ -95,5 +96,8 @@ int main(int argc, char** argv) if (vm.count("cflags") || print_all) std::cout << gr::compiler_flags() << std::endl; + if (vm.count("pybind") || print_all) + std::cout << gr::pybind_version() << std::endl; + return 0; } diff --git a/gnuradio-runtime/include/gnuradio/constants.h b/gnuradio-runtime/include/gnuradio/constants.h index bc4118bbd6..6cf741d87c 100644 --- a/gnuradio-runtime/include/gnuradio/constants.h +++ b/gnuradio-runtime/include/gnuradio/constants.h @@ -76,6 +76,12 @@ GR_RUNTIME_API const std::string compiler_flags(); */ GR_RUNTIME_API const std::string build_time_enabled_components(); +/*! + * \brief return the pybind11 version used to build this version of GNU Radio + */ +GR_RUNTIME_API const std::string pybind_version(); + + } /* namespace gr */ #endif /* INCLUDED_GR_CONSTANTS_H */ diff --git a/gnuradio-runtime/lib/constants.cc.in b/gnuradio-runtime/lib/constants.cc.in index aafd2faa78..4d8e240e24 100644 --- a/gnuradio-runtime/lib/constants.cc.in +++ b/gnuradio-runtime/lib/constants.cc.in @@ -71,4 +71,7 @@ const std::string cxx_compiler() { return "@cmake_cxx_compiler_version@"; } const std::string compiler_flags() { return "@COMPILER_INFO@"; } const std::string build_time_enabled_components() { return "@_gr_enabled_components@"; } + +const std::string pybind_version() { return "@pybind11_VERSION@"; } + } /* namespace gr */ diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/constants_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/constants_python.cc index e2624e808d..b8301e2398 100644 --- a/gnuradio-runtime/python/gnuradio/gr/bindings/constants_python.cc +++ b/gnuradio-runtime/python/gnuradio/gr/bindings/constants_python.cc @@ -14,7 +14,7 @@ /* BINDTOOL_GEN_AUTOMATIC(0) */ /* BINDTOOL_USE_PYGCCXML(0) */ /* BINDTOOL_HEADER_FILE(constants.h) */ -/* BINDTOOL_HEADER_FILE_HASH(d98c7e72cb74921e5e07f332dbf5475a) */ +/* BINDTOOL_HEADER_FILE_HASH(23118d18abd7aebdb0d674771473ed8b) */ /***********************************************************************************/ #include <pybind11/complex.h> |