blob: 513675dc8a740cd37da707e5971108d0daa64712 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
# Copyright 2022-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake
DESCRIPTION="oneAPI Video Processing Library CPU implementation"
HOMEPAGE="https://github.com/oneapi-src/oneVPL-cpu"
SRC_URI="https://github.com/oneapi-src/oneVPL-cpu/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="MIT x264? ( GPL-2 )"
SLOT="0"
KEYWORDS="~amd64"
IUSE="experimental openh264 test +x264"
REQUIRED_USE="^^ ( openh264 x264 )"
# RESTRICT="!test? ( test )"
# Tests fail
RESTRICT="test"
BDEPEND="virtual/pkgconfig"
DEPEND="
media-libs/dav1d
media-libs/oneVPL[experimental?]
media-libs/svt-av1
media-libs/svt-hevc
media-video/ffmpeg
x264? ( media-libs/x264 )
openh264? ( media-libs/openh264 )
"
RDEPEND="${DEPEND}"
PATCHES=(
"${FILESDIR}/${PN}-2022.2.5-use-system-libs.patch"
"${FILESDIR}/${PN}-2022.2.5-respect-user-flags.patch"
)
src_configure() {
# Use system libraries
export VPL_BUILD_DEPENDENCIES="${ESYSROOT}/usr"
local mycmakeargs=(
-DUSE_EXPERIMENTAL_API="$(usex experimental)"
-DBUILD_OPENH264="$(usex openh264)"
-DBUILD_TESTS="$(usex test)"
-DBUILD_GPL_X264="$(usex x264)"
# Use FHS instead
-DUSE_ONEAPI_INSTALL_LAYOUT=NO
)
cmake_src_configure
}
src_install() {
cmake_src_install
# Remove these license files
rm -r "${ED}/usr/share/oneVPL-cpu/licensing" || die
}
|