pjproject: update to 2.6. (#5699)

This commit is contained in:
Chris Brannon 2017-02-13 16:13:59 -08:00 committed by Juan RP
parent f0a7099a95
commit 2168344536
2 changed files with 49 additions and 12 deletions

View file

@ -0,0 +1,38 @@
--- pjlib/src/pj/ssl_sock_ossl.c.orig 2017-02-08 18:48:12.031664919 -0800
+++ pjlib/src/pj/ssl_sock_ossl.c 2017-02-08 18:50:04.302064334 -0800
@@ -112,7 +112,7 @@
#endif
-#if OPENSSL_VERSION_NUMBER >= 0x10100000L
+#if OPENSSL_VERSION_NUMBER >= 0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
# define OPENSSL_NO_SSL2 /* seems to be removed in 1.1.0 */
# define M_ASN1_STRING_data(x) ASN1_STRING_get0_data(x)
# define M_ASN1_STRING_length(x) ASN1_STRING_length(x)
@@ -452,7 +452,7 @@
SSL_set_session(ssl, SSL_SESSION_new());
-#if !defined(OPENSSL_NO_EC) && OPENSSL_VERSION_NUMBER >= 0x1000200fL
+#if !defined(OPENSSL_NO_EC) && OPENSSL_VERSION_NUMBER >= 0x1000200fL && !defined(LIBRESSL_VERSION_NUMBER)
openssl_curves_num = SSL_get_shared_curve(ssl,-1);
if (openssl_curves_num > PJ_ARRAY_SIZE(openssl_curves))
openssl_curves_num = PJ_ARRAY_SIZE(openssl_curves);
@@ -1069,7 +1069,7 @@
static pj_status_t set_curves_list(pj_ssl_sock_t *ssock)
{
-#if !defined(OPENSSL_NO_EC) && OPENSSL_VERSION_NUMBER >= 0x1000200fL
+#if !defined(OPENSSL_NO_EC) && OPENSSL_VERSION_NUMBER >= 0x1000200fL && !defined(LIBRESSL_VERSION_NUMBER)
int ret;
int curves[PJ_SSL_SOCK_MAX_CURVES];
unsigned cnt;
@@ -1100,7 +1100,7 @@
static pj_status_t set_sigalgs(pj_ssl_sock_t *ssock)
{
-#if OPENSSL_VERSION_NUMBER >= 0x1000200fL
+#if OPENSSL_VERSION_NUMBER >= 0x1000200fL && !defined(LIBRESSL_VERSION_NUMBER)
int ret;
if (ssock->param.sigalgs.ptr && ssock->param.sigalgs.slen) {

View file

@ -2,18 +2,20 @@
# no-third-party.patch comes from Alpine,
# and this template is heavily based on Alpine's APKBUILD.
pkgname=pjproject
version=2.5.5
revision=2
version=2.6
revision=1
disable_parallel_build=yes
build_style=gnu-configure
configure_args="--enable-shared \
--enable-libsamplerate \
--with-external-speex \
--with-external-gsm \
--with-external-srtp \
--disable-libyuv"
# Disable libyuv for now. Seems to be optional.
# We don't have this packaged separately for Void, and I don't
# want pjproject including its own libyuv.so in the build.
--disable-libyuv --disable-libwebrtc"
# Disable libyuv and webrtc echo cancelation. Optional. We don't have
# libyuv packaged for Void. Thought I could be smart and use
# webrtc-audio-processing, but it doesn't have what I need. Using the
# bundled versions would also pollute build with libyuv and libwebrtc (yuck).
makedepends="libressl-devel alsa-lib-devel libgsm-devel speex-devel speexdsp-devel
libsrtp-devel libsamplerate-devel"
short_desc="Open source SIP and media stack"
@ -21,9 +23,10 @@ maintainer="Christopher Brannon <chris@the-brannons.com>"
license="GPL-2"
homepage="http://www.pjsip.org/pjsua.htm"
distfiles="http://www.pjsip.org/release/${version}/${pkgname}-${version}.tar.bz2"
checksum=ab39207b761d3485199cd881410afeb2d171dff7c2bf75e8caae91c6dca508f3
checksum=2f5a1da1c174d845871c758bd80fbb580fca7799d3cfaa0d3c4e082b5161c7b4
pre_configure() {
export LD="${CC}"
# Remove target name from lib names
sed -i -e 's/-$(TARGET_NAME)//g' \
-e 's/= $(TARGET_NAME).a/= .a/g' \
@ -42,11 +45,7 @@ pre_configure() {
# Use libsamplerate instead of bundled resample
sed -i -e "s/resample//" third_party/build/Makefile
sed -i -e "s#../../third_party/libsamplerate/src/samplerate.h#samplerate.h#" pjmedia/src/pjmedia/resample_libsamplerate.c
}
do_build() {
make dep LD=$CC
make -j1 LD=$CC
echo "#define PJ_HAS_IPV6 1" >> "pjlib/include/pj/config_site.h"
}
post_install() {