Bump rtpengine to release 11.5.1.12.
New 11.x release require libopus as a new library and also moved to
PCRE2 library.
Refresh patches and also introduce a new one to disable docs as they
changed doc generation tool and now would require a new prereq and docs
are not useful and would waste space on an embedded scenario.
For recording module libcurl is also now required.
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=rtpengine
-PKG_VERSION:=10.5.2.6
-PKG_RELEASE:=3
+PKG_VERSION:=11.5.1.12
+PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-mr$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/sipwise/rtpengine/tar.gz/mr$(PKG_VERSION)?
-PKG_HASH:=6f6d5cc2ebf27b6361ed2bd2f86a0ca74103503fd1a14af69ed423dba8340bc4
+PKG_HASH:=76a16d00926838cdb16b0004043c2476115b8481f85eff454d5134204c780d47
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-mr$(PKG_VERSION)
+libmosquitto \
+libopenssl \
+libpcap \
- +libpcre \
+ +libpcre2 \
+libwebsockets-openssl \
+ +libopus \
+xmlrpc-c-client \
+zlib
+glib2 \
+libffmpeg-full \
+libmariadb \
- +libopenssl
+ +libopenssl \
+ +libcurl
RTPENGINE_USERID:=378
RTPENGINE_GROUPID:=$(RTPENGINE_USERID)
--- a/daemon/Makefile
+++ b/daemon/Makefile
-@@ -30,7 +30,7 @@ CFLAGS+= $(shell pkg-config --cflags lib
+@@ -32,7 +32,7 @@ CFLAGS+= $(shell pkg-config --cflags lib
CFLAGS+= $(shell pkg-config --cflags libavutil)
CFLAGS+= $(shell pkg-config --cflags libswresample)
CFLAGS+= $(shell pkg-config --cflags libavfilter)
-CFLAGS+= $(shell pkg-config --cflags spandsp)
+CFLAGS+= $(shell pkg-config --cflags spandsp3)
+ CFLAGS+= $(shell pkg-config --cflags opus)
CFLAGS+= -DWITH_TRANSCODING
CFLAGS+= $(shell mysql_config --cflags)
- else
-@@ -65,7 +65,7 @@ LDLIBS+= $(shell pkg-config --libs libav
+@@ -68,7 +68,7 @@ LDLIBS+= $(shell pkg-config --libs libav
LDLIBS+= $(shell pkg-config --libs libavutil)
LDLIBS+= $(shell pkg-config --libs libswresample)
LDLIBS+= $(shell pkg-config --libs libavfilter)
-LDLIBS+= $(shell pkg-config --libs spandsp)
+LDLIBS+= $(shell pkg-config --libs spandsp3)
+ LDLIBS+= $(shell pkg-config --libs opus)
LDLIBS+= $(shell mysql_config --libs)
endif
-
+++ /dev/null
-From 2a6d5cd2cbb58c1cab271a65a76decfdbc11dcd7 Mon Sep 17 00:00:00 2001
-From: Nick Hainke <vincent@systemli.org>
-Date: Wed, 8 Jun 2022 09:30:44 +0200
-Subject: [PATCH] fix compilation with iptables 1.8.8
-
-The extension handling changed [0,1]. Fix compilation with iptables
-1.8.8 [2].
-
-[0] - https://git.netfilter.org/iptables/commit/?id=ef108943f69a6e20533d58823740d3f0534ea8ec
-[1] - https://git.netfilter.org/iptables/commit/?id=6c689b639cf8e2aeced8685eca2915892d76ad86
-[2] - openwrt/openwrt#9886
-
-Signed-off-by: Nick Hainke <vincent@systemli.org>
----
- iptables-extension/libxt_RTPENGINE.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
---- a/iptables-extension/libxt_RTPENGINE.c
-+++ b/iptables-extension/libxt_RTPENGINE.c
-@@ -5,6 +5,10 @@
- #include <netinet/in.h>
- #include <arpa/inet.h>
-
-+#ifndef _init
-+#define _init __attribute__((constructor)) _INIT
-+#endif
-+
- #if defined(__ipt)
- #include <iptables.h>
- #elif defined(__ip6t)
--- a/kernel-module/xt_RTPENGINE.c
+++ b/kernel-module/xt_RTPENGINE.c
-@@ -3455,14 +3455,11 @@ static inline ssize_t proc_control_read_
- struct inode *inode;
- uint32_t id;
+@@ -3781,7 +3781,6 @@ static inline ssize_t proc_control_read_
struct rtpengine_table *t;
-- struct rtpengine_message msgbuf;
- struct rtpengine_message *msg;
int err;
+ enum rtpengine_command cmd;
+- char scratchbuf[512];
+ size_t readlen, writelen, writeoffset;
+ int i;
- if (buflen < sizeof(*msg))
- return -EIO;
-- if (buflen == sizeof(*msg))
-- msg = &msgbuf;
- else { /* > */
- msg = kmalloc(buflen, GFP_KERNEL);
- if (!msg)
-@@ -3559,16 +3556,14 @@ static inline ssize_t proc_control_read_
- goto out;
+@@ -3823,13 +3822,9 @@ static inline ssize_t proc_control_read_
+ return -ERANGE;
+
+ // do we need an extra large storage buffer?
+- if (buflen > sizeof(scratchbuf)) {
+- msg.storage = kmalloc(buflen, GFP_KERNEL);
+- if (!msg.storage)
+- return -ENOMEM;
+- }
+- else
+- msg.storage = scratchbuf;
++ msg.storage = kmalloc(buflen, GFP_KERNEL);
++ if (!msg.storage)
++ return -ENOMEM;
+
+ // get our table
+ inode = file->f_path.dentry->d_inode;
+@@ -3942,16 +3937,14 @@ static inline ssize_t proc_control_read_
+ goto err_free;
}
-- if (msg != &msgbuf)
-- kfree(msg);
-+ kfree(msg);
+- if (msg.storage != scratchbuf)
+- kfree(msg.storage);
++ kfree(msg.storage);
return buflen;
- err:
+ err_table_free:
table_put(t);
- out:
-- if (msg != &msgbuf)
-- kfree(msg);
-+ kfree(msg);
+ err_free:
+- if (msg.storage != scratchbuf)
+- kfree(msg.storage);
++ kfree(msg.storage);
return err;
}
static ssize_t proc_control_write(struct file *file, const char __user *ubuf, size_t buflen, loff_t *off) {
--- /dev/null
+--- a/lib/common.Makefile
++++ b/lib/common.Makefile
+@@ -34,12 +34,6 @@ $(DAEMONSRCS) $(HASHSRCS): $(patsubst %,
+ echo '#line 1' && \
+ cat ../daemon/"$@" ) > "$@"
+
+-%.8: ../docs/%.md
+- cat "$<" | sed '/^# /d; s/^##/#/' | \
+- pandoc -s -t man \
+- -M "footer:$(RTPENGINE_VERSION)" \
+- -M "date:$(BUILD_DATE)" \
+- -o "$@"
+
+ resample.c codeclib.strhash.c mix.c packet.c: fix_frame_channel_layout.h
+
+--- a/daemon/Makefile
++++ b/daemon/Makefile
+@@ -93,11 +93,8 @@ LIBASM= mvr2s_x64_avx2.S mvr2s_x64_avx5
+ endif
+ OBJS= $(SRCS:.c=.o) $(LIBSRCS:.c=.o) $(LIBASM:.S=.o)
+
+-MDS= rtpengine.ronn
+-MANS= $(MDS:.ronn=.8)
+
+ include ../lib/common.Makefile
+
+ install: $(TARGET) $(MANS)
+ install -m 0755 -D $(TARGET) $(DESTDIR)/usr/bin/$(TARGET)
+- install -m 0644 -D $(TARGET).8 $(DESTDIR)/usr/share/man/man8/$(TARGET).8
+--- a/recording-daemon/Makefile
++++ b/recording-daemon/Makefile
+@@ -39,11 +39,8 @@ LIBSRCS= loglib.c auxlib.c rtplib.c code
+ LIBASM= mvr2s_x64_avx2.S mvr2s_x64_avx512.S mix_in_x64_avx2.S mix_in_x64_avx512bw.S mix_in_x64_sse2.S
+ OBJS= $(SRCS:.c=.o) $(LIBSRCS:.c=.o) $(LIBASM:.S=.o)
+
+-MDS= rtpengine-recording.ronn
+-MANS= $(MDS:.ronn=.8)
+
+ include ../lib/common.Makefile
+
+ install: $(TARGET) $(MANS)
+ install -m 0755 -D $(TARGET) $(DESTDIR)/usr/bin/$(TARGET)
+- install -m 0644 -D $(TARGET).8 $(DESTDIR)/usr/share/man/man8/$(TARGET).8