summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStéphane Cerveau <scerveau@igalia.com>2024-02-15 17:56:38 +0100
committerGStreamer Marge Bot <gitlab-merge-bot@gstreamer-foundation.org>2024-02-19 06:02:58 +0000
commit8b6f7e22c419648311e5c2571f7c17211689c211 (patch)
tree4972b65b27c4848735812e57d5d6391c3ffef90a
parent83bf69cadc2311805a3a1e3ac59a6dbbef4169b5 (diff)
x264: fix linker path in pc file
The library x264 should be searched in ${prefix}/lib/x86_64-linux-gnu Part-of: <https://gitlab.freedesktop.org/gstreamer/cerbero/-/merge_requests/1371>
-rw-r--r--recipes/x264/0001-configure-Force-pkgconfig-file-to-have-relative-valu.patch38
1 files changed, 20 insertions, 18 deletions
diff --git a/recipes/x264/0001-configure-Force-pkgconfig-file-to-have-relative-valu.patch b/recipes/x264/0001-configure-Force-pkgconfig-file-to-have-relative-valu.patch
index dd14b7b6..68d8a145 100644
--- a/recipes/x264/0001-configure-Force-pkgconfig-file-to-have-relative-valu.patch
+++ b/recipes/x264/0001-configure-Force-pkgconfig-file-to-have-relative-valu.patch
@@ -1,34 +1,36 @@
-From 696486fbf58eb85a82947caa0af20a72e6579d7f Mon Sep 17 00:00:00 2001
-From: Cerbero Build System <cerbero@gstreamer.freedesktop.org>
-Date: Thu, 16 Apr 2020 22:27:20 +0530
+From 1b0fa783a8199790abdafc49cfa0d71dc398c1e0 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?St=C3=A9phane=20Cerveau?= <scerveau@igalia.com>
+Date: Fri, 16 Feb 2024 11:37:42 +0100
Subject: [PATCH] configure: Force pkgconfig file to have relative values
-We must define everything relative to `${prefix}`, so that
-pkg-config's `--define-prefix` argument works correctly.
+Use rel_libdir
---
- configure | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
+ configure | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/configure b/configure
-index 3cf63e0..d0c4701 100644
+index 3cf63e0..8308fd5 100755
--- a/configure
+++ b/configure
-@@ -1530,13 +1530,13 @@ echo "CLI_LIBX264 = $CLI_LIBX264" >> config.mak
+@@ -534,6 +534,7 @@ CC="${CC-${cross_prefix}gcc}"
+ STRIP="${STRIP-${cross_prefix}strip}"
+ INSTALL="${INSTALL-install}"
+ PKGCONFIG="${PKGCONFIG-${cross_prefix}pkg-config}"
++rel_libdir="${libdir#$prefix/}"
+
+ # ar and ranlib doesn't load the LTO plugin by default, prefer the gcc-prefixed wrappers which does.
+ if ${cross_prefix}gcc-ar --version >/dev/null 2>&1; then
+@@ -1530,8 +1531,8 @@ echo "CLI_LIBX264 = $CLI_LIBX264" >> config.mak
cat > x264.pc << EOF
prefix=$prefix
exec_prefix=$exec_prefix
-libdir=$libdir
-+libdir=\${prefix}/lib
- includedir=$includedir
+-includedir=$includedir
++libdir=\${prefix}/$rel_libdir
++includedir=\${prefix}/include
Name: x264
Description: H.264 (MPEG4 AVC) encoder library
- Version: $(grep POINTVER < x264_config.h | sed -e 's/.* "//; s/".*//')
--Libs: -L$libdir -lx264 $([ "$shared" = "yes" ] || echo $libpthread $libm $libdl)
-+Libs: -L\${libdir} -lx264 $([ "$shared" = "yes" ] || echo $libpthread $libm $libdl)
- Libs.private: $([ "$shared" = "yes" ] && echo $libpthread $libm $libdl)
- Cflags: -I$includedir
- EOF
--
-2.26.1.windows.1
+2.34.1