Skip to content

Commit

Permalink
comms/spandsp: Update to 3.0.0
Browse files Browse the repository at this point in the history
Patch consumers and bump PORTREVISION where appropriate.

PR:	258999
Reported by:	jailbird@fdf.net (maintainer)
Reviewed by:	madpilot@
  • Loading branch information
fernape committed Nov 10, 2021
1 parent 4027ae5 commit a55c182
Show file tree
Hide file tree
Showing 17 changed files with 321 additions and 53 deletions.
2 changes: 1 addition & 1 deletion audio/baresip/Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PORTNAME= baresip
PORTVERSION= 0.5.8
PORTREVISION= 8
PORTREVISION= 9
CATEGORIES= audio
MASTER_SITES= http://www.creytiv.com/pub/

Expand Down
18 changes: 13 additions & 5 deletions comms/spandsp/Makefile
Original file line number Diff line number Diff line change
@@ -1,20 +1,28 @@
# Created by: wlloyd@slap.net

PORTNAME= spandsp
PORTVERSION= 0.0.6
DISTVERSION= ${SPANDSP_VERSION}.g20211014
CATEGORIES= comms
MASTER_SITES= http://www.soft-switch.org/downloads/spandsp/

MAINTAINER= ports@FreeBSD.org
MAINTAINER= jailbird@fdf.net
COMMENT= DSP library and software FAX machine

LICENSE= LGPL21

LIB_DEPENDS= libtiff.so:graphics/tiff

USES= autoreconf gmake jpeg libtool localbase

USE_GITHUB= yes
GH_ACCOUNT= freeswitch
GH_TAGNAME= ${GITHUB_COMMIT}
GITHUB_COMMIT= 284fe91

USE_LDCONFIG= yes

GNU_CONFIGURE= yes
INSTALL_TARGET= install-strip
USES= autoreconf gmake libtool localbase
USE_LDCONFIG= yes

SPANDSP_VERSION= 3.0.0

