This is a tracking bug for Change: Separate Subpackage and Source Debuginfo For more details, see: https://fedoraproject.org//wiki/Changes/SubpackageAndSourceDebuginfo Allow to install just the debuginfo for a subpackage and/or without the source files. The debuginfo packages are huge because they contain debuginfo and all sources for all subpackages. Being able to install only the debuginfo for the subpackage that is installed reduces the size that needs to be downloaded to analyze, trace, profile or debug a program or core file. Some tracing and profiling tools don't need the actual source files to provide stack traces or insert probes. So installing the debugsources should be optional.
On 2017-Feb-28, we have reached the Fedora 26 Change Checkpoint: Completion deadline (testable). At this point, all accepted changes should be substantially complete, and testable. Additionally, if a change is to be enabled by default, it must be enabled at Change Completion deadline as well. Change tracking bug should be set to the MODIFIED state to indicate it achieved completeness. Incomplete and non testable Changes will be reported to FESCo for 2017-Mar-03 meeting.
This bug appears to have been reported against 'rawhide' during the Fedora 26 development cycle. Changing version to '26'.
May I ask for status update on this Change, as requested in Comment #1 ?
The feature is not complete and testable. We'll include it in rawhide only. We might even backport it to f26, but NOT enable it by default.
Deferred to F27: https://meetbot.fedoraproject.org/teams/fesco/fesco.2017-03-17-16.00.html
This has been enabled just before the f27 mass rebuild.
This bug appears to have been reported against 'rawhide' during the Fedora 27 development cycle. Changing version to '27'.
On 2017-Sep-05 we reached the "Change Checkpoint: 100% Code Complete Deadline" milestone for Fedora 27 release. At this point all the Changes not at least in "ON_QA" state should be brought to FESCo for review. Please update the state of this bug to "ON_QA" if it is already 100% completed. Please let me know in case you have any trouble with the implementation and the Change needs any help or review. Thanks, Jan
"How To Test" section on wiki https://fedoraproject.org//wiki/Changes/SubpackageAndSourceDebuginfo says: Unfinished. Running a tracer (systemtap), profiler (pref) or debugger (gdb) against a program or core file should suggest the correct debuginfo/sources packages to install. After that the tracing/profiling/debugging session should work as before. And it does not work for me. There are missing source files: sh# rpm -q gdb gdb-8.0-24.fc27.x86_64 sh# gdb /usr/bin/ls GNU gdb (GDB) Fedora 8.0-24.fc27 Copyright (C) 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-redhat-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from /usr/bin/ls...Reading symbols from /usr/bin/ls...(no debugg (no debugging symbols found)...done. Missing separate debuginfos, use: dnf debuginfo-install coreutils-8.27-16.fc27.x (gdb) q sh# dnf debuginfo-install -y coreutils-8.27-16.fc27.x86_64 enabling updates-testing-debuginfo repository enabling updates-debuginfo repository enabling fedora-debuginfo repository Last metadata expiration check: 0:05:46 ago on Sat 09 Sep 2017 11:10:51 AM EDT. Dependencies resolved. ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: coreutils-debuginfo x86_64 8.27-16.fc27 fedora-debuginfo 2.8 M Transaction Summary ================================================================================ Install 1 Package Total download size: 2.8 M Installed size: 17 M Downloading Packages: coreutils-debuginfo-8.27-16.fc27.x86_64.rpm 4.2 MB/s | 2.8 MB 00:00 -------------------------------------------------------------------------------- Total 2.6 MB/s | 2.8 MB 00:01 Running transaction check Transaction check succeeded. Running transaction test Transaction test succeeded. Running transaction Preparing : 1/1 Installing : coreutils-debuginfo-8.27-16.fc27.x86_64 1/1 Verifying : coreutils-debuginfo-8.27-16.fc27.x86_64 1/1 Installed: coreutils-debuginfo.x86_64 8.27-16.fc27 Complete! sh# gdb /usr/bin/ls -ex "b main" -ex r GNU gdb (GDB) Fedora 8.0-24.fc27 Copyright (C) 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-redhat-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from /usr/bin/ls...Reading symbols from /usr/lib/debug/usr/bin/ls-8.27-16.fc27.x86_64.debug...done. done. Breakpoint 1 at 0x3c10: file ../src/ls.c, line 1427. Starting program: /usr/bin/ls [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". Breakpoint 1, main (argc=1, argv=0x7fffffffdb88) at ../src/ls.c:1427 1427 ../src/ls.c: No such file or directory. Missing separate debuginfos, use: dnf debuginfo-install libcap-2.25-7.fc27.x86_64 The main problem is "No such file or directory." sh# rpm -qa | grep debugsource sh# rpm -qa | grep coreut coreutils-common-8.27-16.fc27.x86_64 policycoreutils-devel-2.7-1.fc27.x86_64 policycoreutils-python-utils-2.7-1.fc27.x86_64 policycoreutils-python-2.7-1.fc27.x86_64 policycoreutils-python3-2.7-1.fc27.x86_64 coreutils-8.27-16.fc27.x86_64 policycoreutils-2.7-1.fc27.x86_64 coreutils-debuginfo-8.27-16.fc27.x86_64
(In reply to Lukas Slebodnik from comment #9) > "How To Test" section on wiki > https://fedoraproject.org//wiki/Changes/SubpackageAndSourceDebuginfo says: > > Unfinished. Running a tracer (systemtap), profiler (pref) or debugger (gdb) > against a program or core file should suggest the correct debuginfo/sources > packages to install. After that the tracing/profiling/debugging session > should > work as before. > > And it does not work for me. There are missing source files: Thanks for testing. > sh# dnf debuginfo-install -y coreutils-8.27-16.fc27.x86_64 > enabling updates-testing-debuginfo repository > enabling updates-debuginfo repository > enabling fedora-debuginfo repository > Last metadata expiration check: 0:05:46 ago on Sat 09 Sep 2017 11:10:51 AM > EDT. > Dependencies resolved. > ============================================================================= > === > Package Arch Version Repository > Size > ============================================================================= > === > Installing: > coreutils-debuginfo x86_64 8.27-16.fc27 fedora-debuginfo > 2.8 M > > Transaction Summary > ============================================================================= > === > Install 1 Package > > Total download size: 2.8 M > Installed size: 17 M > Downloading Packages: > coreutils-debuginfo-8.27-16.fc27.x86_64.rpm 4.2 MB/s | 2.8 MB 00:00 > > ----------------------------------------------------------------------------- > --- > Total 2.6 MB/s | 2.8 MB 00:01 > > Running transaction check > Transaction check succeeded. > Running transaction test > Transaction test succeeded. > Running transaction > Preparing : > 1/1 > Installing : coreutils-debuginfo-8.27-16.fc27.x86_64 > 1/1 > Verifying : coreutils-debuginfo-8.27-16.fc27.x86_64 > 1/1 > > Installed: > coreutils-debuginfo.x86_64 8.27-16.fc27 > > > Complete! > > sh# gdb /usr/bin/ls -ex "b main" -ex r > GNU gdb (GDB) Fedora 8.0-24.fc27 > Copyright (C) 2017 Free Software Foundation, Inc. > License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> > This is free software: you are free to change and redistribute it. > There is NO WARRANTY, to the extent permitted by law. Type "show copying" > and "show warranty" for details. > This GDB was configured as "x86_64-redhat-linux-gnu". > Type "show configuration" for configuration details. > For bug reporting instructions, please see: > <http://www.gnu.org/software/gdb/bugs/>. > Find the GDB manual and other documentation resources online at: > <http://www.gnu.org/software/gdb/documentation/>. > For help, type "help". > Type "apropos word" to search for commands related to "word"... > Reading symbols from /usr/bin/ls...Reading symbols from > /usr/lib/debug/usr/bin/ls-8.27-16.fc27.x86_64.debug...done. > done. > Breakpoint 1 at 0x3c10: file ../src/ls.c, line 1427. > Starting program: /usr/bin/ls > [Thread debugging using libthread_db enabled] > Using host libthread_db library "/lib64/libthread_db.so.1". > > Breakpoint 1, main (argc=1, argv=0x7fffffffdb88) at ../src/ls.c:1427 > 1427 ../src/ls.c: No such file or directory. > [...] > sh# rpm -qa | grep debugsource > sh# rpm -qa | grep coreut > coreutils-common-8.27-16.fc27.x86_64 > policycoreutils-devel-2.7-1.fc27.x86_64 > policycoreutils-python-utils-2.7-1.fc27.x86_64 > policycoreutils-python-2.7-1.fc27.x86_64 > policycoreutils-python3-2.7-1.fc27.x86_64 > coreutils-8.27-16.fc27.x86_64 > policycoreutils-2.7-1.fc27.x86_64 > coreutils-debuginfo-8.27-16.fc27.x86_64 Right. The problem is that you do also need coreutils-debugsource. And coreutils-debuginfo doesn't require it (and that is intended). Igor, should we make the dnf debuginfo-install plugin also install the -debugsources package? We could also make coreutils-debuginfo recommend coreutils-debugsources. And/Or we could make gdb smarter and let it suggest you install coreutils-debugsources if it detects the sources are missing.
> Igor, should we make the dnf debuginfo-install plugin also install the -debugsources package? We can, but should we? > We could also make coreutils-debuginfo recommend coreutils-debugsources. Might be not bad idea.
I'm fine with extending gdb as well. because I usually copy&paste (In reply to Igor Gnatenko from comment #11) > > Igor, should we make the dnf debuginfo-install plugin also install the -debugsources package? > > We can, but should we? > Maybe not by default but after setting new and extra option. ( > > We could also make coreutils-debuginfo recommend coreutils-debugsources. > > Might be not bad idea. This well not work for users which disabled weak dependencies in dnf.conf (install_weak_deps=False) unless gdb recommends to enable installing weak dependencies. >And/Or we could make gdb smarter and let it suggest you install coreutils-debugsources if it detects the sources are missing. That would work for me. Because I usually copy&paste hint from gdb.
(In reply to Igor Gnatenko from comment #11) > > Igor, should we make the dnf debuginfo-install plugin also install the -debugsources package? > > We can, but should we? Yes, I think we should at least offer the option to (also) install the debugsources packages. It might even be the default in f27 to make things compatible with how they were in f26. > > We could also make coreutils-debuginfo recommend coreutils-debugsources. > > Might be not bad idea. OK. I'll propose something upstream. It will of course require packages to be rebuild. (In reply to Lukas Slebodnik from comment #12) > >And/Or we could make gdb smarter and let it suggest you install coreutils-debugsources if it detects the sources are missing. > > That would work for me. Because I usually copy&paste hint from gdb. OK. But that requires knowing how/if dnf debuginfo-install plugin gets changed to support fetching the debugsources package. Because currently it suggests: (no debugging symbols found)...done. Missing separate debuginfos, use: dnf debuginfo-install ...
(In reply to Mark Wielaard from comment #13) > (In reply to Lukas Slebodnik from comment #12) > > >And/Or we could make gdb smarter and let it suggest you install coreutils-debugsources if it detects the sources are missing. > > > > That would work for me. Because I usually copy&paste hint from gdb. > > OK. But that requires knowing how/if dnf debuginfo-install plugin gets > changed to support fetching the debugsources package. Because currently it > suggests: > > (no debugging symbols found)...done. > Missing separate debuginfos, use: dnf debuginfo-install ... A new option could be backported also to older version of plugin (f25, f26) and it would be a noop there. e.g. dnf debuginfo-install --install-debug-source mc
(In reply to Mark Wielaard from comment #13) > (In reply to Igor Gnatenko from comment #11) > > > Igor, should we make the dnf debuginfo-install plugin also install the -debugsources package? > > > > We can, but should we? > > Yes, I think we should at least offer the option to (also) install the > debugsources packages. It might even be the default in f27 to make things > compatible with how they were in f26. This turned out to be very easy. It is just two oneliners. One to base dnf to return the correct debug source package name: --- dnf/package.py.orig 2017-09-14 17:01:59.017810658 +0200 +++ dnf/package.py 2017-09-14 17:45:33.992366055 +0200 @@ -103,7 +103,7 @@ returns name of debuginfo package for source package of given package e.g. krb5-libs -> krb5-debuginfo """ - return "{}-debuginfo".format(self.source_name) + return "{}-debugsource".format(self.source_name) @property def source_name(self): And one to the debuginfo-install dnf plugin to not abort too early when looking for all available debug packages: --- dnf-plugins/debuginfo-install.py.orig 2017-09-14 17:44:26.624875885 +0200 +++ dnf-plugins/debuginfo-install.py 2017-09-14 17:44:47.672404171 +0200 @@ -98,7 +98,7 @@ def _di_install(self, package): for dbgname in [package.debug_name, package.source_debug_name]: if dbgname in self.dbgdone: - break + continue if self._dbg_available(dbgname, package, True): di = "{0}-{1}:{2}-{3}.{4}".format( dbgname,
(In reply to Mark Wielaard from comment #13) > (In reply to Igor Gnatenko from comment #11) > > > We could also make coreutils-debuginfo recommend coreutils-debugsources. > > > > Might be not bad idea. > > OK. I'll propose something upstream. > It will of course require packages to be rebuild. I suggested a patch upstream to implement this: http://lists.rpm.org/pipermail/rpm-maint/2017-September/006607.html
(In reply to Mark Wielaard from comment #16) > (In reply to Mark Wielaard from comment #13) > > (In reply to Igor Gnatenko from comment #11) > > > > We could also make coreutils-debuginfo recommend coreutils-debugsources. > > > > > > Might be not bad idea. > > > > OK. I'll propose something upstream. > > It will of course require packages to be rebuild. > > I suggested a patch upstream to implement this: > http://lists.rpm.org/pipermail/rpm-maint/2017-September/006607.html This is now upstream and will be in the 4.14 release that should also go into Fedora 27. (In reply to Mark Wielaard from comment #15) > (In reply to Mark Wielaard from comment #13) > > (In reply to Igor Gnatenko from comment #11) > > > > Igor, should we make the dnf debuginfo-install plugin also install the -debugsources package? > > > > > > We can, but should we? > > > > Yes, I think we should at least offer the option to (also) install the > > debugsources packages. It might even be the default in f27 to make things > > compatible with how they were in f26. > > This turned out to be very easy. It is just two oneliners. > One to base dnf to return the correct debug source package name: For this I opened a new bug: https://bugzilla.redhat.com/show_bug.cgi?id=1494628