2 issues with latest GIT master, at least on OSX 10.5.8

(1) % …/…/configure

checking build system type… i386-apple-darwin9.8.0
checking host system type… i386-apple-darwin9.8.0
checking target system type… i386-apple-darwin9.8.0
checking for git… /opt/local/bin/git
checking existence of git version control directory… ok
checking git description of current commit… cut: illegal option – -
usage: cut -b list [-n] [file …]
cut -c list [file …]
cut -f list [-s] [-d delim] [file …]
…/…/configure: line 3672: test: too many arguments
v3.3.0-rc3-0-g944a8b6f
configure: GNU Radio Release 3.3.0-rc3
checking for a BSD-compatible install… /opt/local/bin/ginstall -c
[snip]
checking whether the boost::program_options includes are available…
yes
checking for exit in -lboost_program_options-d… yes
date: illegal option – R
usage: date [-jnu] [-d dst] [-r seconds] [-t west] [-
v[+|-]val[ymwdHMS]] …
[-f fmt date | [[[mm]dd]HH]MM[[cc]yy][.ss]] [+format]
checking for arpa/inet.h… (cached) yes
checking for netinet/in.h… (cached) yes
[snip]

(2) % make check

[snip]

gr_fir_fff: using SSE
gr_fir_ccf: using SSE

OK (98 tests)

PASS: test_all

1 test passed

Making check in python
Making check in gnuradio
Making check in gr
make check-TESTS
Traceback (most recent call last):
File “…/…/…/…/…/…/…/gnuradio-core/src/python/gnuradio/gr/
qa_add_and_friends.py”, line 23, in
from gnuradio import gr, gr_unittest
File “/opt/GNURadio/git/gnuradio-core/src/python/gnuradio/gr/
init.py”, line 43, in
from gnuradio_swig_python import *
File “/opt/GNURadio/git/gnuradio-core/src/lib/swig/
gnuradio_swig_python.py”, line 23, in
from gnuradio_swig_py_runtime import *
File “/opt/GNURadio/git/builds/master/gnuradio-core/src/lib/swig/
gnuradio_swig_py_runtime.py”, line 24, in
_gnuradio_swig_py_runtime = swig_import_helper()
File “/opt/GNURadio/git/builds/master/gnuradio-core/src/lib/swig/
gnuradio_swig_py_runtime.py”, line 16, in swig_import_helper
import _gnuradio_swig_py_runtime
ImportError: dlopen(/opt/GNURadio/git/builds/master/gnuradio-core/src/
lib/swig/.libs/_gnuradio_swig_py_runtime.so, 10): Library not loaded: /
usr/local/lib/libgnuradio-core.0.dylib
Referenced from: /opt/GNURadio/git/builds/master/gnuradio-core/src/
lib/swig/.libs/_gnuradio_swig_py_runtime.so
Reason: image not found
[snip]

On Tue, Jun 1, 2010 at 09:50, Michael D. [email protected] wrote:

checking git description of current commit… cut: illegal option – -
…/…/configure: line 3672: test: too many arguments
v3.3.0-rc3-0-g944a8b6f

This is from config/gr_git.m4, which I was updated in rc3 with
processing to extract various parameters from the git describe output.
My system has ‘cut’ from the GNU Core Utilities 7.4. Is OSX using
something different by default?

date: illegal option – R
usage: date [-jnu] [-d dst] [-r seconds] [-t west] [-v[+|-]val[ymwdHMS]] …
[-f fmt date | [[[mm]dd]HH]MM[[cc]yy][.ss]] [+format]

Nothing has changed here in the code since rc2.

line 16, in swig_import_helper
import _gnuradio_swig_py_runtime
ImportError:
dlopen(/opt/GNURadio/git/builds/master/gnuradio-core/src/lib/swig/.libs/_gnuradio_swig_py_runtime.so,
10): Library not loaded: /usr/local/lib/libgnuradio-core.0.dylib
Referenced from:
/opt/GNURadio/git/builds/master/gnuradio-core/src/lib/swig/.libs/_gnuradio_swig_py_runtime.so
Reason: image not found

