* [PATCH] Makefile: Force gzip and xz on module install
@ 2015-07-07 18:26 Jason A. Donenfeld
2015-07-13 22:42 ` Jason A. Donenfeld
2015-07-22 15:47 ` Michal Marek
0 siblings, 2 replies; 3+ messages in thread
From: Jason A. Donenfeld @ 2015-07-07 18:26 UTC (permalink / raw)
To: Michal Marek, linux-kbuild, linux-kernel; +Cc: Jason A. Donenfeld
Running `make modules_install` ordinarily will overwrite existing
modules. This is the desired behavior, and is how pretty much every
other `make install` target works.
However, if CONFIG_MODULE_COMPRESS is enabled, modules are passed
through gzip and xz which then do the file writing. Both gzip and xz
will error out if the file already exists, unless -f is passed.
This patch adds -f so that the behavior is uniform.
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
---
Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile
index 6c6f146..5d2ec1c 100644
--- a/Makefile
+++ b/Makefile
@@ -849,10 +849,10 @@ export mod_strip_cmd
mod_compress_cmd = true
ifdef CONFIG_MODULE_COMPRESS
ifdef CONFIG_MODULE_COMPRESS_GZIP
- mod_compress_cmd = gzip -n
+ mod_compress_cmd = gzip -n -f
endif # CONFIG_MODULE_COMPRESS_GZIP
ifdef CONFIG_MODULE_COMPRESS_XZ
- mod_compress_cmd = xz
+ mod_compress_cmd = xz -f
endif # CONFIG_MODULE_COMPRESS_XZ
endif # CONFIG_MODULE_COMPRESS
export mod_compress_cmd
--
2.4.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Makefile: Force gzip and xz on module install
2015-07-07 18:26 [PATCH] Makefile: Force gzip and xz on module install Jason A. Donenfeld
@ 2015-07-13 22:42 ` Jason A. Donenfeld
2015-07-22 15:47 ` Michal Marek
1 sibling, 0 replies; 3+ messages in thread
From: Jason A. Donenfeld @ 2015-07-13 22:42 UTC (permalink / raw)
To: Michal Marek, linux-kbuild, linux-kernel
Bump? This should be trivial to merge, and it fixes a really annoying
bug for module development.
On Tue, Jul 7, 2015 at 8:26 PM, Jason A. Donenfeld <Jason@zx2c4.com> wrote:
> Running `make modules_install` ordinarily will overwrite existing
> modules. This is the desired behavior, and is how pretty much every
> other `make install` target works.
>
> However, if CONFIG_MODULE_COMPRESS is enabled, modules are passed
> through gzip and xz which then do the file writing. Both gzip and xz
> will error out if the file already exists, unless -f is passed.
>
> This patch adds -f so that the behavior is uniform.
>
> Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
> ---
> Makefile | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 6c6f146..5d2ec1c 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -849,10 +849,10 @@ export mod_strip_cmd
> mod_compress_cmd = true
> ifdef CONFIG_MODULE_COMPRESS
> ifdef CONFIG_MODULE_COMPRESS_GZIP
> - mod_compress_cmd = gzip -n
> + mod_compress_cmd = gzip -n -f
> endif # CONFIG_MODULE_COMPRESS_GZIP
> ifdef CONFIG_MODULE_COMPRESS_XZ
> - mod_compress_cmd = xz
> + mod_compress_cmd = xz -f
> endif # CONFIG_MODULE_COMPRESS_XZ
> endif # CONFIG_MODULE_COMPRESS
> export mod_compress_cmd
> --
> 2.4.2
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Makefile: Force gzip and xz on module install
2015-07-07 18:26 [PATCH] Makefile: Force gzip and xz on module install Jason A. Donenfeld
2015-07-13 22:42 ` Jason A. Donenfeld
@ 2015-07-22 15:47 ` Michal Marek
1 sibling, 0 replies; 3+ messages in thread
From: Michal Marek @ 2015-07-22 15:47 UTC (permalink / raw)
To: Jason A. Donenfeld, linux-kbuild, linux-kernel
Dne 7.7.2015 v 20:26 Jason A. Donenfeld napsal(a):
> Running `make modules_install` ordinarily will overwrite existing
> modules. This is the desired behavior, and is how pretty much every
> other `make install` target works.
>
> However, if CONFIG_MODULE_COMPRESS is enabled, modules are passed
> through gzip and xz which then do the file writing. Both gzip and xz
> will error out if the file already exists, unless -f is passed.
>
> This patch adds -f so that the behavior is uniform.
>
> Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Applied to kbuild.git#rc-fixes.
Michal
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-07-22 15:47 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-07 18:26 [PATCH] Makefile: Force gzip and xz on module install Jason A. Donenfeld
2015-07-13 22:42 ` Jason A. Donenfeld
2015-07-22 15:47 ` Michal Marek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).