.include <bsd.port.mk>
5 changes: 3 additions & 2 deletions comms/spandsp/distinfo
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
SHA256 (spandsp-0.0.6.tar.gz) = cc053ac67e8ac4bb992f258fd94f275a7872df959f6a87763965feabfdcc9465
SIZE (spandsp-0.0.6.tar.gz) = 3309837
TIMESTAMP = 1634216290
SHA256 (freeswitch-spandsp-3.0.0.g20211014-284fe91_GH0.tar.gz) = 288b12eb058d615c526e85fe0fe339293e5713b3513e7918043e93e52e4efd49
SIZE (freeswitch-spandsp-3.0.0.g20211014-284fe91_GH0.tar.gz) = 3584374
6 changes: 3 additions & 3 deletions comms/spandsp/files/patch-Makefile.am
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- Makefile.am.orig 2014-09-03 14:15:04.000000000 +0300
+++ Makefile.am 2014-09-03 14:15:16.000000000 +0300
@@ -61,7 +61,7 @@ SUBDIRS = src $(MAYBE_DOC) $(MAYBE_TESTD
--- Makefile.am.orig 2021-08-14 20:26:24 UTC
+++ Makefile.am
@@ -60,7 +60,7 @@ SUBDIRS = src $(MAYBE_DOC) $(MAYBE_TESTS)

DIST_SUBDIRS = src doc test-data spandsp-sim tests

Expand Down
37 changes: 0 additions & 37 deletions comms/spandsp/files/patch-configure.ac

This file was deleted.

18 changes: 16 additions & 2 deletions comms/spandsp/pkg-plist
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
include/spandsp.h
include/spandsp/adsi.h
include/spandsp/alloc.h
include/spandsp/arctan2.h
include/spandsp/async.h
include/spandsp/at_interpreter.h
Expand All @@ -14,6 +15,7 @@ include/spandsp/complex_filters.h
include/spandsp/complex_vector_float.h
include/spandsp/crc.h
include/spandsp/dc_restore.h
include/spandsp/data_modems.h
include/spandsp/dds.h
include/spandsp/dtmf.h
include/spandsp/echo.h
Expand Down Expand Up @@ -84,6 +86,7 @@ include/spandsp/private/awgn.h
include/spandsp/private/bell_r2_mf.h
include/spandsp/private/bert.h
include/spandsp/private/bitstream.h
include/spandsp/private/data_modems.h
include/spandsp/private/dtmf.h
include/spandsp/private/echo.h
include/spandsp/private/fax.h
Expand All @@ -102,6 +105,9 @@ include/spandsp/private/modem_connect_tones.h
include/spandsp/private/modem_echo.h
include/spandsp/private/noise.h
include/spandsp/private/oki_adpcm.h
include/spandsp/private/playout.h
include/spandsp/private/plc.h
include/spandsp/private/power_meter.h
include/spandsp/private/queue.h
include/spandsp/private/schedule.h
include/spandsp/private/sig_tone.h
Expand All @@ -120,6 +126,10 @@ include/spandsp/private/t4_rx.h
include/spandsp/private/t4_t6_decode.h
include/spandsp/private/t4_t6_encode.h
include/spandsp/private/t4_tx.h
include/spandsp/private/t42.h
include/spandsp/private/t43.h
include/spandsp/private/t81_t82_arith_coding.h
include/spandsp/private/t85.h
include/spandsp/private/time_scale.h
include/spandsp/private/timezone.h
include/spandsp/private/tone_detect.h
Expand All @@ -143,10 +153,14 @@ include/spandsp/t4_rx.h
include/spandsp/t4_t6_decode.h
include/spandsp/t4_t6_encode.h
include/spandsp/t4_tx.h
include/spandsp/t42.h
include/spandsp/t43.h
include/spandsp/t81_t82_arith_coding.h
include/spandsp/t85.h
include/spandsp/timezone.h
include/spandsp/v18.h
lib/libspandsp.a
lib/libspandsp.so
lib/libspandsp.so.2
lib/libspandsp.so.2.0.0
lib/libspandsp.so.3
lib/libspandsp.so.3.0.0
libdata/pkgconfig/spandsp.pc
2 changes: 1 addition & 1 deletion misc/libsupertone/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

PORTNAME= libsupertone
PORTVERSION= 0.0.2
PORTREVISION= 6
PORTREVISION= 7
CATEGORIES= misc
MASTER_SITES= http://www.soft-switch.org/downloads/unicall/

Expand Down
1 change: 1 addition & 0 deletions net/asterisk16/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
PORTNAME= asterisk
PORTVERSION= 16.22.0
PORTREVISION= 1
CATEGORIES= net
MASTER_SITES= https://downloads.asterisk.org/pub/telephony/%SUBDIR%/:DEFAULT,g729
MASTER_SITE_SUBDIR= asterisk/ \
Expand Down
62 changes: 62 additions & 0 deletions net/asterisk16/files/patch-res_res__fax__spandsp.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
--- res/res_fax_spandsp.c.orig 2021-11-02 08:40:01 UTC
+++ res/res_fax_spandsp.c
@@ -167,8 +167,8 @@ struct spandsp_pvt {
static int spandsp_v21_new(struct spandsp_pvt *p);
static void session_destroy(struct spandsp_pvt *p);
static int t38_tx_packet_handler(t38_core_state_t *t38_core_state, void *data, const uint8_t *buf, int len, int count);
-static void t30_phase_e_handler(t30_state_t *t30_state, void *data, int completion_code);
-static void spandsp_log(int level, const char *msg);
+static void t30_phase_e_handler(void *data, int completion_code);
+static void spandsp_log(void *user_data, int level, const char *msg);
static int update_stats(struct spandsp_pvt *p, int completion_code);
static int spandsp_modems(struct ast_fax_session_details *details);

@@ -375,10 +375,11 @@ static int update_stats(struct spandsp_pvt *p, int com
* This function pulls stats from the spandsp stack and stores them for res_fax
* to use later.
*/
-static void t30_phase_e_handler(t30_state_t *t30_state, void *data, int completion_code)
+static void t30_phase_e_handler(void *data, int completion_code)
{
struct ast_fax_session *s = data;
struct spandsp_pvt *p = s->tech_pvt;
+ t30_state_t *t30_state = p->t30_state;
char headerinfo[T30_MAX_PAGE_HEADER_INFO + 1];
const char *c;
t30_stats_t stats;
@@ -430,7 +431,7 @@ static void t30_phase_e_handler(t30_state_t *t30_state
*
* \note This function is a callback function called by spandsp.
*/
-static void spandsp_log(int level, const char *msg)
+static void spandsp_log(void *user_data, int level, const char *msg)
{
if (level == SPAN_LOG_ERROR) {
ast_log(LOG_ERROR, "%s", msg);
@@ -449,7 +450,7 @@ static void set_logging(logging_state_t *state, struct
level = SPAN_LOG_DEBUG_3;
}

- span_log_set_message_handler(state, spandsp_log);
+ span_log_set_message_handler(state, spandsp_log, NULL);
span_log_set_level(state, SPAN_LOG_SHOW_SEVERITY | SPAN_LOG_SHOW_PROTOCOL | level);
}

@@ -479,7 +480,7 @@ static void set_file(t30_state_t *t30_state, struct as
static void set_ecm(t30_state_t *t30_state, struct ast_fax_session_details *details)
{
t30_set_ecm_capability(t30_state, details->option.ecm);
- t30_set_supported_compressions(t30_state, T30_SUPPORT_T4_1D_COMPRESSION | T30_SUPPORT_T4_2D_COMPRESSION | T30_SUPPORT_T6_COMPRESSION);
+ t30_set_supported_compressions(t30_state, T4_COMPRESSION_T4_1D | T4_COMPRESSION_T4_2D | T4_COMPRESSION_T6);
}

static int spandsp_v21_new(struct spandsp_pvt *p)
@@ -1256,7 +1257,7 @@ static int load_module(void)
}

/* prevent logging to stderr */
- span_set_message_handler(NULL);
+ span_set_message_handler(NULL, NULL);

return AST_MODULE_LOAD_SUCCESS;
}
1 change: 1 addition & 0 deletions net/asterisk18/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
PORTNAME= asterisk
PORTVERSION= 18.8.0
PORTREVISION= 1
CATEGORIES= net
MASTER_SITES= https://downloads.asterisk.org/pub/telephony/%SUBDIR%/:DEFAULT,g729
MASTER_SITE_SUBDIR= asterisk/ \
Expand Down
62 changes: 62 additions & 0 deletions net/asterisk18/files/patch-res_res__fax__spandsp.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
--- res/res_fax_spandsp.c.orig 2021-11-02 08:42:19 UTC
+++ res/res_fax_spandsp.c
@@ -167,8 +167,8 @@ struct spandsp_pvt {
static int spandsp_v21_new(struct spandsp_pvt *p);
static void session_destroy(struct spandsp_pvt *p);
static int t38_tx_packet_handler(t38_core_state_t *t38_core_state, void *data, const uint8_t *buf, int len, int count);
-static void t30_phase_e_handler(t30_state_t *t30_state, void *data, int completion_code);
-static void spandsp_log(int level, const char *msg);
+static void t30_phase_e_handler(void *data, int completion_code);
+static void spandsp_log(void *user_data, int level, const char *msg);
static int update_stats(struct spandsp_pvt *p, int completion_code);
static int spandsp_modems(struct ast_fax_session_details *details);

@@ -375,10 +375,11 @@ static int update_stats(struct spandsp_pvt *p, int com
* This function pulls stats from the spandsp stack and stores them for res_fax
* to use later.
*/
-static void t30_phase_e_handler(t30_state_t *t30_state, void *data, int completion_code)
+static void t30_phase_e_handler(void *data, int completion_code)
{
struct ast_fax_session *s = data;
struct spandsp_pvt *p = s->tech_pvt;
+ t30_state_t *t30_state = p->t30_state;
char headerinfo[T30_MAX_PAGE_HEADER_INFO + 1];
const char *c;
t30_stats_t stats;
@@ -430,7 +431,7 @@ static void t30_phase_e_handler(t30_state_t *t30_state
*
* \note This function is a callback function called by spandsp.
*/
-static void spandsp_log(int level, const char *msg)
+static void spandsp_log(void *user_data, int level, const char *msg)
{
if (level == SPAN_LOG_ERROR) {
ast_log(LOG_ERROR, "%s", msg);
@@ -449,7 +450,7 @@ static void set_logging(logging_state_t *state, struct
level = SPAN_LOG_DEBUG_3;
}

- span_log_set_message_handler(state, spandsp_log);
+ span_log_set_message_handler(state, spandsp_log, NULL);
span_log_set_level(state, SPAN_LOG_SHOW_SEVERITY | SPAN_LOG_SHOW_PROTOCOL | level);
}

@@ -479,7 +480,7 @@ static void set_file(t30_state_t *t30_state, struct as
static void set_ecm(t30_state_t *t30_state, struct ast_fax_session_details *details)
{
t30_set_ecm_capability(t30_state, details->option.ecm);
- t30_set_supported_compressions(t30_state, T30_SUPPORT_T4_1D_COMPRESSION | T30_SUPPORT_T4_2D_COMPRESSION | T30_SUPPORT_T6_COMPRESSION);
+ t30_set_supported_compressions(t30_state, T4_COMPRESSION_T4_1D | T4_COMPRESSION_T4_2D | T4_COMPRESSION_T6);
}

static int spandsp_v21_new(struct spandsp_pvt *p)
@@ -1256,7 +1257,7 @@ static int load_module(void)
}

/* prevent logging to stderr */
- span_set_message_handler(NULL);
+ span_set_message_handler(NULL, NULL);

return AST_MODULE_LOAD_SUCCESS;
}
2 changes: 1 addition & 1 deletion net/mediastreamer/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

PORTNAME= mediastreamer
PORTVERSION= 2.16.1
PORTREVISION= 5
PORTREVISION= 6
CATEGORIES= net
MASTER_SITES= https://www.linphone.org/releases/sources/mediastreamer/

Expand Down
2 changes: 1 addition & 1 deletion net/opal/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

PORTNAME= opal
PORTVERSION= 3.10.10
PORTREVISION= 28
PORTREVISION= 29
CATEGORIES= net
MASTER_SITES= GNOME

Expand Down
Loading

0 comments on commit a55c182

Please sign in to comment.