Cleanup trailing slashes from FOO_SITE
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest3 patches 0 repliesNew
- v34 patches 0 repliesSuperseded
- v24 patches 0 repliesSuperseded
Earlier versions · 1
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v1 | 0 of 3 patches | 0 replies | Superseded |
Patches in v4 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | toolchain-external: strip trailing slash from autogenerated FOO_SITEtoolchain/ | +1 | 1 reply | |
| 2/3 | pkg-generic: prevent _SITE URLs with a trailing slashpackage/ | +4 | 1 reply | |
| 2/3 | pkg-generic: prevent _SITE URLs with a trailing slash | +0 | 0 replies | |
| 3/3 | download: get rid of trailing slash removal hack for FOO_SITEpackage/ | +1 | 1 reply |
Reviews trailers per patch
2 of 4 patches have a Reviewed-by or Acked-by.
| Patch | Arnout Vandecappelle (Essensium/Mind) |
|---|---|
| 1/3 | R-b |
| 2/3 | |
| 2/3 | |
| 3/3 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [Buildroot] [PATCH v4 0/3] Cleanup trailing slashes from FOO_SITE
Hi,
here's the respin of my patch set to clean up the form of FOO_SITE variables by removing all trailing slashes.
Those slashes are useless and potentially armful, which led to introducing a workaround to strip them:
commit 1cbffbd015106ea90fe49e27433375769dc1035b
Author: Shawn J. Goff <[email protected]>
Date: Fri Apr 12 09:40:30 2013 +0000
eliminate double slashes caused by FOO_SITE ending in a slash
When a FOO_SITE variable ends in a slash and gets joined with a FOO_SOURCE variable like $(FOO_SITE)/$(FOO_SOURCE), the resulting URI has a double slash. While double-slashes are fine in unix paths, they are reserved in URIs - the part following '//' must be an authority.
v1 removed all these slashes but did not add a check to prevent some more ones from slipping in new pagkages, and of course they did. v3 proposed a check, but taht was not ideal. So here's the new, shiny, fully-make-based version that Arnout's headache produced! :)
Patches from v3 have already be merged that remove the slashes in existing packages and to state in tha manual that trailing slashes are incorrect. Here's what's left.
Patch 1 fixes toolchain-external, which introduces a trailing slash on its own. Patch 2 adds a the check to block trailing slashes before building. Finally patch 3 removes the workaround that is not needed anymore.
This work has been inspired by this comment from Arnout Vandecappelle [1]:
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
+else
+ifneq ($$($(2)_ACTUAL_SOURCE_TARBALL),$$($(2)_SOURCE))
+ $(call DOWNLOAD,$$($(2)_ACTUAL_SOURCE_SITE:/=)/$$($(2)$($(PKG)_SITE:/=)_ACTUAL_SOURCE_TARBALL))I think the $($(PKG)_SITE:/=) construct was just introduced because for some
packages, the_SITEends with a / and that should be stripped, and we were too lazy to fix the packages. Hm, looks like all the the external toolchain_SITEsend with a /...
[0] http://lists.busybox.net/pipermail/buildroot/2015-March/121502.html
[1] https://patchwork.ozlabs.org/patch/424980/
Luca Ceresoli (3):
toolchain-external: strip trailing slash from autogenerated FOO_SITE
pkg-generic: prevent _SITE URLs with a trailing slash
download: get rid of trailing slash removal hack for FOO_SITE
package/pkg-generic.mk | 6 +++++- toolchain/toolchain-external/toolchain-external.mk | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-)
Signature · 1 line
1.9.1