First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 27175
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Mamoru KOMACHI (RETIRED) <usata@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Akinori Hattori <hattya@gentoo.org>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
anthy-4300b.diff anthy-4300b.diff patch Akinori Hattori 2003-08-23 07:14 0000 489 bytes Details | Diff
anthy-4300b.diff anthy-4300b.diff (another solution) patch Mamoru KOMACHI (RETIRED) 2003-08-23 09:46 0000 1.54 KB Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 27175 depends on: Show dependency tree
Show dependency graph
Bug 27175 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)







View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2003-08-23 07:12 0000
Hello!

When I tested "emerge -epv anthy" with USE="-emacs", but it still emerge emacs.
Perhaps, if some ebuild inherit elisp eclass, it will automatically install emacs.
So I made one line patch for enable emacs use flag.

Sorry for my English.
Thank you.


Reproducible: Always
Steps to Reproduce:

------- Comment #1 From Akinori Hattori 2003-08-23 07:14:54 0000 -------
Created an attachment (id=16500) [edit]
anthy-4300b.diff

------- Comment #2 From Mamoru KOMACHI (RETIRED) 2003-08-23 09:46:10 0000 -------
Created an attachment (id=16502) [edit]
anthy-4300b.diff (another solution)

------- Comment #3 From Mamoru KOMACHI (RETIRED) 2003-08-23 10:00:22 0000 -------
Thanks for reporting.  It certainly is a bug, but the patch
(`use emacs && inherit elisp` rather than just `inherit elisp`)
doesn't seem to solve the problem.

Once you do 

	ACCEPT_KEYWORDS="~x86" USE="emacs" emerge -pev anthy

you will get app-editors/emacs as dependency and  the next time you do

	ACCEPT_KEYWORDS="~x86" USE="-emacs" emerge -pev anthy

you will still get app-editors/emacs as dependency.  It seems
that the result of emerge -pe is cached and will not be re-caliculated
the next emerge, which will lead to incorrect dependency.

In short, your patch should work if Portage correctly caliculates
dependency when USE has been changed (i.e. I think `use emacs &&
ihnerit elisp` should be allowed by Portage), but momentarily I added
a patch to not declare `inherit elisp` at the top of the ebuild to
avoid this problem.

------- Comment #4 From Mamoru KOMACHI (RETIRED) 2003-08-24 11:58:46 0000 -------
Committed the temporal fix.  Thanks.

------- Comment #5 From Nicholas Jones (RETIRED) 2003-08-24 12:15:43 0000 -------
inherit is NEVER allowed to be conditional that way.
Either you inherit, or you don't. There is no middle ground.

It can be worked around, but any auxdb variables MAY NOT be
involved in bash conditional statements.

------- Comment #6 From Mamoru KOMACHI (RETIRED) 2003-08-24 13:31:08 0000 -------
I see.  I found an ebuild side workaround to this problem in net-im/licq.
licq-1.2.7.ebuild says:

inherit kde-base
need-kde 3.0

[snip]

# we can't have conditional dependencies so "use kde && inherit kde-base" 
# won't work -- messes up dep caching.

# need-kde and their eclass friends inject things into DEPEND. But we only
# want them enabled if the kde USE flag is set. We get around this in the
# following dep lines:
RDEPEND="kde? ( ${DEPEND} )"
DEPEND="kde? ( ${DEPEND} )
        ssl? ( >=dev-libs/openssl-0.9.6 )
	qt? ( >=x11-libs/qt-3.0.0 )
	ncurses? ( sys-libs/ncurses )"

However, it doesn't seem to work.  When I run USE="-kde" emerge -pev licq,
hundreds of kde-related ebuild are going to be installed.  Is there any
general workaround for the problem?

* x11-misc/rss-glx
* x11-misc/rss-glx
* app-i18n/nkf
* app-i18n/xsim
* app-text/kbedic
* net-irc/kvirc
* net-www/swish-e
* net-im/sim
* net-mail/evolution
* app-office/siag
* media-sound/apollo
* app-sci/chemtool

are those packages which uses conditional statement with eclass ihneritance.
I think it would be better to describe the problem in Ebuild HOWTO or Eclass
HOWTO. 

First Last Prev Next    No search results available      Search page      Enter new bug