On Jan 19, 2009, at 1:41 AM, Peter W. Draper wrote:
>
> OK, think I understand now. You need to clean out SMURF and then
> rebuild
> the whole package using "make CFLAGS=-std=c99".
>
> The problem is that isfinite etc. are redefined using macros, so
> compiling
> without c99 on just leaves the compiler thinking these are functions
> to be
> resolved when linking, rather linking against the mangled names...
>
> Question for Tim, is requiring a C99 compiler for SMURF deliberate?
Yes and no. In that sometimes a c99 feature makes life easy and
sometimes one simply creeps in without even realising it's a problem.
The lack of nightly builds really bites. SMURF does explicitly state
it is using c99.
I think the fix here is that smurf should always use -std=c99 for gcc
not just for gcc4. Peter, do you want to adjust that? Obviously some
of the other command line switches that I enable for gcc4 won't work
in both. Also, we know for a fact that gcc2 doesn't build starlink any
more (the threads stuff in AST introduced some things that broke it -
amazingly enough gcc2 does not like ";;" so some macros with ";" cause
trouble).
At least with a nightly build we'd find out sooner rather than later
when something breaks and explicitly get the choice of fixing it or
keeping it broken.
Not that I can understand why Mark shouldn't switch to gcc4/gfortran
since no code changes are required and it's got a better optimizer.
--
Tim Jenness
Joint Astronomy Centre
|