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

Bug 816453

Summary: media-libs/codec2-1.0.1 breaks net-wireless/gnuradio (USE=vocoder)
Product: Gentoo Linux Reporter: hangglider
Component: Current packagesAssignee: Gentoo Sound Team <sound>
Status: RESOLVED FIXED    
Severity: normal CC: dan, fordfrog, radio, sam, wgh
Priority: Normal Keywords: PullRequest
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://github.com/gentoo/gentoo/pull/22639
https://bugs.gentoo.org/show_bug.cgi?id=822966
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: build.log
emerge --info output

Description hangglider 2021-10-05 16:29:04 UTC
media-libs/codec2-1.0.1 makes gnuradio to abort compilation because of /usr/include/codec2/freedv_api.h:148 contains

typedef void (*freedv_callback_rx_sym)(void *, _Complex float, float);

what makes swig report an input error.

Downgrading to codec2-1.0.0 solves that, as it doesn't contain the declaration.
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-10-05 17:03:56 UTC
Please do include the full build.log and emerge —-info.
Comment 2 hangglider 2021-10-20 07:34:29 UTC
(In reply to Sam James from comment #1)
> Please do include the full build.log and emerge —-info.

sorry - didn't recognize this, will have to regenerate asap.

But maybe it's much better to fix gnuradio, if the problem occurs only there. Here ffmpeg is another dependency, didn't notice the prob there, will also retry that.
Comment 3 hangglider 2021-10-20 16:21:50 UTC
Created attachment 745923 [details]
build.log
Comment 4 hangglider 2021-10-20 16:22:16 UTC
Created attachment 745926 [details]
emerge --info output
Comment 5 hangglider 2021-10-20 16:24:46 UTC
* emerge --info and build.log attached,
* ffmpeg, which also depends on codec2, compiles fine.

As it'd be better to fix gnuradio in that case, so please close this bug report.
Comment 6 WGH 2021-11-14 13:03:25 UTC
> Downgrading to codec2-1.0.0 solves that, as it doesn't contain the declaration.

Yeah, and that version was removed from the portage tree...
Comment 7 WGH 2021-11-14 13:03:51 UTC
> Downgrading to codec2-1.0.0 solves that, as it doesn't contain the declaration.

Yeah, and that version was removed as "obsolete"
Comment 8 Miroslav Šulc gentoo-dev 2021-11-14 13:10:30 UTC
tbh from the comments i'm not even sure whether codec2 is broken or gnuradio is broken. anyone has a better understanding of the issue?
Comment 9 WGH 2021-11-14 13:18:06 UTC
It could be a swig bug, too
Comment 10 Larry the Git Cow gentoo-dev 2021-11-14 13:21:43 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1db29ed4fa20a3cb890cc5d078ad7a348376f13d

commit 1db29ed4fa20a3cb890cc5d078ad7a348376f13d
Author:     Miroslav Šulc <fordfrog@gentoo.org>
AuthorDate: 2021-11-14 13:19:49 +0000
Commit:     Miroslav Šulc <fordfrog@gentoo.org>
CommitDate: 2021-11-14 13:21:41 +0000

    Revert "media-libs/codec2: removed obsolete 1.0.0"
    
    This reverts commit 7c5826792ef6245f1bc46e905eaab988982b698a.
    
    Bug: https://bugs.gentoo.org/816453
    Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>

 media-libs/codec2/Manifest            |  1 +
 media-libs/codec2/codec2-1.0.0.ebuild | 26 ++++++++++++++++++++++++++
 2 files changed, 27 insertions(+)
Comment 11 WGH 2021-11-14 13:22:45 UTC
https://github.com/drowe67/codec2/pull/232#issuecomment-932686075

> The problem is swig and its C/C++ parser. Then, the fix depends on which version do you use: release or trunk. The former doesn't have swig/swig#252 and swig/swig#1770 and this is the reason for #233 to work.

The complex thing has been removed from codec2 because of this very issue - https://github.com/drowe67/codec2/pull/235 - but there has been no new release.

The linked Gentoo PR backports the fix (the complex removal).
Comment 12 Miroslav Šulc gentoo-dev 2021-11-14 13:25:38 UTC
ok, so i reverted the removal of the previous version as it seems it's easier and faster "fix" then to fix the real issue, at least as of now.

to avoid emerge of codec2-1.0.1, you can mask it.
Comment 13 Larry the Git Cow gentoo-dev 2021-12-01 17:27:18 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2d51c6ab80708422dddd6ba7773f48e601c47238

commit 2d51c6ab80708422dddd6ba7773f48e601c47238
Author:     Huang Rui <vowstar@gmail.com>
AuthorDate: 2021-10-20 03:48:09 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2021-12-01 17:27:06 +0000

    media-libs/codec2: fix freedv_callback_rx_sym typedef
    
    Fix net-wireless/gnuradio (USE=vocoder)
    Patch from https://github.com/drowe67/codec2/pull/235
    Backport to codec2-1.0.1
    
    Closes: https://bugs.gentoo.org/822966
    Closes: https://bugs.gentoo.org/816453
    Package-Manager: Portage-3.0.28, Repoman-3.0.3
    Signed-off-by: Huang Rui <vowstar@gmail.com>
    Closes: https://github.com/gentoo/gentoo/pull/22639
    Signed-off-by: Sam James <sam@gentoo.org>

 ...{codec2-1.0.1.ebuild => codec2-1.0.1-r1.ebuild} |  3 +-
 .../files/codec2-1.0.1-fix-freedv-callback.patch   | 48 ++++++++++++++++++++++
 2 files changed, 50 insertions(+), 1 deletion(-)