On Thu, Dec 16, 2021 at 11:18:08AM +0000, Andrew Cooper wrote:
> On 25/11/2021 13:39, Anthony PERARD wrote:
> > I guess it's easier to remember that %.E does "$(CC) -E" or "$(CPP)".
> >
> > -%.o %.i %.s: %.c tools_fixdep FORCE
> > +%.o %.i %.s %.E: %.c tools_fixdep FORCE
> >     $(Q)$(MAKE) $(build)=$(*D) $(*D)/$(@F)
> 
> So what I hadn't realised when asking was that Linux calls this .i and
> we've already got support for what I wanted.  Sorry :)
> 
> Thus, I suspect we probably don't want to take an extra %.E alias to the
> existing %.i, although...
> 
> >  
> > -%.o %.s: %.S tools_fixdep FORCE
> > +%.o %.s %.E: %.S tools_fixdep FORCE

> > +$(obj)/%.E: $(src)/%.c FORCE
> > +   $(call if_changed_dep,cpp_i_c)
> > +$(obj)/%.E: $(src)/%.S FORCE
> > +   $(call if_changed_dep,cpp_s_S)
> 
> ... I don't currently see support for %.i from %.S in the tree.  That
> one probably would be useful to introduce.

It's %.s for %.S, easy ;-)

Yep, %.s may run `gcc -S` or `gcc -E`.
And %.i may run `gcc -E` or may not run at all.

It seems that Linux have the same rules.

So, I guess to run gcc -E, one have to run `make dir/target.i || make
dir/target.s` currently, :-).

Another thing, %.s:%.S was broken for a while, and no one complained.

Cheers,

-- 
Anthony PERARD

Reply via email to