This is the mail archive of the binutils@sourceware.org mailing list for the binutils 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: How to enable the option '--build-id' to ld ?


On Wed, Dec 11, 2019 at 6:44 PM William Tambe <tambewilliam@gmail.com> wrote:
>
> On Wed, Dec 11, 2019 at 7:42 PM Ian Lance Taylor <iant@google.com> wrote:
> >
> > On Wed, Dec 11, 2019 at 3:36 PM William Tambe <tambewilliam@gmail.com> wrote:
> > >
> > > On Wed, Dec 11, 2019 at 10:08 AM Ian Lance Taylor <iant@google.com> wrote:
> > > >
> > > > On Wed, Dec 11, 2019 at 7:03 AM William Tambe <tambewilliam@gmail.com> wrote:
> > > > >
> > > > > On Wed, Dec 11, 2019 at 9:29 AM Ian Lance Taylor <iant@google.com> wrote:
> > > > > >
> > > > > > On Wed, Dec 11, 2019 at 4:45 AM William Tambe <tambewilliam@gmail.com> wrote:
> > > > > > >
> > > > > > > How to enable the option '--build-id' to ld such that the following
> > > > > > > error does not occur:
> > > > > > > ld: unrecognized option '--build-id'
> > > > > >
> > > > > > What system are you running on?
> > > > >
> > > > > I am using GNU/Linux.
> > > >
> > > > What is the output of "ld --version"?
> > >
> > > $ arch-elf-ld --version
> > > GNU ld (GNU Binutils) 2.32
> > > Copyright (C) 2019 Free Software Foundation, Inc.
> > > This program is free software; you may redistribute it under the terms of
> > > the GNU General Public License version 3 or (at your option) a later version.
> > > This program has absolutely no warranty.
> > >
> > > >
> > > > What is the exact command that you are running, and what is the exact
> > > > output that you see from that command?
> > >
> > > $ arch-elf-ld --build-id objfile.o
> > > arch-elf-ld: unrecognized option '--build-id'
> > > arch-elf-ld: use the --help option for usage information
> >
> > Hmmm, I haven't seen arch-elf-ld before.  What is the output of
> > arch-elf-ld --help?
>
> I ported Binutils to a new architecture that I call "arch"; I would
> like to know what code change I can do such that the option
> '--build-id' is recognized.

For future reference, this is the kind of essential information that
you should provide in the first e-mail message asking for help.
Please don't make us guess what is going on.  That just wastes
everybody's time.  Thanks.

A port of GNU ld to a new architecture requires a
emulparams/TARGET.sh, as selected by ld/configure.tgt.  For an ELF
target, that file should set, among many other things,
TEMPLATE_NAME=elf.  Doing that should cause ld to get a --build-id
option.

Ian


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