From: "H.J. Lu" <hjl.tools@gmail.com>
To: binutils@sourceware.org
Cc: nickc@redhat.com
Subject: Re: [PATCH] ld: Always call output_unknown_cmdline_warning
Date: Thu, 25 Jan 2024 09:26:13 -0800 [thread overview]
Message-ID: <CAMe9rOp-CM8LfeL_9yM1Jrq-uAbcw_xs+qio11uxU+81JqNFTQ@mail.gmail.com> (raw)
In-Reply-To: <20240125154319.788647-1-hjl.tools@gmail.com>
On Thu, Jan 25, 2024 at 7:43 AM H.J. Lu <hjl.tools@gmail.com> wrote:
>
> Call output_unknown_cmdline_warning if there are no input files so that
>
> $ ld -z bad-option
>
> reports
>
> ld: warning: -z bad-option ignored
> ld: no input files
>
> instead of
>
> ld: no input files
>
> PR ld/31289
> * ldmain.c (main): Call output_unknown_cmdline_warning if there
> are no input files.
> ---
> ld/ldmain.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/ld/ldmain.c b/ld/ldmain.c
> index 3b4ad144a2f..9ae541a5d82 100644
> --- a/ld/ldmain.c
> +++ b/ld/ldmain.c
> @@ -471,6 +471,7 @@ main (int argc, char **argv)
> {
> if (version_printed || command_line.print_output_format)
> xexit (0);
> + output_unknown_cmdline_warnings ();
> einfo (_("%F%P: no input files\n"));
> }
>
> --
> 2.43.0
>
I am checking in this.
--
H.J.
prev parent reply other threads:[~2024-01-25 17:26 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-25 15:43 H.J. Lu
2024-01-25 17:26 ` H.J. Lu [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAMe9rOp-CM8LfeL_9yM1Jrq-uAbcw_xs+qio11uxU+81JqNFTQ@mail.gmail.com \
--to=hjl.tools@gmail.com \
--cc=binutils@sourceware.org \
--cc=nickc@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).