aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJamie Landeg-Jones <jamie@catflap.org>2026-03-08 21:41:35 +0000
committerVladimir Druzenko <vvd@FreeBSD.org>2026-03-08 21:41:35 +0000
commit1c2c25efa837ff4659580ed7edd914ef02810849 (patch)
treeb06148834f661b199b56b0f334e3d4cd4d0d2629
parent1d6c2bbb6ec98926cad6b1d6f11eda6b89a3576c (diff)
sysutils/symon: Fix build on 32 bit machines
symonnet.c:76:9: error: comparison of integers of different signs: 'ssize_t' (aka 'int') and 'u_int32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]" While here, also remove the unneccesary dependency on "groff". PR: 293667
-rw-r--r--sysutils/symon/Makefile4
-rw-r--r--sysutils/symon/files/patch-symon_symonnet.c20
2 files changed, 22 insertions, 2 deletions
diff --git a/sysutils/symon/Makefile b/sysutils/symon/Makefile
index 53cc318a3671..6e895cbe760d 100644
--- a/sysutils/symon/Makefile
+++ b/sysutils/symon/Makefile
@@ -1,6 +1,6 @@
PORTNAME= symon
DISTVERSION= 2.90
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= sysutils
MASTER_SITES= https://wpd.home.xs4all.nl/symon/philes/
@@ -11,7 +11,7 @@ WWW= https://wpd.home.xs4all.nl/symon/
LICENSE= BSD2CLAUSE
LICENSE_FILE= ${WRKSRC}/LICENSE
-USES= groff perl5 shebangfix
+USES= perl5 shebangfix
USE_PERL5= build
SHEBANG_FILES= client/getsymonitem.pl
diff --git a/sysutils/symon/files/patch-symon_symonnet.c b/sysutils/symon/files/patch-symon_symonnet.c
new file mode 100644
index 000000000000..eeabcd6e59fa
--- /dev/null
+++ b/sysutils/symon/files/patch-symon_symonnet.c
@@ -0,0 +1,20 @@
+# The unpatched version made assumptions about types that don't hold true on 32 bit
+# machines. Express the same function in a more portable way.
+#
+# (The compile error was: symonnet.c:76:9: error: comparison of integers of different signs: 'ssize_t' (aka 'int') and 'u_int32_t' (aka 'unsigned int') [-Werror,-Wsign-compare]"
+#
+--- symon/symonnet.c.orig 2025-01-03 13:36:33 UTC
++++ symon/symonnet.c
+@@ -70,9 +70,11 @@ send_packet(struct mux * mux)
+ void
+ send_packet(struct mux * mux)
+ {
+- if (sendto(mux->symuxsocket, mux->packet.data,
++ ssize_t sent = sendto(mux->symuxsocket, mux->packet.data,
+ mux->packet.offset, 0, (struct sockaddr *) & mux->sockaddr,
+ SS_LEN(&mux->sockaddr))
++ ;
++ if (sent < 0 || (size_t)sent
+ != mux->packet.offset) {
+ mux->senderr++;
+ }