I successfully built the how-to-write-a-block example outside of gnuradio-core. Now, I would like to implement my own version of gr_file_source, and I was hoping to do it outside of gnuradio-core. As a first step, I copied gr_file_source.* from core into a directory structure similar to that used in the howto, and then changed all occurrences of gr_file* to rad_file* and made the appropriate (?) changes to configure.ac and all the Makefile.am. However, on make, SWIG reports that it doesn't know anything about gr_sync_block, which is inherited from rad_file_source. Here's what make says: make all-recursive make: Entering directory `/home/pattonlk/grrad/radar' Making all in config make: Entering directory `/home/pattonlk/grrad/radar/config' make: Nothing to be done for `all'. make: Leaving directory `/home/pattonlk/grrad/radar/config' Making all in src make: Entering directory `/home/pattonlk/grrad/radar/src' Making all in lib make: Entering directory `/home/pattonlk/grrad/radar/src/lib' /gnuradio/gr/bin/swig -c++ -fvirtual -python -modern - I/gnuradio/gr/include/gnuradio/swig -I/gnuradio/gr/include/gnuradio - module rad -o rad.cc rad.i rad.i:31: Error: Syntax error in input(1). rad.i:35: Warning(401): Nothing known about base class 'gr_sync_block'. Ignored. make: *** [rad.cc] Error 1 make: Leaving directory `/home/pattonlk/grrad/radar/src/lib' make: *** [all-recursive] Error 1 make: Leaving directory `/home/pattonlk/grrad/radar/src' make: *** [all-recursive] Error 1 make: Leaving directory `/home/pattonlk/grrad/radar' make: *** [all] Error 2 gr_sync_block.h is in /gnuradio/gr/include/gnuradio, which is in the include path. Do I need a -L or something? Does anyone have any idea what bone-headed thing I'm doing wrong? I've attached logs of configure and make, along with my swig file. Thanks, - Lee
on 2006-05-12 00:10
on 2006-05-12 00:25
Never mind. I was basing my rad.i file on gr_file_source.i. However, gr_file_source.i is not stand-alone (unlike the *.i file in the howto). Instead, it is included in io.i. So, I was missing some requisite SWIG file stuff.