Forum: GNU Radio templates in "gr-howto-write-a-block-0.3"

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Achilleas A. (Guest)
on 2006-04-19 01:47
(Received via mailing list)
I have handwritten a couple of blocks in the howto
directory and am able to compile/install them.

I would like to generate versions of these blocks for
different input/output variable types, thus I have written the
appropriate template files _XX.i.t, _XX.h.t, _XX.cc.t
(I followed some examples in core/src/lib/general/)


My question is how to automate the compile and install step
to generate the appropriate code from the templates.

Thanks
Achilleas
Eric B. (Guest)
on 2006-04-19 01:56
(Received via mailing list)
On Tue, Apr 18, 2006 at 05:45:40PM -0400, Achilleas A.
wrote:
> My question is how to automate the compile and install step
> to generate the appropriate code from the templates.
>
> Thanks
> Achilleas

Take a look at gnuradio-core/src/lib/general/Makefile.am to see how we
do it there.

FYI, this is the Makefile rule that runs the code generator:

$(GENERATED_H) $(GENERATED_I) $(GENERATED_CC): $(CODE_GENERATOR)
	PYTHONPATH=$(top_srcdir)/src/python srcdir=$(srcdir)
$(srcdir)/generate_all.py


All of the $(srcdir) and $(top_srcdir) stuff is required to make this
work when doing VPATH builds.  That is, builds where the source and
objects are in different directories.

Eric
This topic is locked and can not be replied to.