<pre style='margin:0'>
Christopher Nielsen (mascguy) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/2020a9261ecd51f554b7628e8b666b6ec4ded076">https://github.com/macports/macports-ports/commit/2020a9261ecd51f554b7628e8b666b6ec4ded076</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit 2020a9261ecd51f554b7628e8b666b6ec4ded076
</span>Author: barracuda156 <vital.had@gmail.com>
AuthorDate: Sun Apr 24 18:34:14 2022 +0800
<span style='display:block; white-space:pre;color:#404040;'> libvpx: generic fix for PowerPC
</span>---
multimedia/libvpx/Portfile | 39 +++++++++++++++++++++-------
multimedia/libvpx/files/patch-vpx_ports.diff | 38 +++++++++++++++++++++++++++
2 files changed, 67 insertions(+), 10 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/libvpx/Portfile b/multimedia/libvpx/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 4bd6211eef4..7378afdce4d 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/libvpx/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/libvpx/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -8,10 +8,9 @@ name libvpx
</span> conflicts libvpx-devel
set my_name libvpx
version 1.11.0
<span style='display:block; white-space:pre;background:#ffe0e0;'>-revision 1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+revision 2
</span> categories multimedia
maintainers {mascguy @mascguy} openmaintainer
<span style='display:block; white-space:pre;background:#ffe0e0;'>-platforms darwin
</span> license Permissive
description WebM VP8/VP9 Codec SDK
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -37,9 +36,6 @@ fetch.type git
</span> git.url https://chromium.googlesource.com/webm/${my_name}
git.branch v${version}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-# support for non-intel archs removed in version 1.5.0
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-supported_archs x86_64 i386 arm64
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span> patchfiles patch-Makefile.diff \
patch-configure.sh.diff
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -55,12 +51,22 @@ configure.args --enable-vp8 \
</span> --enable-postproc \
--enable-multithread \
--enable-experimental \
<span style='display:block; white-space:pre;background:#ffe0e0;'>- --enable-shared \
</span> --disable-install-docs \
--disable-debug-libs \
--disable-examples \
--disable-unit-tests
<span style='display:block; white-space:pre;background:#e0ffe0;'>+platform darwin {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${build_arch} eq "ppc" || ${build_arch} eq "ppc64"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # disable a wrong kind of abi
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patchfiles-append patch-vpx_ports.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # with shared enabled the build fails
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.args-append --disable-shared
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.args-append --enable-shared
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> build.target
build.args verbose=1
destroot.args verbose=1
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -89,6 +95,15 @@ if {${universal_possible} && [variant_isset universal]} {
</span> set merger_configure_env(${my_arch}) LD=${configure.cc}
}
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ foreach my_arch {ppc ppc64} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set merger_host(${my_arch}) ""
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set merger_configure_args(${my_arch}) --force-target=generic-gnu
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set merger_configure_env(${my_arch}) LD=${configure.cc}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> if {"x86_64" in ${configure.universal_archs} || "i386" in ${configure.universal_archs}} {
depends_build-append port:yasm
depends_skip_archcheck-append yasm
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -107,10 +122,14 @@ if {${universal_possible} && [variant_isset universal]} {
</span>
} else {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- # normal build
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # force the target
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- configure.args-append --force-target=${configure.build_arch}-${os.platform}${os.major}-gcc
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # single-arch build
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # force the target: generic fix for PowerPC
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${build_arch} eq "ppc" || ${build_arch} eq "ppc64"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.args-append --force-target=generic-gnu
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.args-append --force-target=${configure.build_arch}-${os.platform}${os.major}-gcc
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span>
# set LD
configure.env-append LD=${configure.cc}
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/libvpx/files/patch-vpx_ports.diff b/multimedia/libvpx/files/patch-vpx_ports.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 00000000000..a2c24e1ff46
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/libvpx/files/patch-vpx_ports.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,38 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# This is a wrong kind of PPC, we donʼt want it.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- vpx_ports/vpx_ports.mk.orig 2021-10-07 01:41:19.000000000 +0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ vpx_ports/vpx_ports.mk 2022-04-24 17:38:34.000000000 +0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -39,8 +39,10 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PORTS_SRCS-$(VPX_ARCH_ARM) += arm_cpudetect.c
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PORTS_SRCS-$(VPX_ARCH_ARM) += arm.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ifeq ($(VPX_ARCH_PPC64LE),yes)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PORTS_SRCS-$(VPX_ARCH_PPC) += ppc_cpudetect.c
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PORTS_SRCS-$(VPX_ARCH_PPC) += ppc.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PORTS_SRCS-$(VPX_ARCH_MIPS) += mips_cpudetect.c
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PORTS_SRCS-$(VPX_ARCH_MIPS) += mips.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- vp8/common/generic/systemdependent.c.orig 2021-10-07 01:41:19.000000000 +0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ vp8/common/generic/systemdependent.c 2022-04-24 18:03:19.000000000 +0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -14,7 +14,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "vpx_ports/arm.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #elif VPX_ARCH_X86 || VPX_ARCH_X86_64
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "vpx_ports/x86.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-#elif VPX_ARCH_PPC
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#elif VPX_ARCH_PPC64LE
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "vpx_ports/ppc.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #elif VPX_ARCH_MIPS
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "vpx_ports/mips.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -96,7 +96,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ctx->cpu_caps = arm_cpu_caps();
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #elif VPX_ARCH_X86 || VPX_ARCH_X86_64
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ctx->cpu_caps = x86_simd_caps();
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-#elif VPX_ARCH_PPC
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#elif VPX_ARCH_PPC64LE
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ctx->cpu_caps = ppc_simd_caps();
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #elif VPX_ARCH_MIPS
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ctx->cpu_caps = mips_cpu_caps();
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span></pre><pre style='margin:0'>
</pre>