This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Build fail on gthr-simple.h targets (Re: AsyncI/O patch committed)
- From: "Ulrich Weigand" <uweigand at de dot ibm dot com>
- To: nk at koenigni dot com (Nicolas Koenig)
- Cc: fortran at gcc dot gnu dot org (gfortran), gcc-patches at gcc dot gnu dot org
- Date: Thu, 26 Jul 2018 15:31:42 +0200 (CEST)
- Subject: Build fail on gthr-simple.h targets (Re: AsyncI/O patch committed)
Nicholas Koenig wrote:
> Hello everyone,
>
> I have committed the async I/O patch as r262978.
>
> The test cases are in libgomp.fortran for now, maybe that can be changed
> later.
It looks like this broke building libgfortran on spu, and presumably
any platform that uses gthr-simple instead of gthr-posix.
The problem is that io/asynch.h unconditionally uses a couple of
features that are not provided by gthr-simplex, in particular
__gthread_cond_t
and
__gthread_equal / __gthread_self
According to the documentation in gthr.h, the former is only available
if __GTHREAD_HAS_COND is defined, and the latter are only available if
__GTHREADS_CXX0X is defined. Neither is true for gthr-simple.h.
To fix the build error, either libgfortran should only use those features
conditionally on those defines, or else the gthr.h logic needs to be
changed and (stubs for) those features provided in gthr-simple.h as well.
Bye,
Ulrich
--
Dr. Ulrich Weigand
GNU/Linux compilers and toolchain
Ulrich.Weigand@de.ibm.com