]> gcc.gnu.org Git - gcc.git/commit
driver: error for nonexistent linker inputs [PR 98943]
authorNathan Sidwell <nathan@acm.org>
Thu, 4 Feb 2021 16:16:17 +0000 (08:16 -0800)
committerNathan Sidwell <nathan@acm.org>
Fri, 5 Feb 2021 13:32:34 +0000 (05:32 -0800)
commit6606b852bfa866c19375a7c5e9cb94776a28bd94
tree47ea757d2b70c5eabd3e71ce8a76785e1a28a138
parent63538886d1f7fc7cbf066b4c2d6d7fd4da537259
driver: error for nonexistent linker inputs [PR 98943]

We used to check all unknown input files, even when passing them to a
compiler.  But that caused problems.  However, not erroring out on
non-existent would-be-linker inputs confuses configure machinery that
probes the compiler to see if it accepts various inputs.  This
restores the access check for things that are thought to be linker
input files, when we're not linking.  (If we are linking, we presume
the linker will error out on its own accord.)

PR driver/98943
gcc/
* gcc.c (driver::maybe_run_linker): Check for input file
accessibility if not linking.
gcc/testsuite/
* c-c++-common/pr98943.c: New.
gcc/gcc.c
gcc/testsuite/c-c++-common/pr98943.c [new file with mode: 0644]
This page took 0.054938 seconds and 6 git commands to generate.