F28 Self Contained Change: MinGW MiniDebugInfo

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



= Proposed Self Contained Change: MinGW MiniDebugInfo =
https://fedoraproject.org/wiki/Changes/MingwMiniDebugInfo

Change owner(s):
* Sandro Mani <manisandro AT gmail DOT com>

Analogously to the MiniDebugInfo change [1] for native packages,
install minimal debuginfos by default also for MinGW packages.

== Detailed Description ==
Currently the debuginfo data of MinGW binaries is completely stripped
from the binary and placed in the respective .debuginfo file. This
change proposes keeping the PE symbols in the binary, similarly to
what was done for native binaries [1].

The change basically involves changing mingw-find-debuginfo.sh as follows:

diff --git a/mingw-filesystem/mingw-find-debuginfo.sh
b/mingw-filesystem/mingw-find-debuginfo.sh
index de6dee1..261385f 100755
--- a/mingw-filesystem/mingw-find-debuginfo.sh
+++ b/mingw-filesystem/mingw-find-debuginfo.sh
@@ -25,7 +25,10 @@ do
        echo extracting debug info from $f
        mingw-objcopy --only-keep-debug $f $f.debug || :
        pushd `dirname $f`
-       mingw-objcopy --add-gnu-debuglink=`basename $f.debug`
--strip-unneeded `basename $f` || :
+       keep_symbols=`mktemp`
+  mingw-nm $f.debug --format=sysv --defined-only | awk -F \| '{ if
($4 ~ "Function") print $1 }' | sort > "$keep_symbols"
+       mingw-objcopy --add-gnu-debuglink=`basename $f.debug`
--strip-unneeded `basename $f` --keep-symbols="$keep_symbols" || :
+       rm -f "$keep_symbols"
        popd
 done

A test with some packages in this COPR repo [2] shows that the price
is a size increase of in average 17%:


== Scope ==
* Proposal owners:
- Change mingw-binutils toalso install a generic mingw-nm, which will
be used by mingw-find-debuginfo.sh
- Change mingw-find-debuginfo.sh as outlined above
- Rebuild all mingw packages

* Other developers: N/A (not a System Wide Change)

* Release engineering: #7005 https://pagure.io/releng/issue/7005

* List of deliverables: N/A (not a System Wide Change)

* Policies and guidelines: N/A (not a System Wide Change)

* Trademark approval: N/A (not needed for this Change)


[1] https://fedoraproject.org/wiki/Features/MiniDebugInfo
[2] https://copr.fedorainfracloud.org/coprs/smani/mingw-debuginfo-test/builds/
-- 
Jan Kuřík
Platform & Fedora Program Manager
Red Hat Czech s.r.o., Purkynova 99/71, 612 45 Brno, Czech Republic
_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux