package/gerbera: fix static build with curl and libidn2
PATCH 1/1 package/gerbera: fix static build with curl and libidn2
Fixes:
- http://autobuild.buildroot.org/results/be5893b507d22a23951efeea20c18642742cef5a
--- ...ix-static-build-with-curl-and-libidn.patch | 41 +++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 package/gerbera/0001-CMakeLists.txt-fix-static-build-with-curl-and-libidn.patch
package/gerbera/0001-CMakeLists.txt-fix-static-build-with-curl-and-libidn.patch new file +41 -0
@@ -0,0 +1,41 @@ +From de0e7fe3b56cff79c11aedc89448814fab8d1877 Mon Sep 17 00:00:00 2001 +From: Fabrice Fontaine <[email protected]> +Date: Fri, 8 Mar 2019 19:11:11 +0100 +Subject: [PATCH] MakeLists.txt: fix static build with curl and libidn2 + +curl can be statically linked with libidn2, in this case, build fails: +/accts/mlweber1/rclinux/rc-buildroot-test/scripts/instance-0/output/host/m68k-buildroot-linux-uclibc/sysroot/usr/lib/libcurl.a(libcurl_la-url.o): In function `free_idnconverted_hostname.isra.1': +url.c:(.text+0xf4): undefined reference to `idn2_free' + +To fix this issue, add a call to pkg_check_modules to retrieve any +needed dependencies + +Fixes: + - http://autobuild.buildroot.org/results/be5893b507d22a23951efeea20c18642742cef5a + +Signed-off-by: Fabrice Fontaine <[email protected]> +[Upstream status: https://github.com/gerbera/gerbera/pull/429] +--- + CMakeLists.txt | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index d0eed230..e6b62c96 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -443,7 +443,11 @@ if(WITH_MYSQL) + endif() + + if(WITH_CURL) +- find_package (CURL REQUIRED) ++ find_package(PkgConfig QUIET) ++ pkg_check_modules (CURL QUIET libcurl) ++ if (NOT CURL_FOUND) ++ find_package (CURL REQUIRED) ++ endif() + if (CURL_FOUND) + include_directories(${CURL_INCLUDE_DIRS}) + target_link_libraries (gerbera ${CURL_LIBRARIES}) +-- +2.20.1 +
Signature · 1 line
2.20.1
PATCH 1/1 package/gerbera: fix static build with curl and libidn2
Quoted 4 lines · On Fri, 8 Mar 2019 22:52:00 +0100 Fabrice Fontaine…
Fixes:
- http://autobuild.buildroot.org/results/be5893b507d22a23951efeea20c18642742cef5aSigned-off-by Fabrice Fontaine <[email protected]>
As upstream replied in the pull request, the CMake FindCURL module already uses pkg-config if available. Could you investigate what this doesn't work as expected ?
Thanks,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
PATCH 1/1 package/gerbera: fix static build with curl and libidn2
Dear Thomas,
Le sam. 9 mars 2019 ? 15:09, Thomas Petazzoni
<[email protected]> a ?crit :
Quoted 4 lines
On Fri, 8 Mar 2019 22:52:00 +0100
Fabrice Fontaine <[email protected]> wrote:
Quoted 8 lines
Quoted 4 lines
Fixes:
- http://autobuild.buildroot.org/results/be5893b507d22a23951efeea20c18642742cef5aSigned-off-by Fabrice Fontaine <[email protected]>As upstream replied in the pull request, the CMake FindCURL module already uses pkg-config if available. Could you investigate what this doesn't work as expected ?
Cmake does not use pkgconfig in FindCurl in any "official" versions (including 3.13.4), they have added a call to pkgconfig only in December 2018 with
https://github.com/Kitware/CMake/commit/fc5afbe97094d741b853b045d51351f3a370e87e#diff-62c4a3bc6680cd4945de9749af697a2a
I'll be a part of the upcoming 3.14.0.
Quoted 8 lines
Thanks,
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
Best Regards,
Fabrice
Thomas Petazzoni
AppliedPATCH 1/1 package/gerbera: fix static build with curl and libidn2
Hello,
Quoted 8 lines · On Sat, 9 Mar 2019 16:04:50 +0100 Fabrice Fontaine…
Quoted 3 lines
As upstream replied in the pull request, the CMake FindCURL module already uses pkg-config if available. Could you investigate what this doesn't work as expected ?
Cmake does not use pkgconfig in FindCurl in any "official" versions (including 3.13.4), they have added a call to pkgconfig only in December 2018 with
https://github.com/Kitware/CMake/commit/fc5afbe97094d741b853b045d51351f3a370e87e#diff-62c4a3bc6680cd4945de9749af697a2a
I'll be a part of the upcoming 3.14.0.
Thanks for the additional explication!
I've applied the patch to master. Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
PATCH 1/1 package/gerbera: fix static build with curl and libidn2
In reply to Fabrice FontaineQuoted 6 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Fabrice" == Fabrice Fontaine <[email protected]> writes:
Fixes:
- http://autobuild.buildroot.org/results/be5893b507d22a23951efeea20c18642742cef5aSigned-off-by Fabrice Fontaine <[email protected]>
Committed to 2019.02.x, thanks.
Signature · 1 line
Bye, Peter Korsgaard