瀏覽代碼

[lwip] apply patch snmp_mib2_system

balbekova 5 年之前
父節點
當前提交
9a4e2f0d3b
共有 1 個文件被更改,包括 22 次插入18 次删除
  1. 22 18
      modules/Makefile

+ 22 - 18
modules/Makefile

@@ -86,16 +86,16 @@ CSRC += $(wildcard ../thirdparty/FreeRTOS/portable/MemMang/heap_4.c)
 	
 	# LwIP + Web #	
     INCLUDES += -IHTTP_Server
-    INCLUDES += -I../thirdparty/lwip/src/include
-    INCLUDES += -I../thirdparty/lwip/src/include/lwip
-    INCLUDES += -I../thirdparty/lwip/src/include/netif
-    INCLUDES += -I../thirdparty/lwip/src/include/lwip/apps
-    INCLUDES += -I../thirdparty/lwip/src/apps/snmp/
-#    INCLUDES += -I../thirdparty/lwip/src/netif/ppp
-    INCLUDES += -I../thirdparty/lwip/port
-    INCLUDES += -I../thirdparty/lwip/port/FreeRTOS
-    INCLUDES += -I../thirdparty/lwip/system
-    INCLUDES += -I../thirdparty/lwip/system/arch
+    INCLUDES += -I../thirdparty/lwip_patched/src/include
+    INCLUDES += -I../thirdparty/lwip_patched/src/include/lwip
+    INCLUDES += -I../thirdparty/lwip_patched/src/include/netif
+    INCLUDES += -I../thirdparty/lwip_patched/src/include/lwip/apps
+    INCLUDES += -I../thirdparty/lwip_patched/src/apps/snmp/
+#    INCLUDES += -I../thirdparty/lwip_patched/src/netif/ppp
+    INCLUDES += -I../thirdparty/lwip_patched/port
+    INCLUDES += -I../thirdparty/lwip_patched/port/FreeRTOS
+    INCLUDES += -I../thirdparty/lwip_patched/system
+    INCLUDES += -I../thirdparty/lwip_patched/system/arch
     INCLUDES += -IEthernet
  # INCLUDES += -I../stm32/stm32f4x7_ethernet 
  	INCLUDES += -ISTM32F4x7_ETH_Driver
@@ -110,14 +110,14 @@ ifneq (,$(filter $(HARDWARE),bt6706 bt6708))
 endif
     CSRC += $(wildcard HTTP_Server/trap_params.c)
     CSRC += $(wildcard HTTP_Server/web_params_api.c)
-    CSRC += $(wildcard ../thirdparty/lwip/src/*.c)
-    CSRC += $(wildcard ../thirdparty/lwip/src/api/*.c)
-    CSRC += $(wildcard ../thirdparty/lwip/src/core/*.c)
-    CSRC += $(wildcard ../thirdparty/lwip/src/core/ipv4/*.c)
-    CSRC += $(wildcard ../thirdparty/lwip/src/netif/*.c)
-    CSRC += $(wildcard ../thirdparty/lwip/src/apps/snmp/*.c)
-#    CSRC += $(wildcard ../thirdparty/lwip/src/netif/ppp/*.c)
-    CSRC += $(wildcard ../thirdparty/lwip/port/FreeRTOS/*.c)
+    CSRC += $(wildcard ../thirdparty/lwip_patched/src/*.c)
+    CSRC += $(wildcard ../thirdparty/lwip_patched/src/api/*.c)
+    CSRC += $(wildcard ../thirdparty/lwip_patched/src/core/*.c)
+    CSRC += $(wildcard ../thirdparty/lwip_patched/src/core/ipv4/*.c)
+    CSRC += $(wildcard ../thirdparty/lwip_patched/src/netif/*.c)
+    CSRC += $(wildcard ../thirdparty/lwip_patched/src/apps/snmp/*.c)
+#    CSRC += $(wildcard ../thirdparty/lwip_patched/src/netif/ppp/*.c)
+    CSRC += $(wildcard ../thirdparty/lwip_patched/port/FreeRTOS/*.c)
     CSRC += $(wildcard Ethernet/*.c)
 
   #  CSRC += $(wildcard ../stm32/stm32f4x7_ethernet/*.c)
@@ -200,6 +200,10 @@ RELEASE_PATH := $(ARTIFACTS_PATH)/$(RELEASE_VERSION)
 
 prebuild: $(FSDATA_DIR)/fsdata.c
 	@echo "Hardware version: $(HARDWARE)"
+	rm -rf ../thirdparty/lwip_patched
+	mkdir -p ../thirdparty/lwip_patched
+	cp -R ../thirdparty/lwip/* ../thirdparty/lwip_patched
+	cd ../thirdparty/lwip_patched/ && patch -p3 < ../../patches/snmp_mib2_system_patch.diff
 	
 postbuild: $(BUILDDIR)/$(TARGET).bin
 	@echo "FW start address: $(FW_FLASH_START)"