See https://gitlab.alpinelinux.org/alpine/aports/-/issues/16106

diff -upr a/scripts/openvpn-script.c b/scripts/openvpn-script.c
--- a/scripts/openvpn-script.c	2014-08-18 14:20:06.000000000 +0200
+++ b/scripts/openvpn-script.c	2024-07-13 19:31:02.390390494 +0200
@@ -32,6 +32,8 @@
 
 #include <dbus/dbus.h>
 
+#define basename(name) (strrchr((name),'/') ? strrchr((name),'/')+1 : (name))
+
 extern char **environ;
 
 static void print(const char *format, ...)
diff -upr a/scripts/vpn-script.c b/scripts/vpn-script.c
--- a/scripts/vpn-script.c	2020-02-14 23:11:50.000000000 +0100
+++ b/scripts/vpn-script.c	2024-07-13 19:31:06.740477241 +0200
@@ -31,6 +31,8 @@
 
 #include <dbus/dbus.h>
 
+#define basename(name) (strrchr((name),'/') ? strrchr((name),'/')+1 : (name))
+
 extern char **environ;
 
 static void print(const char *format, ...)
diff -upr a/src/log.c b/src/log.c
--- a/src/log.c	2019-03-29 09:49:28.000000000 +0100
+++ b/src/log.c	2024-07-13 19:31:11.930580735 +0200
@@ -34,6 +34,8 @@
 
 #include "connman.h"
 
+#define basename(name) (strrchr((name),'/') ? strrchr((name),'/')+1 : (name))
+
 static const char *program_exec;
 static const char *program_path;
 
