[packages/libmodbus] - updated to 3.1.12

bszx bszx at pld-linux.org
Thu Mar 12 18:44:03 CET 2026


commit 415904e83cb5adf1ed203fab94c220fae6e8cf37
Author: Bartek Szady <bszx at bszx.eu>
Date:   Thu Mar 12 18:42:30 2026 +0100

    - updated to 3.1.12

 libmodbus.spec | 11 ++++++++---
 optflags.patch | 18 ++++++++++++++++++
 test.patch     | 19 +++++++++++++++++++
 3 files changed, 45 insertions(+), 3 deletions(-)
---
diff --git a/libmodbus.spec b/libmodbus.spec
index d8e71be..16ea18f 100644
--- a/libmodbus.spec
+++ b/libmodbus.spec
@@ -9,13 +9,15 @@ Name:		libmodbus
 # 3.0.x is stable, 3.1.x devel
 # This development version is very stable and will be marked as stable very soon
 # according to https://www.libmodbus.org/download
-Version:	3.1.10
+Version:	3.1.12
 Release:	1
 License:	LGPL v2.1+
 Group:		Libraries
 #Source0Download: https://github.com/stephane/libmodbus/releases
 Source0:	https://github.com/stephane/libmodbus/archive/v%{version}/%{name}-%{version}.tar.gz
-# Source0-md5:	4ff4f54659695d7688ca9f4b70980821
+# Source0-md5:	24482d341203e048d4a7b7c15a417f53
+Patch0:		optflags.patch
+Patch1:		test.patch
 URL:		https://libmodbus.org/
 BuildRequires:	autoconf >= 2.63
 BuildRequires:	automake >= 1:1.11
@@ -59,6 +61,9 @@ Statyczna biblioteka libmodbus.
 %prep
 %setup -q
 
+%patch -P0 -p1
+%patch -P1 -p1
+
 %build
 %{__libtoolize}
 %{__aclocal}
@@ -94,7 +99,7 @@ rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
-%doc AUTHORS NEWS README.md
+%doc AUTHORS NEWS.md README.md
 %attr(755,root,root) %{_libdir}/libmodbus.so.*.*.*
 %attr(755,root,root) %ghost %{_libdir}/libmodbus.so.5
 
diff --git a/optflags.patch b/optflags.patch
new file mode 100644
index 0000000..3acdbf9
--- /dev/null
+++ b/optflags.patch
@@ -0,0 +1,18 @@
+diff -up libmodbus-3.1.11/configure.ac._orig libmodbus-3.1.11/configure.ac
+--- libmodbus-3.1.11/configure.ac._orig	2024-10-22 11:10:05.000000000 +0200
++++ libmodbus-3.1.11/configure.ac	2025-01-06 11:34:27.803181238 +0100
+@@ -178,14 +178,6 @@ AC_ARG_ENABLE([debug],
+   [enable_debug=$enableval],
+   [enable_debug=no])
+ 
+-AS_IF([test "x$enable_debug" = "xyes"], [
+-  CFLAGS="-g -O0"
+-  CXXFLAGS="-g -O0"
+-], [
+-  CFLAGS="-O2"
+-  CXXFLAGS="-O2"
+-])
+-
+ AC_OUTPUT
+ AC_MSG_RESULT([
+         $PACKAGE $VERSION
diff --git a/test.patch b/test.patch
new file mode 100644
index 0000000..bbf8c85
--- /dev/null
+++ b/test.patch
@@ -0,0 +1,19 @@
+diff -up libmodbus-3.1.11/tests/unit-tests.sh._orig libmodbus-3.1.11/tests/unit-tests.sh
+--- libmodbus-3.1.11/tests/unit-tests.sh._orig	2024-10-22 11:10:05.000000000 +0200
++++ libmodbus-3.1.11/tests/unit-tests.sh	2025-01-06 12:32:54.139591645 +0100
+@@ -7,6 +7,7 @@ rm -f $client_log $server_log
+ 
+ echo "Starting server"
+ ./unit-test-server > $server_log 2>&1 &
++serverpid="$!"
+ 
+ sleep 1
+ 
+@@ -14,6 +15,6 @@ echo "Starting client"
+ ./unit-test-client > $client_log 2>&1
+ rc=$?
+ 
+-killall unit-test-server
++kill "$serverpid"
+ exit $rc
+ 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/libmodbus.git/commitdiff/415904e83cb5adf1ed203fab94c220fae6e8cf37



More information about the pld-cvs-commit mailing list