Skip to content

Commit c429f48

Browse files
committed
media-libs/libva: Fix build with LLD 17
Upstream PR: intel/libva#732 In the upcoming LLD 17 (and previously in LLD 16.0.0, but reverted in 16.0.1), --no-undefined-version is becoming the default behavior. This causes the configure check for --version-scripts support to fail due to the symbols in the version script not being defined, which will cause the version script to not be used, and the build will fail due to --no-undefined-version. This patch adds '-Wl,--undefined-version' to the args of the configure check. Signed-off-by: Violet Purcell <[email protected]>
1 parent b77a5ac commit c429f48

File tree

4 files changed

+41
-0
lines changed

4 files changed

+41
-0
lines changed
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
From https://github.com/intel/libva/pull/732/commits/48a1674e9d5b0ea33bc1677c88743c59f087ffde Mon Sep 17 00:00:00 2001
2+
From: Violet Purcell <[email protected]>
3+
Date: Wed, 19 Jul 2023 22:12:59 -0400
4+
Subject: [PATCH] va: fix configure check for --version-script with
5+
--no-undefined-version
6+
7+
In the upcoming LLD 17 (and previously in LLD 16.0.0, but reverted in 16.0.1),
8+
--no-undefined-version is becoming the default behavior. This causes the
9+
configure check for --version-scripts support to fail due to the symbols
10+
in the version script not being defined, which will cause the version
11+
script to not be used, and the build will fail due to
12+
--no-undefined-version. This commit adds '-Wl,--undefined-version' to
13+
the args of the configure check.
14+
15+
Signed-off-by: Violet Purcell <[email protected]>
16+
--- a/va/meson.build
17+
+++ b/va/meson.build
18+
@@ -60,7 +60,7 @@ libva_sym_arg = '-Wl,-version-script,' + '@0@/@1@'.format(meson.current_source_d
19+
20+
libva_link_args = []
21+
libva_link_depends = []
22+
-if cc.links('', name: '-Wl,--version-script', args: ['-shared', libva_sym_arg])
23+
+if cc.links('', name: '-Wl,--version-script', args: ['-shared', '-Wl,--undefined-version', libva_sym_arg])
24+
libva_link_args = libva_sym_arg
25+
libva_link_depends = libva_sym
26+
endif
27+
--
28+
2.41.0
29+

media-libs/libva/libva-2.18.0-r1.ebuild renamed to media-libs/libva/libva-2.18.0-r2.ebuild

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,10 @@ BDEPEND="
3939
virtual/pkgconfig
4040
"
4141

42+
PATCHES=(
43+
"${FILESDIR}/${PN}-2.19.0-undefined-version.patch"
44+
)
45+
4246
MULTILIB_WRAPPED_HEADERS=(
4347
/usr/include/va/va_x11.h
4448
/usr/include/va/va_dri2.h

media-libs/libva/libva-2.19.0.ebuild renamed to media-libs/libva/libva-2.19.0-r1.ebuild

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,10 @@ BDEPEND="
3939
virtual/pkgconfig
4040
"
4141

42+
PATCHES=(
43+
"${FILESDIR}/${PN}-2.19.0-undefined-version.patch"
44+
)
45+
4246
MULTILIB_WRAPPED_HEADERS=(
4347
/usr/include/va/va_x11.h
4448
/usr/include/va/va_dri2.h

media-libs/libva/libva-9999.ebuild

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,10 @@ BDEPEND="
3939
virtual/pkgconfig
4040
"
4141

42+
PATCHES=(
43+
"${FILESDIR}/${PN}-2.19.0-undefined-version.patch"
44+
)
45+
4246
MULTILIB_WRAPPED_HEADERS=(
4347
/usr/include/va/va_x11.h
4448
/usr/include/va/va_dri2.h

0 commit comments

Comments
 (0)