mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-22 08:58:47 +00:00
audio/sox: Update to latest commit (20210509)
Since development seems to progress very slowly just follow other distros
and update to latest commit. We're using Gentoo's distfile as source since
there's no way to download arbitrary git hashes in tar/zip format without
using a browser and there's no need for us to roll our own.
This fixes following CVEs:
CVE-2019-13590
CVE-2019-8357
CVE-2019-8356
CVE-2019-8355
CVE-2019-8354
CVE-2017-18189
CVE-2017-15642
CVE-2017-15372
CVE-2017-15371
CVE-2017-15370
CVE-2017-11359
CVE-2017-11358
CVE-2017-11332
Reference:
d05aba55a8
PR: 267128
Reviewed by: Dan Nelson <dnelson@allantgroup.com> (maintainer)
This commit is contained in:
parent
52821d5eeb
commit
0075dcd7f9
@ -1,11 +1,8 @@
|
||||
PORTNAME= sox
|
||||
PORTVERSION= 14.4.2
|
||||
PORTREVISION= 7
|
||||
DISTVERSION= 14.4.2.20210509
|
||||
CATEGORIES= audio
|
||||
MASTER_SITES= SF
|
||||
|
||||
PATCHFILES= 0001-Remove-pure-attribute-from-functions-with-side-effec.patch:-p1
|
||||
PATCH_SITES= https://sourceforge.net/p/sox/patches/104/attachment/
|
||||
MASTER_SITES= https://dev.gentoo.org/~fordfrog/distfiles/
|
||||
DISTNAME= sox-code-42b3557e13e0fe01a83465b672d89faddbe65f49
|
||||
|
||||
MAINTAINER= dnelson@allantgroup.com
|
||||
COMMENT= SOund eXchange - universal sound sample translator
|
||||
@ -14,34 +11,30 @@ WWW= http://sox.sourceforge.net/
|
||||
LICENSE= LGPL21 GPLv2
|
||||
LICENSE_COMB= dual
|
||||
|
||||
BUILD_DEPENDS= autoconf-archive>=0:devel/autoconf-archive
|
||||
LIB_DEPENDS= libltdl.so:devel/libltdl
|
||||
|
||||
CONFLICTS= play
|
||||
|
||||
USES= autoreconf cpe libtool localbase:ldflags pkgconfig zip
|
||||
GNU_CONFIGURE= yes
|
||||
USES= autoreconf cpe libtool localbase:ldflags pkgconfig
|
||||
USE_LDCONFIG= yes
|
||||
|
||||
WRKSRC= ${WRKDIR}/${DISTNAME}
|
||||
|
||||
OPTIONS_DEFINE= AMRNB AMRWB FLAC GSM ID3TAG LADSPA LAME MAD OPUS PNG \
|
||||
SNDFILE TWOLAME VORBIS WAVPACK
|
||||
OPTIONS_DEFAULT= AO FLAC GSM ID3TAG MAD OPUS OSS PNG SNDFILE VORBIS
|
||||
OPTIONS_DEFAULT= AO FLAC GSM ID3TAG LAME MAD OPUS OSS PNG SNDFILE VORBIS
|
||||
OPTIONS_GROUP= SOUND
|
||||
OPTIONS_GROUP_SOUND= ALSA AO OSS PULSEAUDIO SNDIO
|
||||
# Default LAME to off for packages so we don't end up RESTRICTED
|
||||
.if !defined(PACKAGE_BUILDING)
|
||||
OPTIONS_DEFAULT+= LAME
|
||||
.endif
|
||||
|
||||
AMRNB_DESC= AMR Speech Codec (Narrowband)
|
||||
AMRWB_DESC= AMR Speech Codec (Wideband)
|
||||
GSM_DESC= Use libgsm from ports (else use bundled lib)
|
||||
PNG_DESC= PNG spectrogram creation
|
||||
|
||||
LDFLAGS+= -lpthread
|
||||
CONFIGURE_ARGS+= --with-pkgconfigdir="${PREFIX}/libdata/pkgconfig"
|
||||
CONFIGURE_ARGS+= --with-distro="${CONFIGURE_TARGET} ${PKGNAME}"
|
||||
CONFIGURE_ARGS+= --with-gsm
|
||||
CONFIGURE_ARGS+= --disable-stack-protector
|
||||
CONFIGURE_ARGS= --with-pkgconfigdir="${PREFIX}/libdata/pkgconfig" \
|
||||
--with-distro="${CONFIGURE_TARGET} ${PKGNAME}" \
|
||||
--disable-stack-protector --disable-static
|
||||
|
||||
ALSA_CONFIGURE_WITH= alsa
|
||||
ALSA_LIB_DEPENDS= libasound.so:audio/alsa-lib
|
||||
@ -86,6 +79,7 @@ PULSEAUDIO_LIB_DEPENDS= libpulse.so:audio/pulseaudio
|
||||
SNDIO_CONFIGURE_WITH= sndio
|
||||
SNDIO_LIB_DEPENDS= libsndio.so:audio/sndio
|
||||
|
||||
GSM_CONFIGURE_WITH= gsm libgsm
|
||||
GSM_LIB_DEPENDS= libgsm.so:audio/gsm
|
||||
|
||||
ID3TAG_CONFIGURE_WITH= id3tag
|
||||
@ -100,11 +94,6 @@ TWOLAME_LIB_DEPENDS= libtwolame.so:audio/twolame
|
||||
OPUS_CONFIGURE_WITH= opus
|
||||
OPUS_LIB_DEPENDS= libopusfile.so:audio/opusfile
|
||||
|
||||
# We cannot ask for gsm to be enabled without it trying to use external gsm,
|
||||
# so force the autoconf checks to fail
|
||||
GSM_CONFIGURE_ENV_OFF= ac_cv_header_gsm_h=no ac_cv_header_gsm_gsm_h=no \
|
||||
ac_cv_lib_gsm_gsm_create=no
|
||||
|
||||
INSTALL_TARGET= install-strip
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
@ -1,4 +1,3 @@
|
||||
SHA256 (sox-14.4.2.tar.gz) = b45f598643ffbd8e363ff24d61166ccec4836fea6d3888881b8df53e3bb55f6c
|
||||
SIZE (sox-14.4.2.tar.gz) = 1134299
|
||||
SHA256 (0001-Remove-pure-attribute-from-functions-with-side-effec.patch) = c267442c506e674b8cba800c0a3425904d91b69f25c0cf5bcb8f31445361c0a0
|
||||
SIZE (0001-Remove-pure-attribute-from-functions-with-side-effec.patch) = 1273
|
||||
TIMESTAMP = 1665916081
|
||||
SHA256 (sox-code-42b3557e13e0fe01a83465b672d89faddbe65f49.zip) = bfe00d1530cd69431d16511ddc83b266889187fd2cad0cd7d2c2c140ab3c4009
|
||||
SIZE (sox-code-42b3557e13e0fe01a83465b672d89faddbe65f49.zip) = 942551
|
||||
|
@ -1,17 +0,0 @@
|
||||
$NetBSD: patch-src_oss.c,v 1.1 2015/05/25 19:06:24 bsiegert Exp $
|
||||
|
||||
Fix segfault when playing (PR pkg/49929).
|
||||
|
||||
http://gnats.netbsd.org/cgi-bin/query-pr-single.pl?number=49929
|
||||
|
||||
--- src/oss.c.orig 2014-10-06 02:02:30 UTC
|
||||
+++ src/oss.c
|
||||
@@ -369,7 +369,7 @@ static size_t osswrite(
|
||||
size_t cbStride;
|
||||
int cbWritten;
|
||||
|
||||
- cStride = cInput;
|
||||
+ cStride = cInputRemaining;
|
||||
if (cStride > pPriv->cOutput) {
|
||||
cStride = pPriv->cOutput;
|
||||
}
|
14
audio/sox/files/patch-src_output.c
Normal file
14
audio/sox/files/patch-src_output.c
Normal file
@ -0,0 +1,14 @@
|
||||
--- src/output.c.orig 2021-05-09 20:19:07 UTC
|
||||
+++ src/output.c
|
||||
@@ -31,6 +31,11 @@ static int flow(sox_effect_t *effp, sox_sample_t const
|
||||
sox_sample_t * obuf, size_t * isamp, size_t * osamp)
|
||||
{
|
||||
priv_t * p = (priv_t *)effp->priv;
|
||||
+ /* Abort if there are no samples to write */
|
||||
+ if (*isamp == 0) {
|
||||
+ *osamp = 0;
|
||||
+ return SOX_SUCCESS;
|
||||
+ }
|
||||
/* Write out *isamp samples */
|
||||
size_t len = sox_write(p->file, ibuf, *isamp);
|
||||
|
@ -3,7 +3,6 @@ bin/rec
|
||||
bin/sox
|
||||
bin/soxi
|
||||
include/sox.h
|
||||
lib/libsox.a
|
||||
lib/libsox.so
|
||||
lib/libsox.so.3
|
||||
lib/libsox.so.3.0.0
|
||||
|
Loading…
Reference in New Issue
Block a user