[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problems with configure on HP-UX: "-O" option needs argument



Hi Dave,

> To: address@hidden
> From: Dave Glowacki <address@hidden>
> Subject: netCDF 3.4: Problems with configure on HP-UX
> Organization: University of Wisconsin
> Keywords: 199811091540.IAA22285

In the above message, you wrote:

> The configure.in file in netCDF 3.4 has this definition near the top
> of the file:
> 
>       FFLAGS=${FFLAGS--O}
> 
> Unfortunately, when configure tries to build a test program using this
> flag, the HP-UX 'fort77' compiler spits out:
> 
>       fort77: POSIX 1003.2 mandates opt level following -O; \
>       expected values 0-4, received: conftest.c; ignored
> 
> If I were well versed in the art of writing configure.in rules, I'd
> hack up a rule to check for whether a compiler would accept -O2 or -O
> and use that for testing both ${CC} and ${FC}.
> 
> Unfortunately I'm not, so I just changed "${FFLAGS--O}" to
> "${FFLAGS--O2}".  This worked for HP-UX 10.20, Solaris 2.6, AIX 4.3.1
> and IRIX64 6.5, but I think we've got the commercial-grade compilers
> installed on all those machines...

This is why the HP-UX B.10.20 example in the INSTALL file sets the value
of the FFLAGS environment variable and why we tell people to use the
examples.

Regards,
Steve