Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 190258

Summary: media-sound/picard dependency on dev-python/ctypes incorrect
Product: Gentoo Linux Reporter: Mike M <sanchoperez>
Component: New packagesAssignee: Santiago M. Mola (RETIRED) <coldwind>
Status: RESOLVED FIXED    
Severity: normal CC: gentoo, marti, sound
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: picard-0.9.0_alpha14-r1.ebuild
picard-0.9.0_alpha14-r1.ebuild #2

Description Mike M 2007-08-26 01:01:18 UTC
media-sound/picard-0.9.0_alpha14 has a dependency as follows:

        cdaudio? ( >=media-libs/libdiscid-0.1.1
                || ( >=dev-lang/python-2.5 >=dev-python/ctypes-0.9 ) )

I compiled picard without cdaudio USE flag and get the following error:

$ picard 
Traceback (most recent call last):
  File "/usr/bin/picard", line 2, in ?
    from picard.tagger import main; main('/usr/share/locale', True)
  File "/usr/lib/python2.4/site-packages/picard/tagger.py", line 60, in ?
    from picard.disc import Disc, DiscError
  File "/usr/lib/python2.4/site-packages/picard/disc.py", line 21, in ?
    import ctypes
ImportError: No module named ctypes

Reproducible: Always

Steps to Reproduce:
Comment 1 René 'Necoro' Neumann 2007-09-05 23:03:32 UTC
By looking at the current ebuild I would say that the cdaudio useflag can be completely omitted. It is only used to print a warning, but has no effect for the install/compile process. (And by a look at the code, I don't see anything where this dependency can be disabled...)
Comment 2 René 'Necoro' Neumann 2007-09-05 23:27:30 UTC
Created attachment 130120 [details]
picard-0.9.0_alpha14-r1.ebuild

For your (the devs) convenience :) - the changed ebuild

I also looked at the code in more detail - and there really is nothing to disable cdaudio at all.
Comment 3 René 'Necoro' Neumann 2007-09-06 00:01:17 UTC
Created attachment 130122 [details]
picard-0.9.0_alpha14-r1.ebuild #2

Ok -- the cdaudio flag does not need to be purged. Only the ctypes dependency should not be further dependent on the useflag.

This is because "ctypes" is always imported - but the non-existence of libdiscid is silently ignored. (In fact it is ignored so silent that it is not discovered easily when reading the code ... - [can anyone please stab the author of this project for using NotImplementedErrors for this task? ;)])

To reflect this, I changed the ebuild once again :)
Comment 4 Santiago M. Mola (RETIRED) gentoo-dev 2007-09-16 21:24:41 UTC
python herd does not maintain this. Please, next time check metadata.xml before assigning or don't assign the bug.
Comment 5 Santiago M. Mola (RETIRED) gentoo-dev 2007-09-16 21:43:54 UTC
Fixed in CVS. Thanks Mike for the report, and René for the ebuild and tips.