[Bug bootstrap/41771] Bootstrap with Sun Studio 12.1 fails

uweigand at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Thu Nov 5 13:18:00 GMT 2009



------- Comment #10 from uweigand at gcc dot gnu dot org  2009-11-05 13:18 -------
(In reply to comment #9)

> IMHO, flags.h should not include real.h if things like gcc.c will include it
> and not link against real.o and -lgmp etc.  But I don't know which if any
> targets now depend on this include.  I tried x86_64-linux-gnu and I was able to
> link xgcc and cc1.  But some other target may have a problem.
> 
> Perhaps Ulrich can explain why he chose to add that include so we can see if
> there's another way to accomplish the goal.

flags.h contains macros like HONOR_NANS which are defined in terms of
macros like MODE_HAS_NANS.  The MODE_HAS_... macros used to be defined
in target headers (or defaults.h) before my patch.

That patch changed the MODE_HAS_... macros to be defined in terms of
properties of the floating-point format structure (struct real_format)
instead of requiring the target to provide this information in a 
redundant way via special target macros.

In order to be able to access struct real_format, those new MODE_HAS_...
macros needed to be defined in real.h.  In order to keep the definition
of the HONOR_... macros in flags.h working, I added the include of real.h
to flags.h.

If this is problematic, I guess an alternative might be to move the
HONOR_... macros from flags.h to real.h as well, and update all files
that use these macros to also include real.h.


-- 


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



More information about the Gcc-bugs mailing list