From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH v6 02/10] package/patchelf: add patch for rpath sanitization under a root directory
Date: Wed, 5 Jul 2017 13:16:00 +0200 [thread overview]
Message-ID: <20170705131600.05eadaa9@windsurf> (raw)
In-Reply-To: <1499185359-8293-3-git-send-email-wg@grandegger.com>
Hello,
On Tue, 4 Jul 2017 18:22:31 +0200, Wolfgang Grandegger wrote:
> diff --git a/package/patchelf/0001-Remove-apparently-incorrect-usage-of-static.patch b/package/patchelf/0001-Remove-apparently-incorrect-usage-of-static.patch
> new file mode 100644
> index 0000000..46fd123
> --- /dev/null
> +++ b/package/patchelf/0001-Remove-apparently-incorrect-usage-of-static.patch
> @@ -0,0 +1,49 @@
> +From a365bcb7d7025da51b33165ef7ebc7180199a05e Mon Sep 17 00:00:00 2001
> +From: Eelco Dolstra <eelco.dolstra@logicblox.com>
> +Date: Mon, 19 Sep 2016 17:31:37 +0200
> +Subject: [PATCH 14/30] Remove apparently incorrect usage of "static"
The 14/30 should be removed, just make it [PATCH]
> +
Please add here:
[Upstream commit: URL of the upstream commit.]
Signed-off-by: ...
> diff --git a/package/patchelf/0002-Extract-a-function-for-splitting-a-colon-separated-s.patch b/package/patchelf/0002-Extract-a-function-for-splitting-a-colon-separated-s.patch
> new file mode 100644
> index 0000000..63f3bce
> --- /dev/null
> +++ b/package/patchelf/0002-Extract-a-function-for-splitting-a-colon-separated-s.patch
> @@ -0,0 +1,58 @@
> +From 2e3fdc2030c75c19df6fc2924083cfad53856562 Mon Sep 17 00:00:00 2001
> +From: Tuomas Tynkkynen <tuomas@tuxera.com>
> +Date: Fri, 3 Jun 2016 23:03:51 +0300
> +Subject: [PATCH 08/30] Extract a function for splitting a colon-separated
> + string
> +
> +We're going to need this logic in another place, so make a function of
> +this.
Same comments here.
> diff --git a/package/patchelf/0003-Add-option-to-make-the-rpath-relative-under-a-specif.patch b/package/patchelf/0003-Add-option-to-make-the-rpath-relative-under-a-specif.patch
> new file mode 100644
> index 0000000..4f700d9
> --- /dev/null
> +++ b/package/patchelf/0003-Add-option-to-make-the-rpath-relative-under-a-specif.patch
> @@ -0,0 +1,419 @@
> +From af8d4a24a0ef613bdb47f0b1c3d962d59c53a4be Mon Sep 17 00:00:00 2001
> +From: Wolfgang Grandegger <wg@grandegger.com>
> +Date: Mon, 20 Feb 2017 16:29:24 +0100
> +Subject: [PATCH] Add option to make the rpath relative under a specified root
> + directory
> +
> +Running "patchelf" with the option "--make-rpath-relative ROOTDIR" will
> +modify or delete the RPATHDIRs according the following rules
> +similar to Martin's patches [1] making the Buildroot toolchaing/SDK
> +relocatable.
> +
> +RPATHDIR starts with "$ORIGIN":
> + The original build-system already took care of setting a relative
> + RPATH, resolve it and test if it's valid (does exist)
> +
> +RPATHDIR starts with ROOTDIR:
> + The original build-system added some absolute RPATH (absolute on
> + the build machine). Test if it's valid (does exist).
> +
> +ROOTDIR/RPATHDIR exists:
> + The original build-system already took care of setting an absolute
> + RPATH (absolute in the final rootfs), resolve it and test if it's
> + valid (does exist).
> +
> +RPATHDIR points somewhere else:
> + (can be anywhere: build trees, staging tree, host location,
> + non-existing location, etc.). Just discard such a path.
> +
> +The option "--no-standard-libs" will discard RPATHDIRs ROOTDIR/lib and
> +ROOTDIR/usr/lib. Like "--shrink-rpath", RPATHDIRs are also discarded
> +if the directories do not contain a library referenced by the
> +DT_NEEDED fields.
> +If the option "--relative-to-file" is given, the rpath will start
> +with "$ORIGIN" making it relative to the ELF file, otherwise an
> +absolute path relative to ROOTDIR will be used.
> +
> +[1] http://lists.busybox.net/pipermail/buildroot/2016-April/159422.html
If this has been accepted upstream, add the URL to the upstream commit
here as well.
Thanks!
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
next prev parent reply other threads:[~2017-07-05 11:16 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-04 16:22 [Buildroot] [PATCH v6 00/10] Make the SDK relocatable Wolfgang Grandegger
2017-07-04 16:22 ` [Buildroot] [PATCH v6 01/10] support/scripts: check-host-rpath now handles $ORIGIN/../lib Wolfgang Grandegger
2017-07-05 11:14 ` Thomas Petazzoni
2017-07-04 16:22 ` [Buildroot] [PATCH v6 02/10] package/patchelf: add patch for rpath sanitization under a root directory Wolfgang Grandegger
2017-07-05 11:16 ` Thomas Petazzoni [this message]
2017-07-05 12:35 ` Wolfgang Grandegger
2017-07-05 13:13 ` Thomas Petazzoni
2017-07-05 14:26 ` Arnout Vandecappelle
2017-07-04 16:22 ` [Buildroot] [PATCH v6 03/10] support/scripts: add fix-rpath script to sanitize the rpath Wolfgang Grandegger
2017-07-04 16:22 ` [Buildroot] [PATCH v6 04/10] core: sanitize RPATH in staging tree at the end of target finalization Wolfgang Grandegger
2017-07-04 16:22 ` [Buildroot] [PATCH v6 05/10] core: sanitize RPATH in target " Wolfgang Grandegger
2017-07-04 16:22 ` [Buildroot] [PATCH v6 06/10] core: sanitize RPATH in host tree at the very end of the build Wolfgang Grandegger
2017-07-04 16:22 ` [Buildroot] [PATCH v6 07/10] support/scripts: add relocate-sdk.sh script for SDK relocation Wolfgang Grandegger
2017-07-04 16:22 ` [Buildroot] [PATCH v6 08/10] core: install relocation script and location at the end of the build Wolfgang Grandegger
2017-07-04 16:22 ` [Buildroot] [PATCH v6 09/10] external-toolchain: check if a buildroot SDK has already been relocated Wolfgang Grandegger
2017-07-04 16:22 ` [Buildroot] [PATCH v6 10/10] package/qt5base: provide "qt.conf" to make "qmake" relocatable Wolfgang Grandegger
2017-07-05 8:59 ` Arnout Vandecappelle
2017-07-05 9:30 ` Wolfgang Grandegger
2017-07-05 10:28 ` Wolfgang Grandegger
2017-07-05 13:48 ` Wolfgang Grandegger
2017-07-05 14:13 ` Thomas Petazzoni
2017-07-05 14:33 ` Wolfgang Grandegger
2017-07-05 14:48 ` Thomas Petazzoni
2017-07-05 15:10 ` Wolfgang Grandegger
2017-07-05 14:49 ` Arnout Vandecappelle
2017-07-05 14:34 ` Arnout Vandecappelle
2017-07-05 9:30 ` Thomas Petazzoni
2017-07-05 9:55 ` Wolfgang Grandegger
2017-07-04 17:55 ` [Buildroot] [PATCH v6 00/10] Make the SDK relocatable Arnout Vandecappelle
2017-07-04 19:54 ` Wolfgang Grandegger
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=20170705131600.05eadaa9@windsurf \
--to=thomas.petazzoni@free-electrons.com \
--cc=buildroot@busybox.net \
/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