blob: 61e35fe73d71eff3f3a41a7488f5a99e27c36b1f [file] [log] [blame]
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
SCM=""
if [ "${PV%9999}" != "${PV}" ] ; then # Live ebuild
SCM=git-r3
EGIT_BRANCH=master
EGIT_REPO_URI="https://github.com/intel/intel-vaapi-driver"
fi
AUTOTOOLS_AUTORECONF="yes"
inherit autotools-multilib ${SCM}
DESCRIPTION="HW video decode support for Intel integrated graphics"
HOMEPAGE="https://github.com/intel/intel-vaapi-driver"
if [ "${PV%9999}" != "${PV}" ] ; then # Live ebuild
SRC_URI=""
S="${WORKDIR}/${PN}"
else
SRC_URI="https://github.com/intel/intel-vaapi-driver/archive/${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/intel-vaapi-driver-${PV}"
fi
LICENSE="MIT"
SLOT="0"
if [ "${PV%9999}" = "${PV}" ] ; then
KEYWORDS="*"
else
KEYWORDS=""
fi
IUSE="+drm wayland X hybrid_codec"
RDEPEND=">=x11-libs/libva-2.1.0[X?,wayland?,drm?]
>=x11-libs/libdrm-2.4.46[video_cards_intel]
hybrid_codec? ( media-libs/intel-hybrid-driver )
wayland? ( >=media-libs/mesa-9.1.6[egl] >=dev-libs/wayland-1.0.6 )"
DEPEND="${RDEPEND}
virtual/pkgconfig"
DOCS=( AUTHORS NEWS README )
AUTOTOOLS_PRUNE_LIBTOOL_FILES="all"
src_prepare() {
epatch "${FILESDIR}"/no_explicit_sync_in_va_sync_surface.patch
epatch "${FILESDIR}"/Avoid-GPU-crash-with-malformed-streams.patch
epatch "${FILESDIR}"/set_multisample_state_for_gen6.patch
epatch "${FILESDIR}"/Disable-VP8-decoder-on-BDW.patch
epatch "${FILESDIR}"/FROMGIT-i965_pciids-add-kbl-y-refresh-PCI-ID.patch
epatch "${FILESDIR}"/UPSTREAM-Always-set-pre-post-deblocking-output-buffe.patch
sed -e 's/intel-gen4asm/\0diSaBlEd/g' -i configure.ac || die
autotools-multilib_src_prepare
}
multilib_src_configure() {
local myeconfargs=(
$(use_enable drm)
$(use_enable wayland)
$(use_enable X x11)
$(use_enable hybrid_codec)
)
autotools-utils_src_configure
}