[PATCH] Fix unresolved symbols on non-C99 platforms

Toon Moene toon@moene.indiv.nluug.nl
Sun May 22 12:23:00 GMT 2005


Eric Botcazou wrote:
> Hi,
> 
> The patch
> 
> 2005-05-18  Tobias Schl"uter  <tobias.schlueter@physik.uni-muenchen.de>
> 
> 	* f95-lang.c (gfc_init_builtin_functions): Define BUILT_IN_TRUNC
> 	and BUILT_IN_TRUNCF instead of BUILT_IN_FLOOR and BUILT_IN_FLOORF.
> 	* trans-intrinsic.c (build_fix_expr): Change 'op' argument
> 	to correct enum type.
> 	(gfc_conv_intrinsic_aint): Likewise.  Clarify comment in front of
> 	function.  Add default case to switch, deal with FIX_TRUNC_EXPR
> 	instead of FIX_FLOOR_EXPR.
> 
> has broken the F95 compiler on non-C99 platforms because of the new 
> dependencies on C99's 'trunc' and 'truncf'.
> 
> The attached patch adds 'trunc' and 'truncf' to intrinsics/c99_functions.c and 
> tweak the configure machinery accordingly.  Built and tested on SPARC/Solaris 
> 2.5.1, 2.6, 7, 8, 9 (non-C99) and 10 (C99).  OK for mainline?
> 
> 
> 2005-05-20  Eric Botcazou  <ebotcazou@libertysurf.fr>
> 
> 	* configure.ac: Check for trunc and truncf in libm.
> 	* configure: Regenerate.
> 	* config.h.in: Likewise.
> 	* intrinsics/c99_functions.c (trunc, truncf): New functions.
> 	* c99_protos.h (trunc, truncf): Declare them.

OK, thanks.

[ Can't check it on our own Solaris platform, as it busy forecasting the
   weather, but you did that already :-) ]

-- 
Toon Moene - e-mail: toon@moene.indiv.nluug.nl - phone: +31 346 214290
Saturnushof 14, 3738 XG  Maartensdijk, The Netherlands
A maintainer of GNU Fortran 95: http://gcc.gnu.org/fortran/
News on GNU Fortran 95: http://gfortran.org/



More information about the Fortran mailing list