diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-09-17 18:55:12 +0200 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-09-17 23:40:54 +0200 |
commit | 1906c279fbe3420e31a5a48a19b6daac5fbf1904 (patch) | |
tree | 7eed52ac4d5c9abc0fa67392d11f681c50cf46e6 /src/crypto/Kbuild.include | |
parent | 61450db1388ad8ef0936c114da8cbd2192fc2dc6 (diff) |
crypto: do not use -include trick
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'src/crypto/Kbuild.include')
-rw-r--r-- | src/crypto/Kbuild.include | 30 |
1 files changed, 12 insertions, 18 deletions
diff --git a/src/crypto/Kbuild.include b/src/crypto/Kbuild.include index c252c80..9ea7452 100644 --- a/src/crypto/Kbuild.include +++ b/src/crypto/Kbuild.include @@ -1,49 +1,43 @@ -ifeq ($(wildcard $(src)/compat/compat.h),) -cmd_include_path_prefix := $(srctree)/$(src) -else -cmd_include_path_prefix := $(src) -endif - ccflags-y += -I$(src)/crypto/include wireguard-y += crypto/zinc/chacha20/chacha20.o ifeq ($(CONFIG_X86_64)$(if $(CONFIG_UML),y,n),yn) wireguard-y += crypto/zinc/chacha20/chacha20-x86_64.o -CFLAGS_chacha20.o += -include $(cmd_include_path_prefix)/crypto/zinc/chacha20/chacha20-x86_64-glue.h +CFLAGS_chacha20.o += -DCONFIG_ZINC_ARCH_X86_64 endif ifeq ($(CONFIG_ARM),y) wireguard-y += crypto/zinc/chacha20/chacha20-arm.o -CFLAGS_chacha20.o += -include $(cmd_include_path_prefix)/crypto/zinc/chacha20/chacha20-arm-glue.h +CFLAGS_chacha20.o += -DCONFIG_ZINC_ARCH_ARM endif ifeq ($(CONFIG_ARM64),y) wireguard-y += crypto/zinc/chacha20/chacha20-arm64.o -CFLAGS_chacha20.o += -include $(cmd_include_path_prefix)/crypto/zinc/chacha20/chacha20-arm-glue.h +CFLAGS_chacha20.o += -DCONFIG_ZINC_ARCH_ARM64 endif ifeq ($(CONFIG_MIPS)$(CONFIG_CPU_MIPS32_R2),yy) wireguard-y += crypto/zinc/chacha20/chacha20-mips.o -CFLAGS_chacha20.o += -include $(cmd_include_path_prefix)/crypto/zinc/chacha20/chacha20-mips-glue.h +CFLAGS_chacha20.o += -DCONFIG_ZINC_ARCH_MIPS endif wireguard-y += crypto/zinc/poly1305/poly1305.o ifeq ($(CONFIG_X86_64)$(if $(CONFIG_UML),y,n),yn) wireguard-y += crypto/zinc/poly1305/poly1305-x86_64.o -CFLAGS_poly1305.o += -include $(cmd_include_path_prefix)/crypto/zinc/poly1305/poly1305-x86_64-glue.h +CFLAGS_poly1305.o += -DCONFIG_ZINC_ARCH_X86_64 endif ifeq ($(CONFIG_ARM),y) wireguard-y += crypto/zinc/poly1305/poly1305-arm.o -CFLAGS_poly1305.o += -include $(cmd_include_path_prefix)/crypto/zinc/poly1305/poly1305-arm-glue.h +CFLAGS_poly1305.o += -DCONFIG_ZINC_ARCH_ARM endif ifeq ($(CONFIG_ARM64),y) wireguard-y += crypto/zinc/poly1305/poly1305-arm64.o -CFLAGS_poly1305.o += -include $(cmd_include_path_prefix)/crypto/zinc/poly1305/poly1305-arm-glue.h +CFLAGS_poly1305.o += -DCONFIG_ZINC_ARCH_ARM64 endif ifeq ($(CONFIG_MIPS)$(CONFIG_CPU_MIPS32_R2),yy) wireguard-y += crypto/zinc/poly1305/poly1305-mips.o -CFLAGS_poly1305.o += -include $(cmd_include_path_prefix)/crypto/zinc/poly1305/poly1305-mips-glue.h +CFLAGS_poly1305.o += -DCONFIG_ZINC_ARCH_MIPS endif ifeq ($(CONFIG_MIPS)$(CONFIG_64BIT),yy) wireguard-y += crypto/zinc/poly1305/poly1305-mips64.o -CFLAGS_poly1305.o += -include $(cmd_include_path_prefix)/crypto/zinc/poly1305/poly1305-mips-glue.h +CFLAGS_poly1305.o += -DCONFIG_ZINC_ARCH_MIPS64 endif wireguard-y += crypto/zinc/chacha20poly1305.o @@ -51,14 +45,14 @@ wireguard-y += crypto/zinc/chacha20poly1305.o wireguard-y += crypto/zinc/curve25519/curve25519.o ifeq ($(CONFIG_ARM)$(CONFIG_KERNEL_MODE_NEON),yy) wireguard-y += crypto/zinc/curve25519/curve25519-arm.o -CFLAGS_curve25519.o += -include $(cmd_include_path_prefix)/crypto/zinc/curve25519/curve25519-arm-glue.h +CFLAGS_curve25519.o += -DCONFIG_ZINC_ARCH_ARM endif ifeq ($(CONFIG_X86_64)$(if $(CONFIG_UML),y,n),yn) -CFLAGS_curve25519.o += -include $(cmd_include_path_prefix)/crypto/zinc/curve25519/curve25519-x86_64-glue.h +CFLAGS_curve25519.o += -DCONFIG_ZINC_ARCH_X86_64 endif wireguard-y += crypto/zinc/blake2s/blake2s.o ifeq ($(CONFIG_X86_64)$(if $(CONFIG_UML),y,n),yn) wireguard-y += crypto/zinc/blake2s/blake2s-x86_64.o -CFLAGS_blake2s.o += -include $(cmd_include_path_prefix)/crypto/zinc/blake2s/blake2s-x86_64-glue.h +CFLAGS_blake2s.o += -DCONFIG_ZINC_ARCH_X86_64 endif |