Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 251881 - haskell-cabal.eclass strips all binaries by default
Summary: haskell-cabal.eclass strips all binaries by default
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High QA (vote)
Assignee: Gentoo's Haskell Language team
URL:
Whiteboard:
Keywords:
: 251882 251883 251884 251886 299494 (view as bug list)
Depends on:
Blocks: prestripped
  Show dependency tree
 
Reported: 2008-12-21 15:59 UTC by Diego Elio Pettenò (RETIRED)
Modified: 2010-07-12 18:21 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Diego Elio Pettenò (RETIRED) gentoo-dev 2008-12-21 15:59:37 UTC
dev-haskell/c2hs-0.15.1:20081213-025446.log:  * QA Notice: Pre-stripped files found:
dev-haskell/c2hs-0.15.1:20081213-025446.log:  * /var/tmp/portage/dev-haskell/c2hs-0.15.1/image/usr/bin/c2hs

Portage warns about pre-stripped files being installed into the image directory; this is a bad thing since it makes Portage's splitdebug feature useless, and it stops the users and the developers from looking into backtraces with full debug information available.

For the developers going to look into it, what you have to look out for, to
find what is stripping the files, is one of these conditions:

- explicit "strip" command run on the produced files;
- "install -s" command to install the binary files;
- "-Wl,-s" flag passed during linking

Remove the "strip" commands, remove the "-s" option at install, and remove
"-Wl,-s" and the problem should be gone.

Thanks,
Diego
Comment 1 Lennart Kolmodin (RETIRED) gentoo-dev 2009-04-05 17:34:33 UTC
Hi Diego,

all haskell packages are compiled with ghc, and are then stripped.
Keeping the symbols will do no good, as they are useless -- they come from generated code. It will not help debugging if the symbols are kept.

What's the best way to proceed with this issue? It affects all haskell applications.
Comment 2 Sergei Trofimovich (RETIRED) gentoo-dev 2010-07-12 08:48:59 UTC
haskell-cabal.eclass: Don't strip executables, let portage do it.
revision:             1.18
date:                 2010-01-26 22:50:40 +0200
author:               kolmodin;

+       if version_is_at_least "1.4" "$(cabal-version)"; then
+               # disable executable stripping for the executables, as portage will
+               # strip by itself, and pre-stripping gives a QA warning.
+               # cabal versions previous to 1.4 does not strip executables, and does
+               # not accept the flag.
+               # this fixes numerous bugs, amongst them;
+               # bug #251881, bug #251882, bug #251884, bug #251886, bug #299494
+               cabalconf="${cabalconf} --disable-executable-stripping"
+       fi

Preserving debug info can help in cases when package is built of both haskell and C sources mixed.
Comment 3 Sergei Trofimovich (RETIRED) gentoo-dev 2010-07-12 08:51:32 UTC
*** Bug 251882 has been marked as a duplicate of this bug. ***
Comment 4 Sergei Trofimovich (RETIRED) gentoo-dev 2010-07-12 08:56:24 UTC
*** Bug 251883 has been marked as a duplicate of this bug. ***
Comment 5 Sergei Trofimovich (RETIRED) gentoo-dev 2010-07-12 09:00:29 UTC
*** Bug 251884 has been marked as a duplicate of this bug. ***
Comment 6 Sergei Trofimovich (RETIRED) gentoo-dev 2010-07-12 09:17:46 UTC
*** Bug 251886 has been marked as a duplicate of this bug. ***
Comment 7 Sergei Trofimovich (RETIRED) gentoo-dev 2010-07-12 18:21:27 UTC
*** Bug 299494 has been marked as a duplicate of this bug. ***