Merge pull request #839 from Ansuel/rtengine-pcre2

rtpengine: bump to 11.5.1.12 release and set PCRE2
This commit is contained in:
micmac1 2023-11-05 09:38:16 +01:00 committed by GitHub
commit 35b00b04cf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 86 additions and 61 deletions

View file

@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=rtpengine PKG_NAME:=rtpengine
PKG_VERSION:=10.5.2.6 PKG_VERSION:=11.5.1.12
PKG_RELEASE:=3 PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-mr$(PKG_VERSION).tar.gz PKG_SOURCE:=$(PKG_NAME)-mr$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/sipwise/rtpengine/tar.gz/mr$(PKG_VERSION)? 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) PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-mr$(PKG_VERSION)
@ -48,8 +48,9 @@ ENGINE_DEPENDS := \
+libmosquitto \ +libmosquitto \
+libopenssl \ +libopenssl \
+libpcap \ +libpcap \
+libpcre \ +libpcre2 \
+libwebsockets-openssl \ +libwebsockets-openssl \
+libopus \
+xmlrpc-c-client \ +xmlrpc-c-client \
+zlib +zlib
@ -65,7 +66,8 @@ RECORDING_DEPENDS := \
+glib2 \ +glib2 \
+libffmpeg-full \ +libffmpeg-full \
+libmariadb \ +libmariadb \
+libopenssl +libopenssl \
+libcurl
RTPENGINE_USERID:=378 RTPENGINE_USERID:=378
RTPENGINE_GROUPID:=$(RTPENGINE_USERID) RTPENGINE_GROUPID:=$(RTPENGINE_USERID)

View file

@ -1,20 +1,20 @@
--- a/daemon/Makefile --- a/daemon/Makefile
+++ b/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 libavutil)
CFLAGS+= $(shell pkg-config --cflags libswresample) CFLAGS+= $(shell pkg-config --cflags libswresample)
CFLAGS+= $(shell pkg-config --cflags libavfilter) CFLAGS+= $(shell pkg-config --cflags libavfilter)
-CFLAGS+= $(shell pkg-config --cflags spandsp) -CFLAGS+= $(shell pkg-config --cflags spandsp)
+CFLAGS+= $(shell pkg-config --cflags spandsp3) +CFLAGS+= $(shell pkg-config --cflags spandsp3)
CFLAGS+= $(shell pkg-config --cflags opus)
CFLAGS+= -DWITH_TRANSCODING CFLAGS+= -DWITH_TRANSCODING
CFLAGS+= $(shell mysql_config --cflags) CFLAGS+= $(shell mysql_config --cflags)
else @@ -68,7 +68,7 @@ LDLIBS+= $(shell pkg-config --libs libav
@@ -65,7 +65,7 @@ LDLIBS+= $(shell pkg-config --libs libav
LDLIBS+= $(shell pkg-config --libs libavutil) LDLIBS+= $(shell pkg-config --libs libavutil)
LDLIBS+= $(shell pkg-config --libs libswresample) LDLIBS+= $(shell pkg-config --libs libswresample)
LDLIBS+= $(shell pkg-config --libs libavfilter) LDLIBS+= $(shell pkg-config --libs libavfilter)
-LDLIBS+= $(shell pkg-config --libs spandsp) -LDLIBS+= $(shell pkg-config --libs spandsp)
+LDLIBS+= $(shell pkg-config --libs spandsp3) +LDLIBS+= $(shell pkg-config --libs spandsp3)
LDLIBS+= $(shell pkg-config --libs opus)
LDLIBS+= $(shell mysql_config --libs) LDLIBS+= $(shell mysql_config --libs)
endif endif

View file

@ -1,30 +0,0 @@
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)

View file

@ -1,36 +1,46 @@
--- a/kernel-module/xt_RTPENGINE.c --- a/kernel-module/xt_RTPENGINE.c
+++ b/kernel-module/xt_RTPENGINE.c +++ b/kernel-module/xt_RTPENGINE.c
@@ -3455,14 +3455,11 @@ static inline ssize_t proc_control_read_ @@ -3781,7 +3781,6 @@ static inline ssize_t proc_control_read_
struct inode *inode;
uint32_t id;
struct rtpengine_table *t; struct rtpengine_table *t;
- struct rtpengine_message msgbuf;
struct rtpengine_message *msg;
int err; int err;
enum rtpengine_command cmd;
- char scratchbuf[512];
size_t readlen, writelen, writeoffset;
int i;
if (buflen < sizeof(*msg)) @@ -3823,13 +3822,9 @@ static inline ssize_t proc_control_read_
return -EIO; return -ERANGE;
- if (buflen == sizeof(*msg))
- msg = &msgbuf; // do we need an extra large storage buffer?
else { /* > */ - if (buflen > sizeof(scratchbuf)) {
msg = kmalloc(buflen, GFP_KERNEL); - msg.storage = kmalloc(buflen, GFP_KERNEL);
if (!msg) - if (!msg.storage)
@@ -3559,16 +3556,14 @@ static inline ssize_t proc_control_read_ - return -ENOMEM;
goto out; - }
- 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) - if (msg.storage != scratchbuf)
- kfree(msg); - kfree(msg.storage);
+ kfree(msg); + kfree(msg.storage);
return buflen; return buflen;
err: err_table_free:
table_put(t); table_put(t);
out: err_free:
- if (msg != &msgbuf) - if (msg.storage != scratchbuf)
- kfree(msg); - kfree(msg.storage);
+ kfree(msg); + kfree(msg.storage);
return err; return err;
} }
static ssize_t proc_control_write(struct file *file, const char __user *ubuf, size_t buflen, loff_t *off) { static ssize_t proc_control_write(struct file *file, const char __user *ubuf, size_t buflen, loff_t *off) {

View file

@ -0,0 +1,43 @@
--- 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