On 07/07/2012 14:10, Jon TURNEY wrote:
On 29/06/2012 20:48, Yaakov (Cygwin/X) wrote:
On Thu, 2012-06-21 at 01:24 -0500, Yaakov (Cygwin/X) wrote:
Attached is a first draft of a patch to support split debuginfo packages
automatically in cygport.
Second draft patch attached.
This works fine. Thanks.
I was going to suggest the use of objcopy --compress-debug-sections, but it
appears that does nothing for PE/COFF files at the moment [1] :-(
[1] http://sourceware.org/bugzilla/show_bug.cgi?id=14067
That bug has been fixed for a while, so how about the attached?
This appears to reduce the disk space used by .dbg files to about 1/3 of
the size, so seems worthwhile.
From 69d6127921a041022990386cb2eed4e8487e23c9 Mon Sep 17 00:00:00 2001
From: Jon TURNEY <jon.tur...@dronecode.org.uk>
Date: Mon, 23 Feb 2015 12:06:07 +0000
Subject: [PATCH] prepstrip: use --compress-debug-sections
---
lib/src_postinst.cygpart | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/src_postinst.cygpart b/lib/src_postinst.cygpart
index e7b80d4..e214e44 100644
--- a/lib/src_postinst.cygpart
+++ b/lib/src_postinst.cygpart
@@ -1053,7 +1053,7 @@ __prepstrip() {
if ! ${objdump} -h "${exe}" | grep -q '\.gnu_deb'
then
dodir "${dbg%/*}";
- ${objcopy} --long-section-names enable
--add-gnu-debuglink=/dev/null --only-keep-debug "${exe}" "${D}${dbg}";
+ ${objcopy} --long-section-names enable
--add-gnu-debuglink=/dev/null --only-keep-debug --compress-debug-sections
"${exe}" "${D}${dbg}";
chmod 0644 "${D}${dbg}";
${objcopy} --strip-all "${exe}";
${objcopy} --long-section-names enable
--add-gnu-debuglink="${D}${dbg}" "${exe}" 2>/dev/null;
--
2.1.4