Bug 1149850 - RFE: subpackage Haskell haddock documentation
Summary: RFE: subpackage Haskell haddock documentation
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: cabal-rpm
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jens Petersen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-10-06 18:34 UTC by Matěj Cepl
Modified: 2020-03-03 10:33 UTC (History)
4 users (show)

Fixed In Version: cabal-rpm-1.0.1-1.fc31
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-03-03 10:33:33 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Matěj Cepl 2014-10-06 18:34:41 UTC
Description of problem:
From the Packagin guidelines:

“[…] Or if there's a lot of documentation, consider putting it into a subpackage. In this case, it is recommended to use *-doc as the subpackage name, and Documentation as the value of the Group tag.”

Because of failure to do this, ghc-compiler has 80+MB in /usr/share/doc/ghc-compiler/html

Version-Release number of selected component (if applicable):
ghc-compiler.x86_64 0:7.6.3-26.fc21

How reproducible:
100%

Comment 1 Jens Petersen 2014-10-07 01:02:51 UTC
(In reply to Matěj Cepl from comment #0)
> ghc-compiler has 80+MB in /usr/share/doc/ghc-compiler/html

I assume you mean /usr/share/doc/ghc/html/libraries ?

While that directory is owned by ghc-compiler most of the content
in there is from various libraries.

At a minimum, ghc-compiler pulls in ghc-base-devel which contains:

15M	base-4.6.0.1/
2.5M	ghc-prim-0.3.0.0/
392K	integer-gmp-0.5.0.0/

ghc-compiler does own /usr/share/doc/ghc/html/libraries/doc-index-All.html (21M)
which is a ghost file generated if then ghc-doc-index cronjob is installed.

(ghc-ghc-devel's doc is the largest: 62M)

I guess you're really suggesting that Haskell libraries
use subpackages for their docs.  That is quite a big
packaging structural change but maybe it is worth doing
for F22.  The downside to that is that docs of deps
are used when generating lib docs so we need to add
BRs for all the docs packages too across 280+ packages
so it is not a completely trivial change but it is possible.

Comment 2 Jens Petersen 2014-12-12 06:27:56 UTC
A smaller option might be to move all the docs from ghc
to a separate doc subpackages perhaps, then maybe ghc-rpm-macros
could Requires ghc-doc.  That would at least address your
immediate complaint even if it doesn't face the wider problem.

Comment 3 Jaroslav Reznik 2015-03-03 16:20:46 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 22 development cycle.
Changing version to '22'.

More information and reason for this action is here:
https://fedoraproject.org/wiki/Fedora_Program_Management/HouseKeeping/Fedora22

Comment 4 Jens Petersen 2015-05-15 07:31:50 UTC
I am kind of tempted to close this wontfix...

Any further comments?

Comment 5 Matěj Cepl 2015-05-15 10:09:43 UTC
(In reply to Jens Petersen from comment #1)
> (In reply to Matěj Cepl from comment #0)
> > ghc-compiler has 80+MB in /usr/share/doc/ghc-compiler/html
> 
> I assume you mean /usr/share/doc/ghc/html/libraries ?

Yes, sorry.

> While that directory is owned by ghc-compiler most of the content
> in there is from various libraries.

Partially, but still

ghc-compiler    x86_64     7.6.3-18.3.el7       epel     15 M

matej@mitmanek: ~$ du -hs /usr/share/doc/ghc/html/
20M	/usr/share/doc/ghc/html/
matej@mitmanek: ~$ 

(When installing just ghc-compiler on a computer where no ghc-* package
was).

> At a minimum, ghc-compiler pulls in ghc-base-devel which contains:
> 
> 15M	base-4.6.0.1/
> 2.5M	ghc-prim-0.3.0.0/
> 392K	integer-gmp-0.5.0.0/

So probably /usr/share/doc/ghc/html should be owned by ghc-base not
ghc-compiler, shouldn't it?

> I guess you're really suggesting that Haskell libraries
> use subpackages for their docs.  That is quite a big
> packaging structural change but maybe it is worth doing
> for F22.  The downside to that is that docs of deps
> are used when generating lib docs so we need to add
> BRs for all the docs packages too across 280+ packages
> so it is not a completely trivial change but it is possible.

Couldn't this be somehow scripted?

Anyway, being bound to install tens of megabytes of completely useless
documentation just because I want to run rpm --rebuild pandoc*.src.rpm
is really crappy user experience, which really doesn't makes me
interested in further investigation of the Haskell universe.

Comment 6 Jens Petersen 2015-05-18 03:16:33 UTC
(In reply to Matěj Cepl from comment #5)
> So probably /usr/share/doc/ghc/html should be owned by ghc-base not
> ghc-compiler, shouldn't it?

It could be perhaps - there are still various shared files
under libraries/.  Let me think more about it.

> > I guess you're really suggesting that Haskell libraries
> > use subpackages for their docs.  That is quite a big
> > packaging structural change but maybe it is worth doing
> > for F22.  The downside to that is that docs of deps
> > are used when generating lib docs so we need to add
> > BRs for all the docs packages too across 280+ packages
> > so it is not a completely trivial change but it is possible.

> Anyway, being bound to install tens of megabytes of completely useless
> documentation just because I want to run rpm --rebuild pandoc*.src.rpm
> is really crappy user experience, which really doesn't makes me
> interested in further investigation of the Haskell universe.

Thanks for the feedback.
I think you're the first person to have really complained about this
since we dropped doc subpackages for Haskell libraries in F14. :)
The main reason for doing that was to simplify the packaging
but I take your point: probably not many people use the
doc files anyway since they are mostly all online anyway.
Another radical approach would be to drop them completely
but I think it is good to have them available for offline access.

I will try to consider addressing this for F23.

Comment 7 Jens Petersen 2015-05-18 03:20:44 UTC
Changes needed to cabal-rpm to address general packages
and to ghc-rpm-macros for ghc and haskell-platform.

Comment 8 Jens Petersen 2017-10-27 09:26:46 UTC
I opened https://github.com/juhp/cabal-rpm/issues/53 for this.

Comment 9 Jens Petersen 2019-10-01 14:31:58 UTC
This is now available in cabal-rpm-1.0.1 (coming soon to Fedora 31+) and already reflected in Fedora 31 haskell packages.


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