odrling-overlay/media-plugins/vapoursynth-descale/vapoursynth-descale-9999.ebuild
2019-07-06 14:59:16 +02:00

41 lines
951 B
Bash

# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit toolchain-funcs
DESCRIPTION="VapourSynth plugin to undo upscaling"
HOMEPAGE="https://github.com/BluBb-mADe/vapoursynth-descale"
if [[ ${PV} == *9999* ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/BluBb-mADe/vapoursynth-descale.git"
KEYWORDS=""
else
inherit vcs-snapshot
SRC_URI="https://github.com/BluBb-mADe/${PN}/archive/r${PV}.tar.gz -> ${PN}-${PV}.tar.gz"
KEYWORDS="~amd64 ~x86"
fi
LICENSE="WTFPL"
SLOT="0"
RDEPEND+="
media-libs/vapoursynth
"
DEPEND="${RDEPEND}"
LIBNAME="libdescale.so"
EXTRAFLAGS="-fPIC -shared -std=c++17"
src_compile(){
echo "$(tc-getCXX) ${CFLAGS} ${EXTRAFLAGS} ${LDFLAGS} -o ${LIBNAME} descale.cpp"
$(tc-getCXX) ${CFLAGS} ${EXTRAFLAGS} ${LDFLAGS} -o ${LIBNAME} descale.cpp || die "Build failed"
}
src_install(){
exeinto /usr/$(get_libdir)/vapoursynth/
doexe ${LIBNAME}
}