git: 8430de47aa7c - main - wg: fix the LINT-NOIP build
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 20 Oct 2026 14:34:22 UTC
The branch main has been updated by kevans:
URL: https://cgit.FreeBSD.org/src/commit/?id=8430de47aa7c004e1330b8f6a3018c360425606e
commit 8430de47aa7c004e1330b8f6a3018c360425606e
Author: Kyle Evans <kevans@FreeBSD.org>
AuthorDate: 2026-10-20 14:34:03 +0000
Commit: Kyle Evans <kevans@FreeBSD.org>
CommitDate: 2026-10-20 14:34:03 +0000
wg: fix the LINT-NOIP build
We don't have anything to tunnel without INET or INET6, so just smack
it with the same config(5) hammer that ovpn uses and exclude it from
such builds.
Reported by: mjg
Reviewed by: emaste, markj
Differential Revision: https://reviews.freebsd.org/D60896
---
sys/conf/files | 8 ++++----
sys/dev/wg/if_wg.c | 2 --
2 files changed, 4 insertions(+), 6 deletions(-)
diff --git a/sys/conf/files b/sys/conf/files
index 2e9c6ac4f19c..d74bd0b0f648 100644
--- a/sys/conf/files
+++ b/sys/conf/files
@@ -3600,13 +3600,13 @@ dev/vt/vt_font.c optional vt
dev/vt/vt_sysmouse.c optional vt
dev/vte/if_vte.c optional vte pci
dev/watchdog/watchdog.c standard
-dev/wg/if_wg.c optional wg \
+dev/wg/if_wg.c optional wg inet | wg inet6 \
compile-with "${NORMAL_C} -include $S/dev/wg/compat.h"
-dev/wg/wg_cookie.c optional wg \
+dev/wg/wg_cookie.c optional wg inet | wg inet6 \
compile-with "${NORMAL_C} -include $S/dev/wg/compat.h"
-dev/wg/wg_crypto.c optional wg \
+dev/wg/wg_crypto.c optional wg inet | wg inet6 \
compile-with "${NORMAL_C} -include $S/dev/wg/compat.h"
-dev/wg/wg_noise.c optional wg \
+dev/wg/wg_noise.c optional wg inet | wg inet6 \
compile-with "${NORMAL_C} -include $S/dev/wg/compat.h"
dev/wpi/if_wpi.c optional wpi pci
wpifw.c optional wpifw \
diff --git a/sys/dev/wg/if_wg.c b/sys/dev/wg/if_wg.c
index 5877c1966512..8a3878207e27 100644
--- a/sys/dev/wg/if_wg.c
+++ b/sys/dev/wg/if_wg.c
@@ -533,12 +533,10 @@ wg_peer_get_endpoint(struct wg_peer *peer, struct wg_endpoint *e)
static int
wg_aip_addrinfo(struct wg_aip *aip, const void *baddr, uint8_t cidr)
{
-#if defined(INET) || defined(INET6)
struct aip_addr *addr, *mask;
addr = &aip->a_addr;
mask = &aip->a_mask;
-#endif
switch (aip->a_af) {
#ifdef INET
case AF_INET: