From: Yann E. MORIN <yann.morin.1998@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH v3 2/2] docs/manual: patches that change files with spaces in the name
Date: Sun, 24 Jan 2016 17:20:02 +0100 [thread overview]
Message-ID: <20160124162002.GE3405@free.fr> (raw)
In-Reply-To: <1453641593-31129-3-git-send-email-ricardo.martincoski@gmail.com>
Ricardo, All,
On 2016-01-24 11:19 -0200, Ricardo Martincoski spake thusly:
> When a patch changes one or more files with spaces in the name, a
> workaround must be applied to ensure the build using old versions of
> patch in the host system.
>
> Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com>
> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
> Cc: Thomas De Schampheleire <patrickdepinguin@gmail.com>
> Cc: "Yann E. MORIN" <yann.morin.1998@free.fr>
> Cc: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> ---
> Changes v2 -> v3:
> - say "post-extract" instead of "POST_EXTRACT"
> - there is no strong argument to use post-extract instead of pre-patch
> (Arnout)
> - Arnout suggested to drop the patch to the manual:
> "I think that this situation is so exotic that it doesn't warrant a
> mention in the manual. The manual is already long and complicated
> enough."
> I updated the manual for now because it is a separate patch that can
> be Rejected if others agree with Arnout.
Well, like Arnout said, the number of cases that this would bite us is
very limited (as in: there is only one case).
The most problematic issue here is not doing the fix, but recognising
the symptoms. This is such a rare occurence that I'm afraid we'll again
scratch our heads when we next encounter this issue. That is, if there's
ever a "next time"...
So I don't think it is necessary that the manual has a blurb about that.
Regards,
Yann E. MORIN.
> Changes v1 -> v2:
> - update the manual entry
> - use 1 or 2 hooks to rename the file that contains spaces
> (based on the suggestion to use a symlink from Thomas DS)
> - change the patch file to be applied on the renamed file
>
> Symlink and hard link cannot be used because patch unlinks them.
> So I renamed the file before patching it.
> The file can be renamed back when needed.
>
> Probably this patch will need some rewording.
> It's my first patch to the manual.
> I tested using 'make manual-html'
> ---
> docs/manual/patch-policy.txt | 16 ++++++++++++++++
> 1 file changed, 16 insertions(+)
>
> diff --git a/docs/manual/patch-policy.txt b/docs/manual/patch-policy.txt
> index 0b4604e..8e6b3ee 100644
> --- a/docs/manual/patch-policy.txt
> +++ b/docs/manual/patch-policy.txt
> @@ -134,6 +134,22 @@ AC_PROG_MAKE_SET
> +AM_CONDITIONAL([CXX_WORKS], [test "x$rw_cv_prog_cxx_works" = "xyes"])
> ---------------
>
> +==== Patches that change files with spaces in the name
> +
> +When a patch changes one or more files with spaces in the name, a workaround
> +must be applied to ensure the build using old versions of +patch+ in the
> +host system.
> +
> +. Add a pre-patch or a post-extract hook to rename the file to be patched,
> + replacing spaces with underscores;
> +
> +. Create the patch file using the usual diff command, but both
> + +package-version.orig/+ and +package-version/+ must have the file renamed
> + to replace the spaces with underscores;
> +
> +. If the file must keep its name, add a post-patch hook to rename the patched
> + file to its original name;
> +
> === Integrating patches found on the Web
>
> When integrating a patch of which you are not the author, you have to
> --
> 1.9.1
>
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
next prev parent reply other threads:[~2016-01-24 16:20 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-24 13:19 [Buildroot] [PATCH v3 0/2] fix build using old versions of patch Ricardo Martincoski
2016-01-24 13:19 ` [Buildroot] [PATCH v3 1/2] package/libsoil: " Ricardo Martincoski
2016-01-24 14:31 ` Arnout Vandecappelle
2016-01-25 22:35 ` Thomas Petazzoni
2016-02-20 22:26 ` Peter Korsgaard
2016-01-24 13:19 ` [Buildroot] [PATCH v3 2/2] docs/manual: patches that change files with spaces in the name Ricardo Martincoski
2016-01-24 16:20 ` Yann E. MORIN [this message]
2016-01-24 20:48 ` Ricardo Martincoski
2016-01-24 21:08 ` Yann E. MORIN
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=20160124162002.GE3405@free.fr \
--to=yann.morin.1998@free.fr \
--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 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.