This may be a downstream error that would go away when the upstream
issue is fixed.

Did anything else change in your test environment?

Johnathan

Sorry for the double post; strange internet goings-on down here.

Nothing has changed about my setup w/r.t. ‘cut’ or anything else.

‘which cut’ returns ‘/usr/bin/cut’ which is supplied by Darwin.

‘which date’ returns ‘/bin/date’ which is also Darwin – this issue
has been around for a while now, well before rc0; I’m just getting
around to complaining :slight_smile:

(1) configure.ac:296
++++
BUILD_DATE=date -R -u
++++

The ‘-u’ works (“Display or set the date in UTC (Coordinated
Universal) time”), but there is no “-R” option to Darwin’s built-in
‘date’. What does the ‘-R’ option specify? Maybe there’s another way
to do it on Darwin that’s more compatible with Linux (or, vice versa)?

(2) config/gr_git.m4:37
++++
if test xecho $GIT_DESCRIBE | cut -f 1- -d '-' --output-delimiter=' ' | wc -w = x4; then
++++

It’s the “–output-delimiter” that doesn’t work with Darwin’s ‘cut’;
this version only handles single ‘-’ parameters. What does this
option do? Maybe there’s another way to do it on Darwin that’s more
compatible with Linux (or, vice versa)?

On Tue, Jun 1, 2010 at 10:31, Michael D. [email protected] wrote:

Nothing has changed about my setup w/r.t. ‘cut’ or anything else.

‘which cut’ returns ‘/usr/bin/cut’ which is supplied by Darwin.

‘which date’ returns ‘/bin/date’ which is also Darwin – this issue has been
around for a while now, well before rc0; I’m just getting around to
complaining :slight_smile:

Okay, we may need to make darwin specific variables for cut and date,
and then use $CUT and $DATE in our scripts. I hope not.

Johnathan

On Tue, Jun 1, 2010 at 12:02, Michael D. [email protected] wrote:

BUILD_DATE=date -R -u
++++

The ‘-u’ works (“Display or set the date in UTC (Coordinated Universal)
time”), but there is no “-R” option to Darwin’s built-in ‘date’. What does
the ‘-R’ option specify?

From the manpage:

-R, --rfc-2822
output date and time in RFC 2822 format. Example: Mon,
07 Aug 2006 12:34:56 -0600

(2) config/gr_git.m4:37
++++
if test xecho $GIT_DESCRIBE | cut -f 1- -d '-' --output-delimiter=' ' | wc -w = x4; then
++++

It’s the “–output-delimiter” that doesn’t work with Darwin’s ‘cut’; this
version only handles single ‘-’ parameters. What does this option do?

From the manpage:

–output-delimiter=STRING
use STRING as the output delimiter the default is to use
the input delimiter

In our case, we ask cut to delimit the output fields with spaces
instead of the input delimiter ‘-’. This is so the ‘wc’ program can
tell how many fields there are by counting words. We need to know if
there are 3 or 4 ‘-’ delimited fields in the output of git describe.

Feel free to suggest an alternative way of doing this test. My
script-fu is not my greatest asset :slight_smile:

Johnathan

On Jun 1, 2010, at 2:38 PM, Johnathan C. wrote:

$ echo ‘1-2-3-4’ | awk -F- ‘{print NF}’
4

Can you test Darwin’s ‘awk’ for this?

the ‘$’ line returns exactly ‘4’ … I guess that’s good?

On Tue, Jun 1, 2010 at 12:52, Johnathan C.
[email protected] wrote:

Feel free to suggest an alternative way of doing this test. My
script-fu is not my greatest asset :slight_smile:

I have a solution for this using awk (thanks Jordan):

$ echo ‘1-2-3-4’ | awk -F- ‘{print NF}’
4

