All of lore.kernel.org
 help / color / mirror / Atom feed
From: Konrad Rzeszutek Wilk <konrad@kernel.org>
To: Jan Beulich <JBeulich@suse.com>
Cc: wei.liu2@citrix.com, Ian Campbell <ian.campbell@citrix.com>,
	andrew.cooper3@citrix.com, "xen.org" <ian.jackson@eu.citrix.com>,
	Martin Pohlack <mpohlack@amazon.de>,
	xen-devel@lists.xenproject.org, dgdegra@tycho.nsa.gov
Subject: Re: [PATCH v3 2/3] XENVER_build_id: Provide ld-embedded build-ids (v8)
Date: Tue, 19 Jan 2016 11:05:34 -0500	[thread overview]
Message-ID: <CACJDEmpfC_v+5u_hcHJMrfBO76Xa0rvSgcBVNQWiRznk8OMhOg@mail.gmail.com> (raw)
In-Reply-To: <569CB59E02000078000C7D10@prv-mh.provo.novell.com>

>>> Wouldn't it be better to probe the linker for recognizing the --build-id
>>> command line option, along the lines of $(cc-option)?
>>
>> +ld-ver-build-id = $(shell $(1) --build-id 2>&1 | \
>> +                                       grep -q unrecognized && echo n
>> || echo y)
>>
>> -ish ?
>
> If that fulfills the purpose - why not?

Great. Will use that (after checking it on on SLES10).
>
>>> In any event the option should be added to LDFLAGS unless this
>>> conflicts with something else.
>>
>> That had some interesting side-effect:
>>
>> $ find . -name *.o | xargs readelf -n | more
>> File: ./arch/x86/built_in.o
>>
>> Displaying notes found at file offset 0x00000040 with length 0x00000240:
>>   Owner                 Data size       Description
>>   GNU                  0x00000014       NT_GNU_BUILD_ID (unique build
>> ID bitstring)
>>     Build ID: a114d1fdec2ace38448f141013f5a659122f2390
>>   GNU                  0x00000014       NT_GNU_BUILD_ID (unique build
>> ID bitstring)
.. snip..
>> And during build:
>> ld: warning: Cannot create .note.gnu.build-id section, --build-id ignored.
.. snip..
>> I think we should skip on the LDFLAGS idea.
>
> Isn't that merely a result of LDFLAGS being used for both the
> linking of the various built_in.o and the final binaries? A fully

True.
> shared set of flags for these two pretty distinct operations
> doesn't seem very sensible anyway. In fact I wonder how
> much of LDFLAGS is actually relevant when passing -r to ld.
>

That would imply that the idea of putting --build-id should be part
only of the final binaries. Which comes back to how this patch was done
originally - only have the --build-id on specific $(LD) lines.

Are you OK if I re-institute the $(build_id) back in the Makefile, perhaps
rename it to $(build_id_linker) to make it more clear?

Thanks.

  reply	other threads:[~2016-01-19 16:05 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-08  2:25 [PATCH v3] Add build-id to XENVER hypercall Konrad Rzeszutek Wilk
2016-01-08  2:25 ` [PATCH v3 1/3] xsm/xen_version: Add XSM for the xen_version hypercall (v6) Konrad Rzeszutek Wilk
2016-01-08 17:57   ` Daniel De Graaf
2016-01-12 16:08   ` Jan Beulich
2016-01-08  2:25 ` [PATCH v3 2/3] XENVER_build_id: Provide ld-embedded build-ids (v8) Konrad Rzeszutek Wilk
2016-01-12 16:25   ` Jan Beulich
2016-01-12 16:43     ` Konrad Rzeszutek Wilk
2016-01-12 17:00       ` Jan Beulich
2016-01-14  2:02         ` Konrad Rzeszutek Wilk
2016-01-14  8:58           ` Jan Beulich
2016-01-14  9:07             ` Martin Pohlack
2016-01-14  9:14               ` Jan Beulich
2016-01-25 15:16         ` Konrad Rzeszutek Wilk
2016-01-25 16:10           ` Jan Beulich
2016-01-15 21:49     ` Konrad Rzeszutek Wilk
2016-01-18  8:51       ` Jan Beulich
2016-01-19 16:05         ` Konrad Rzeszutek Wilk [this message]
2016-01-19 16:36           ` Jan Beulich
2016-01-19 16:47             ` Konrad Rzeszutek Wilk
2016-02-17 11:37   ` Ian Jackson
2016-01-08  2:25 ` [PATCH v3 3/3] libxl: info: Display build_id of the hypervisor Konrad Rzeszutek Wilk
2016-01-11 14:12   ` Wei Liu
2016-01-14  2:58     ` Konrad Rzeszutek Wilk

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=CACJDEmpfC_v+5u_hcHJMrfBO76Xa0rvSgcBVNQWiRznk8OMhOg@mail.gmail.com \
    --to=konrad@kernel.org \
    --cc=JBeulich@suse.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=dgdegra@tycho.nsa.gov \
    --cc=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=mpohlack@amazon.de \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.