* A question about compiling Linux kernel
@ 2023-03-09 21:22 Mirsad Goran Todorovac
2023-03-10 2:21 ` Bagas Sanjaya
0 siblings, 1 reply; 2+ messages in thread
From: Mirsad Goran Todorovac @ 2023-03-09 21:22 UTC (permalink / raw)
To: Bagas Sanjaya; +Cc: LKML
Hi Mr. Bagas,
If you can recall, you instructed me to use ccache, however with frequent rebuilds
and especially bisects it would be better to recompile just the objects that have
changed between the versions, rather than doing "make clean; make CC='ccache gcc'"
Is it safe to just do make CC='ccache gcc' and let make decide what to recompile?
Normally I would experiment, but it is hard to predict what could happen with
63500 source files. Especially if .config is changed?
Of course "make clean" is obviously the safest way, but it might not be exactly
environmentally friendly :-)
I am not certain how git changes mtime and ctime when doing "git checkout <version>"?
Will make be able to handle this, or is it best to do a "make clean" and rebuild
from scratch. Possibly speeding up things with ccache ...
Thank you very much for all your support in the past months since August.
Best regards,
Mirsad
--
Mirsad Goran Todorovac
Sistem inženjer
Grafički fakultet | Akademija likovnih umjetnosti
Sveučilište u Zagrebu
System engineer
Faculty of Graphic Arts | Academy of Fine Arts
University of Zagreb, Republic of Croatia
The European Union
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: A question about compiling Linux kernel
2023-03-09 21:22 A question about compiling Linux kernel Mirsad Goran Todorovac
@ 2023-03-10 2:21 ` Bagas Sanjaya
0 siblings, 0 replies; 2+ messages in thread
From: Bagas Sanjaya @ 2023-03-10 2:21 UTC (permalink / raw)
To: Mirsad Goran Todorovac; +Cc: LKML, Linux Kernel Build System, Masahiro Yamada
On 3/10/23 04:22, Mirsad Goran Todorovac wrote:
> Hi Mr. Bagas,
>
> If you can recall, you instructed me to use ccache, however with frequent rebuilds
> and especially bisects it would be better to recompile just the objects that have
> changed between the versions, rather than doing "make clean; make CC='ccache gcc'"
>
> Is it safe to just do make CC='ccache gcc' and let make decide what to recompile?
>
I have tried building a userspace application, for which the source code is
obtained by git. I do the initial build first, then git pull-ing without cleaning
the build directory, then incremental rebuild (usually `make` or `ninja`).
The incremental build only rebuild what is changed. However, when the version
identifier (mostly via build config) is changed, all previous build artifacts
are invalidated, essentially rebuild from scratch.
IMO, above can also be applied to Linux kernel (but I haven't tried to build
that way).
Cc: linux-kbuild list since I'm unsure on this.
Thanks.
--
An old man doll... just what I always wanted! - Clara
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-03-10 2:21 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-09 21:22 A question about compiling Linux kernel Mirsad Goran Todorovac
2023-03-10 2:21 ` Bagas Sanjaya
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®