Using chmod fails under MinGW
Steve Kargl
sgk@troutmask.apl.washington.edu
Fri Oct 3 14:49:00 GMT 2008
On Fri, Oct 03, 2008 at 04:07:53PM +0200, Arjen Markus wrote:
> Steve Kargl wrote:
>
> >That's the smart configure problem I'm talking about. When building
> >libgfortran may detect that the program chmod does not exist, so the
> >library does not include _gfortran_chmod_func(). The front-end of the
> >compiler has no knowledge of this missing function and happily
> >generates a call for the intrinsic function chmod().
> >
> >
> Ah, I get it. My, that is an intricate problem. Like I said before: the
> simplest
> solution is probably a chapter on such issues in the manual.
>
Well, I finally had a peak at the library code. It does
#if defined(HAVE_FORK) && defined(HAVE_EXECL) && Defined(HAVE_WAIT)
....
#endif
Notice the lack of an #else. The above should at least do
#if defined(HAVE_FORK) && defined(HAVE_EXECL) && Defined(HAVE_WAIT)
....
#else
PREFIX(chmod_func)
{
warning("chmod() not available");
return -1; /* Chmod failed. */
}
#endif
--
Steve
More information about the Fortran
mailing list