Skip to content
This repository has been archived by the owner on May 10, 2019. It is now read-only.

gr-baz build broken #1

Closed
dmopalmer opened this issue Jun 6, 2012 · 5 comments
Closed

gr-baz build broken #1

dmopalmer opened this issue Jun 6, 2012 · 5 comments

Comments

@dmopalmer
Copy link

Using instructions from
https://github.com/titanous/homebrew-gnuradio
everything was fine or recoverable until I tried to install the rtlsdr stuff.

Two source files had errors:
baz_udp_source.cc:224:40: error: use of undeclared identifier 'SO_RCVBUFFORCE'
if (setsockopt(d_socket, SOL_SOCKET, SO_RCVBUFFORCE, (optval_t)&requested_recv_buff_size, sizeof(int)) == -1) {
^

baz_udp_sink.cc:189:40: error: use of undeclared identifier 'SO_SNDBUFFORCE'
if (setsockopt(d_socket, SOL_SOCKET, SO_SNDBUFFORCE, (optval_t)&requested_send_buff_size, sizeof(int)) == -1) {
^

==> Build Environment
CPU: quad-core 64-bit sandybridge
MacOS: 10.7.4-x86_64
Xcode: 4.3.2
CC: /usr/bin/clang
CXX: /usr/bin/clang++ => /usr/bin/clang
LD: /usr/bin/clang
CFLAGS: -Os -w -pipe -march=native -Qunused-arguments
CXXFLAGS: -Os -w -pipe -march=native -Qunused-arguments
CPPFLAGS: -I/usr/local/Cellar/cairo/1.10.2/include -I/usr/local/Cellar/libffi/3.0.11/include -I/usr/local/Cellar/gettext/0.18.1.1/include
LDFLAGS: -L/usr/local/Cellar/cairo/1.10.2/lib -L/usr/local/Cellar/libffi/3.0.11/lib -L/usr/local/Cellar/gettext/0.18.1.1/lib
MAKEFLAGS: -j4
PKG_CONFIG_PATH: /usr/local/Cellar/cairo/1.10.2/lib/pkgconfig:/usr/local/Cellar/libffi/3.0.11/lib/pkgconfig
Error: Failed executing: make install (gr-baz.rb:17)
If `brew doctor' does not help diagnose the issue, please report the bug:
https://github.com/titanous/homebrew-gnuradio/issues/new

@titanous
Copy link
Owner

titanous commented Jun 6, 2012

I've pushed a patch that uses a slightly older version of gr-baz and reported the error upstream: balint256/gr-baz#6

Did you have any other issues with the instructions? I'm always looking for ways to improve them.

@dmopalmer
Copy link
Author

On Jun 6, 2012, at 10:55 AM, Jonathan Rudenberg wrote:

I've pushed a patch that uses a slightly older version of gr-baz and reported the error upstream: balint256/gr-baz#6

Thank you, that compiled and runs (after resolving issues listed below). However, it puts out disconcerting error messages (also shown below)

Do you have any pointers to example .grc files of radios that do neat things with the rtl-sdr? I am new to gnuradio, and want to start by modifying something working rather than start from scratch.

Issues that I had to resolve to get it to compile:


The gr-baz install initially failed:

% brew install rtlsdr gr-osmosdr gr-baz --HEAD
Error: rtlsdr-HEAD already installed
Error: gr-osmosdr-HEAD already installed
==> Installing gr-baz
==> Cloning https://github.com/balint256/gr-baz.git
Updating /Users/palmer/Library/Caches/Homebrew/gr-baz--git
==> Checking out revision 63c68feb
fatal: invalid reference: 63c68feb
Error: Failure while executing: git checkout -q 63c68feb --

I removed the /Users/palmer/Library/Caches/Homebrew/gr-baz--git directory and installation worked

I tried doing a brew update which found your new gr-baz . However, when I then did brew upgrade, it started upgrading wxmac, which was not among the updated packages. That eventually failed, but rerunning your command:
brew install wxmac --devel --use-llvm --python
made things smooth again. (Is there some brew command I can give to prevent it from trying to use clang again next time I do a general brew upgrade?)


Disconcerting messages:

A bajillion lines of the form

Warning: Block with key "audio_sink" already exists.
Ignoring: /usr/local/Cellar/gnuradio/3.6.0/share/gnuradio/grc/blocks/audio_sink.xml
Warning: Block with key "audio_source" already exists.
Ignoring: /usr/local/Cellar/gnuradio/3.6.0/share/gnuradio/grc/blocks/audio_source.xml
Warning: Block with key "band_pass_filter" already exists.
Ignoring: /usr/local/Cellar/gnuradio/3.6.0/share/gnuradio/grc/blocks/band_pass_filter.xml

These go away if I remove the ~/.gnuradio/config.conf file, but then I can't use OsmoSDR

Using Volk machine: sse4_1_64
/Users/palmer/.gnuradio/prefs/gr_vmcircbuf_default_factory: No such file or directory
gr_vmcircbuf_createfilemapping: createfilemapping is not available
gr_vmcircbuf_sysv_shm: shmat (1): Too many open files
gr_vmcircbuf_sysv_shm: shmget (1): Invalid argument
gr_vmcircbuf_mmap_shm_open: mmap or shm_open is not available

Did you have any other issues with the instructions? I'm always looking for ways to improve them.

Comments on the rest of the build instructions, starting with a brew directory that didn't have much in it. I am picking nits because you are looking for feedback.
brew install gfortran umfpack
should also include swig , because that is required to pip install scipy .

At the point where you say
Install gnuradio (add --with-qt for gr-qtgui)
it might be nice to add line about whether there are any relative advantages to either wx or qt. I had trouble with qt when trying to install gnu radio with ports, so I tried qt, to learn that it is missing, e.g. waterfall display.
Also, should point out here that the optional step for gr-wxgui has to be done first

At the point where you say
Create the ~/.gnuradio/config.conf config file for custom block support

[grc]
local_blocks_path=/usr/local/share/gnuradio/grc/blocks

change the first line to …custom block support with the following contents:

Also, [grc] appears in boldface. I assume that this is not significant and the config.conf file should have those two lines.

In order to even start with
brew install rtlsdr gr-osmosdr gr-baz --HEAD
it required
brew link autoconf
which may be a residue of a previous attempt to install something else with brew.

A pointer to a page that has test programs on it would also be useful at the end so people can see if it works without having to RTFM. Saying 'run the program:
% gnuradio-companion /path/to/simple/example.grc
would go a long way in jumpstarting the user's confidence.


Reply to this email directly or view it on GitHub:
#1 (comment)

@titanous
Copy link
Owner

titanous commented Jun 7, 2012

@dmopalmer
Copy link
Author

Thanks. It's working and I can listen to FM broadcasts. Time for experimentation.

On Jun 6, 2012, at 8:42 PM, Jonathan Rudenberg wrote:

Awesome feedback, thanks! I'll roll it into the README over the next few days. Don't worry about the messages, homebrew has some weird feelings about head-only formulas.

Try these examples:

You may have to play around with the audio sinks (try clearing the device field), as most of these are designed for Linux.


Reply to this email directly or view it on GitHub:
#1 (comment)

@dmopalmer
Copy link
Author

Lots of fun. Playing with various radios.

The duplicated blocks seem to be caused by items in two directories:
1) /usr/local/Cellar/gnuradio/3.6.0/share/gnuradio/grc/blocks
2) /usr/local/share/gnuradio/grc/blocks
where the second directories contents are mostly aliases (symbolic links) to files in the first directory. There are also aliases in 2) that point to a third directory:
3) /usr/local/Cellar//gr-baz/HEAD/share/gnuradio/grc/blocks
and those items are not duplicated.

Is there some way to modify the default path so that it doesn't point to the 1) directory? Or should I remove the specific aliases in 2) that point to the files in 1). I have
% more ~/.gnuradio/config.conf
[grc]
local_blocks_path=/usr/local/share/gnuradio/grc/blocks
as your recipe suggests.

Also, the wx gui waterfall display doesn't have any controls, axes, titles etc. attached. Unlike the display in
http://www.joshknows.com/images/wxgui/wxgui_waterfall.png
the waterfall display I get (e.g. when I make the simplest possible flow graph with just a signal source hooked to a waterfall) shows only a block of the waterfall display with an empty space beside it. (Attached screenshot)

Might this have something to do with the 8 messages like
objc[52871]: Class WebCoreMovieObserver is implemented in both /usr/local/lib/QtWebKit.framework/Versions/4/QtWebKit and /System/Library/Frameworks/WebKit.framework/Versions/A/Frameworks/WebCore.framework/Versions/A/WebCore. One of the two will be used. Which one is undefined.
that it emits on startup?

Of minimal importance, unless you think the aesthetics are important enough to fix, is the error message:
% gnuradio-companion
/usr/local/bin/gnuradio-companion:61: GtkWarning: Could not find the icon 'gnuradio-grc'. The 'hicolor' theme
was not found either, perhaps you need to install it.
You can get a copy from:
http://icon-theme.freedesktop.org/releases
try: gtk.window_set_default_icon(gtk.IconTheme().load_icon('gnuradio-grc', 256, 0))

On Jun 6, 2012, at 8:42 PM, Jonathan Rudenberg wrote:

Awesome feedback, thanks! I'll roll it into the README over the next few days. Don't worry about the messages, homebrew has some weird feelings about head-only formulas.

Try these examples:

You may have to play around with the audio sinks (try clearing the device field), as most of these are designed for Linux.


Reply to this email directly or view it on GitHub:
#1 (comment)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants