From owner-svn-ports-all@freebsd.org Sat Dec 15 17:21:50 2018 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3A20C1326FCA; Sat, 15 Dec 2018 17:21:50 +0000 (UTC) (envelope-from jbeich@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D4555811D1; Sat, 15 Dec 2018 17:21:49 +0000 (UTC) (envelope-from jbeich@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id BD8801AA82; Sat, 15 Dec 2018 17:21:49 +0000 (UTC) (envelope-from jbeich@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id wBFHLno7043582; Sat, 15 Dec 2018 17:21:49 GMT (envelope-from jbeich@FreeBSD.org) Received: (from jbeich@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id wBFHLm2N043576; Sat, 15 Dec 2018 17:21:48 GMT (envelope-from jbeich@FreeBSD.org) Message-Id: <201812151721.wBFHLm2N043576@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jbeich set sender to jbeich@FreeBSD.org using -f From: Jan Beich Date: Sat, 15 Dec 2018 17:21:48 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r487536 - in head/multimedia: . dav1d dav1d/files X-SVN-Group: ports-head X-SVN-Commit-Author: jbeich X-SVN-Commit-Paths: in head/multimedia: . dav1d dav1d/files X-SVN-Commit-Revision: 487536 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: D4555811D1 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.86 / 15.00]; local_wl_from(0.00)[FreeBSD.org]; NEURAL_HAM_MEDIUM(-0.99)[-0.990,0]; NEURAL_HAM_SHORT(-0.99)[-0.985,0]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; NEURAL_HAM_LONG(-0.88)[-0.881,0] X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Dec 2018 17:21:50 -0000 Author: jbeich Date: Sat Dec 15 17:21:48 2018 New Revision: 487536 URL: https://svnweb.freebsd.org/changeset/ports/487536 Log: multimedia/dav1d: add new port Added: head/multimedia/dav1d/ head/multimedia/dav1d/Makefile (contents, props changed) head/multimedia/dav1d/distinfo (contents, props changed) head/multimedia/dav1d/files/ head/multimedia/dav1d/files/patch-neon (contents, props changed) head/multimedia/dav1d/pkg-descr (contents, props changed) head/multimedia/dav1d/pkg-plist (contents, props changed) Modified: head/multimedia/Makefile (contents, props changed) Modified: head/multimedia/Makefile ============================================================================== --- head/multimedia/Makefile Sat Dec 15 17:19:53 2018 (r487535) +++ head/multimedia/Makefile Sat Dec 15 17:21:48 2018 (r487536) @@ -44,6 +44,7 @@ SUBDIR += cmrt SUBDIR += cuse4bsd-kmod SUBDIR += cx88 + SUBDIR += dav1d SUBDIR += deforaos-player SUBDIR += devede SUBDIR += din Added: head/multimedia/dav1d/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/dav1d/Makefile Sat Dec 15 17:21:48 2018 (r487536) @@ -0,0 +1,42 @@ +# $FreeBSD$ + +PORTNAME= dav1d +DISTVERSION= 0.1.0 +CATEGORIES= multimedia + +MAINTAINER= jbeich@FreeBSD.org +COMMENT= Small and fast AV1 decoder + +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/COPYING + +BUILD_DEPENDS= ${BUILD_DEPENDS_${ARCH}} +BUILD_DEPENDS_aarch64= as:devel/binutils +BUILD_DEPENDS_amd64= nasm:devel/nasm +BUILD_DEPENDS_armv6= ${LOCALBASE}/bin/as:devel/binutils +BUILD_DEPENDS_armv7= ${LOCALBASE}/bin/as:devel/binutils +BUILD_DEPENDS_i386= nasm:devel/nasm + +USES= meson +USE_GITLAB= yes +USE_LDCONFIG= yes +GL_SITE= https://code.videolan.org +GL_ACCOUNT= videolan +GL_COMMIT= a6b903fb6d78f1515b2c50ba17ae50ead8cf5b72 +CONFIGURE_ENV= UNAME_m=${ARCH} # XXX cpu_family() +CFLAGS_aarch64= -no-integrated-as +CFLAGS_armv6= -no-integrated-as -B${LOCALBASE}/bin +CFLAGS_armv7= -no-integrated-as -B${LOCALBASE}/bin + +OPTIONS_DEFINE= TEST + +TEST_GL_TUPLE= videolan:dav1d-test-data:0028f7f3d9cdcd0e95643e16d49d5a691807cb77:testdata/tests/dav1d-test-data +TEST_MESON_TRUE=build_tests testdata_tests + +.if make(makesum) # for optional distfiles +.MAKEFLAGS: WITH="${OPTIONS_DEFINE}" +.endif + +pre-install-TEST-on: do-test + +.include Added: head/multimedia/dav1d/distinfo ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/dav1d/distinfo Sat Dec 15 17:21:48 2018 (r487536) @@ -0,0 +1,5 @@ +TIMESTAMP = 1544537696 +SHA256 (videolan-dav1d-a6b903fb6d78f1515b2c50ba17ae50ead8cf5b72_GL0.tar.gz) = 28894914313dce4b8ffa5752502c486d11594f2b0ebd64c9dc8ee4ee28cb5e9c +SIZE (videolan-dav1d-a6b903fb6d78f1515b2c50ba17ae50ead8cf5b72_GL0.tar.gz) = 443816 +SHA256 (videolan-dav1d-test-data-0028f7f3d9cdcd0e95643e16d49d5a691807cb77_GL0.tar.gz) = f7172cb7d4f57e54d0caad8ab60fd43235983a2673a5e955c62fc3565a711eb9 +SIZE (videolan-dav1d-test-data-0028f7f3d9cdcd0e95643e16d49d5a691807cb77_GL0.tar.gz) = 31033900 Added: head/multimedia/dav1d/files/patch-neon ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/dav1d/files/patch-neon Sat Dec 15 17:21:48 2018 (r487536) @@ -0,0 +1,75 @@ +- Assume NEON on FreeBSD armv7 +- Implement NEON runtime detection on FreeBSD armv6 + +--- meson.build.orig 2018-12-11 14:14:56 UTC ++++ meson.build +@@ -147,6 +147,9 @@ if (host_machine.cpu_family() == 'aarch64' or + if cc.has_function('getauxval', prefix : '#include ', args : test_args) + cdata.set('HAVE_GETAUXVAL', 1) + endif ++ if cc.has_function('elf_aux_info', prefix : '#include ', args : test_args) ++ cdata.set('HAVE_ELF_AUX_INFO', 1) ++ endif + endif + + # Compiler flag tests +--- src/arm/cpu.c.orig 2018-12-11 14:14:56 UTC ++++ src/arm/cpu.c +@@ -29,7 +29,7 @@ + + #include "src/arm/cpu.h" + +-#if defined(HAVE_GETAUXVAL) && ARCH_ARM ++#if (defined(HAVE_GETAUXVAL) || defined(HAVE_ELF_AUX_INFO)) && ARCH_ARM + #include + + #ifndef HWCAP_ARM_NEON +@@ -68,12 +68,48 @@ static unsigned parse_proc_cpuinfo(const char *flag) { + } + #endif + ++#if defined(__FreeBSD__) && __FreeBSD__ < 12 ++#include ++#include ++#include ++#include ++#include ++ ++#define HAVE_GETAUXVAL ++#define NEON_HWCAP HWCAP_NEON ++static unsigned long getauxval(unsigned long type) { ++ Elf_Auxinfo auxv[AT_COUNT]; ++ size_t len = sizeof(auxv); ++ int mib[] = { ++ CTL_KERN, ++ KERN_PROC, ++ KERN_PROC_AUXV, ++ getpid(), ++ }; ++ ++ if (sysctl(mib, nitems(mib), auxv, &len, NULL, 0) != -1) { ++ for (size_t i = 0; i < nitems(auxv); i++) ++ if ((unsigned long)auxv[i].a_type == type) ++ return auxv[i].a_un.a_val; ++ ++ errno = ENOENT; ++ } ++ return 0; ++} ++#endif ++ + unsigned dav1d_get_cpu_flags_arm(void) { + unsigned flags = 0; + #if ARCH_AARCH64 + flags |= DAV1D_ARM_CPU_FLAG_NEON; ++#elif defined(__ARM_NEON) ++ flags |= DAV1D_ARM_CPU_FLAG_NEON; + #elif defined(HAVE_GETAUXVAL) && ARCH_ARM + unsigned long hw_cap = getauxval(AT_HWCAP); ++ flags |= (hw_cap & NEON_HWCAP) ? DAV1D_ARM_CPU_FLAG_NEON : 0; ++#elif defined(HAVE_ELF_AUX_INFO) && ARCH_ARM ++ unsigned long hw_cap; ++ elf_aux_info(AT_HWCAP, &hw_cap, sizeof(hw_cap)); + flags |= (hw_cap & NEON_HWCAP) ? DAV1D_ARM_CPU_FLAG_NEON : 0; + #elif defined(__ANDROID__) + flags |= parse_proc_cpuinfo("neon") ? DAV1D_ARM_CPU_FLAG_NEON : 0; Added: head/multimedia/dav1d/pkg-descr ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/dav1d/pkg-descr Sat Dec 15 17:21:48 2018 (r487536) @@ -0,0 +1,4 @@ +dav1d is a new AV1 cross-platform decoder, open-source, and focused on +speed and correctness. + +WWW: https://code.videolan.org/videolan/dav1d Added: head/multimedia/dav1d/pkg-plist ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/dav1d/pkg-plist Sat Dec 15 17:21:48 2018 (r487536) @@ -0,0 +1,10 @@ +bin/dav1d +include/dav1d/common.h +include/dav1d/data.h +include/dav1d/dav1d.h +include/dav1d/headers.h +include/dav1d/picture.h +lib/libdav1d.so +lib/libdav1d.so.0 +lib/libdav1d.so.0.1.0 +libdata/pkgconfig/dav1d.pc