Bug 571686 - mingw32 information on generating debuginfo in the guidelines is incorrect, and they need to be updated
Summary: mingw32 information on generating debuginfo in the guidelines is incorrect, a...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: mingw32-filesystem
Version: rawhide
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Richard W.M. Jones
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-03-09 08:39 UTC by Anders Wäänänen
Modified: 2011-05-18 19:18 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-05-18 19:18:33 UTC


Attachments (Terms of Use)

Description Anders Wäänänen 2010-03-09 08:39:38 UTC
Description of problem:

Even if the specfile includes:

%define __strip %{_mingw32_strip}

mingw32 cross-compiled packages does not get their DLL's or binaries
stripped.

Version-Release number of selected component (if applicable):

Checked with:

mingw32-filesystem-56-1

How reproducible:

Very easy to reproduce by building a mingw32 package. Also official Fedora
mingw32 packages are not stripped either - I tested the package:
mingw32-pixman-0.14.0-1.fc11.

Steps to Reproduce:
1. cp -p /usr/i686-pc-mingw32/sys-root/mingw/bin/libpixman-1-0.dll /tmp
2. i686-pc-mingw32-strip /tmp/libpixman-1-0.dll
  
Actual results:

# ls -1s /usr/i686-pc-mingw32/sys-root/mingw/bin/libpixman-1-0.dll /tmp/libpixman-1-0.dll
 252 /tmp/libpixman-1-0.dll
1252 /usr/i686-pc-mingw32/sys-root/mingw/bin/libpixman-1-0.dll


Expected results:

# ls -1s /usr/i686-pc-mingw32/sys-root/mingw/bin/libpixman-1-0.dll /tmp/libpixman-1-0.dll
 252 /tmp/libpixman-1-0.dll
 252 /usr/i686-pc-mingw32/sys-root/mingw/bin/libpixman-1-0.dll

Additional info:

Comment 1 Erik van Pienbroek 2010-03-09 16:52:27 UTC
Hi,

Stripping debug symbols and collecting them in -debuginfo subpackages was introduced in Fedora 12. I noticed that you're still using the Fedora 11 mingw packages, so chances are that your problem is already solved in Fedora 12. Could you please try again with the Fedora 12 packages ?

Comment 2 Mattias Ellert 2010-03-09 18:36:03 UTC
None of the packages I build on Fedora 12 gets stripped, even though I follow the guidelines on http://fedoraproject.org/wiki/Packaging/MinGW

Looking at the mingw32 packages in Fedora 12 some are stripped and some are not. Looking at the specfiles of some of the packages that are stripped reveals that they contain:

%define __debug_install_post %{_mingw32_debug_install_post}

and later

%{?_mingw32_debug_package}

Which seems to be the undocumented additions needed to get it to work.

Neither of these are mentioned in the guidelines, and searching for them in the http://fedoraproject.org/wiki/ gives no hits.

As the guidelines are written, they say that if you follow the guidelines you get stripped binaries:

> Libraries and executables should be stripped. This is done correctly and
> automatically if the spec file includes these lines:
> 
> %global __strip %{_mingw32_strip}
> %global __objdump %{_mingw32_objdump}

Which doesn't happen. To get stripped binaries you need to add two lines to your specfile that are neither mentioned in the guidelines nor anywhere else.

Comment 3 Richard W.M. Jones 2010-03-09 19:05:02 UTC
The currently approved packaging guidelines have a number of
problems.  We have been collecting the list of problems here:

http://fedoraproject.org/wiki/MinGW/Packaging_issues

so that when we come to update and seek approval for the
guidelines again, we know what needs to change.  It sounds like
this issue (and the whole issue of generating debuginfo) needs
to be added to the above page.

Updated the summary line to reflect this.

Comment 4 Erik van Pienbroek 2010-03-09 19:07:38 UTC
You're right that the usage of the debuginfo macro's isn't documented in the guidelines. The topic (debuginfo support) has been discussed on the fedora-mingw mailing list though. This can be read at http://lists.fedoraproject.org/pipermail/mingw/2009-June/001613.html (+ follow ups) and http://lists.fedoraproject.org/pipermail/mingw/2009-July/001811.html (+ follow ups).

Unfortunately the Fedora MinGW SIG has had a lack of leadership and interest these days. One year ago I spent a lot of time on the Fedora MinGW SIG to get new packages and features in, but a few months ago I started on a new full-time job leaving me with very little spare time to work on the Fedora MinGW SIG.

The %global __strip override is only used for static libraries, so that's why you're not seeing any effects when used on libraries or executables.

Comment 5 Bug Zapper 2010-11-03 20:22:12 UTC
This message is a reminder that Fedora 12 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 12.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '12'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 12's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 12 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 6 Richard W.M. Jones 2010-11-04 11:04:06 UTC
Still a problem in rawhide.

Comment 7 Kalev Lember 2011-05-18 19:18:33 UTC
The FPC amended the MinGW guidelines today, including the changes for generating the -debuginfo subpackages.
https://fedorahosted.org/fpc/ticket/83

Closing the ticket.


Note You need to log in before you can comment on or make changes to this bug.