Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 Jan 2014 21:21:52 +0000 (UTC)
From:      Max Brazhnikov <makc@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r341456 - in head/audio: . opusfile opusfile/files
Message-ID:  <201401272121.s0RLLqOC010319@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: makc
Date: Mon Jan 27 21:21:51 2014
New Revision: 341456
URL: http://svnweb.freebsd.org/changeset/ports/341456
QAT: https://qat.redports.org/buildarchive/r341456/

Log:
  Add new port audio/opusfile:
  
  Library for decoding .opus files, including seeking support.
  
  WWW: http://www.opus-codec.org/
  
  PR:		ports/177370
  Submitted by:	RyoTa SimaMoto <liangtai.s16 at gmail.com>

Added:
  head/audio/opusfile/
  head/audio/opusfile/Makefile   (contents, props changed)
  head/audio/opusfile/distinfo   (contents, props changed)
  head/audio/opusfile/files/
  head/audio/opusfile/files/ftime.c   (contents, props changed)
  head/audio/opusfile/files/patch-configure.ac   (contents, props changed)
  head/audio/opusfile/pkg-descr   (contents, props changed)
  head/audio/opusfile/pkg-plist   (contents, props changed)
Modified:
  head/audio/Makefile

Modified: head/audio/Makefile
==============================================================================
--- head/audio/Makefile	Mon Jan 27 21:20:21 2014	(r341455)
+++ head/audio/Makefile	Mon Jan 27 21:21:51 2014	(r341456)
@@ -535,6 +535,7 @@
     SUBDIR += optimfrog
     SUBDIR += opus
     SUBDIR += opus-tools
+    SUBDIR += opusfile
     SUBDIR += osalp
     SUBDIR += osd-lyrics
     SUBDIR += osdmixer

Added: head/audio/opusfile/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/audio/opusfile/Makefile	Mon Jan 27 21:21:51 2014	(r341456)
@@ -0,0 +1,57 @@
+# $FreeBSD$
+
+PORTNAME=	opusfile
+PORTVERSION=	0.5
+CATEGORIES=	audio
+MASTER_SITES=	http://downloads.xiph.org/releases/opus/ \
+		${MASTER_SITE_MOZILLA_EXTENDED}
+MASTER_SITE_SUBDIR=	opus
+
+MAINTAINER=	liangtai.s16@gmail.com
+COMMENT=	Opus playback library
+
+LICENSE=	BSD3CLAUSE
+
+LIB_DEPENDS=	libogg.so:${PORTSDIR}/audio/libogg \
+		libopus.so:${PORTSDIR}/audio/opus
+
+USES=		gmake pkgconfig pathfix
+USE_LDCONFIG=	yes
+GNU_CONFIGURE=	yes
+USE_AUTOTOOLS=	autoconf:env aclocal:env automake:env libtool
+MAKE_JOBS_UNSAFE=	yes
+PATHFIX_MAKEFILEIN=	Makefile.am
+
+PORTDOCS=	AUTHORS README.txt
+
+OPTIONS_DEFINE=	DOXYGEN DOCS
+OPTIONS_DEFAULT=	# empty
+
+DOXYGEN_CONFIGURE_ENABLE=	doc
+DOXYGEN_BUILD_DEPENDS=	doxygen:${PORTSDIR}/devel/doxygen
+
+.include <bsd.port.options.mk>
+
+post-patch:
+	@${REINPLACE_CMD} -e 's| @openssl@||' \
+		${WRKSRC}/opusfile.pc.in  ${WRKSRC}/opusurl.pc.in
+	@${REINPLACE_CMD} -e '/libopusurl_la_SOURCES/s/http.c/& src\/ftime.c/' \
+		${WRKSRC}/Makefile.am
+	@${CP} ${FILESDIR}/ftime.c ${WRKSRC}/src/
+
+pre-configure:
+	@(cd ${WRKSRC} && ${AUTORECONF} -fi)
+
+post-install:
+.if ${PORT_OPTIONS:MDOXYGEN}
+	@${RM} -f ${WRKDIR}/PLIST.doc ; \
+	${FIND} ${STAGEDIR}${DOCSDIR}/html -type f | \
+		${SED} 's|${STAGEDIR}${PREFIX}/||' \
+		>> ${WRKDIR}/PLIST.doc ; \
+	${FIND} ${STAGEDIR}${DOCSDIR}/html -type d | \
+		${SED} 's|${STAGEDIR}${PREFIX}/|@dirrm |' \
+		| ${SORT} -r >> ${WRKDIR}/PLIST.doc ; \
+	(cd ${WRKDIR} ; ${SED} -i -e '/PLIST.doc/ r PLIST.doc' ${TMPPLIST})
+.endif
+
+.include <bsd.port.mk>

Added: head/audio/opusfile/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/audio/opusfile/distinfo	Mon Jan 27 21:21:51 2014	(r341456)
@@ -0,0 +1,2 @@
+SHA256 (opusfile-0.5.tar.gz) = 2ce52d006aeeec9f10260dbe3073c4636954a1ab19c82b8baafefe0180aa4a39
+SIZE (opusfile-0.5.tar.gz) = 437671

Added: head/audio/opusfile/files/ftime.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/audio/opusfile/files/ftime.c	Mon Jan 27 21:21:51 2014	(r341456)
@@ -0,0 +1,53 @@
+/*
+ * Copyright (c) 1994 Christopher G. Demetriou
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ *    must display the following acknowledgement:
+ *      This product includes software developed by Christopher G. Demetriou.
+ * 4. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef lint
+static char rcsid[] = "$FreeBSD$";
+#endif /* not lint */
+
+#include <sys/types.h>
+#include <sys/time.h>
+#include <sys/timeb.h>
+
+int
+ftime(struct timeb *tbp)
+{
+	struct timezone tz;
+	struct timeval t;
+
+	if (gettimeofday(&t, &tz) < 0)
+		return (-1);
+	tbp->millitm = t.tv_usec / 1000;
+	tbp->time = t.tv_sec;
+	tbp->timezone = tz.tz_minuteswest;
+	tbp->dstflag = tz.tz_dsttime;
+
+	return (0);
+}

Added: head/audio/opusfile/files/patch-configure.ac
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/audio/opusfile/files/patch-configure.ac	Mon Jan 27 21:21:51 2014	(r341456)
@@ -0,0 +1,16 @@
+--- ./configure.ac.orig	2014-01-09 22:35:34.000000000 +0000
++++ ./configure.ac	2014-01-17 17:25:40.113916574 +0000
+@@ -90,10 +90,12 @@
+ AS_IF([test "$enable_http" != "no"], [
+    openssl="openssl"
+    AC_DEFINE([OP_ENABLE_HTTP], [1], [Enable HTTP support])
+-   PKG_CHECK_MODULES([URL_DEPS], [openssl])
+ ])
+ AM_CONDITIONAL(OP_ENABLE_HTTP, [test "$enable_http" != "no"])
+ AC_SUBST([openssl])
++AC_CHECK_LIB(ssl, SSL_read,
++	[AC_CHECK_HEADERS(openssl/ssl.h, LIBS="$LIBS -lssl -lcrypto",,)],,
++	-lcrypto -lssl)
+ 
+ PKG_CHECK_MODULES([DEPS], [ogg >= 1.3 opus >= 1.0.1])
+ 

Added: head/audio/opusfile/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/audio/opusfile/pkg-descr	Mon Jan 27 21:21:51 2014	(r341456)
@@ -0,0 +1,3 @@
+Library for decoding .opus files, including seeking support.
+
+WWW: http://www.opus-codec.org/

Added: head/audio/opusfile/pkg-plist
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/audio/opusfile/pkg-plist	Mon Jan 27 21:21:51 2014	(r341456)
@@ -0,0 +1,13 @@
+include/opus/opusfile.h
+lib/libopusfile.a
+lib/libopusfile.la
+lib/libopusfile.so
+lib/libopusfile.so.3
+lib/libopusurl.a
+lib/libopusurl.la
+lib/libopusurl.so
+lib/libopusurl.so.3
+libdata/pkgconfig/opusfile.pc
+libdata/pkgconfig/opusurl.pc
+@comment Insert PLIST.doc here
+@dirrmtry include/opus



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201401272121.s0RLLqOC010319>