New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Static build issue with soxr #733
Comments
The Buildroot autobuilder detected a build [issue](http://autobuild.buildroot.org/results/53d/53d21686780aa2485745b59e812b6280dd39f1c5//shairport-sync-3.2.1/config.log) when building shairport-sync statically: ``` arm-buildroot-linux-uclibcgnueabi/sysroot/usr//lib/libsoxr.a(soxr.c.o): In function `soxr_create': soxr.c:(.text+0xd4c): undefined reference to `av_get_cpu_flags' collect2: error: ld returned 1 exit status ``` A quick look at the soxr source code shows that `soxr_create()` might use `av_get_cpu_flags()` under certain circumstances. Therefore, add `-lavutil` to `[other-libraries]` when using `AC_CHECK_LIB`. Fixes: mikebrady#733
Thanks Jörg Krause. It looks great -- let me do a quick check on it today and hopefully accept the pull request. |
Hi Jörg Krause. That |
Did you mean KB? |
Nope -- I really mean megabytes! I'm redoing everything again -- it'll probably take another day or so, and I'll record the log this time. |
This is a transcript for looking for and installing
|
Apologies -- just (!) 18 MB of a download, but 185 MB of dis space needed! |
libavutil-dev itself is only about 343 kB on Debian Stretch, 1179 kB installed. This is probably a full-blown development build with all possible dependencies of FFmpeg. |
Perhaps. The puzzling thing is that
By the way, this process seems to install version 0.1.2:
At a guess, in the |
Correct.
No. If There is nothing wrong with |
Thanks. The situation, therefore, is that In Ubuntu and in Raspbian and (AFAIK) in OpenWrt, the version of Therefore Now, if there was a way to check if |
I'm wondering if something like this might work:
|
I wasn't aware that So, following your suggestion for the non-pkg-config branch I would suggest:
|
That looks nice, thanks. Let me check it out. Does it do the same thing as my suggestion? [Update] I see that it's a bit more sophisticated. Let me check it out. Many thanks. |
Is this what you had in mind? If so, would you be kind enough to try it out and let us know how it goes. From my point of view, it seems okay -- it doesn't trigger unnecessary loading or linking of the It is all in a (temporary!) new branch called avutilsoxr. |
Yes, this is exactly what I had in mind. Thanks! |
The Buildroot autobuilder detected a build [issue](http://autobuild.buildroot.org/results/53d/53d21686780aa2485745b59e812b6280dd39f1c5//shairport-sync-3.2.1/config.log) when building shairport-sync statically: ``` arm-buildroot-linux-uclibcgnueabi/sysroot/usr//lib/libsoxr.a(soxr.c.o): In function `soxr_create': soxr.c:(.text+0xd4c): undefined reference to `av_get_cpu_flags' collect2: error: ld returned 1 exit status ``` A quick look at the soxr source code shows that `soxr_create()` might use `av_get_cpu_flags()` under certain circumstances. Therefore, add `-lavutil` to `[other-libraries]` when using `AC_CHECK_LIB`. Fixes: mikebrady#733
Closed in 5101ab2. |
Add upstream patch to fix build issue detected by the Buildroot autobuilder: ``` arm-buildroot-linux-uclibcgnueabi/sysroot/usr//lib/libsoxr.a(soxr.c.o): In function `soxr_create': soxr.c:(.text+0xd4c): undefined reference to `av_get_cpu_flags' collect2: error: ld returned 1 exit status ``` A quick look at the soxr source code shows that `soxr_create()` might use `av_get_cpu_flags()` depending on the architecture. For the sake of simplicity link with `-lavutil` if it is found when using soxr. Even better, as soxr provides a pkg-config file, this should be prefered. Upstream issue: mikebrady/shairport-sync#733 Upstream status: 5101ab2d13e2b89ea3c1276df5fb7413634eeccd Fixes: http://autobuild.buildroot.net/results/53d/53d21686780aa2485745b59e812b6280dd39f1c5 http://autobuild.buildroot.net/results/605/60576363adfca404c3a7883d5d46e8a4a9ee8171 http://autobuild.buildroot.net/results/806/806867ab1c6f42ad1b34d44844efc57272d48235 http://autobuild.buildroot.net/results/840/840810601fbb8a7957ea9dae175b959a7f9b7491 .. and more. Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Add upstream patch to fix build issue detected by the Buildroot autobuilder: ``` arm-buildroot-linux-uclibcgnueabi/sysroot/usr//lib/libsoxr.a(soxr.c.o): In function `soxr_create': soxr.c:(.text+0xd4c): undefined reference to `av_get_cpu_flags' collect2: error: ld returned 1 exit status ``` A quick look at the soxr source code shows that `soxr_create()` might use `av_get_cpu_flags()` depending on the architecture. For the sake of simplicity link with `-lavutil` if it is found when using soxr. Even better, as soxr provides a pkg-config file, this should be prefered. Upstream issue: mikebrady/shairport-sync#733 Upstream status: 5101ab2d13e2b89ea3c1276df5fb7413634eeccd Fixes: http://autobuild.buildroot.net/results/53d/53d21686780aa2485745b59e812b6280dd39f1c5 http://autobuild.buildroot.net/results/605/60576363adfca404c3a7883d5d46e8a4a9ee8171 http://autobuild.buildroot.net/results/806/806867ab1c6f42ad1b34d44844efc57272d48235 http://autobuild.buildroot.net/results/840/840810601fbb8a7957ea9dae175b959a7f9b7491 .. and more. Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> (cherry picked from commit e047dee) Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Add upstream patch to fix build issue detected by the Buildroot autobuilder: ``` arm-buildroot-linux-uclibcgnueabi/sysroot/usr//lib/libsoxr.a(soxr.c.o): In function `soxr_create': soxr.c:(.text+0xd4c): undefined reference to `av_get_cpu_flags' collect2: error: ld returned 1 exit status ``` A quick look at the soxr source code shows that `soxr_create()` might use `av_get_cpu_flags()` depending on the architecture. For the sake of simplicity link with `-lavutil` if it is found when using soxr. Even better, as soxr provides a pkg-config file, this should be prefered. Upstream issue: mikebrady/shairport-sync#733 Upstream status: 5101ab2d13e2b89ea3c1276df5fb7413634eeccd Fixes: http://autobuild.buildroot.net/results/53d/53d21686780aa2485745b59e812b6280dd39f1c5 http://autobuild.buildroot.net/results/605/60576363adfca404c3a7883d5d46e8a4a9ee8171 http://autobuild.buildroot.net/results/806/806867ab1c6f42ad1b34d44844efc57272d48235 http://autobuild.buildroot.net/results/840/840810601fbb8a7957ea9dae175b959a7f9b7491 .. and more. Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com> (cherry picked from commit e047dee) Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
The Buildroot autobuilder detected a build issue when building shairport-sync statically:
A quick look at the soxr source code shows that
soxr_create()
might useav_get_cpu_flags()
under certain circumstances.Therefore,
-lavutil
should be added to[other-libraries]
. Even better, as soxr provides a pkg-config file, this should be prefered.The text was updated successfully, but these errors were encountered: