Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 25 Mar 2013 11:41:58 GMT
From:      RyoTa SimaMoto <liangtai.s4@gmail.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/177370: New port: audio/opusfile
Message-ID:  <201303251141.r2PBfwVk017961@red.freebsd.org>
Resent-Message-ID: <201303251150.r2PBo0Ms018166@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         177370
>Category:       ports
>Synopsis:       New port: audio/opusfile
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Mar 25 11:50:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     RyoTa SimaMoto
>Release:        9.1-STABLE
>Organization:
>Environment:
FreeBSD takiba.fakenet 9.1-STABLE FreeBSD 9.1-STABLE #4 r245831M: Wed Jan 23 12:47:50 JST 2013     root@takiba.fakenet:/usr/obj/usr/src/sys/VAIO  i386
>Description:
New port: opusfile-0.2

opusfile is a library for decoding *.opus files, including
seeking support.
http://www.opus-codec.org/

This package does not contain online manual, but you can
install API document in HTML (optional).

NOTE for ports directors: I decided using autoconf tools to
detect libssl.so without help of Pkgconfig, and to capture
libcompat.so too.  If it costs too much against its purpose,
or something wrong in changes of configure.ac, please tell
me.  Then I would write patch to replace generated configure
script than modifying configure.ac file because I am not
sure about autoconf tools.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	audio/opusfile
#	audio/opusfile/Makefile
#	audio/opusfile/distinfo
#	audio/opusfile/files
#	audio/opusfile/files/patch-configure.ac
#	audio/opusfile/pkg-descr
#	audio/opusfile/pkg-plist
#
echo c - audio/opusfile
mkdir -p audio/opusfile > /dev/null 2>&1
echo x - audio/opusfile/Makefile
sed 's/^X//' >audio/opusfile/Makefile << 'dc923892a36dc107d7984e71d2d7558c'
X# $FreeBSD$
X
XPORTNAME=	opusfile
XPORTVERSION=	0.2
XCATEGORIES=	audio
XMASTER_SITES=	http://downloads.xiph.org/releases/opus/ \
X		${MASTER_SITE_MOZILLA_EXTENDED}
XMASTER_SITE_SUBDIR=	opus
X
XMAINTAINER=	liangtai.s4@gmail.com
XCOMMENT=	Opus playback library
X
XLICENSE=	BSD
X
XLIB_DEPENDS=	ogg:${PORTSDIR}/audio/libogg \
X		opus:${PORTSDIR}/audio/opus
X
XUSE_GZIP=	yes
XUSE_GMAKE=	yes
XUSE_LDCONFIG=	yes
XGNU_CONFIGURE=	yes
XUSE_PKGCONFIG=	yes
XUSE_AUTOTOOLS=	autoconf:env aclocal:env automake:env libtool
XPATCH_STRIP=	-p1
XMAKE_JOBS_UNSAFE=	yes
X
XOPTIONS_DEFINE=	APIDOC DOCS
XOPTIONS_DEFAULT=
XAPIDOC_DESC=	Install Doxygen generated doc (libopusfile)
X
X.include <bsd.port.options.mk>
X
X.if ${PORT_OPTIONS:MAPIDOC}
XCONFIGURE_ARGS+=	--enable-doc
XBUILD_DEPENDS+=	doxygen:${PORTSDIR}/devel/doxygen
X.else
XCONFIGURE_ARGS+=	--disable-doc
X.endif
X
X.if ${PORT_OPTIONS:MDOCS}
XDIST_DOCS=	AUTHORS README.txt
X.endif
X
Xpost-patch:
X	@${REINPLACE_CMD} -e 's|%%PACKAGE_VERSION%%|${PORTVERSION}|' \
X		${WRKSRC}/configure.ac
X
Xpre-configure:
X	@${REINPLACE_CMD} -e 's|^\(dist_doc_DATA =\).*|\1 ${DIST_DOCS}|' \
X		-e 's|^\(pkgconfigdir =\).*|\1 ${PREFIX}/libdata/pkgconfig|' \
X		${WRKSRC}/Makefile.am
X	@(cd ${WRKSRC} && ${AUTORECONF} -fi)
X
Xpost-install:
X.if ${PORT_OPTIONS:MAPIDOC}
X	@${RM} -f ${WRKDIR}/PLIST.doc ; \
X	${FIND} ${DOCSDIR}/html -type f | ${SED} 's|${PREFIX}/||' \
X		>> ${WRKDIR}/PLIST.doc ; \
X	${FIND} ${DOCSDIR}/html -type d | ${SED} 's|${PREFIX}/|@dirrm |' \
X		| ${SORT} -r >> ${WRKDIR}/PLIST.doc ; \
X	(cd ${WRKDIR} ; ${SED} -i -e '/PLIST.doc/ r PLIST.doc' ${TMPPLIST})
X.endif
X
X.include <bsd.port.mk>
dc923892a36dc107d7984e71d2d7558c
echo x - audio/opusfile/distinfo
sed 's/^X//' >audio/opusfile/distinfo << 'b6ba950745df1c6714a9c8ed9088dd0c'
XSHA256 (opusfile-0.2.tar.gz) = b4a678b3b6c4adfb6aff1f67ef658becfe146ea7c7ff228e99543762171557f9
XSIZE (opusfile-0.2.tar.gz) = 399527
b6ba950745df1c6714a9c8ed9088dd0c
echo c - audio/opusfile/files
mkdir -p audio/opusfile/files > /dev/null 2>&1
echo x - audio/opusfile/files/patch-configure.ac
sed 's/^X//' >audio/opusfile/files/patch-configure.ac << 'f05de535f1a05e26f8fecc524204f524'
XFrom b70517b768e8f546427a745c5e834bb0b0e98e0c Mon Sep 17 00:00:00 2001
XFrom: =?UTF-8?q?SimaMoto=2CRy=C5=8DTa?= <liangtai.s4@gmail.com>
XDate: Sun, 3 Mar 2013 12:42:23 +0900
XSubject: [PATCH] Detect openssl without using pkgconfig
X
X* Allow to run on FreeBSD that don't have openssl.pc while it has
X  libssl.so
X* Detect libcompat.so to use ftime(3)
X* Allow to specify PACKAGE_VERSION out of GIT repository
X---
X configure.ac | 8 ++++++--
X 1 file changed, 6 insertions(+), 2 deletions(-)
X
Xdiff --git a/configure.ac b/configure.ac
Xindex 3133b7f..dd508e3 100644
X--- a/configure.ac
X+++ b/configure.ac
X@@ -1,6 +1,6 @@
X # autoconf source script for generating configure
X 
X-AC_INIT([opusfile], m4_esyscmd([doc/git-version.sh]))
X+AC_INIT([opusfile], %%PACKAGE_VERSION%%)
X 
X AC_USE_SYSTEM_EXTENSIONS
X AC_SYS_LARGEFILE
X@@ -53,8 +53,12 @@ AS_IF([test "x$enable_http" != "xno"], [
X    AC_DEFINE([OP_ENABLE_HTTP], [1], [Enable HTTP support])
X ])
X AC_SUBST(openssl)
X+AC_CHECK_LIB(ssl,SSL_read,
X+	[AC_CHECK_HEADERS(openssl/ssl.h,LIBS="$LIBS -lssl -lcrypto",,)],,
X+	-lcrypto -lssl)
X 
X-PKG_CHECK_MODULES([DEPS], [ogg >= 1.3 opus >= 1.0.1 ${openssl}])
X+PKG_CHECK_MODULES([DEPS], [ogg >= 1.3 opus >= 1.0.1])
X+AC_CHECK_LIB(compat,ftime)
X 
X AC_ARG_ENABLE([fixed-point],
X   AS_HELP_STRING([--enable-fixed-point], [Enable fixed-point calculation]),,
X-- 
X1.8.1.3
X
f05de535f1a05e26f8fecc524204f524
echo x - audio/opusfile/pkg-descr
sed 's/^X//' >audio/opusfile/pkg-descr << 'f4c9bfd160261d8dbc20d912bdc5ebc3'
XLibrary for decoding .opus files, including seeking support.
X
XWWW: http://www.opus-codec.org/
f4c9bfd160261d8dbc20d912bdc5ebc3
echo x - audio/opusfile/pkg-plist
sed 's/^X//' >audio/opusfile/pkg-plist << '8237c198d64d206873c535aa067941a4'
Xinclude/opus/opusfile.h
Xlib/libopusfile.a
Xlib/libopusfile.la
Xlib/libopusfile.so
Xlib/libopusfile.so.0
Xlibdata/pkgconfig/opusfile.pc
X@comment Insert PLIST.doc here
X@dirrmtry include/opus
8237c198d64d206873c535aa067941a4
exit



>Release-Note:
>Audit-Trail:
>Unformatted:



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