libvpx: Added libvpx 1.15.2 (#12648)

This commit is contained in:
kenmays
2025-08-22 09:09:40 -07:00
committed by GitHub
parent af6391cd16
commit ac4f662091
4 changed files with 152 additions and 288 deletions

View File

@@ -1,112 +0,0 @@
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="4"
SOURCE_URI="https://github.com/webmproject/libvpx/archive/refs/tags/v1.0.0.tar.gz"
CHECKSUM_SHA256="6d625f5f93f905c593238a037306ef28be96f330a1f9e813515c3b59946dfdeb"
PATCHES="libvpx-1.0.0.patchset"
ARCHITECTURES="!all x86_gcc2"
SECONDARY_ARCHITECTURES="x86_gcc2 !x86"
libVersion="1.0.0"
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
portVersionCompat="$portVersion compat >= ${portVersion%.*}"
PROVIDES="
libvpx$secondaryArchSuffix = $portVersion
lib:libvpx$secondaryArchSuffix = $libVersionCompat
"
REQUIRES="
haiku$secondaryArchSuffix
"
if [ -z "$secondaryArchSuffix" ]; then
PROVIDES_bin="
libvpx${secondaryArchSuffix}_bin = $portVersion
cmd:vp8_scalable_patterns = $portVersion
cmd:vpxdec = $portVersionCompat
cmd:vpxenc = $portVersionCompat
"
REQUIRES_bin="
haiku$secondaryArchSuffix
libvpx$secondaryArchSuffix == $portVersion base
"
fi
PROVIDES_devel="
libvpx${secondaryArchSuffix}_devel = $portVersion
devel:libvpx$secondaryArchSuffix = $libVersionCompat
"
REQUIRES_devel="
libvpx$secondaryArchSuffix == $portVersion
"
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()
{
# not an auto tools configure
./configure \
--prefix="$prefix" \
--libdir="$libDir" \
--as=yasm \
--enable-pic \
--enable-shared \
--disable-static \
--enable-vp8
make $jobArgs
}
INSTALL()
{
make install
prepareInstalledDevelLibs libvpx
fixPkgconfig
mkdir -p $includeDir
mv $prefix/include/* $includeDir
rmdir $prefix/include
# devel package
packageEntries devel \
$developDir
# Remove stuff we don't need in the secondary architecture base package.
if [ -n "$secondaryArchSuffix" ]; then
rm -rf $prefix/bin
else
# bin package
packageEntries bin \
"$binDir"
fi
}

View File

@@ -7,7 +7,7 @@ COPYRIGHT="2009-2012 Google Inc.,
The Mozilla Foundation and
The Xiph.Org Foundation"
LICENSE="BSD (3-clause)"
REVISION="4"
REVISION="2"
SOURCE_URI="https://github.com/webmproject/libvpx/archive/v$portVersion.tar.gz"
CHECKSUM_SHA256="965e51c91ad9851e2337aebcc0f517440c637c506f3a03948062e3d5ea129a83"
SOURCE_FILENAME="libvpx-$portVersion.tar.gz"
@@ -41,18 +41,18 @@ BUILD_REQUIRES="
# 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:diff
cmd:egrep
cmd:gcc$secondaryArchSuffix
cmd:find
cmd:grep
cmd:ld$secondaryArchSuffix
cmd:make
cmd:perl
cmd:yasm
cmd:egrep
cmd:grep
cmd:sed
cmd:find
cmd:xargs
cmd:diff
cmd:yasm
"
BUILD()

View File

@@ -0,0 +1,144 @@
SUMMARY="WebM VP8/VP9 video codec library"
DESCRIPTION="The WebM VP8/VP9 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."
HOMEPAGE="https://www.webmproject.org/"
COPYRIGHT="2010-2025 The WebM project authors
2002-2010 The Xiph.Org Foundation and contributors"
LICENSE="BSD (3-clause)"
REVISION="1"
SOURCE_URI="https://github.com/webmproject/libvpx/archive/v$portVersion.tar.gz"
CHECKSUM_SHA256="26fcd3db88045dee380e581862a6ef106f49b74b6396ee95c2993a260b4636aa"
SOURCE_FILENAME="libvpx-$portVersion.tar.gz"
SOURCE_DIR="libvpx-$portVersion"
ARCHITECTURES="all !x86_gcc2"
SECONDARY_ARCHITECTURES="x86"
commandSuffix=$secondaryArchSuffix
commandBinDir=$binDir
if [ "$targetArchitecture" = x86_gcc2 ]; then
commandSuffix=
commandBinDir=$prefix/bin
fi
libVersion="11.0.1"
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
portVersionCompat="$portVersion compat >= ${portVersion%.*}"
PROVIDES="
libvpx1.15$secondaryArchSuffix = $portVersion
lib:libvpx$secondaryArchSuffix = $libVersionCompat
"
REQUIRES="
haiku$secondaryArchSuffix
lib:libstdc++$secondaryArchSuffix
"
PROVIDES_bin="
libvpx1.15${secondaryArchSuffix}_bin = $portVersion
cmd:vpxdec$commandSuffix = $portVersionCompat
cmd:vpxenc$commandSuffix = $portVersionCompat
"
REQUIRES_bin="
haiku$secondaryArchSuffix
lib:libstdc++$secondaryArchSuffix
"
if [ -n "$secondaryArchSuffix" -a "$commandBinDir" = "$prefix"/bin ]; then
CONFLICTS_bin="
libvpx_bin
"
fi
PROVIDES_devel="
libvpx1.15${secondaryArchSuffix}_devel = $portVersion
devel:libvpx$secondaryArchSuffix = $libVersionCompat
"
REQUIRES_devel="
libvpx1.15$secondaryArchSuffix == $portVersion base
"
CONFLICTS_devel="
libvpx${secondaryArchSuffix}_devel
libvpx1.11${secondaryArchSuffix}_devel
"
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:curl$secondaryArchSuffix
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
"
TEST_REQUIRES="
cmd:curl$secondaryArchSuffix
cmd:sha1sum
cmd:which
"
BUILD()
{
export CONFIG_SPATIAL_SVC=yes
# not an auto tools configure
./configure \
--prefix="$prefix" \
--libdir="$libDir" \
--as=yasm \
--enable-pic \
--enable-shared \
--disable-static \
--enable-vp8 \
--enable-vp9 \
--enable-postproc \
--enable-unit-tests
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
}
TEST()
{
make test
}

View File

@@ -1,168 +0,0 @@
From 98f5dcd5f2dba828f545dac2a534c90d0c5e6c53 Mon Sep 17 00:00:00 2001
From: korli <jerome.duval@gmail.com>
Date: Wed, 14 Mar 2012 00:15:38 +0000
Subject: patch for 1.0.0
diff --git a/build/make/configure.sh b/build/make/configure.sh
index cbf000b..4222e52 100755
--- a/build/make/configure.sh
+++ b/build/make/configure.sh
@@ -579,6 +579,9 @@ process_common_toolchain() {
*solaris2.10)
tgt_os=solaris
;;
+ *haiku*)
+ tgt_os=haiku
+ ;;
esac
if [ -n "$tgt_isa" ] && [ -n "$tgt_os" ]; then
@@ -909,8 +912,8 @@ process_common_toolchain() {
esac
;;
gcc*)
- add_cflags -m${bits}
- add_ldflags -m${bits}
+ enabled haiku || add_cflags -m${bits}
+ enabled haiku || add_ldflags -m${bits}
link_with_cc=gcc
tune_cflags="-march="
setup_gnu_toolchain
@@ -939,7 +942,7 @@ process_common_toolchain() {
add_asflags -f x64
enabled debug && add_asflags -g cv8
;;
- linux*|solaris*)
+ linux*|solaris*|haiku*)
add_asflags -f elf${bits}
enabled debug && [ "${AS}" = yasm ] && add_asflags -g dwarf2
enabled debug && [ "${AS}" = nasm ] && add_asflags -g
@@ -1019,6 +1022,7 @@ EOF
case ${toolchain} in
*-win*);;
*-android-gcc);;
+ *-haiku*);;
*) check_header pthread.h && add_extralibs -lpthread
esac
fi
diff --git a/configure b/configure
index 6195b2d..eb8a359 100755
--- a/configure
+++ b/configure
@@ -107,6 +107,7 @@ all_platforms="${all_platforms} x86-darwin8-icc"
all_platforms="${all_platforms} x86-darwin9-gcc"
all_platforms="${all_platforms} x86-darwin9-icc"
all_platforms="${all_platforms} x86-darwin10-gcc"
+all_platforms="${all_platforms} x86-haiku-gcc"
all_platforms="${all_platforms} x86-linux-gcc"
all_platforms="${all_platforms} x86-linux-icc"
all_platforms="${all_platforms} x86-solaris-gcc"
diff --git a/examples.mk b/examples.mk
index f6c9045..ab9657f 100644
--- a/examples.mk
+++ b/examples.mk
@@ -113,7 +113,9 @@ vp8_multi_resolution_encoder.DESCRIPTION = VP8 Multiple-resolution Encoding
# We should not link to math library (libm) on RVCT
# when building for bare-metal targets
ifeq ($(CONFIG_OS_SUPPORT), yes)
-CODEC_EXTRA_LIBS-$(CONFIG_VP8) += m
+ ifneq ($(TOOLCHAIN),x86-haiku-gcc)
+ CODEC_EXTRA_LIBS-$(CONFIG_VP8) += m
+ endif
else
ifeq ($(CONFIG_GCC), yes)
CODEC_EXTRA_LIBS-$(CONFIG_VP8) += m
--
1.8.3.4
From 9a194ee7b8498467e5700e2c4e39bc6a30c95714 Mon Sep 17 00:00:00 2001
From: Ingo Weinhold <ingo_weinhold@gmx.de>
Date: Tue, 11 Jun 2013 21:09:11 +0200
Subject: configure: enable shared library building for Haiku
diff --git a/configure b/configure
index eb8a359..a2ef98d 100755
--- a/configure
+++ b/configure
@@ -438,7 +438,7 @@ process_detect() {
# Can only build shared libs on a subset of platforms. Doing this check
# here rather than at option parse time because the target auto-detect
# magic happens after the command line has been parsed.
- enabled linux || die "--enable-shared only supported on ELF for now"
+ enabled linux || enabled haiku || die "--enable-shared only supported on ELF for now"
fi
if [ -z "$CC" ]; then
echo "Bypassing toolchain for environment detection."
--
1.8.3.4
From 238a1625cbbb75a1a84c112bacd3e6afee54a919 Mon Sep 17 00:00:00 2001
From: Ingo Weinhold <ingo_weinhold@gmx.de>
Date: Tue, 11 Jun 2013 21:09:28 +0200
Subject: libs.mk: no -lm or -lpthread on Haiku
diff --git a/libs.mk b/libs.mk
index 79a1d00..d88cfa7 100644
--- a/libs.mk
+++ b/libs.mk
@@ -196,7 +196,6 @@ LIBVPX_SO := libvpx.so.$(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION
LIBS-$(BUILD_LIBVPX_SO) += $(BUILD_PFX)$(LIBVPX_SO)\
$(notdir $(LIBVPX_SO_SYMLINKS))
$(BUILD_PFX)$(LIBVPX_SO): $(LIBVPX_OBJS) libvpx.ver
-$(BUILD_PFX)$(LIBVPX_SO): extralibs += -lm
$(BUILD_PFX)$(LIBVPX_SO): SONAME = libvpx.so.$(VERSION_MAJOR)
$(BUILD_PFX)$(LIBVPX_SO): SO_VERSION_SCRIPT = libvpx.ver
LIBVPX_SO_SYMLINKS := $(addprefix $(LIBSUBDIR)/, \
@@ -398,7 +397,7 @@ $(foreach bin,$(LIBVPX_TEST_BINS),\
$(if $(BUILD_LIBVPX),$(eval $(bin): libvpx.a libgtest.a ))\
$(if $(BUILD_LIBVPX),$(eval $(call linkerxx_template,$(bin),\
$(bin).cc.o \
- -L. -lvpx -lgtest -lpthread -lm)\
+ -L. -lvpx -lgtest)\
)))\
$(if $(LIPO_LIBS),$(eval $(call lipo_bin_template,$(bin))))\
--
1.8.3.4
From 214d6e14250d72980faf3798501efe5808562854 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Duval?= <jerome.duval@gmail.com>
Date: Tue, 3 Dec 2013 22:18:36 +0000
Subject: x86_64 support
* configure, amples.mk
diff --git a/configure b/configure
index a2ef98d..4b671ee 100755
--- a/configure
+++ b/configure
@@ -118,6 +118,7 @@ all_platforms="${all_platforms} x86-win32-vs9"
all_platforms="${all_platforms} x86_64-darwin9-gcc"
all_platforms="${all_platforms} x86_64-darwin10-gcc"
all_platforms="${all_platforms} x86_64-darwin11-gcc"
+all_platforms="${all_platforms} x86_64-haiku-gcc"
all_platforms="${all_platforms} x86_64-linux-gcc"
all_platforms="${all_platforms} x86_64-linux-icc"
all_platforms="${all_platforms} x86_64-solaris-gcc"
diff --git a/examples.mk b/examples.mk
index ab9657f..947a645 100644
--- a/examples.mk
+++ b/examples.mk
@@ -113,7 +113,7 @@ vp8_multi_resolution_encoder.DESCRIPTION = VP8 Multiple-resolution Encoding
# We should not link to math library (libm) on RVCT
# when building for bare-metal targets
ifeq ($(CONFIG_OS_SUPPORT), yes)
- ifneq ($(TOOLCHAIN),x86-haiku-gcc)
+ ifeq (,$(findstring haiku,$(TOOLCHAIN)))
CODEC_EXTRA_LIBS-$(CONFIG_VP8) += m
endif
else
--
1.8.3.4