# "make" error while making detector (howto\_detect\_ff) block

**URL:** <https://www.ruby-forum.com/t/make-error-while-making-detector-howto-detect-ff-block/241321>\
**Category:** GNU Radio\
**Created:** [March 29, 2015, 3:17pm UTC](https://www.ruby-forum.com/t/make-error-while-making-detector-howto-detect-ff-block/241321 "2015-03-29T15:17:32Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![musicdenotation](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ea666f/32.png) [@musicdenotation](https://www.ruby-forum.com/u/musicdenotation)\
**Post date:** [March 29, 2015, 3:17pm UTC](https://www.ruby-forum.com/t/make-error-while-making-detector-howto-detect-ff-block/241321/1 "2015-03-29T15:17:32Z")

</div>

hey,  
I am working to make a detector block in gnuradio 3.7.1 using gr-how  
“out-of-tree module”. I am stuck with an error during make command

abhishek@abhishek-Inspiron-N5110:~/gr-howto/build$ make  
Scanning dependencies of target gnuradio-howto  
[5%] Building CXX object  
lib/CMakeFiles/gnuradio-howto.dir/howto\_detect\_ff\_impl.cc.o  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:37:5: error:  
‘howto\_detect\_ff\_sptr’ does not name a type  
howto\_detect\_ff\_sptr  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc: In constructor  
‘gr::howto::howto\_detect\_ff\_impl::howto\_detect\_ff\_impl(float, int,  
int)’:  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:59:17: error:  
expression cannot be used as a function  
d\_pfa(pfa), d\_L(L), d\_samples(samples)  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:59:25: error:  
expression cannot be used as a function  
d\_pfa(pfa), d\_L(L), d\_samples(samples)  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:59:45: error:  
expression cannot be used as a function  
d\_pfa(pfa), d\_L(L), d\_samples(samples)  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:185:1: error:  
expected  
‘{’ before ‘}’ token  
} /\* namespace howto \*/  
^  
make[2]: \*\*\*  
[lib/CMakeFiles/gnuradio-howto.dir/howto\_detect\_ff\_impl.cc.o]  
Error 1  
make[1]: \*\*\* [lib/CMakeFiles/gnuradio-howto.dir/all] Error 2  
make: \*\*\* [all] Error 2

Os is ubuntu 14.04. Even i have attached howto\_detect\_ff\_impl.h,  
howto\_detect\_ff\_impl.cc and howto\_swig.i file.  
It seems that some mistake is there in howto\_detect\_ff.h file whose path  
is  
gr-howto/include/howto. But i am not getting what exactly it is  
Any solution to sort an error will be appreciated.  
Thanks in advance,  
Abhishek.

---

<div class="post-metadata">

**Author:** ![abhishek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/7ba0ec/32.png) [@abhishek](https://www.ruby-forum.com/u/abhishek)\
**Post date:** [March 29, 2015, 3:28pm UTC](https://www.ruby-forum.com/t/make-error-while-making-detector-howto-detect-ff-block/241321/2 "2015-03-29T15:28:05Z")

</div>

Hi Abhishek,

your \_impl.cc is using old-style naming in out-of-tree-modules and their  
components, whilst your detect\_ff.h uses the consistent new way.  
I think this could be the result of using gr\_modtool to generate the  
module skeleton, and then copy/pasting over lines from a pre-3.7 code  
example. Is that possible?

Also, I already pointed you to the newer guided tutorials[1], which  
don’t build on the unmaintained gr-howto example. Please use these to  
get used to GNU Radio.

Greetings,  
Marcus

[1] [https://gnuradio.org/redmine/projects/gnuradio/wiki/Guided\_Tutorials](https://gnuradio.org/redmine/projects/gnuradio/wiki/Guided_Tutorials)

---

<div class="post-metadata">

**Author:** ![abhishek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/7ba0ec/32.png) [@abhishek](https://www.ruby-forum.com/u/abhishek)\
**Post date:** [April 1, 2015, 6:30am UTC](https://www.ruby-forum.com/t/make-error-while-making-detector-howto-detect-ff-block/241321/3 "2015-04-01T06:30:33Z")

</div>

hey marcus,  
here error given is, could not insert function, but we can according to  
“[http://gnuradio.org/redmine/projects/gnuradio/wiki/BlocksCodingGuide#Public-Header-Files](http://gnuradio.org/redmine/projects/gnuradio/wiki/BlocksCodingGuide#Public-Header-Files)”.  
Even i am not able to get last and second last error of expected “(” and  
“{”, but in the code all brackets are up to the mark and used properly.

abhishek@abhishek-Inspiron-N5110:~/gr-howto/build$ make  
Scanning dependencies of target gnuradio-howto  
[5%] Building CXX object  
lib/CMakeFiles/gnuradio-howto.dir/howto\_detect\_ff\_impl.cc.o  
In file included from  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:27:0:  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.h:40:7: error:  
???gr::howto::howto\_detect\_ff\_impl::howto\_detect\_ff\_impl(float, int,  
int)???  
cannot be overloaded  
howto\_detect\_ff\_impl(float pfa, int L, int samples);  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.h:37:6: error: with  
???gr::howto::howto\_detect\_ff\_impl::howto\_detect\_ff\_impl(float, int,  
int)???  
howto\_detect\_ff\_impl (float pfa, int L, int samples);  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:37:27: error:  
prototype for ???gr::howto::howto\_detect\_ff::sptr  
gr::howto::howto\_detect\_ff::make(float, int, int)??? does not match any  
in  
class ???gr::howto::howto\_detect\_ff???  
howto\_detect\_ff::sptr howto\_detect\_ff::make(float pfa, int L, int  
samples)  
^  
In file included from  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.h:24:0,  
from  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:27:  
/home/abhishek/gr-howto/include/howto/howto\_detect\_ff.h:49:19: error:  
candidate is: static gr::howto::howto\_detect\_ff::sptr  
gr::howto::howto\_detect\_ff::make()  
static sptr make();  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc: In constructor  
???gr::howto::howto\_detect\_ff\_impl::howto\_detect\_ff\_impl(float, int,  
int)???:  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:57:71: warning:  
extended initializer lists only available with -std=c++11 or  
-std=gnu++11 [enabled by default]  
gr::io\_signature::make (MIN\_OUT, MAX\_OUT,  
sizeof(float)),  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:66:5: error:  
expected ???)??? before ???(??? token  
(howto\_detect\_ff\_impl()::~howto\_detect\_ff\_impl())  
^  
/home/abhishek/gr-howto/lib/howto\_detect\_ff\_impl.cc:187:1: error:  
expected ???{??? before ???}??? token  
} /\* namespace howto \*/  
^  
make[2]: \*\*\*  
[lib/CMakeFiles/gnuradio-howto.dir/howto\_detect\_ff\_impl.cc.o] Error 1  
make[1]: \*\*\* [lib/CMakeFiles/gnuradio-howto.dir/all] Error 2  
make: \*\*\* [all] Error 2

Could you please help me out with all individual errors. Attachment of  
al the 3 files are provided.  
Thanks in advance,  
Abhishek.

---

<div class="post-metadata">

**Author:** ![abhishek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/7ba0ec/32.png) [@abhishek](https://www.ruby-forum.com/u/abhishek)\
**Post date:** [April 5, 2015, 5:27pm UTC](https://www.ruby-forum.com/t/make-error-while-making-detector-howto-detect-ff-block/241321/4 "2015-04-05T17:27:19Z")

</div>

hey Marcus,  
Now, I am able to import detect\_ff block. But while running an example  
using that block, i am stuck with a runtime error

File “/usr/local/lib/python2.7/dist-packages/howto/howto\_swig.py”,  
line  
24, in swig\_import\_helper  
\_mod = imp.load\_module(‘\_howto\_swig’, fp, pathname, description)  
ImportError: /usr/local/lib/libgnuradio-howto.so: undefined symbol:  
gsl\_matrix\_alloc

> > > Done

Hence not able to generate flow graph. Screen shot of given example is  
attached.  
Also i have attached .cc file of detect\_ff block.  
Would you please help me out with this error.  
Thanks in advance,  
Abhishek

On Wed, Apr 1, 2015 at 1:44 PM, Marcus Müller [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)

---

<div class="post-metadata">

**Author:** ![abhishek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/7ba0ec/32.png) [@abhishek](https://www.ruby-forum.com/u/abhishek)\
**Post date:** [April 5, 2015, 7:17pm UTC](https://www.ruby-forum.com/t/make-error-while-making-detector-howto-detect-ff-block/241321/5 "2015-04-05T19:17:55Z")

</div>

Hey Abishek,  
happy easter. How did you you generate your module? gr\_modtool? Does it  
use any matrix methods from GSL?

Greetings,  
Marcus

---

<div class="post-metadata">

**Author:** ![abhishek](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/7ba0ec/32.png) [@abhishek](https://www.ruby-forum.com/u/abhishek)\
**Post date:** [April 1, 2015, 10:15am UTC](https://www.ruby-forum.com/t/make-error-while-making-detector-howto-detect-ff-block/241321/6 "2015-04-01T10:15:55Z")

</div>

Hi Abhishek,

that guide refers to a somewhat outdated API, so it doesn’t apply to  
your case (that guide refers to an architecture where there was no  
separate \_impl class).

Have you read the guided tutorials and their chapter on C++ blocks? It’s  
explaining how you can add functions to blocks.  
I’d personally recommend just starting anew, sticking to the guided  
tutorials; wherever you got your guidance from, it mixes things that  
apply to different versions of GNU Radio, and debugging this is really  
not worth it when you could as well just start with a clean slate and  
learn things _right_.

Best regards,  
Marcus
