On Thu, Dec 18, 2014 at 07:25:03PM +0100, Thomas Schwinge wrote: > Hi! > > On Wed, 17 Dec 2014 23:26:53 +0100, I wrote: > > Committed to gomp-4_0-branch in r218840: > > > > commit febcd8dfdb10fa80edff0880973d1915ca2fef74 > > Author: tschwinge <tschwinge@138bc75d-0d04-0410-961f-82ee72b054a4> > > Date: Wed Dec 17 22:26:24 2014 +0000 > > > > Use include/gomp-constants.h more actively. > > > diff --git gcc/tree-core.h gcc/tree-core.h > > index 743bc0d..fc61b88 100644 > > --- gcc/tree-core.h > > +++ gcc/tree-core.h > > @@ -32,6 +32,7 @@ along with GCC; see the file COPYING3. If not see > > #include "alias.h" > > #include "flags.h" > > #include "symtab.h" > > +#include "gomp-constants.h" > > > > /* This file contains all the data structures that define the 'tree' type. > > There are no accessor macros nor functions in this file. Only the > > Is it actually "OK" to #include "gomp-constants.h" (living in > [GCC]/include/) from gcc/tree-core.h? Isn't the tree-core.h file getting > installed, for later use by plugins -- which then need to be able to find > gomp-constants, too, but that is not being installed?
Generally, it must be possible to include include/ headers from gcc/ headers, even when they are used by plugins. Otherwise system.h including libiberty.h and safe-ctype.h etc. wouldn't work. Perhaps you need to add gomp-constants.h to some Makefile variable or something, look at how is safe-ctype.h etc. handled. That said, including gomp-constants.h from tree-core.h is I think very much against all the Andrew's efforts to flatten headers (which is something I'm not very happy with generally, but in this case, I think only the very few files that really need the constants should include it). Jakub