summaryrefslogtreecommitdiff
path: root/recipes
diff options
context:
space:
mode:
authorNirbheek Chauhan <nirbheek@centricular.com>2020-04-16 23:47:53 +0530
committerNirbheek Chauhan <nirbheek@centricular.com>2020-04-16 23:47:53 +0530
commit97c913ea443825b9e69d056c44bf91deb0c9ddef (patch)
tree20851442799100a4523e5debd5599e318f3039ed /recipes
parent2d0713a6760ef8b00c8901fa047f7d29ea300129 (diff)
x264.recipe: Use relative paths in pkgconfig file
Diffstat (limited to 'recipes')
-rw-r--r--recipes/x264.recipe2
-rw-r--r--recipes/x264/0001-configure-Force-pkgconfig-file-to-have-relative-valu.patch34
2 files changed, 36 insertions, 0 deletions
diff --git a/recipes/x264.recipe b/recipes/x264.recipe
index efdc1c4f..ee691870 100644
--- a/recipes/x264.recipe
+++ b/recipes/x264.recipe
@@ -15,6 +15,8 @@ class Recipe(recipe.Recipe):
tarball_dirname= 'x264-snapshot-%(version)s-stable'
tarball_checksum = 'b2495c8f2930167d470994b1ce02b0f4bfb24b3317ba36ba7f112e9809264160'
+ patches = ['x264/0001-configure-Force-pkgconfig-file-to-have-relative-valu.patch']
+
files_libs = ['libx264']
files_bins = ['x264']
files_devel = ['lib/pkgconfig/x264.pc', 'include/x264.h',
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
new file mode 100644
index 00000000..dd14b7b6
--- /dev/null
+++ b/recipes/x264/0001-configure-Force-pkgconfig-file-to-have-relative-valu.patch
@@ -0,0 +1,34 @@
+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
+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.
+---
+ configure | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/configure b/configure
+index 3cf63e0..d0c4701 100644
+--- a/configure
++++ b/configure
+@@ -1530,13 +1530,13 @@ echo "CLI_LIBX264 = $CLI_LIBX264" >> config.mak
+ cat > x264.pc << EOF
+ prefix=$prefix
+ exec_prefix=$exec_prefix
+-libdir=$libdir
++libdir=\${prefix}/lib
+ includedir=$includedir
+
+ 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
+