update to lksctp-tools-1.0.18
This commit is contained in:
parent
a5cc7a695c
commit
30c951390f
117
bugfix-automake-errno-tests.patch
Normal file
117
bugfix-automake-errno-tests.patch
Normal file
@ -0,0 +1,117 @@
|
||||
From 356de6906c5b6d563f2d0568e86e3875ad482c66 Mon Sep 17 00:00:00 2001
|
||||
From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
|
||||
Date: Wed, 26 Sep 2018 13:46:58 -0300
|
||||
Subject: [PATCH] func_tests: fix use of unitialized var
|
||||
|
||||
From f0183c87b15a9b1ad06db88325d7e5eeddb89c7f Mon Sep 17 00:00:00 2001
|
||||
From: Jianwen Ji <jijianwen@gmail.com>
|
||||
Date: Tue, 18 Dec 2018 14:40:37 +0800
|
||||
Subject: [PATCH] Fix error->errno typos
|
||||
|
||||
From 200eca7f1419b1ae53958b51e8551f7e7f6cd467 Mon Sep 17 00:00:00 2001
|
||||
From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
|
||||
Date: Tue, 30 Apr 2019 11:31:59 -0300
|
||||
Subject: [PATCH] automake: fix include dir for the now autogenerated header
|
||||
|
||||
diff -Naur a/src/apps/Makefile.am b/src/apps/Makefile.am
|
||||
--- a/src/apps/Makefile.am 2020-07-01 17:01:04.452069819 +0800
|
||||
+++ b/src/apps/Makefile.am 2020-07-01 17:16:30.203758750 +0800
|
||||
@@ -4,7 +4,7 @@
|
||||
include $(top_srcdir)/Makefile.dirs
|
||||
|
||||
# General compilation flags
|
||||
-AM_CPPFLAGS = -I. -I$(top_srcdir)/src/include -I$(top_srcdir)/src/testlib \
|
||||
+AM_CPPFLAGS = -I. -I$(top_builddir)/src/include -I$(top_srcdir)/src/testlib \
|
||||
-g -O2 -fno-strict-aliasing -Wall -Wstrict-prototypes \
|
||||
-Wimplicit-function-declaration
|
||||
|
||||
diff -Naur a/src/apps/sctp_status.c b/src/apps/sctp_status.c
|
||||
--- a/src/apps/sctp_status.c 2020-07-01 17:01:04.442069801 +0800
|
||||
+++ b/src/apps/sctp_status.c 2020-07-01 17:14:37.943559239 +0800
|
||||
@@ -529,7 +529,7 @@
|
||||
DEBUG_PRINT(DEBUG_MIN, "\trecvmsg(sk=%d) ", sk);
|
||||
|
||||
error = recvmsg(sk, &inmessage, MSG_WAITALL);
|
||||
- if (error < 0 && error != EAGAIN) {
|
||||
+ if (error < 0 && errno != EAGAIN) {
|
||||
fprintf(stderr, "\n\t\t*** recvmsg: %s ***\n\n",
|
||||
strerror(errno));
|
||||
fflush(stdout);
|
||||
diff -Naur a/src/apps/sctp_test.c b/src/apps/sctp_test.c
|
||||
--- a/src/apps/sctp_test.c 2020-07-01 17:01:04.442069801 +0800
|
||||
+++ b/src/apps/sctp_test.c 2020-07-01 17:15:35.263661098 +0800
|
||||
@@ -870,7 +870,7 @@
|
||||
DEBUG_PRINT(DEBUG_MIN, "\trecvmsg(sk=%d) ", sk);
|
||||
|
||||
error = recvmsg(recvsk, &inmessage, MSG_WAITALL);
|
||||
- if (error < 0 && error != EAGAIN) {
|
||||
+ if (error < 0 && errno != EAGAIN) {
|
||||
if (errno == ENOTCONN && socket_type == SOCK_STREAM &&
|
||||
role == SERVER) {
|
||||
printf("No association is present now!!\n");
|
||||
diff -Naur a/src/func_tests/Makefile.am b/src/func_tests/Makefile.am
|
||||
--- a/src/func_tests/Makefile.am 2020-07-01 17:01:04.442069801 +0800
|
||||
+++ b/src/func_tests/Makefile.am 2020-07-01 17:17:00.143811975 +0800
|
||||
@@ -4,7 +4,7 @@
|
||||
include $(top_srcdir)/Makefile.dirs
|
||||
|
||||
# General compilation flags
|
||||
-AM_CPPFLAGS = -I. -I$(top_srcdir)/src/include -I$(top_srcdir)/src/testlib \
|
||||
+AM_CPPFLAGS = -I. -I$(top_builddir)/src/include -I$(top_srcdir)/src/testlib \
|
||||
-g -O2 -fno-strict-aliasing -Wall -Wstrict-prototypes \
|
||||
-Wimplicit-function-declaration
|
||||
|
||||
diff -Naur a/src/func_tests/test_1_to_1_events.c b/src/func_tests/test_1_to_1_events.c
|
||||
--- a/src/func_tests/test_1_to_1_events.c 2020-07-01 17:01:04.442069801 +0800
|
||||
+++ b/src/func_tests/test_1_to_1_events.c 2020-07-01 17:13:38.323453320 +0800
|
||||
@@ -92,9 +92,13 @@
|
||||
/* Create the client socket. */
|
||||
clt_sk = test_socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP);
|
||||
|
||||
- event.sctp_data_io_event = 1;
|
||||
+ memset(&event, 0, sizeof(event));
|
||||
+ event.sctp_data_io_event = 1;
|
||||
event.sctp_association_event = 1;
|
||||
event.sctp_shutdown_event = 1;
|
||||
+#ifdef HAVE_SCTP_AUTH_NO_AUTH
|
||||
+ event.sctp_authentication_event = 1;
|
||||
+#endif
|
||||
len = sizeof(struct sctp_event_subscribe);
|
||||
test_setsockopt(svr_sk, SCTP_EVENTS, &event, len);
|
||||
test_setsockopt(clt_sk, SCTP_EVENTS, &event, len);
|
||||
diff -Naur a/src/lib/Makefile.am b/src/lib/Makefile.am
|
||||
--- a/src/lib/Makefile.am 2020-07-01 17:01:04.442069801 +0800
|
||||
+++ b/src/lib/Makefile.am 2020-07-01 17:17:39.323881637 +0800
|
||||
@@ -4,7 +4,7 @@
|
||||
include $(top_srcdir)/Makefile.dirs
|
||||
|
||||
# General compilation flags
|
||||
-AM_CPPFLAGS = -I$(top_srcdir)/src/include
|
||||
+AM_CPPFLAGS = -I$(top_builddir)/src/include
|
||||
|
||||
lib_LTLIBRARIES = libsctp.la
|
||||
|
||||
diff -Naur a/src/testlib/Makefile.am b/src/testlib/Makefile.am
|
||||
--- a/src/testlib/Makefile.am 2020-07-01 17:01:04.442069801 +0800
|
||||
+++ b/src/testlib/Makefile.am 2020-07-01 17:18:13.873943075 +0800
|
||||
@@ -5,7 +5,7 @@
|
||||
include $(top_srcdir)/Makefile.dirs
|
||||
|
||||
# General compilation flags
|
||||
-AM_CPPFLAGS = -I$(top_srcdir)/src/include
|
||||
+AM_CPPFLAGS = -I$(top_builddir)/src/include
|
||||
|
||||
noinst_LTLIBRARIES = libsctputil.la
|
||||
libsctputil_la_SOURCES = sctputil.c sctputil.h
|
||||
diff -Naur a/src/withsctp/Makefile.am b/src/withsctp/Makefile.am
|
||||
--- a/src/withsctp/Makefile.am 2020-07-01 17:01:04.452069819 +0800
|
||||
+++ b/src/withsctp/Makefile.am 2020-07-01 17:18:39.673988960 +0800
|
||||
@@ -10,7 +10,7 @@
|
||||
bin_PROGRAMS = checksctp
|
||||
bin_SCRIPTS = withsctp
|
||||
|
||||
-AM_CPPFLAGS=-I$(top_srcdir)/src/include
|
||||
+AM_CPPFLAGS=-I$(top_builddir)/src/include
|
||||
pkglib_LTLIBRARIES = libwithsctp.la
|
||||
libwithsctp_la_SOURCES = sctp_load_libs.c sctp_socket.c sctp_bind.c \
|
||||
sctp_sockopt.c sctp_socket.h
|
||||
80
bugfix-build-issue.patch
Normal file
80
bugfix-build-issue.patch
Normal file
@ -0,0 +1,80 @@
|
||||
From 378560050a8f93786c590cc99a55461666205b61 Mon Sep 17 00:00:00 2001
|
||||
From: Xin Long <lucien.xin@gmail.com>
|
||||
Date: Fri, 24 Aug 2018 01:13:32 +0800
|
||||
Subject: [PATCH] build: fix netinet/sctp.h not to be installed
|
||||
|
||||
From db6d15bf12a0123e4320e5fd7cb688331dea1bdc Mon Sep 17 00:00:00 2001
|
||||
From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
|
||||
Date: Fri, 24 Aug 2018 09:52:58 -0300
|
||||
Subject: [PATCH] build: remove v4.12 secondary defines in favor of
|
||||
HAVE_SCTP_STREAM_RECONFIG
|
||||
|
||||
From 596efd6631b83069d41782fb0ee2d6cf76a50dfa Mon Sep 17 00:00:00 2001
|
||||
From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
|
||||
Date: Fri, 24 Aug 2018 09:52:59 -0300
|
||||
Subject: [PATCH] build: fix probing for HAVE_SCTP_SENDV
|
||||
|
||||
From e5952a0cdfa8b1b56a5823574835f1f771f14ae0 Mon Sep 17 00:00:00 2001
|
||||
From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
|
||||
Date: Fri, 24 Aug 2018 09:53:00 -0300
|
||||
Subject: [PATCH] build: 0b0dce7a36fb actually belongs to v4.19
|
||||
|
||||
diff -Naur a/configure.ac b/configure.ac
|
||||
--- a/configure.ac 2020-07-01 10:56:38.411772329 +0800
|
||||
+++ b/configure.ac 2020-07-01 14:28:33.355511122 +0800
|
||||
@@ -75,14 +75,6 @@
|
||||
LKSCTP_CHECK_MEMBER([struct sctp_event_subscribe.sctp_stream_reset_event],
|
||||
[HAVE_SCTP_STREAM_RESET_EVENT])
|
||||
|
||||
-# Support for assoc reset event, added on v4.12, c95129d127c6
|
||||
-#LKSCTP_CHECK_MEMBER([struct sctp_event_subscribe.sctp_assoc_reset_event], \
|
||||
-# [HAVE_SCTP_ASSOC_RESET_EVENT])
|
||||
-
|
||||
-# Support for stream change event, added on v4.12, b444153fb5a6
|
||||
-#LKSCTP_CHECK_MEMBER([struct sctp_event_subscribe.sctp_stream_change_event], \
|
||||
-# [HAVE_SCTP_STREAM_CHANGE_EVENT])
|
||||
-
|
||||
# RFC 6525 (Stream Reconf), finished on v4.12, c0d8bab6ae51
|
||||
LKSCTP_CHECK_DECL([SCTP_RECONFIG_SUPPORTED], [HAVE_SCTP_STREAM_RECONFIG])
|
||||
|
||||
@@ -95,15 +87,14 @@
|
||||
LKSCTP_CHECK_MEMBER([struct sctp_pdapi_event.pdapi_seq],
|
||||
[HAVE_SCTP_PDAPI_EVENT_PDAPI_SEQ])
|
||||
|
||||
-# PR-SCTP field used to probe for sendv/recvv support, added on v4.17
|
||||
-LKSCTP_CHECK_MEMBER([struct sendv_prinfo.sctp_prinfo],
|
||||
- [HAVE_SCTP_SENDV])
|
||||
+# PR-SCTP struct used to probe for sendv/recvv support, added on v4.17
|
||||
+LKSCTP_CHECK_TYPE([struct sctp_prinfo], [HAVE_SCTP_SENDV])
|
||||
|
||||
# This event indicates that the peer does not support SCTP authentication,
|
||||
# added on v4.16, 30f6ebf65bc4
|
||||
LKSCTP_CHECK_DECL([SCTP_AUTH_NO_AUTH], [HAVE_SCTP_AUTH_NO_AUTH])
|
||||
|
||||
-# New members to sctp_paddrparams, added on v4.18, 0b0dce7a36fb
|
||||
+# New members to sctp_paddrparams, added on v4.19, 0b0dce7a36fb
|
||||
LKSCTP_CHECK_MEMBER([struct sctp_paddrparams.spp_ipv6_flowlabel],
|
||||
[HAVE_SCTP_SPP_IPV6_FLOWLABEL])
|
||||
LKSCTP_CHECK_MEMBER([struct sctp_paddrparams.spp_dscp],
|
||||
diff -Naur a/src/include/netinet/Makefile.am b/src/include/netinet/Makefile.am
|
||||
--- a/src/include/netinet/Makefile.am 2020-07-01 10:56:38.421772349 +0800
|
||||
+++ b/src/include/netinet/Makefile.am 2020-07-01 14:20:14.894642374 +0800
|
||||
@@ -11,5 +11,4 @@
|
||||
# API.
|
||||
include_HEADERS =
|
||||
|
||||
-libcnetinet_HEADERS = sctp.h.in
|
||||
-BUILT_SOURCES = sctp.h
|
||||
+libcnetinet_HEADERS = sctp.h
|
||||
diff -Naur a/src/include/netinet/sctp.h.in b/src/include/netinet/sctp.h.in
|
||||
--- a/src/include/netinet/sctp.h.in 2020-07-01 10:56:38.421772349 +0800
|
||||
+++ b/src/include/netinet/sctp.h.in 2020-07-01 14:25:06.035149487 +0800
|
||||
@@ -61,8 +61,6 @@
|
||||
#define HAVE_SCTP_CANSET_PRIMARY
|
||||
|
||||
#undef HAVE_SCTP_STREAM_RESET_EVENT
|
||||
-#undef HAVE_SCTP_ASSOC_RESET_EVENT
|
||||
-#undef HAVE_SCTP_STREAM_CHANGE_EVENT
|
||||
#undef HAVE_SCTP_STREAM_RECONFIG
|
||||
#undef HAVE_SCTP_PEELOFF_FLAGS
|
||||
#undef HAVE_SCTP_PDAPI_EVENT_PDAPI_STREAM
|
||||
72
bugfix-withsctp-and-configure.patch
Normal file
72
bugfix-withsctp-and-configure.patch
Normal file
@ -0,0 +1,72 @@
|
||||
From 7c0ef4d441b3833e721df58f56e2cb8c81b34df4 Mon Sep 17 00:00:00 2001
|
||||
From: Xin Long <lucien.xin@gmail.com>
|
||||
Date: Thu, 16 Aug 2018 14:12:01 +0800
|
||||
Subject: [PATCH] withsctp: use @PACKAGE_VERSION@ in withsctp.h
|
||||
|
||||
From 79e7e6e4304bdde2922fab4a446b7384e204440e Mon Sep 17 00:00:00 2001
|
||||
From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
|
||||
Date: Fri, 21 Dec 2018 10:25:19 -0200
|
||||
Subject: [PATCH] withsctp: to not reuse PACKAGE_VERSION as lib version
|
||||
|
||||
From 7de2bd7e769f10521e3d0c2cb42c6f6b9b505dd0 Mon Sep 17 00:00:00 2001
|
||||
From: Xin Long <lucien.xin@gmail.com>
|
||||
Date: Thu, 16 Aug 2018 14:12:30 +0800
|
||||
Subject: [PATCH] configure.ac: add CURRENT REVISION and AGE for libsctp and
|
||||
libwithsctp
|
||||
|
||||
diff -Naur a/configure.ac b/configure.ac
|
||||
--- a/configure.ac 2020-07-01 17:01:04.432069782 +0800
|
||||
+++ b/configure.ac 2020-07-01 17:05:52.942602240 +0800
|
||||
@@ -14,6 +14,13 @@
|
||||
dnl configure will fail ...)
|
||||
|
||||
AC_INIT([lksctp-tools], [1.0.18], [], [], [http://www.lksctp.org/])
|
||||
+AC_SUBST(LIBSCTP_CURRENT, 1)
|
||||
+AC_SUBST(LIBSCTP_REVISION, 18)
|
||||
+AC_SUBST(LIBSCTP_AGE, 0)
|
||||
+AC_SUBST(LIBWITHSCTP_CURRENT, 1)
|
||||
+AC_SUBST(LIBWITHSCTP_REVISION, 18)
|
||||
+AC_SUBST(LIBWITHSCTP_AGE, 0)
|
||||
+
|
||||
AC_CONFIG_AUX_DIR(bin)
|
||||
AC_CONFIG_SRCDIR([src/apps/sctp_darn.c])
|
||||
AC_CONFIG_HEADERS([config.h])
|
||||
diff -Naur a/Makefile.rules b/Makefile.rules
|
||||
--- a/Makefile.rules 2020-07-01 17:01:04.432069782 +0800
|
||||
+++ b/Makefile.rules 2020-07-01 17:03:13.642308299 +0800
|
||||
@@ -15,4 +15,7 @@
|
||||
edit = @sed \
|
||||
-e "s|\@bindir\@|$(bindir)|" \
|
||||
-e "s|\@libdir\@|$(libdir)|" \
|
||||
- -e "s|\@PACKAGE\@|$(PACKAGE)|"
|
||||
+ -e "s|\@PACKAGE\@|$(PACKAGE)|" \
|
||||
+ -e "s|\@LIBWITHSCTP_CURRENT\@|$(LIBWITHSCTP_CURRENT)|" \
|
||||
+ -e "s|\@LIBWITHSCTP_REVISION\@|$(LIBWITHSCTP_REVISION)|" \
|
||||
+ -e "s|\@LIBWITHSCTP_AGE\@|$(LIBWITHSCTP_AGE)|"
|
||||
diff -Naur a/src/withsctp/Makefile.am b/src/withsctp/Makefile.am
|
||||
--- a/src/withsctp/Makefile.am 2020-07-01 17:01:04.452069819 +0800
|
||||
+++ b/src/withsctp/Makefile.am 2020-07-01 17:07:39.482798756 +0800
|
||||
@@ -14,8 +14,8 @@
|
||||
pkglib_LTLIBRARIES = libwithsctp.la
|
||||
libwithsctp_la_SOURCES = sctp_load_libs.c sctp_socket.c sctp_bind.c \
|
||||
sctp_sockopt.c sctp_socket.h
|
||||
-libwithsctp_la_LDFLAGS = -version-info 1:17:0 -ldl
|
||||
-
|
||||
+bwithsctp_la_LDFLAGS = -version-info \
|
||||
+ @LIBWITHSCTP_CURRENT@:@LIBWITHSCTP_REVISION@:@LIBWITHSCTP_AGE@ -ldl
|
||||
pkgdoc_DATA = sctp_load_libs.c sctp_socket.c sctp_bind.c \
|
||||
sctp_sockopt.c sctp_socket.h checksctp.c
|
||||
|
||||
diff -Naur a/src/withsctp/withsctp.in b/src/withsctp/withsctp.in
|
||||
--- a/src/withsctp/withsctp.in 2020-07-01 17:01:04.452069819 +0800
|
||||
+++ b/src/withsctp/withsctp.in 2020-07-01 17:04:52.962491581 +0800
|
||||
@@ -2,7 +2,8 @@
|
||||
# -*- sh -*-
|
||||
LIBDIR=@libdir@/@PACKAGE@
|
||||
BINDIR=@bindir@
|
||||
-export LD_PRELOAD=${LIBDIR}/libwithsctp.so.1.0.17
|
||||
+LIBVER=@LIBWITHSCTP_CURRENT@.@LIBWITHSCTP_AGE@.@LIBWITHSCTP_REVISION@
|
||||
+export LD_PRELOAD=${LIBDIR}/libwithsctp.so.${LIBVER}
|
||||
if ! ${BINDIR}/checksctp 2> /dev/null
|
||||
then
|
||||
${BINDIR}/checksctp;
|
||||
@ -1,10 +0,0 @@
|
||||
--- lksctp-tools-1.0.17/src/withsctp/withsctp.in.orig 2014-02-18 10:42:49.000000000 +0000
|
||||
+++ lksctp-tools-1.0.17/src/withsctp/withsctp.in 2014-05-06 12:24:12.931873787 +0100
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/sh
|
||||
# -*- sh -*-
|
||||
-LIBDIR=@libdir@/@PACKAGE@
|
||||
+LIBDIR=`rpm --eval "%{_libdir}"`/@PACKAGE@
|
||||
BINDIR=@bindir@
|
||||
export LD_PRELOAD=${LIBDIR}/libwithsctp.so.1.0.17
|
||||
if ! ${BINDIR}/checksctp 2> /dev/null
|
||||
Binary file not shown.
BIN
lksctp-tools-1.0.18.tar.gz
Normal file
BIN
lksctp-tools-1.0.18.tar.gz
Normal file
Binary file not shown.
@ -1,13 +1,15 @@
|
||||
Summary: User-space access to Linux Kernel SCTP
|
||||
Name: lksctp-tools
|
||||
Version: 1.0.17
|
||||
Version: 1.0.18
|
||||
Release: 1%{?dist}
|
||||
# src/apps/bindx_test.C is GPLv2, I've asked upstream for clarification
|
||||
License: GPLv2 and GPLv2+ and LGPLv2 and MIT
|
||||
Group: System Environment/Libraries
|
||||
URL: http://lksctp.sourceforge.net
|
||||
Source0: http://downloads.sourceforge.net/lksctp/%{name}-%{version}.tar.gz
|
||||
Patch0: lksctp-tools-1.0.16-libdir.patch
|
||||
Patch0: bugfix-withsctp-and-configure.patch
|
||||
Patch1: bugfix-build-issue.patch
|
||||
Patch2: bugfix-automake-errno-tests.patch
|
||||
BuildRequires: libtool, automake, autoconf
|
||||
|
||||
%description
|
||||
@ -43,6 +45,8 @@ Drafts).
|
||||
%prep
|
||||
%setup -q
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
%patch2 -p1
|
||||
|
||||
%build
|
||||
[ ! -x ./configure ] && sh bootstrap
|
||||
@ -86,8 +90,8 @@ find $RPM_BUILD_ROOT/%{_libdir}/ -name "*.la" | xargs rm -f
|
||||
%doc doc/*.txt
|
||||
|
||||
%changelog
|
||||
* Tue Jun 30 2020 hanhui <hanhui15@huawei.com> - 1.0.17-1
|
||||
- openEuler Mainline Update to 1.0.17
|
||||
* Tue Jun 30 2020 hanhui <hanhui15@huawei.com> - 1.0.18-1
|
||||
- openEuler Mainline Update to 1.0.18
|
||||
|
||||
* Thu Nov 28 2019 Qianbiao.NG <Qianbiao.NG@turnbig.net> - 1.0.16-11
|
||||
- repackage for openEuler OS
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user