[Bug libfortran/47802] [4.6 Regression] libgfortran/intrinsics/ctime.c:75:3: error: too few arguments to function 'ctime_r'

burnus at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Feb 23 18:32:00 GMT 2011


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47802

--- Comment #19 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-02-23 18:24:20 UTC ---
(In reply to comment #17)
> Patch resolves ctime.c build.  However, _REENTRANT is not defined,
> so there are various warnings regarding the declaration of reentrant
> functions such as localtime_r:

As there localtime_r is also used in intrinsics/date_and_time.c, I would assume
that one sees the same message there.

I am also not quite sure that _REENTRANT is the correct solution. At least for
Solaris, one should use _POSIX_C_SOURCE and not _REENTRANT to get the POSIX
version, cf. http://download.oracle.com/docs/cd/E19455-01/806-5257/compile-4/

For HP-UX, I could not find anything (cf. also
http://docs.hp.com/en/B2355-90683/ctime.3C.html). However, IBM has a statement
regarding HP-UX, which is similar to Solaris's above:
http://publib.boulder.ibm.com/infocenter/db2luw/v8/topic/com.ibm.db2.udb.doc/ad/t0007651.htm



More information about the Gcc-bugs mailing list