libraries/gwenhywfar: Fix build

Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
This commit is contained in:
Larry Hajali 2016-02-07 13:25:49 -08:00 committed by Willy Sudiarto Raharjo
parent 2355494a80
commit c1fa7ec228
2 changed files with 25 additions and 1 deletions

View File

@ -0,0 +1,19 @@
diff -up gwenhywfar-4.13.1/src/sio/syncio_tls.c.foo gwenhywfar-4.13.1/src/sio/syncio_tls.c
--- gwenhywfar-4.13.1/src/sio/syncio_tls.c.foo 2015-12-11 22:35:48.474181431 -0500
+++ gwenhywfar-4.13.1/src/sio/syncio_tls.c 2015-12-11 22:41:27.414733356 -0500
@@ -361,12 +361,12 @@ int GWEN_SyncIo_Tls_Prepare(GWEN_SYNCIO
/* possibly force protocol priority */
if (lflags & GWEN_SYNCIO_TLS_FLAGS_FORCE_SSL_V3) {
- const int proto_prio[2] = { GNUTLS_SSL3, 0 };
+ char *force_sslv3_str = "NORMAL:-VERS-TLS-ALL:+VERS-SSL3.0";
DBG_INFO(GWEN_LOGDOMAIN, "Forcing SSL v3");
- rv=gnutls_protocol_set_priority(xio->session, proto_prio);
+ rv=gnutls_priority_set_direct(xio->session, force_sslv3_str, NULL);
if (rv) {
- DBG_ERROR(GWEN_LOGDOMAIN, "gnutls_protocol_set_priority: %d (%s)", rv, gnutls_strerror(rv));
+ DBG_ERROR(GWEN_LOGDOMAIN, "gnutls_priority_set_direct: %d (%s)", rv, gnutls_strerror(rv));
gnutls_deinit(xio->session);
return GWEN_ERROR_GENERIC;
}

View File

@ -48,7 +48,7 @@ elif [ "$ARCH" = "i686" ]; then
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
@ -69,6 +69,11 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
# Don't use deprecated/removed gnutls functions
# Patch from Fedora:
# http://pkgs.fedoraproject.org/cgit/rpms/gwenhywfar.git/tree/gwen-gnutls.patch
patch -p1 < $CWD/gwen-gnutls.patch
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \