Andre Lorbach e4042aa623 runtime: fix Darwin build regressions and improve BSD portability
Fix compilation issues on macOS/Darwin systems and enhance cross-platform
compatibility for BSD variants:

- Add Darwin-specific pthread_setname_np call in tcpsrv.c with enhanced
  platform-specific conditional compilation
- macOS (__APPLE__): Single parameter, returns int
- FreeBSD/NetBSD: Two parameters, returns void
- Linux/glibc (default): Two parameters, returns int

This prevents compilation failures across all BSD systems where the
function signature and return type differ, while maintaining existing
compatibility with macOS and Linux systems.

- Add _PATH_UTMP fallback definition in omusrmsg.c for systems
  without paths.h or missing _PATH_UTMP definition
- Remove trailing empty line in cfsysline.c for consistency

The change adds proper platform-specific conditional compilation
with clear documentation for each variant and maintains error
checking where the return value is available.

Impact: Fixes build regressions on Darwin and BSD systems while
preserving backward compatibility with existing platforms.

Refs: https://github.com/rsyslog/rsyslog/pull/6069
Refs: https://github.com/rsyslog/rsyslog/pull/5635
Refs: https://github.com/Homebrew/homebrew-core/issues/221869
Refs: https://github.com/Homebrew/homebrew-core/issues/226378
2025-09-03 12:29:19 +02:00
..
2024-07-29 10:29:03 +02:00
2025-03-03 11:12:07 +01:00