From: Alexis Ballier Date: Tue, 10 Apr 2018 07:43:23 +0000 (+0200) Subject: media-libs/libaom: fix shared lib underlinking X-Git-Url: http://git.tremily.us/gitweb.cgi?a=commitdiff_plain;h=2ef91df1f0f81deca530b90a249c94d86f4ace36;p=gentoo.git media-libs/libaom: fix shared lib underlinking Package-Manager: Portage-2.3.28, Repoman-2.3.9 --- diff --git a/media-libs/libaom/files/pthread_lib.patch b/media-libs/libaom/files/pthread_lib.patch new file mode 100644 index 000000000000..d8770bc687ca --- /dev/null +++ b/media-libs/libaom/files/pthread_lib.patch @@ -0,0 +1,14 @@ +Index: libaom-9999/CMakeLists.txt +=================================================================== +--- libaom-9999.orig/CMakeLists.txt ++++ libaom-9999/CMakeLists.txt +@@ -598,6 +598,9 @@ if (BUILD_SHARED_LIBS) + include("${AOM_ROOT}/build/cmake/exports.cmake") + setup_exports_target() + set_target_properties(aom PROPERTIES SOVERSION 0) ++ if (HAVE_PTHREAD_H AND CONFIG_MULTITHREAD) ++ target_link_libraries(aom ${AOM_LIB_LINK_TYPE} Threads::Threads) ++ endif () + endif () + + # Handle user supplied compile and link flags last to ensure they're obeyed. diff --git a/media-libs/libaom/libaom-9999.ebuild b/media-libs/libaom/libaom-9999.ebuild index 512d1b35470c..9b472bd99def 100644 --- a/media-libs/libaom/libaom-9999.ebuild +++ b/media-libs/libaom/libaom-9999.ebuild @@ -35,7 +35,7 @@ REQUIRED_USE=" cpu_flags_x86_ssse3? ( cpu_flags_x86_sse2 ) " -PATCHES=( "${FILESDIR}/libdirpc.patch" ) +PATCHES=( "${FILESDIR}/libdirpc.patch" "${FILESDIR}/pthread_lib.patch" ) src_prepare() { sed -e 's/lib"/lib${LIB_SUFFIX}"/' -i CMakeLists.txt || die