1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-11 02:50:24 +00:00

- Add patches to fix build with LibreSSL [1]

- Add dependencies and new SHEBANG_FILE to per stage-qa warnings
- Stop istalling python script to avoid stage-qa error about wrong
  python shabang(adding a python dependency just for a contributed
  python script seems overkill)

PR:		218599 [1]
Submitted by:	OlivierW <olivierw1+bugzilla-freebsd@hotmail.com>
Obtained from:	https://cvsweb.openbsd.org/cgi-bin/cvsweb/ports/telephony/asterisk/patches/ [1]
This commit is contained in:
Guido Falsi 2017-04-16 07:45:33 +00:00
parent 2f13f5e378
commit d8d4fb67e0
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=438620
5 changed files with 64 additions and 5 deletions

View File

@ -2,6 +2,7 @@
PORTNAME= asterisk
PORTVERSION= 13.15.0
PORTREVISION= 1
CATEGORIES= net
MASTER_SITES= http://downloads.asterisk.org/pub/telephony/%SUBDIR%/:DEFAULT,g729
MASTER_SITE_SUBDIR= asterisk/ \
@ -171,6 +172,8 @@ PGSQL_USES= pgsql
PJSIP_CONFIGURE_WITH= pjproject
PJSIP_USES= pkgconfig
PJSIP_LIB_DEPENDS= libspeex.so:audio/speex \
libspeexdsp.so:audio/speexdsp
PORTAUDIO_CONFIGURE_WITH= portaudio
PORTAUDIO_LIB_DEPENDS= libportaudio.so:audio/portaudio
@ -179,13 +182,16 @@ RADIUS_CONFIGURE_WITH= radius
RADIUS_LIB_DEPENDS= libradiusclient-ng.so:net/radiusclient
SNMP_CONFIGURE_WITH= netsnmp
SNMP_LIB_DEPENDS= libnetsnmp.so:net-mgmt/net-snmp
SNMP_LIB_DEPENDS= libnetsnmp.so:net-mgmt/net-snmp \
libpkg.so:ports-mgmt/pkg
SPANDSP_CONFIGURE_WITH= spandsp
SPANDSP_LIB_DEPENDS= libspandsp.so:comms/spandsp
SPANDSP_LIB_DEPENDS= libspandsp.so:comms/spandsp \
libtiff.so:graphics/tiff
SPEEX_CONFIGURE_WITH= speex
SPEEX_LIB_DEPENDS= libspeex.so:audio/speex
SPEEX_LIB_DEPENDS= libspeex.so:audio/speex \
libspeexdsp.so:audio/speexdsp
SQLITE2_CONFIGURE_WITH= sqlite
SQLITE2_LIB_DEPENDS= libsqlite.so:databases/sqlite2
@ -195,7 +201,8 @@ SRTP_CONFIGURE_WITH= srtp
SYSINFO_LIB_DEPENDS= libsysinfo.so:devel/libsysinfo
VORBIS_CONFIGURE_WITH= ogg
VORBIS_LIB_DEPENDS= libvorbis.so:audio/libvorbis
VORBIS_LIB_DEPENDS= libvorbis.so:audio/libvorbis \
libogg.so:audio/libogg
XMPP_CONFIGURE_WITH= iksemel
XMPP_LIB_DEPENDS= libiksemel.so:textproc/iksemel

View File

@ -0,0 +1,15 @@
--- contrib/Makefile.orig 2017-04-12 21:47:53 UTC
+++ contrib/Makefile
@@ -24,10 +24,10 @@ install:
$(INSTALL) -m 755 scripts/ast_logescalator "$(DESTDIR)$(ASTDATADIR)/scripts/ast_logescalator"
$(INSTALL) -m 755 scripts/ast_loggrabber "$(DESTDIR)$(ASTDATADIR)/scripts/ast_loggrabber"
$(INSTALL) -m 755 scripts/ast_coredumper "$(DESTDIR)$(ASTDATADIR)/scripts/ast_coredumper"
- $(INSTALL) -m 755 scripts/refcounter.py "$(DESTDIR)$(ASTDATADIR)/scripts/refcounter.py"
+# $(INSTALL) -m 755 scripts/refcounter.py "$(DESTDIR)$(ASTDATADIR)/scripts/refcounter.py"
uninstall:
-rm -f "$(DESTDIR)$(ASTDATADIR)/scripts/ast_logescalator"
-rm -f "$(DESTDIR)$(ASTDATADIR)/scripts/ast_loggrabber"
-rm -f "$(DESTDIR)$(ASTDATADIR)/scripts/ast_coredumper"
- -rm -f "$(DESTDIR)$(ASTDATADIR)/scripts/refcounter.py"
+# -rm -f "$(DESTDIR)$(ASTDATADIR)/scripts/refcounter.py"

View File

@ -0,0 +1,20 @@
--- main/libasteriskssl.c.orig 2017-04-12 21:07:31 UTC
+++ main/libasteriskssl.c
@@ -74,7 +74,7 @@ static void ssl_lock(int mode, int n, const char *file
}
}
-#if !defined(OPENSSL_VERSION_NUMBER) || OPENSSL_VERSION_NUMBER < 0x10100000L
+#if !defined(OPENSSL_VERSION_NUMBER) || OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
int SSL_library_init(void)
{
#if defined(AST_DEVMODE)
@@ -129,7 +129,7 @@ void ERR_free_strings(void)
int ast_ssl_init(void)
{
#if defined(HAVE_OPENSSL) && defined(OPENSSL_VERSION_NUMBER) && \
- OPENSSL_VERSION_NUMBER < 0x10100000L
+ (OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER))
unsigned int i;
int (*real_SSL_library_init)(void);
void (*real_CRYPTO_set_id_callback)(unsigned long (*)(void));

View File

@ -0,0 +1,18 @@
--- main/tcptls.c.orig 2017-04-12 21:06:16 UTC
+++ main/tcptls.c
@@ -400,13 +400,13 @@ static int tcptls_stream_close(void *cookie)
SSL_get_error(stream->ssl, res));
}
-#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER >= 0x10100000L
+#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
if (!SSL_is_server(stream->ssl)) {
#else
if (!stream->ssl->server) {
#endif
/* For client threads, ensure that the error stack is cleared */
-#if !defined(OPENSSL_VERSION_NUMBER) || OPENSSL_VERSION_NUMBER < 0x10100000L
+#if !defined(OPENSSL_VERSION_NUMBER) || OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
#if defined(OPENSSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER >= 0x10000000L
ERR_remove_thread_state(NULL);
#else

View File

@ -364,7 +364,6 @@ sbin/safe_asterisk
%%DATADIR%%/scripts/ast_coredumper
%%DATADIR%%/scripts/ast_logescalator
%%DATADIR%%/scripts/ast_loggrabber
%%DATADIR%%/scripts/refcounter.py
%%DATADIR%%/static-http/appdocsxml.xslt
%%DATADIR%%/static-http/ajamdemo.html
%%DATADIR%%/static-http/astman.css