-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Based on the work of Carlos Talbot (@tusc) in tusc/wireguard-kmod A lot of improvements have been contributed by @peacey For the full commit history, see the branch udm-support in fossoreslp/wireguard-vyatta-ubnt Signed-off-by: Pascal Vorwerk <info@fossores.de>
- Loading branch information
1 parent
988ef6c
commit 6354cef
Showing
29 changed files
with
23,225 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
config BR2_PACKAGE_OPENRESOLV | ||
bool "openresolv" | ||
help | ||
openresolv is a resolvconf implementation which | ||
manages resolv.conf. This tool provides a dns management | ||
framework to track currently available nameservers. | ||
|
||
https://roy.marples.name/projects/openresolv |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Locally calculated | ||
sha256 7d74c669849183ecefdfcec30d25664b1ca24ba1ca8c2ad5de50fcaeef3b4810 openresolv-3.10.0.tar.gz | ||
sha256 384740bf5e19e7628d20f4dcc22925062fdc6020e9a6f074e567d4d797be57a0 LICENSE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
################################################################################ | ||
# | ||
# openresolv | ||
# | ||
################################################################################ | ||
|
||
OPENRESOLV_VERSION = 3.10.0 | ||
OPENRESOLV_SITE = $(call github,rsmarples,openresolv,openresolv-$(OPENRESOLV_VERSION)) | ||
OPENRESOLV_LICENSE = BSD-2-Clause | ||
OPENRESOLV_LICENSE_FILES = LICENSE | ||
OPENRESOLV_CPE_ID_VENDOR = openresolv_project | ||
|
||
define OPENRESOLV_CONFIGURE_CMDS | ||
cd $(@D) && $(TARGET_CONFIGURE_OPTS) ./configure --sysconfdir=/etc | ||
endef | ||
|
||
define OPENRESOLV_BUILD_CMDS | ||
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) | ||
endef | ||
|
||
define OPENRESOLV_INSTALL_TARGET_CMDS | ||
$(TARGET_MAKE_ENV) $(MAKE) -C $(@D) DESTDIR="$(TARGET_DIR)" install | ||
endef | ||
|
||
$(eval $(generic-package)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
config BR2_PACKAGE_WIREGUARD_LINUX_COMPAT | ||
bool "wireguard linux-compat" | ||
depends on BR2_LINUX_KERNEL | ||
# kernel module requires 3.10+ | ||
depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_10 | ||
# kernel module in upstream linux since 5.6 | ||
depends on !BR2_TOOLCHAIN_HEADERS_AT_LEAST_5_6 | ||
help | ||
WireGuard is an extremely simple yet fast and modern VPN | ||
that utilizes state-of-the-art cryptography. It aims to be | ||
faster, simpler, leaner, and more useful than IPSec, while | ||
avoiding the massive headache. It intends to be considerably | ||
more performant than OpenVPN. WireGuard is designed as a | ||
general purpose VPN for running on embedded interfaces and | ||
super computers alike, fit for many different | ||
circumstances. | ||
|
||
Support for WireGuard is included in Linux 5.6+. This | ||
package provides a backport of the kernel support for older | ||
kernels. | ||
|
||
https://www.wireguard.com | ||
|
||
comment "wireguard-linux-compat needs a toolchain w/ headers >= 3.10" | ||
depends on BR2_LINUX_KERNEL | ||
depends on !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_10 |
24 changes: 24 additions & 0 deletions
24
unifios/packages/wireguard-linux-compat/wireguard-linux-compat.mk
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
################################################################################ | ||
# | ||
# wireguard | ||
# | ||
################################################################################ | ||
|
||
WIREGUARD_LINUX_COMPAT_VERSION = PACKAGE_VERSION | ||
WIREGUARD_LINUX_COMPAT_SITE = $(TOPDIR)/package/wireguard-linux-compat | ||
WIREGUARD_LINUX_COMPAT_SITE_METHOD = file | ||
WIREGUARD_LINUX_COMPAT_SOURCE = wireguard-linux-compat-$(WIREGUARD_LINUX_COMPAT_VERSION).tar | ||
WIREGUARD_LINUX_COMPAT_LICENSE = GPL-2.0 | ||
WIREGUARD_LINUX_COMPAT_LICENSE_FILES = COPYING | ||
WIREGUARD_LINUX_COMPAT_MODULE_SUBDIRS = src | ||
|
||
define WIREGUARD_LINUX_COMPAT_LINUX_CONFIG_FIXUPS | ||
$(call KCONFIG_ENABLE_OPT,CONFIG_INET) | ||
$(call KCONFIG_ENABLE_OPT,CONFIG_NET) | ||
$(call KCONFIG_ENABLE_OPT,CONFIG_NET_FOU) | ||
$(call KCONFIG_ENABLE_OPT,CONFIG_CRYPTO) | ||
$(call KCONFIG_ENABLE_OPT,CONFIG_CRYPTO_MANAGER) | ||
endef | ||
|
||
$(eval $(kernel-module)) | ||
$(eval $(generic-package)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
config BR2_PACKAGE_WIREGUARD_TOOLS | ||
bool "wireguard tools" | ||
# kernel module requires 3.10+, userspace makes no sense without it | ||
depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_10 | ||
help | ||
WireGuard is an extremely simple yet fast and modern VPN | ||
that utilizes state-of-the-art cryptography. It aims to be | ||
faster, simpler, leaner, and more useful than IPSec, while | ||
avoiding the massive headache. It intends to be considerably | ||
more performant than OpenVPN. WireGuard is designed as a | ||
general purpose VPN for running on embedded interfaces and | ||
super computers alike, fit for many different | ||
circumstances. | ||
|
||
This package provides the userspace tooling to configure | ||
WireGuard tunnels. | ||
|
||
https://www.wireguard.com | ||
|
||
comment "wireguard-tools needs a toolchain w/ headers >= 3.10" | ||
depends on !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
################################################################################ | ||
# | ||
# wireguard-tools | ||
# | ||
################################################################################ | ||
|
||
WIREGUARD_TOOLS_VERSION = PACKAGE_VERSION | ||
WIREGUARD_TOOLS_SITE = $(TOPDIR)/package/wireguard-tools | ||
WIREGUARD_TOOLS_SITE_METHOD = file | ||
WIREGUARD_TOOLS_SOURCE = wireguard-tools-$(WIREGUARD_TOOLS_VERSION).tar | ||
WIREGUARD_TOOLS_LICENSE = GPL-2.0 | ||
WIREGUARD_TOOLS_LICENSE_FILES = COPYING | ||
|
||
ifeq ($(BR2_INIT_SYSTEMD),y) | ||
WIREGUARD_TOOLS_MAKE_OPTS += WITH_SYSTEMDUNITS=yes | ||
WIREGUARD_TOOLS_DEPENDENCIES += host-pkgconf | ||
else | ||
WIREGUARD_TOOLS_MAKE_OPTS += WITH_SYSTEMDUNITS=no | ||
endif | ||
|
||
ifeq ($(BR2_PACKAGE_BASH),y) | ||
WIREGUARD_TOOLS_MAKE_OPTS += WITH_BASHCOMPLETION=yes WITH_WGQUICK=yes | ||
else | ||
WIREGUARD_TOOLS_MAKE_OPTS += WITH_BASHCOMPLETION=no WITH_WGQUICK=no | ||
endif | ||
|
||
define WIREGUARD_TOOLS_BUILD_CMDS | ||
$(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) $(WIREGUARD_TOOLS_MAKE_OPTS) \ | ||
-C $(@D)/src | ||
endef | ||
|
||
define WIREGUARD_TOOLS_INSTALL_TARGET_CMDS | ||
$(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) $(WIREGUARD_TOOLS_MAKE_OPTS) \ | ||
-C $(@D)/src install DESTDIR=$(TARGET_DIR) | ||
endef | ||
|
||
$(eval $(generic-package)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
Subject: Workaround change in glibc | ||
|
||
Temporary workaround to compile with glibc 2.28, which | ||
deprecated some constants | ||
|
||
Based on the workaround made for the tools/m4 package | ||
|
||
--- a/lib/stdio-impl.h | ||
+++ b/lib/stdio-impl.h | ||
@@ -18,6 +18,12 @@ | ||
the same implementation of stdio extension API, except that some fields | ||
have different naming conventions, or their access requires some casts. */ | ||
|
||
+/* Glibc 2.28 made _IO_IN_BACKUP private. For now, work around this | ||
+ problem by defining it ourselves. FIXME: Do not rely on glibc | ||
+ internals. */ | ||
+#if !defined _IO_IN_BACKUP && defined _IO_EOF_SEEN | ||
+# define _IO_IN_BACKUP 0x100 | ||
+#endif | ||
|
||
/* BSD stdio derived implementations. */ | ||
|
||
--- a/lib/fseterr.c | ||
+++ b/lib/fseterr.c | ||
@@ -29,7 +29,7 @@ | ||
/* Most systems provide FILE as a struct and the necessary bitmask in | ||
<stdio.h>, because they need it for implementing getc() and putc() as | ||
fast macros. */ | ||
-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ | ||
+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */ | ||
fp->_flags |= _IO_ERR_SEEN; | ||
#elif defined __sferror || defined __DragonFly__ /* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin */ | ||
fp_->_flags |= __SERR; |
Oops, something went wrong.