summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rwxr-xr-xkernel-tree-scripts/create-patch.sh2
-rwxr-xr-xkernel-tree-scripts/jerry-rig.sh7
-rw-r--r--src/tests/qemu/Makefile2
3 files changed, 6 insertions, 5 deletions
diff --git a/kernel-tree-scripts/create-patch.sh b/kernel-tree-scripts/create-patch.sh
index 3f913ae..de3d888 100755
--- a/kernel-tree-scripts/create-patch.sh
+++ b/kernel-tree-scripts/create-patch.sh
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
WG="$(readlink -f "$(dirname "$(readlink -f "$0")")/../../src/")"
diff --git a/kernel-tree-scripts/jerry-rig.sh b/kernel-tree-scripts/jerry-rig.sh
index 3d4139a..fe309a5 100755
--- a/kernel-tree-scripts/jerry-rig.sh
+++ b/kernel-tree-scripts/jerry-rig.sh
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
K="$1"
WG="$(readlink -f "$(dirname "$(readlink -f "$0")")/../../src/")"
@@ -8,5 +8,6 @@ if [[ ! -e $K/net/Kconfig ]]; then
exit 1
fi
-sed -i "/^if INET\$/a source \"$WG/Kconfig\"" "$K/net/Kconfig"
-echo "obj-y += ../../../../../../../../../../../../../../../../../../../../../..$WG/" >> "$K/net/Makefile"
+ln -sfT "$WG" "$K/net/wireguard"
+sed -i "/^obj-\\\$(CONFIG_NETFILTER).*+=/a obj-\$(CONFIG_WIREGUARD) += wireguard/" "$K/net/Makefile"
+sed -i "/^if INET\$/a source \"net/wireguard/Kconfig\"" "$K/net/Kconfig"
diff --git a/src/tests/qemu/Makefile b/src/tests/qemu/Makefile
index 859bdef..646f64c 100644
--- a/src/tests/qemu/Makefile
+++ b/src/tests/qemu/Makefile
@@ -112,7 +112,7 @@ $(KERNEL_PATH)/.installed: $(KERNEL_TAR)
tar -C $(BUILD_PATH) -xf $<
sed -i "/^if INET\$$/a source \"net/wireguard/Kconfig\"" $(KERNEL_PATH)/net/Kconfig
sed -i "/^obj-\$$(CONFIG_NETFILTER).*+=/a obj-\$$(CONFIG_WIREGUARD) += wireguard/" $(KERNEL_PATH)/net/Makefile
- ln -sf $(shell readlink -f ../..) $(KERNEL_PATH)/net/wireguard
+ ln -sfT $(shell readlink -f ../..) $(KERNEL_PATH)/net/wireguard
touch $@
$(KERNEL_PATH)/.config: kernel.config | $(KERNEL_PATH)/.installed