Can you test Darwin’s ‘awk’ for this?

Johnathan

On Jun 1, 2010, at 1:52 PM, Johnathan C. wrote:

From the manpage:

-R, --rfc-2822
output date and time in RFC 2822 format. Example: Mon,
07 Aug 2006 12:34:56 -0600

Can we instead use something like:

$ date -u +"%a, %d %b %Y %R:%S"

which isn’t quite RFC 2822 compliant since it’s missing the following
“+0000” (since ‘-u’) was specified … but it’ll always be “+0000” so
do we really need it there? Doing “grep -r BUILD_DATE .” from the top-
level directory, I think, shows that this variable isn’t even used …
yes? I think the above command is cross-OS compatible … we can
expand out %R if necessary.

With the change in ‘date’ and using ‘awk’, I still got the python dyld
load error, which I tracked down to the SWIG libraries. Doing ‘make
clean’ there and then ‘make’ did the trick. [email protected]#$% fragile SWIG stuff.

  • MLD

On Tue, Jun 1, 2010 at 14:46, Michael D. [email protected] wrote:

Can we instead use something like:

$ date -u +"%a, %d %b %Y %R:%S"

This works.

Doing “grep -r BUILD_DATE .” from the top-level
directory, I think, shows that this variable isn’t even used … yes?

It is in gnuradio-core/src/lib/general/gr_constants.cc.in, and
ultimately shows up in the output of:

$ gnuradio-config-info --builddate
Mon, 31 May 2010 06:51:25 +0000

I’ve got a new solution for the cut issue, using only shell script
commands (we don’t want the awk dependency), so with the two of these,
I think we’re set.

Johnathan

Thanks, Johnathan, for those fixes in recent check-ins; between them
and starting with a clean build, almost everything is taken care
of … one last item now:

$ make check
[snip]
Making check in gr-video-sdl
Making check in src
make check-am
make check-TESTS
objc[56471]: Class SDLTranslatorResponder is implemented in both /opt/
local/lib/libSDL-1.2.0.dylib and /opt/GNURadio/git/builds/master/gr-
video-sdl/src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib. Using
implementation from /opt/GNURadio/git/builds/master/gr-video-sdl/
src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib.
objc[56471]: Class SDL_QuartzView is implemented in both /opt/local/
lib/libSDL-1.2.0.dylib and /opt/GNURadio/git/builds/master/gr-video-
sdl/src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib. Using
implementation from /opt/GNURadio/git/builds/master/gr-video-sdl/
src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib.
objc[56471]: Class SDL_QuartzWindowDelegate is implemented in both /
opt/local/lib/libSDL-1.2.0.dylib and /opt/GNURadio/git/builds/master/
gr-video-sdl/src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib. Using
implementation from /opt/GNURadio/git/builds/master/gr-video-sdl/
src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib.
objc[56471]: Class SDL_QuartzWindow is implemented in both /opt/local/
lib/libSDL-1.2.0.dylib and /opt/GNURadio/git/builds/master/gr-video-
sdl/src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib. Using
implementation from /opt/GNURadio/git/builds/master/gr-video-sdl/
src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib.
[snip]

but otherwise, ‘make check’ works. - MLD

I just checked – it’s a MacPorts / SDL issue; I’ll submit a bug
report to them. Sorry! - MLD

On Thu, Jun 3, 2010 at 08:16, Michael D. [email protected] wrote:

Thanks, Johnathan, for those fixes in recent check-ins; between them and
starting with a clean build, almost everything is taken care of … one last
item now:

objc[56471]: Class SDLTranslatorResponder is implemented in both
/opt/local/lib/libSDL-1.2.0.dylib and
/opt/GNURadio/git/builds/master/gr-video-sdl/src/.libs/libgnuradio-video-sdl-3.3.1git.0.dylib.

I really don’t know what to make of this. When did it start happening?

Johnathan