Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 158073 - app-office/ledger should inherit elisp-common.eclass, not elisp
Summary: app-office/ledger should inherit elisp-common.eclass, not elisp
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gunnar Wrobel (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 184166
  Show dependency tree
 
Reported: 2006-12-13 13:31 UTC by Stephan Weller
Modified: 2007-09-16 14:21 UTC (History)
4 users (show)

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


Attachments
app-office/ledger-2.5-r1.ebuild.diff (ledger-2.5-r1.ebuild.diff,601 bytes, patch)
2006-12-13 13:51 UTC, Jakub Moc (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Stephan Weller 2006-12-13 13:31:20 UTC
I tried to emerge ledger today, but the ebuild always wants to install emacs as a dependency. The ebuild has
emacs? ( virtual/emacs )
in its DEPEND, which is of course ok, but the ebuild also inherits elisp, which in turn depends on virtual/emacs.
So at the moment there is no possibility to install ledger without installing emacs.

I am not that fluent in ebuild writing, is there something like a conditional "inherit"-statement? If not, this should probably be a portage bug...
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2006-12-13 13:38:50 UTC
(In reply to comment #0)
> I am not that fluent in ebuild writing, is there something like a conditional
> "inherit"-statement? 

No, it's strictly forbidden to inherit eclasses only if a use flag is set...
Comment 2 Jakub Moc (RETIRED) gentoo-dev 2006-12-13 13:47:53 UTC
A quick fix, ruby-style...

<snip>
--- elisp.eclass	2006-02-28 04:05:42.000000000 +0100
+++ elisp.eclass	2006-12-13 22:45:15.000000000 +0100
@@ -23,7 +23,11 @@
 #	S="${WORKDIR}/${P}"
 fi
 
-DEPEND="virtual/emacs"
+# If you specify EMACS_OPTIONAL you also need to take care of 
+# emacs useflag and dependency.
+if [[ ${EMACS_OPTIONAL} != "yes" ]]; then
+        DEPEND="virtual/emacs"
+fi
 IUSE=""
 
 elisp_src_unpack() {
</snip>
Comment 3 Jakub Moc (RETIRED) gentoo-dev 2006-12-13 13:51:32 UTC
Created attachment 103982 [details, diff]
app-office/ledger-2.5-r1.ebuild.diff

- make emacs dependency really optional
Comment 4 Stephan Weller 2006-12-13 23:21:46 UTC
Yep, that solves it for me. Thanks a lot, guys!

And, btw, not bad: 20 minutes to solve this one. If only all bugs could be fixed that fast ;-)
Comment 5 Jakub Moc (RETIRED) gentoo-dev 2007-01-03 09:50:40 UTC
*** Bug 159861 has been marked as a duplicate of this bug. ***
Comment 6 Christian Faulhammer (RETIRED) gentoo-dev 2007-01-05 03:32:06 UTC
Use elisp-common.eclass instead of elisp.
Comment 7 Christian Faulhammer (RETIRED) gentoo-dev 2007-02-14 12:46:08 UTC
As there was no reaction from maintainer, I did the eclass migration.
Comment 8 Ulrich Müller gentoo-dev 2007-07-06 06:17:06 UTC
The ebuild should have the following in pkg_postinst and pkg_postrm:
    use emacs && elisp-site-regen

This was automatically called with elisp.eclass, but isn't with elisp-common.eclass anymore.

Reopening.
Comment 9 Christian Faulhammer (RETIRED) gentoo-dev 2007-09-16 10:48:24 UTC
No reaction from maintainer for more than two monts, so closing
Comment 10 Christian Faulhammer (RETIRED) gentoo-dev 2007-09-16 10:48:46 UTC
And of course I fixed it. :)