Hello,
I am trying to implement my own header class derived from 'header_format_default' named 'header_format_counter_dif'. As you can imagine, the class is quite similar to 'header_format_counter' with some minor adjustments. My situation is almost identical to the one presented in this mailing list before https://lists.gnu.org/archive/html/discuss-gnuradio/2017-04/msg00063.html
However, the difference is that I am using GNU Radio 3.9, so in my case the steps I have taken are
Steps taken so far:
1. Created my new module TFMv3 with gr_modtool
2. Added header_format_counter_dif (c++) using gr_modtool as type 'noblock'
3. Fleshed out the .cc and .h files based on the class 'header_format_counter' (but with some changes).
4. Made sure to #include <gnuradio/digital/header_format_default.h> in the header file
5. Used digital::header_format_default as the parent class in the class declaration since it's now in separate namespace to 'digital'
6. Add the line set(GR_REQUIRED_COMPONENTS RUNTIME DIGITAL) at
gr-TFMv3/CMakeLists.txt
6. Add the line py::module::import("gnuradio.digital") at python_bindings.cc
After that, I run gr_modtool bind header_format_counter_dif and I am able to compile successfully. However, when importing TFMv3 I get the error undefined symbol: _ZTIN2gr7digital21header_format_defaultE which stand for typeinfo for gr::digital::header_format_default (I found out using a C++ name demangler).
So it seems I am missing something when including the mother class correctly. Any ideas about what it might be?
Than you very much,
Álvaro