This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] pass @-files to collect2 and beyond, take 2


Nathan Froyd wrote:
> The attached patch adds special handling to the gcc driver and collect2
> to pass @-file arguments to collect2 and subprocesses, respectively,
> when they are passed @-file arguments.  The motivation behind this is to
> avoid argv limits on some systems and/or large compiles.

Thank you for revising this!

The gcc/ parts of this look good.  I've CC'd the libiberty maintainers;
they may not have spotted this patch.

I have one nitpick: it would be better if you could arrange for
HAVE_GNU_LD to be defined as {0,1}-valued macro, so that the tests,
instead of being:

  #ifdef HAVE_GNU_LD

were just:

  if (HAVE_GNU_LD)

That's the preferred style since it means that compilation errors in the
conditional code are detected even by people not building in that
configuration.

The libiberty code should probably check the return value of "fclose"
(that's the point at which you often get errors if writing to a file
over NFS) and one of the calls to fputc is also unchecked.

Please make these minor revisions.

Thanks,

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]