From 7a9d3c03e40edc4769b35ef1987a572de9912ccf Mon Sep 17 00:00:00 2001 From: xuxin19 Date: Wed, 13 Sep 2023 17:35:54 +0800 Subject: [PATCH] cmake:complete missing changes during reforming for net Signed-off-by: xuxin19 --- net/icmp/CMakeLists.txt | 4 ++++ net/icmpv6/CMakeLists.txt | 4 ++++ net/procfs/CMakeLists.txt | 8 -------- net/tcp/CMakeLists.txt | 14 +++++++++++--- 4 files changed, 19 insertions(+), 11 deletions(-) diff --git a/net/icmp/CMakeLists.txt b/net/icmp/CMakeLists.txt index 427008b1451..9adb17dbcf5 100644 --- a/net/icmp/CMakeLists.txt +++ b/net/icmp/CMakeLists.txt @@ -22,6 +22,10 @@ if(CONFIG_NET_ICMP AND NOT CONFIG_NET_ICMP_NO_STACK) # ICMP source files set(SRCS icmp_input.c icmp_reply.c) + if(NOT "${CONFIG_NET_ICMP_PMTU_ENTRIES}" STREQUAL "0") + list(APPEND SRCS icmp_pmtu.c) + endif() + if(CONFIG_NET_ICMP_SOCKET) list( APPEND diff --git a/net/icmpv6/CMakeLists.txt b/net/icmpv6/CMakeLists.txt index 2d921138136..a871778c5c1 100644 --- a/net/icmpv6/CMakeLists.txt +++ b/net/icmpv6/CMakeLists.txt @@ -52,5 +52,9 @@ if(CONFIG_NET_ICMPv6 AND NOT CONFIG_NET_ICMPv6_NO_STACK) list(APPEND SRCS icmpv6_radvertise.c) endif() + if(NOT "${CONFIG_NET_ICMPv6_PMTU_ENTRIES}" STREQUAL "0") + list(APPEND SRCS icmpv6_pmtu.c) + endif() + target_sources(net PRIVATE ${SRCS}) endif() diff --git a/net/procfs/CMakeLists.txt b/net/procfs/CMakeLists.txt index 4f7ae582644..405b5d6a9ec 100644 --- a/net/procfs/CMakeLists.txt +++ b/net/procfs/CMakeLists.txt @@ -28,14 +28,6 @@ if(NOT CONFIG_DISABLE_MOUNTPOINT # General network statistics - if(CONFIG_NET_STATISTICS) - list(APPEND SRCS net_statistics.c) - - if(CONFIG_NET_MLD) - list(APPEND SRCS net_mld.c) - endif() - endif() - if(CONFIG_NET_STATISTICS) list(APPEND SRCS net_statistics.c) if(CONFIG_NET_MLD) diff --git a/net/tcp/CMakeLists.txt b/net/tcp/CMakeLists.txt index b2d9de5491b..9954461b5ec 100644 --- a/net/tcp/CMakeLists.txt +++ b/net/tcp/CMakeLists.txt @@ -76,10 +76,18 @@ if(CONFIG_NET_TCP AND NOT CONFIG_NET_TCP_NO_STACK) if(CONFIG_NET_TCP_WRITE_BUFFERS) list(APPEND SRCS tcp_wrbuffer.c) + endif() - if(CONFIG_DEBUG_FEATURES) - list(APPEND SRCS tcp_dump.c) - endif() + # TCP congestion control + + if(CONFIG_NET_TCP_CC_NEWRENO) + list(APPEND SRCS tcp_cc.c) + endif() + + # TCP debug + + if(CONFIG_DEBUG_FEATURES) + list(APPEND SRCS tcp_dump.c) endif() target_sources(net PRIVATE ${SRCS})