* [PATCH] cc1 and cc1plus had about 20 mbytes of debug information each, in the final redistributable form. This patch strips those two binaries yielding a savings of about 40 mbytes per SDK.
@ 2011-03-07 18:33 Dick Hollenbeck
2011-03-07 19:08 ` Tom Rini
0 siblings, 1 reply; 3+ messages in thread
From: Dick Hollenbeck @ 2011-03-07 18:33 UTC (permalink / raw)
To: openembedded-devel; +Cc: Dick Hollenbeck
Signed-off-by: Dick Hollenbeck <dick@softplc.com>
---
recipes/gcc/gcc-package-sdk.inc | 5 +++++
recipes/gcc/gcc-package-target.inc | 5 +++++
2 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/recipes/gcc/gcc-package-sdk.inc b/recipes/gcc/gcc-package-sdk.inc
index 1b6529f..54452fa 100644
--- a/recipes/gcc/gcc-package-sdk.inc
+++ b/recipes/gcc/gcc-package-sdk.inc
@@ -65,4 +65,9 @@ do_install () {
fi
done
fi
+
+ # Manually strip unneeded debug info from files that were not being stripped
+ ${BUILD_STRIP} ${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/cc1${EXEEXT}
+ ${BUILD_STRIP} ${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/cc1plus${EXEEXT}
+ ${BUILD_STRIP} ${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/collect2${EXEEXT}
}
diff --git a/recipes/gcc/gcc-package-target.inc b/recipes/gcc/gcc-package-target.inc
index 438c314..2a415be 100644
--- a/recipes/gcc/gcc-package-target.inc
+++ b/recipes/gcc/gcc-package-target.inc
@@ -168,4 +168,9 @@ GROUP ( libgcc_s.so.1 libgcc.a )" > ${D}${libdir}/libgcc_s.so
# Remove precompiled c++ headers as they are really big
rm -rf ${D}${includedir}/c++/${BINV}/${TARGET_SYS}/bits/*.gch
+
+ # Manually strip unneeded debug info from files that were not being stripped
+ ${STRIP} ${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/cc1
+ ${STRIP} ${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/cc1plus
+ ${STRIP} ${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/collect2
}
--
1.7.0.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] cc1 and cc1plus had about 20 mbytes of debug information each, in the final redistributable form. This patch strips those two binaries yielding a savings of about 40 mbytes per SDK.
2011-03-07 18:33 Dick Hollenbeck
@ 2011-03-07 19:08 ` Tom Rini
0 siblings, 0 replies; 3+ messages in thread
From: Tom Rini @ 2011-03-07 19:08 UTC (permalink / raw)
To: openembedded-devel
On 03/07/2011 11:33 AM, Dick Hollenbeck wrote:
> Signed-off-by: Dick Hollenbeck<dick@softplc.com>
We recently added logic to conf/distro/include/sane-toolchain-* to
handle the debug level via DEBUG_LEVEL. Would you mind adding a
DEBUG_LEVEL_HOST to conf/bitbake.conf and making BUILD_OPTIMIZATION obey
that instead so that we can drop debug info from all of them? Thanks.
--
Tom Rini
Mentor Graphics Corporation
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] cc1 and cc1plus had about 20 mbytes of debug information each, in the final redistributable form. This patch strips those two binaries yielding a savings of about 40 mbytes per SDK.
@ 2011-03-07 19:57 Dick Hollenbeck
0 siblings, 0 replies; 3+ messages in thread
From: Dick Hollenbeck @ 2011-03-07 19:57 UTC (permalink / raw)
To: openembedded-devel
> Signed-off-by: Dick Hollenbeck<dick at softplc.com
<http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel>>
>We recently added logic to conf/distro/include/sane-toolchain-* to
>handle the debug level via DEBUG_LEVEL. Would you mind adding a
>DEBUG_LEVEL_HOST to conf/bitbake.conf and making BUILD_OPTIMIZATION obey
>that instead so that we can drop debug info from all of them? Thanks.
Tom,
Thanks. On this one, please just take it over. I am still coming up to
speed, and am not able to decipher what you want in a way that will make you
happy.
I know its only a few lines, and you'll want it done a certain way anyway.
Thanks tons. The disk savings is substantial and worth your time.
Next time I'll be better positioned to help.
Dick
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-03-07 20:25 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-07 19:57 [PATCH] cc1 and cc1plus had about 20 mbytes of debug information each, in the final redistributable form. This patch strips those two binaries yielding a savings of about 40 mbytes per SDK Dick Hollenbeck
-- strict thread matches above, loose matches on Subject: below --
2011-03-07 18:33 Dick Hollenbeck
2011-03-07 19:08 ` Tom Rini
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.