Message ID | 20250509173816.1250479-1-erick.shepherd@ni.com |
---|---|
State | New |
Headers | show |
Series | [RFC] kernel-devsrc.bb: Stop copying the System.map files | expand |
On Fri, May 9, 2025 at 1:38 PM Erick Shepherd via lists.openembedded.org <erick.shepherd=ni.com@lists.openembedded.org> wrote: > Currently there are two .map files being copied to $kerneldir/build. > One file is System.map and the other is System.map-<kernel-version>. > Each .map file takes up about 5MB and does not seem to be required for > the compilation of driver software via dkms. This change stops copying > both .map files to save disk space. > dkms isn't something that is relevant for why we copy the .map file It is used for debug and in some scenarios linking. kernel devsrc by definition is not trying to be small, but if the two .map files are exactly the same then a symlink should suffice, or just a single copy. > > Another solution could also be to only copy one .map file to > $kerneldir/build or have one of the .map files by a symlink. If both > .map files are required then this patch can be abandoned. > > Signed-off-by: Erick Shepherd <erick.shepherd@ni.com> > --- > meta/recipes-kernel/linux/kernel-devsrc.bb | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/meta/recipes-kernel/linux/kernel-devsrc.bb > b/meta/recipes-kernel/linux/kernel-devsrc.bb > index 1500aff2e2..298be27ac7 100644 > --- a/meta/recipes-kernel/linux/kernel-devsrc.bb > +++ b/meta/recipes-kernel/linux/kernel-devsrc.bb > @@ -75,7 +75,7 @@ do_install() { > if [ -s Module.symvers ]; then > cp Module.symvers $kerneldir/build > fi > - cp System.map* $kerneldir/build > + > if [ -s Module.markers ]; then > cp Module.markers $kerneldir/build > fi > -- > 2.43.0 > > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#216244): > https://lists.openembedded.org/g/openembedded-core/message/216244 > Mute This Topic: https://lists.openembedded.org/mt/112903585/1050810 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [ > bruce.ashfield@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- > >
diff --git a/meta/recipes-kernel/linux/kernel-devsrc.bb b/meta/recipes-kernel/linux/kernel-devsrc.bb index 1500aff2e2..298be27ac7 100644 --- a/meta/recipes-kernel/linux/kernel-devsrc.bb +++ b/meta/recipes-kernel/linux/kernel-devsrc.bb @@ -75,7 +75,7 @@ do_install() { if [ -s Module.symvers ]; then cp Module.symvers $kerneldir/build fi - cp System.map* $kerneldir/build + if [ -s Module.markers ]; then cp Module.markers $kerneldir/build fi
Currently there are two .map files being copied to $kerneldir/build. One file is System.map and the other is System.map-<kernel-version>. Each .map file takes up about 5MB and does not seem to be required for the compilation of driver software via dkms. This change stops copying both .map files to save disk space. Another solution could also be to only copy one .map file to $kerneldir/build or have one of the .map files by a symlink. If both .map files are required then this patch can be abandoned. Signed-off-by: Erick Shepherd <erick.shepherd@ni.com> --- meta/recipes-kernel/linux/kernel-devsrc.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)