Created attachment 515800 [details] Output of emerge --info Some issues w/ 2 use flags on app-misc/anki-2.1.0_beta27. Flag descriptions are: recording: Enable support for audio recording sound: Enable support for adding sound to cards However, looks like the ebuild ignores the sound flag. Additionally, the recording flag is mandatory -- anki won't run without it. Tried emerging w/ both those disabled: $ emerge -pv anki [ebuild R ~] app-misc/anki-2.1.0_beta27::gentoo USE="-latex -recording -sound {-test}" PYTHON_TARGETS="python3_6" 0 KiB ... but got an error trying to run anki: $ anki Traceback (most recent call last): File "/usr/lib/python-exec/python3.6/anki", line 6, in <module> import aqt File "/usr/lib64/python3.6/site-packages/aqt/__init__.py", line 4, in <module> from anki import version as _version File "/usr/lib64/python3.6/site-packages/anki/__init__.py", line 14, in <module> from anki.storage import Collection File "/usr/lib64/python3.6/site-packages/anki/storage.py", line 11, in <module> from anki.collection import _Collection File "/usr/lib64/python3.6/site-packages/anki/collection.py", line 26, in <module> from anki.sound import stripSounds File "/usr/lib64/python3.6/site-packages/anki/sound.py", line 261, in <module> import pyaudio ModuleNotFoundError: No module named 'pyaudio' Recompiled w/ sound flag added, and got the same error. Finally, compiled w/ recording flag added: $ emerge -pv anki [ebuild N ] media-libs/portaudio-19_pre20140130::gentoo USE="alsa cxx -debug -jack -oss -static-libs" ABI_X86="(64) -32 (-x32)" 1,470 KiB [ebuild N ] dev-python/pyaudio-0.2.11::gentoo USE="-doc" PYTHON_TARGETS="python2_7 python3_4 python3_5 python3_6" 37 KiB [ebuild R ~] app-misc/anki-2.1.0_beta27::gentoo USE="recording* -latex -sound* {-test}" PYTHON_TARGETS="python3_6" 0 KiB That got past the pyaudio error, although then got hit by other errors (e.g. 643004).
Same thing here. Nobody wants to dig through all anki's source code to find why pyaduio is essential I guess, so how about just add unconditional dependency from pyaudio?
I edited sound.py and comment the out pyaudio references and have been running anki without problems although I have not fully tested it. Attached is the modified ebuild I used to edit sound.py if the recording use flag is not selected.
Created attachment 537026 [details] anki-2.1.0_beta27.ebuild with pyaudio edits
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bbf4348280a355c7def871019405fc563730ed7c commit bbf4348280a355c7def871019405fc563730ed7c Author: Chris Burroughs <chris.burroughs@gmail.com> AuthorDate: 2019-11-08 02:37:38 +0000 Commit: Joonas Niilola <juippis@gentoo.org> CommitDate: 2020-06-12 06:59:45 +0000 app-misc/anki: bump to 2.1.15 and modernize ebuild - claiming maintainer timeout to update version and fix bugs, --juippis * Bump to EAPI 7 * Enable python 3.{7,8} support * Fix missing test dependencies * Add missing jsonschema dependency * Backport argument fix to allow mpv versions > 0.31 to be used by anki * Correct and expand LICENSE * Resolve NonexistentDeps DEPEND warning (leftover from PyQtWebEngine split, but no version of PyQt5 with a webengine use flag is still in the tree.) * Use default pkg_setup from eclass and rely on default value for S variable * Clarify optional runtime dependencies needed (mpv OR mplayer) * Move optional runtime dependencies to optfeature * Adjust SRC_URL after upstream re-arranging NOTE: The upstream LICENSE includes "Qt's bundled translations: LGPL3", but since we are building from source that is not directly included. More recent upstream versions have clarified this in the LICENSE file. Bug: https://bugs.gentoo.org/625894 Bug: https://bugs.gentoo.org/645314 Bug: https://bugs.gentoo.org/651472 Bug: https://bugs.gentoo.org/688798 Closes: https://bugs.gentoo.org/700010 Closes: https://bugs.gentoo.org/715624 Bug: https://bugs.gentoo.org/722502 Bug: https://bugs.gentoo.org/724482 Bug: https://bugs.gentoo.org/724990 Closes: https://bugs.gentoo.org/726522 Signed-off-by: Chris Burroughs <chris.burroughs@gmail.com> Closes: https://github.com/gentoo/gentoo/pull/16054 Signed-off-by: Joonas Niilola <juippis@gentoo.org> app-misc/anki/Manifest | 1 + app-misc/anki/anki-2.1.15.ebuild | 93 ++++++++++++++++++++++++++ app-misc/anki/files/anki-2.1.15-mpv-args.patch | 26 +++++++ 3 files changed, 120 insertions(+)