On Fri 12 Sep 2014 09:44:59 Andy Polyakov via RT wrote: > > This reverts commit d1cf23ac86c05b22b8780e2c03b67230564d2d34. > > > > When gcc is given a .s file and told to preprocess it, it outputs nothing. > > Since gcc targets are more common/important than OSF, revert it and let > > the original submitter sort out the problem. > > > > URL: https://bugs.gentoo.org/499086 > > --- > > > > alphacpuid.s: alphacpuid.pl > > - (preproc=/tmp/$$$$.$@; trap "rm $$preproc" INT; \ > > - $(PERL) alphacpuid.pl > $$preproc && \ > > - $(CC) -E $$preproc > $@ && rm $$preproc) > > + $(PERL) $< | $(CC) -E - | tee $@ > /dev/null > > Can you confirm that preproc=/tmp/[email protected] in original snippet solves > the problem?
i don't understand what you mean. the code as written in the tree does not work with gcc. preproc will expand into /tmp/<pid>.alphacpuid.s, and since gcc will skip .s files with -E, you get no output. i'd also highlight that relying on the pid # to give you a global unique tmp file is very very broken. it's easy for malicious people to clobber, and it's not even unique on modern Linux systems with pid namespaces. it should really just write it to [email protected] instead and then do `mv $@ [email protected]`. -mike
signature.asc
Description: PGP signature
