]> git.ipfire.org Git - thirdparty/wireguard-tools.git/commitdiff
extract-{handshakes,keys}: rework for upstream kernel
authorJason A. Donenfeld <Jason@zx2c4.com>
Fri, 31 Jan 2020 23:48:25 +0000 (00:48 +0100)
committerJason A. Donenfeld <Jason@zx2c4.com>
Fri, 31 Jan 2020 23:53:30 +0000 (00:53 +0100)
Now that WireGuard has been upstreamed and the repos split, we have to
look elsewhere for these headers.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
contrib/extract-handshakes/Makefile
contrib/extract-handshakes/offset-finder.c
contrib/extract-keys/Makefile
contrib/extract-keys/config.c

index 77b42f1e4077820532dbe92a8ff7677bbacd2091..241b0d5d4044b19b0dbd278dab5e143d8f53c1e9 100644 (file)
@@ -20,10 +20,5 @@ clean:
 
 .PHONY: clean
 else
-offset-finder-m := offset-finder.o
-oldsrc := $(src)
-src := $(src)/../../../src
-include $(src)/compat/Kbuild.include
-include $(src)/crypto/Kbuild.include
-src := $(oldsrc)
+obj-m := offset-finder.o
 endif
index 1b54cf3e2f06bf592a994a003d97553e0107ef26..4c1034175494b8ba1bbb4c52559832e0f878f2d5 100644 (file)
@@ -11,7 +11,7 @@ struct def {
 extern const struct def defs[];
 
 #ifdef __KERNEL__
-#include "../../../src/noise.h"
+#include "../drivers/net/wireguard/noise.h"
 
 const struct def defs[] = {
        { "LOCAL_STATIC_PRIVATE_KEY", offsetof(struct noise_static_identity, static_private), offsetof(struct noise_handshake, static_identity) },
index 1f7308d06b0f15f7d223c922914ff1a174a75900..53e77672a411a6d6f562517270b784f31746434e 100644 (file)
@@ -23,10 +23,5 @@ clean:
 
 .PHONY: clean
 else
-config-m := config.o
-oldsrc := $(src)
-src := $(src)/../../../src
-include $(src)/compat/Kbuild.include
-include $(src)/crypto/Kbuild.include
-src := $(oldsrc)
+obj-m := config.o
 endif
index 640c61be066dce28c7cc3af2cfab1089e5efd2dd..59009ef9330be18eb7238af70746b3a1b403e211 100644 (file)
@@ -10,9 +10,9 @@ struct def {
 extern const struct def defs[];
 
 #ifdef __KERNEL__
-#include "../../../src/device.h"
-#include "../../../src/peer.h"
-#include "../../../src/noise.h"
+#include "../drivers/net/wireguard/device.h"
+#include "../drivers/net/wireguard/peer.h"
+#include "../drivers/net/wireguard/noise.h"
 const struct def defs[] = {
        { "SOCK_DEVICE_OFFSET", offsetof(struct sock, sk_user_data) },
        { "DEVICE_NAME_OFFSET", -ALIGN(sizeof(struct net_device), NETDEV_ALIGN) + offsetof(struct net_device, name) },