mirror of
https://github.com/yann64/haikuports.git
synced 2026-05-04 14:08:51 +02:00
132 lines
3.0 KiB
Bash
132 lines
3.0 KiB
Bash
SUMMARY="WebM VP8 video codec library"
|
|
DESCRIPTION="The WebM VP8 SDK allows you to integrate your applications with \
|
|
the VP8 video codec, a high quality, royalty free, open source codec deployed \
|
|
on millions of computers and devices worldwide.
|
|
|
|
This distribution of the WebM VP8 Codec SDK includes the following support:
|
|
- WebM VP8 Encoder
|
|
- WebM VP8 Decoder"
|
|
HOMEPAGE="https://www.webmproject.org/"
|
|
COPYRIGHT="2009-2012 Google Inc.,
|
|
The Mozilla Foundation and
|
|
The Xiph.Org Foundation"
|
|
LICENSE="BSD (3-clause)"
|
|
REVISION="3"
|
|
SOURCE_URI="https://github.com/webmproject/libvpx/archive/v$portVersion.tar.gz"
|
|
CHECKSUM_SHA256="1fec931eb5c94279ad219a5b6e0202358e94a93a90cfb1603578c326abfc1238"
|
|
SOURCE_FILENAME="libvpx-$portVersion.tar.gz"
|
|
SOURCE_DIR="libvpx-$portVersion"
|
|
PATCHES="libvpx-$portVersion.patchset"
|
|
|
|
ARCHITECTURES="!x86_gcc2 ?x86 x86_64"
|
|
SECONDARY_ARCHITECTURES="x86"
|
|
|
|
commandSuffix=$secondaryArchSuffix
|
|
commandBinDir=$binDir
|
|
if [ "$targetArchitecture" = x86_gcc2 ]; then
|
|
commandSuffix=
|
|
commandBinDir=$prefix/bin
|
|
fi
|
|
|
|
libVersion="5.0.0"
|
|
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
|
portVersionCompat="$portVersion compat >= ${portVersion%.*}"
|
|
|
|
PROVIDES="
|
|
libvpx$secondaryArchSuffix = $portVersion
|
|
lib:libvpx$secondaryArchSuffix = $libVersionCompat
|
|
"
|
|
REQUIRES="
|
|
haiku$secondaryArchSuffix
|
|
"
|
|
|
|
PROVIDES_bin="
|
|
libvpx${secondaryArchSuffix}_bin = $portVersion
|
|
cmd:vpxdec$commandSuffix = $portVersionCompat
|
|
cmd:vpxenc$commandSuffix = $portVersionCompat
|
|
"
|
|
REQUIRES_bin="
|
|
haiku$secondaryArchSuffix
|
|
libvpx$secondaryArchSuffix == $portVersion base
|
|
"
|
|
if [ -n "$secondaryArchSuffix" -a "$commandBinDir" = "$prefix"/bin ]; then
|
|
CONFLICTS_bin="
|
|
libvpx_bin
|
|
"
|
|
fi
|
|
|
|
PROVIDES_devel="
|
|
libvpx${secondaryArchSuffix}_devel = $portVersion
|
|
devel:libvpx$secondaryArchSuffix = $libVersionCompat
|
|
"
|
|
REQUIRES_devel="
|
|
libvpx$secondaryArchSuffix == $portVersion base
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku${secondaryArchSuffix}_devel
|
|
"
|
|
# Note: The build system also looks for libvorbis and SDL, but that seems
|
|
# to be needed only for building the sample player, which we don't need.
|
|
BUILD_PREREQUIRES="
|
|
cmd:gcc$secondaryArchSuffix
|
|
cmd:ld$secondaryArchSuffix
|
|
cmd:awk
|
|
cmd:make
|
|
cmd:perl
|
|
cmd:yasm
|
|
cmd:egrep
|
|
cmd:grep
|
|
cmd:sed
|
|
cmd:find
|
|
cmd:xargs
|
|
cmd:diff
|
|
"
|
|
|
|
BUILD()
|
|
{
|
|
export CONFIG_SPATIAL_SVC=yes
|
|
# not an auto tools configure
|
|
./configure \
|
|
--prefix="$prefix" \
|
|
--libdir="$libDir" \
|
|
--as=yasm \
|
|
--enable-pic \
|
|
--enable-shared \
|
|
--enable-vp8 \
|
|
--enable-vp9 \
|
|
|
|
make $jobArgs
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
CONFIG_SPATIAL_SVC=yes \
|
|
make install
|
|
|
|
prepareInstalledDevelLibs libvpx
|
|
fixPkgconfig
|
|
|
|
mkdir -p $includeDir
|
|
mv $prefix/include/* $includeDir
|
|
rmdir $prefix/include
|
|
|
|
if [ -n "$secondaryArchSuffix" -a "$commandBinDir" != "$prefix/bin" ]; then
|
|
mkdir -p "$commandBinDir"
|
|
mv "$prefix"/bin/vpxdec "$commandBinDir"
|
|
mv "$prefix"/bin/vpxenc "$commandBinDir"
|
|
fi
|
|
|
|
# devel package
|
|
packageEntries devel \
|
|
"$developDir"
|
|
|
|
# bin package
|
|
packageEntries bin \
|
|
"$commandBinDir"
|
|
|
|
if [ -n "$secondaryArchSuffix" -a "$commandBinDir" != "$prefix"/bin ]; then
|
|
rmdir "$prefix"/bin
|
|
fi
|
|
}
|