Hi Roland,
first things first: Bugs with GNU Radio recipes (and in doubt, when
something doesn't build properly, the recipes aren't right, pybombs
probably works) are best submitted to
https://github.com/gnuradio/gr-recipes/issues
to Pybombs itself:
https://github.com/gnuradio/pybombs/issues/
> What I would like even more: using my distros gnuradio with OOT
> modules.
That should be thoroughly possible!
So... Yeah, building a complete GNU Radio can be a hassle, but building
an OOT doesn't require you to have built GNU Radio yourself.
What you need is the *development headers* of the GNU Radio that came
with your distro.
sudo apt install gnuradio-dev
should do that. You can also install all the tools necessary to build
GNU Radio (but my wild guess is this does nothing new, so try it):
sudo apt build-dep gnuradio
Now, I had a look at gr-op25, and what you need is something like
sudo apt install libitpp-dev libpcap-dev gr-osmosdr
and then just (notice the lack of sudo!)
git clone git://git.osmocom.org/op25
cd op25
# or really, replace the URL with the git URL of about any OOT
# you'd like to buils
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/home/roland/path/to/prefix/ ..
# the -DCMAKE_INSTALL_PREFIX sets an installation prefix
# that we'll use below
make -j4 #-j4 is for four parallel compilations
make install # doesn't need sudo if the prefix is writable by you
I had a problem at the "cmake" step; seemingly, op25 can't detect the
gr-filter library autonomously anymore, and I had to fix that using
cmake -DCMAKE_INSTALL_PREFIX=/home/roland/path/to/prefix/ \
-DGR_FILTER_LIBRARY=/usr/lib/x86_64-linux-gnu/libgnuradio-
filter.so.3.7.11 ..
(It was demanding very directly I set that GR_FILTER_LIBRARY thing; I
don't know why it can't autodetect the library)
Afterwards, I continued down the list above (didn't follow through, but
usually it's done at this point).
Then, I just had to tell the OS component that looks for libraries to
also look into my prefix, and tell python where to look for my python
modules, and tell GRC where to look for block definitions. Sounds
exhausting, isn't. I just do a:
export GRPREFIX=/home/roland/path/to/prefix
export LD_LIBRARY_PATH=$GRPREFIX/lib:$LD_LIBRARY_PATH
# lib or lib64, just look into the prefix and find the directory
# containing all the *.so
export PYTHONPATH=$GRPREFIX/lib/python2.7/site-packages:$PYTHONPATH
# same here, check whether that directory is right
export GRC_BLOCKS_PATH=$GRPREFIX/share/gnuradio/grc/blocks
and because I don't want to type this every time, I save it to a text
file "prefixsettings.sh", and
source prefixsettings.sh
gnuradio-companion
Tadaaa!
You get the same prefix installation that pybombs does (i.e. totally
independent from your main system, if something breaks, just delete
that prefix; when you don't source the prefixsettings.py, Python
doesn't even know your OOTs exist, neither does GRC...), but without
pybombs. (you'll notice that it's really just source;git
clone;mkdir;cd;cmake;make;make install)
Honestly, Pybombs is a really cool tool for people who need to juggle a
few prefixes and potentially do cross-compilations, and would like
something to handle dependencies.
I just have maybe 5 to 10 different prefixes on my main machine, and I
live well without pybombs; it's up to your preference whether you want
to have a tool that keeps tabs of what's installed in each prefix, or
if you can live without that. Frankly, for the pure
clone–cmake–make–install cycle, the automation gain is negligible. For
the looking up dependencies – installing them in the prefix –
remembering a month later cycle, Pybombs definitely is helpful.
But assuming you just want to run a few OOTs for the one GNU Radio
version you've installed using your distro's package manager: Nah.
building an OOT from source normally isn't that complicated.
Best regards,
Marcus
On Tue, 2018-08-14 at 18:20 +0200, Roland Schwarz wrote:
>
> Am 2018-08-14 um 17:50 schrieb Müller, Marcus (CEL):
> > Hi Roland,
> >
> > is there a specific reason you prefer building quite everything
> > from
> > source rather than going for the binary packages Ubuntu ships?
> >
>
> gr-dsd , gr-op25
>
> > For usage and module development, I generally recommend that people
> > just use the packages that their distros offer.
>
> I would prefer that route.
>
> What I would like even more: using my distros gnuradio with OOT
> modules.
>
> > Now, as usual, Ubuntu
> > lags quite a bit behind e.g. Debian Unstable, but Ubuntu 18.04
> > ships
> > 3.7.11.0, so it's tolerably old. If there's a bug in that, we'd
> > love to
> > hear about it!
>
> Hmm, I ran into yet another bug with pyBOMBS, at package wxpython
> (the
> error messages were not really useful, needed to patch the recipe.py
> file to print the package name.)
>
> Would like to report. Where do you suggest to send reports / patches?
> Unfortunately I did not get the organizational structure of gnuradio.
>
> Thank you, Roland
>
No comments:
Post a Comment