Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 817437 - media-libs/codec2-1.0.1: build failure with -Os (src/libcodec2.so.1.0: undefined reference to `rx_filter_coh')
Summary: media-libs/codec2-1.0.1: build failure with -Os (src/libcodec2.so.1.0: undefi...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Sound Team
URL: https://github.com/drowe67/codec2/iss...
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2021-10-10 22:22 UTC by Alessandro Barbieri
Modified: 2022-02-07 04:33 UTC (History)
2 users (show)

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


Attachments
emerge_info (emerge_info,36.63 KB, text/plain)
2021-10-10 22:22 UTC, Alessandro Barbieri
Details
codec2-1.0.1:20211010-221108.log (codec2-1.0.1:20211010-221108.log,128.24 KB, text/plain)
2021-10-10 22:22 UTC, Alessandro Barbieri
Details
Make rx_filter_coh() static (codec2-1.0.1-make-rx_filter_coh-static.patch,688 bytes, patch)
2021-10-13 06:12 UTC, Tee KOBAYASHI
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alessandro Barbieri 2021-10-10 22:22:28 UTC
This package fails to build on an unstable system. Attached relevant logs and emerge --info
Comment 1 Alessandro Barbieri 2021-10-10 22:22:52 UTC
Created attachment 744402 [details]
emerge_info

emerge --info
Comment 2 Alessandro Barbieri 2021-10-10 22:22:54 UTC
Created attachment 744405 [details]
codec2-1.0.1:20211010-221108.log

build log
Comment 3 Alessandro Barbieri 2021-10-10 22:30:08 UTC
Reproduced in my clean chroot
Comment 4 Tee KOBAYASHI 2021-10-13 06:12:02 UTC
Created attachment 744672 [details, diff]
Make rx_filter_coh() static

Upstream GitHub PR: https://github.com/drowe67/codec2/pull/240
Comment 5 Larry the Git Cow gentoo-dev 2021-10-27 07:03:31 UTC
The bug has been closed via the following commit(s):

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

commit cb59eb7aebe85455c7c2d8133464b226d72f8ed3
Author:     Miroslav Šulc <fordfrog@gentoo.org>
AuthorDate: 2021-10-27 07:03:17 +0000
Commit:     Miroslav Šulc <fordfrog@gentoo.org>
CommitDate: 2021-10-27 07:03:29 +0000

    media-libs/codec2: 1.0.1 - fixed compilation issue
    
    Closes: https://bugs.gentoo.org/817437
    Package-Manager: Portage-3.0.28, Repoman-3.0.3
    Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>

 media-libs/codec2/codec2-1.0.1.ebuild                       |  4 ++++
 .../codec2/files/codec2-1.0.1-static-rx_filter_coh.patch    | 13 +++++++++++++
 2 files changed, 17 insertions(+)
Comment 6 Rick Farina (Zero_Chaos) gentoo-dev 2022-01-31 02:08:46 UTC
I hate necromancing but can replicate this on 1.0.3 :-(

[138/201] : && /usr/bin/x86_64-pc-linux-gnu-gcc -m32 -Os -march=native -mtune=native -pipe -frecord-gcc-switches -Wall -Wno-strict-overflow -std=gnu11 -fPIC -Wl,-O1 -Wl,--as-needed -Wl,--defsym=__gentoo_check_ldflags__=0    -rdynamic src/CMakeFiles/ldpc_dec.dir/ldpc_dec.c.o -o src/ldpc_dec  -Wl,-rpath,/var/tmp/portage/media-libs/codec2-1.0.3/work/codec2-1.03_build-abi_x86_32.x86/src  -lm  src/libcodec2.so.1.0  -lm && :
FAILED: src/ldpc_dec 
: && /usr/bin/x86_64-pc-linux-gnu-gcc -m32 -Os -march=native -mtune=native -pipe -frecord-gcc-switches -Wall -Wno-strict-overflow -std=gnu11 -fPIC -Wl,-O1 -Wl,--as-needed -Wl,--defsym=__gentoo_check_ldflags__=0    -rdynamic src/CMakeFiles/ldpc_dec.dir/ldpc_dec.c.o -o src/ldpc_dec  -Wl,-rpath,/var/tmp/portage/media-libs/codec2-1.0.3/work/codec2-1.03_build-abi_x86_32.x86/src  -lm  src/libcodec2.so.1.0  -lm && :
/usr/lib/gcc/x86_64-pc-linux-gnu/11.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: src/libcodec2.so.1.0: undefined reference to `rx_filter_coh'
collect2: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.
Comment 7 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-01-31 02:10:36 UTC
(In reply to Rick Farina (Zero_Chaos) from comment #6)
> I hate necromancing but can replicate this on 1.0.3 :-(
> 

full build.log please, and tell us if it happens without -Os (try -O2)
Comment 8 Rick Farina (Zero_Chaos) gentoo-dev 2022-01-31 02:22:52 UTC
It's an -Os bug.  I'm fully okay with just replace-flags as a workaround.
Comment 9 Larry the Git Cow gentoo-dev 2022-01-31 02:56:08 UTC
The bug has been closed via the following commit(s):

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

commit d8c782eac7b40793a8629c911345b54bfe1a7784
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2022-01-31 02:55:34 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-01-31 02:55:34 +0000

    media-libs/codec2: replace -Os with -O2
    
    Fails to build with -Os and given previous issues we've had,
    seems like this is the better option as a workaround for now.
    
    Closes: https://bugs.gentoo.org/817437
    Signed-off-by: Sam James <sam@gentoo.org>

 media-libs/codec2/codec2-1.0.3.ebuild | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
Comment 10 Larry the Git Cow gentoo-dev 2022-02-07 04:33:54 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=350cf9e5ff41a6a589a8ed40b69154eed7adbed7

commit 350cf9e5ff41a6a589a8ed40b69154eed7adbed7
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2022-02-07 04:32:24 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-02-07 04:33:37 +0000

    media-libs/codec2: add upstream -Os patch
    
    Bug: https://bugs.gentoo.org/817437
    Signed-off-by: Sam James <sam@gentoo.org>

 media-libs/codec2/codec2-1.0.3.ebuild                 |  9 +++++----
 .../codec2/files/codec2-1.0.3-fix-build-with-Os.patch | 19 +++++++++++++++++++
 2 files changed, 24 insertions(+), 4 deletions(-)