[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: depcomp deficiency [was: m4-1.4.7 build feedback]
From: |
Joseph S. Myers |
Subject: |
Re: depcomp deficiency [was: m4-1.4.7 build feedback] |
Date: |
Thu, 28 Sep 2006 12:15:05 +0000 (UTC) |
On Thu, 28 Sep 2006, Nelson H. F. Beebe wrote:
> The gcc folks could probably argue that -- is indeed ambiguous,
> because there is no way to tell which of the following arguments are
> intended for the preprocessor, the compiler, the assembler, or the
> linker. There are already -W[x],-option,value options to direct
> arguments to specific components.
It's not ambiguous; the following arguments should all be treated as input
files, not options, and whether the input files are compiled (and as what
language) or linked is determined by their suffixes in the documented
manner. Thus
gcc -- -foo.c -lbar
should compile the C source file "-foo.c" and link the resulting object
with the object file called "-lbar" (not with the library libbar.a).
This does require passing the "--" through to the linker (and I don't know
if the linker supports -- as would be required), or rewriting the command
as the equivalent
gcc ./-foo.c ./-lbar
--
Joseph S. Myers
address@hidden
- depcomp deficiency [was: m4-1.4.7 build feedback], (continued)
- depcomp deficiency [was: m4-1.4.7 build feedback], Eric Blake, 2006/09/26
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Ralf Wildenhues, 2006/09/27
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Nelson H. F. Beebe, 2006/09/27
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Eric Blake, 2006/09/27
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Ralf Wildenhues, 2006/09/27
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Andreas Schwab, 2006/09/27
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Eric Blake, 2006/09/27
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Andreas Schwab, 2006/09/28
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Joseph S. Myers, 2006/09/28
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Nelson H. F. Beebe, 2006/09/28
- Re: depcomp deficiency [was: m4-1.4.7 build feedback],
Joseph S. Myers <=
- Re: depcomp deficiency [was: m4-1.4.7 build feedback], Ralf Wildenhues, 2006/09/28
vasprintf on DEC [was: m4-1.4.7 build feedback], Eric Blake, 2006/09/26
fpending issues on LSB [was: m4-1.4.7 build feedback], Eric Blake, 2006/09/26