- Fix search
if_tun.h:
--- CMakeLists.txt.orig 2026-03-23 08:45:44 UTC
+++ CMakeLists.txt
@@ -252,7 +252,7 @@ if(ENABLE_TUNTAP)
elseif(CMAKE_SYSTEM_NAME MATCHES "FreeBSD")
include(CheckIncludeFile)
- cm_check_include("net/if_tun.h" HAVE_NET_IF_TUN_H)
+ cm_check_include("net/if.h;net/if_tun.h" HAVE_NET_IF_TUN_H)
if(HAVE_NET_IF_TUN_H)
add_definitions(-DHAVE_TUNTAP=1)
else()
--- Macros.cmake.orig 2026-03-23 08:45:44 UTC
+++ Macros.cmake
@@ -1,4 +1,4 @@
-include(CheckIncludeFile)
+include(CheckIncludeFiles)
include(CheckFunctionExists)
include(CheckLibraryExists)
include(CheckTypeSize)
@@ -30,7 +30,7 @@ macro(cm_check_include include var)
endmacro()
macro(cm_check_include include var)
- check_include_file(${include} ${var})
+ check_include_files("${include}" ${var})
if(${var})
set(defines ${defines} "#cmakedefine ${var}\n\n")
else()
- Fix build error:
--- src/dpipe.c.orig 2026-03-23 08:45:44 UTC
+++ src/dpipe.c
@@ -201,7 +201,11 @@ int main(int argc, char *argv[])
if (daemonize != 0)
daemon(0,0);
+#ifdef VDE_FREEBSD
+ else if (setpgrp(0,getpid()) == -1) {
+#else
else if (setpgrp() == -1) {
+#endif
fprintf(stderr,"Err: cannot create pgrp\n");
perror("setpgrp");
exit(1);
- Fix build if libpcap installed from ports:
--- src/vde_pcapplug.c.orig 2026-03-23 08:45:44 UTC
+++ src/vde_pcapplug.c
@@ -32,7 +32,6 @@
#include <libgen.h>
#define _GNU_SOURCE
#include <getopt.h>
-#include <pcap.h>
#include <limits.h>
#include <config.h>
@@ -41,8 +40,11 @@
#include <libvdeplug.h>
#ifdef VDE_FREEBSD
+#include <net/bpf.h>
#include <sys/socket.h>
#endif
+
+#include <pcap.h>
#if defined(VDE_DARWIN) || defined(VDE_FREEBSD)
# if defined HAVE_SYSLIMITS_H
- Fix build error:
--- src/vde_vxlan/vxlan.c.orig 2026-03-23 08:45:44 UTC
+++ src/vde_vxlan/vxlan.c
@@ -24,6 +24,7 @@
#include <netinet/in.h>
#include <sys/un.h>
+#include <sys/socket.h>
#include "vxlan_hash.h"
#include "log.h"
if_tun.h: