The revised patch is attached. The differences are in what options are defined 
and propagated to Makefile for CET enabling. -iclude option is dropped, each 
needed asm file is processed separately.

Igor


> -----Original Message-----
> From: Ian Lance Taylor [mailto:i...@airs.com]
> Sent: Friday, October 13, 2017 6:45 PM
> To: Tsimbalist, Igor V <igor.v.tsimbal...@intel.com>
> Cc: gcc-patches@gcc.gnu.org; Jeff Law <l...@redhat.com>
> Subject: Re: [PATCH 09/22] Enable building libbacktrace with Intel CET
> 
> "Tsimbalist, Igor V" <igor.v.tsimbal...@intel.com> writes:
> 
> >
> > This file is included to simplify building a library that might have
> > assembler files.
> > This is an auxiliary file to automate creation of a special section in
> > an output object
> > file. Without it every assembler file has to be modified by hand to
> > include a special
> > section. This "-include cet.h " option is specified at a high level to
> > not bother if a
> > library has or does not have assembler files. The option either has no 
> > effect
> if
> > all source files are C/C++ or used only for assembler file
> > processing. The file itself
> > has an assembler code. The same code is generated by the compiler for
> each
> > input C/C++/etc. files.
> >
> > In real life a user who is going to write an assemble code and have it
> > CET compatible
> > has to add a special section to mark the object file as CET compatible.
> 
> I guess I don't understand how you can assume that general assembly code
> is CET compatible.  And if you know it is CET compatible then adding the
> section seems simple enough; people already do it routinely for
> .note.GNU-stack.
> 
> In any case a -include file such as you describe does not belong in a
> general FLAGS variable, it belongs in CPPFLAGS or, ideally, ASPPFLAGS if
> there were such a Make variable.
> 
> Ian

Attachment: 0009-Enable-building-libbacktrace-with-Intel-CET.PATCH
Description: 0009-Enable-building-libbacktrace-with-Intel-CET.PATCH

Reply via email to