blob: 0f0e9e63b73ecab96310a51eb67180e363a36100 [file] [log] [blame]
Ratheesh Kannoth24fb1db2021-10-20 07:28:06 +05301#
2# Makefile for Shortcut FE.
3#
Suruchi Agarwal2f098c92021-09-21 16:16:38 -07004
Nitin Shettye6ed5b52021-12-27 14:50:11 +05305KERNELVERSION := $(word 1, $(subst ., ,$(KERNELVERSION))).$(word 2, $(subst ., ,$(KERNELVERSION)))
6
Ratheesh Kannoth6307bec2021-11-25 08:26:39 +05307SFE_BASE_OBJS := sfe.o sfe_init.o
Tian Yangd98d91b2022-03-09 14:50:12 -08008SFE_IPV4_OBJS := sfe_ipv4.o sfe_ipv4_udp.o sfe_ipv4_tcp.o sfe_ipv4_icmp.o sfe_ipv4_tun6rd.o
Tian Yangafb03452022-01-13 18:53:13 -08009SFE_IPV6_OBJS := sfe_ipv6.o sfe_ipv6_udp.o sfe_ipv6_tcp.o sfe_ipv6_icmp.o sfe_ipv6_tunipip6.o
Guduri Prathyusha79a5fee2021-11-11 17:59:10 +053010SFE_PPPOE_OBJS := sfe_pppoe.o
Ratheesh Kannoth6307bec2021-11-25 08:26:39 +053011
Nitin Shettye6ed5b52021-12-27 14:50:11 +053012
13ifeq ($(findstring 4.4, $(KERNELVERSION)),)
14 SFE_IPV4_OBJS += sfe_ipv4_gre.o
15 SFE_IPV6_OBJS += sfe_ipv6_gre.o
16 ccflags-y += -DSFE_GRE_TUN_ENABLE
17endif
18
19
Ratheesh Kannoth24fb1db2021-10-20 07:28:06 +053020obj-m += qca-nss-sfe.o
Suruchi Agarwal2f098c92021-09-21 16:16:38 -070021
Ratheesh Kannoth6307bec2021-11-25 08:26:39 +053022#
23# Base files
24#
25qca-nss-sfe-objs := $(SFE_BASE_OBJS)
26
27#
28# IPv4 files
29#
30qca-nss-sfe-objs += $(SFE_IPV4_OBJS)
Guduri Prathyusha79a5fee2021-11-11 17:59:10 +053031qca-nss-sfe-objs += $(SFE_PPPOE_OBJS)
Suruchi Agarwal2f098c92021-09-21 16:16:38 -070032
Ratheesh Kannoth24fb1db2021-10-20 07:28:06 +053033ifdef SFE_SUPPORT_IPV6
Ratheesh Kannoth6307bec2021-11-25 08:26:39 +053034qca-nss-sfe-objs += $(SFE_IPV6_OBJS)
Ratheesh Kannoth24fb1db2021-10-20 07:28:06 +053035ccflags-y += -DSFE_SUPPORT_IPV6
36endif
Suruchi Agarwal2f098c92021-09-21 16:16:38 -070037
Amitesh Anand63be37d2021-12-24 20:51:48 +053038ifdef SFE_PROCESS_LOCAL_OUT
39ccflags-y += -DSFE_PROCESS_LOCAL_OUT
40endif
Nitin Shettye6ed5b52021-12-27 14:50:11 +053041
Ratheesh Kannothf4f26f42021-12-06 07:36:20 +053042ccflags-y += -Werror -Wall -Iexports/