LwIP的编译记录 - 静态库

标签:prototype   提示   auto   frame   net   link   style   des   read   

1.获取LwIP的源码

http://savannah.nongnu.org/   

lwip-2.1.2.zip

 

2.获取移植和应用LwIP的一些demo源码

http://savannah.nongnu.org/

contrib-2.1.0.zip

 

3.Linux环境下编译LwIP成静态库的方法

3.1准备

[plh@localhost LwIP]$ ls
contrib-2.1.0.zip lwip-2.1.2.zip
[plh@localhost LwIP]$ unzip lwip-2.1.2.zip
[plh@localhost LwIP]$ unzip contrib-2.1.0.zip
[plh@localhost LwIP]$ mv lwip-2.1.2 lwip
[plh@localhost LwIP]$ cd contrib-2.1.0/ports/unix/example_app/
[plh@localhost example_app]$ mkdir build
[plh@localhost example_app]$ cd build/

3.2 编译有两种方法

[方法1]: 默认是没有详细的编译日志和不能gdb调试的
[plh@localhost build]$ cmake ..
[plh@localhost build]$ make

[方法2]: 打印详细的编译日志和方便gdb调试
[plh@localhost build]$ vi CMakeCache.txt
CMAKE_BUILD_TYPE:STRING=Debug
CMAKE_VERBOSE_MAKEFILE:BOOL=ON
[plh@localhost build]$cmake ..
[plh@localhost build]$make clean && make

[编译成功后的输出文件]
[plh@localhost build]$ ls -al liblwip*
-rw-rw-r--. 1 plh plh 791662 12月 23 10:31 liblwipallapps.a
-rw-rw-r--. 1 plh plh 17856 12月 23 10:31 liblwipcontribaddons.a
-rw-rw-r--. 1 plh plh 244830 12月 23 10:10 liblwipcontribapps.a
-rw-rw-r--. 1 plh plh 102202 12月 23 10:10 liblwipcontribexamples.a
-rw-rw-r--. 1 plh plh 95738 12月 23 10:10 liblwipcontribportunix.a
-rw-rw-r--. 1 plh plh 2178902 12月 23 10:10 liblwipcore.a
[plh@localhost build]$ ls -al example_app
-rwxrwxr-x. 1 plh plh 784400 12月 23 10:39 example_app
[plh@localhost build]$ ls -al makefsdata
-rwxrwxr-x. 1 plh plh 58192 12月 23 10:39 makefsdata

 

4.记录编译过程中遇到的问题和解决方法

问题1:遇到警告不能进行执行

1 解决方法: 屏蔽如下文件中的行
2 ./ports/CMakeCommon.cmake:30:    -Werror

问题2:提示不识别到的编译选项"-Wlogical-not-parentheses"和"-Wc90-c99-compat"

1 解决方法: 屏蔽文件contrib-2.1.0/目录下的如下文件中的行
2 ./ports/CMakeCommon.cmake:48:    -Wlogical-not-parentheses
3 ./ports/CMakeCommon.cmake:65:            -Wc90-c99-compat

问题3:提示typedef‘httpc_state_t’重定义

技术图片

 1 httpc_state_t重定义问题
 2 /tmp/LwIP/lwip/src/apps/http/http_client.c:153:3 定义了 httpc_state_t
 3 /tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../../lwip/src/include/lwip/apps/http_client.h:97:29 又定义了httpc_state_t
 4 解决方法:
 5 修改文件 /tmp/LwIP/lwip/src/apps/http/http_client.c:153 的内容
 6 old:
 7 typedef struct _httpc_state
 8 {
 9   struct altcp_pcb* pcb;
10   ip_addr_t remote_addr;
11   u16_t remote_port;
12   int timeout_ticks;
13   struct pbuf *request;
14   struct pbuf *rx_hdrs;
15   u16_t rx_http_version;
16   u16_t rx_status;
17   altcp_recv_fn recv_fn;
18   const httpc_connection_t *conn_settings;
19   void* callback_arg;
20   u32_t rx_content_len;
21   u32_t hdr_content_len;
22   httpc_parse_state_t parse_state;
23 #if HTTPC_DEBUG_REQUEST
24   char* server_name;
25   char* uri;
26 #endif
27 } httpc_state_t;
28 new:
29 typedef struct _httpc_state
30 {
31   struct altcp_pcb* pcb;
32   ip_addr_t remote_addr;
33   u16_t remote_port;
34   int timeout_ticks;
35   struct pbuf *request;
36   struct pbuf *rx_hdrs;
37   u16_t rx_http_version;
38   u16_t rx_status;
39   altcp_recv_fn recv_fn;
40   const httpc_connection_t *conn_settings;
41   void* callback_arg;
42   u32_t rx_content_len;
43   u32_t hdr_content_len;
44   httpc_parse_state_t parse_state;
45 #if HTTPC_DEBUG_REQUEST
46   char* server_name;
47   char* uri;
48 #endif
49 } httpc_state_t_plh;
50 #ifndef HTTP_C_STATE_T
51 #define HTTP_C_STATE_T
52 typedef struct _httpc_state httpc_state_t;
53 #endif
54 
55 修改文件 /tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../../lwip/src/include/lwip/apps/http_client.h:97:29
56 old:
57 typedef struct _httpc_state httpc_state_t;
58 new:
59 #ifndef HTTP_C_STATE_T
60 #define HTTP_C_STATE_T
61 typedef struct _httpc_state httpc_state_t;
62 #endif

httpc_state_t重定义问题

问题4:提示缺少lwipcfg.h文件

1 [plh@localhost build]$ mv /tmp/LwIP/contrib-2.1.0/examples/example_app/lwipcfg.h.example /tmp/LwIP/contrib-2.1.0/examples/example_app/lwipcfg.h

 

5.其中两条详细的编译log

技术图片

 1 其中两条编译的详细log
 2 [ 93%] Building C object CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/altcp_tls/altcp_tls_mbedtls.c.o
 3 /usr/bin/cc -DLWIP_DEBUG 
 4 -I/tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../../lwip/src/include 
 5 -I/tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../.. 
 6 -I/tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../ports/unix/port/include 
 7 -I/tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../examples/example_app  
 8 -g -Wall -pedantic -Werror -Wparentheses -Wsequence-point -Wswitch-default -Wextra -Wundef -Wshadow -Wpointer-arith -Wcast-qual -Wc++-compat -Wwrite-strings -Wold-style-definition -Wcast-align -Wmissing-prototypes -Wnested-externs -Wunreachable-code -Wuninitialized -Waggregate-return -Wredundant-decls -Wlogical-op -Wtrampolines 
 9 -o CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/altcp_tls/altcp_tls_mbedtls.c.o   
10 -c /tmp/LwIP/lwip/src/apps/altcp_tls/altcp_tls_mbedtls.c
11 
12 [ 97%] Building C object CMakeFiles/example_app.dir/tmp/LwIP/contrib-2.1.0/examples/example_app/test.c.o
13 /usr/bin/cc -DLWIP_DEBUG 
14 -I/tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../../lwip/src/include 
15 -I/tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../.. 
16 -I/tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../ports/unix/port/include 
17 -I/tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../examples/example_app  
18 -g -Wall -pedantic -Werror -Wparentheses -Wsequence-point -Wswitch-default -Wextra -Wundef -Wshadow -Wpointer-arith -Wcast-qual -Wc++-compat -Wwrite-strings -Wold-style-definition -Wcast-align -Wmissing-prototypes -Wnested-externs -Wunreachable-code -Wuninitialized -Waggregate-return -Wredundant-decls -Wlogical-op -Wtrampolines 
19 -o CMakeFiles/example_app.dir/tmp/LwIP/contrib-2.1.0/examples/example_app/test.c.o   
20 -c /tmp/LwIP/contrib-2.1.0/examples/example_app/test.c
21 
22 
23 这里重点关注包含的头文件
24 [plh@localhost build]$ ls -al /tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../../lwip/src/include
25 总用量 4
26 drwxrwxrwx. 5 plh plh   45 11月 23 2018 .
27 drwxrwxrwx. 7 plh plh  125 11月 23 2018 ..
28 drwxrwxrwx. 4 plh plh   31 11月 23 2018 compat
29 drwxrwxrwx. 5 plh plh 4096 12月 23 10:54 lwip
30 drwxrwxrwx. 3 plh plh  227 11月 23 2018 netif
31 [plh@localhost build]$ ls -al /tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../..
32 总用量 8
33 drwxrwxr-x.  7 plh plh  120 9月  26 2018 .
34 drwxrwxr-x.  4 plh plh   86 12月 23 10:03 ..
35 drwxrwxr-x.  6 plh plh   78 9月  26 2018 addons
36 drwxrwxr-x. 14 plh plh  202 9月  26 2018 apps
37 drwxrwxr-x.  2 plh plh   24 9月  26 2018 Coverity
38 drwxrwxr-x. 12 plh plh  142 9月  26 2018 examples
39 -rw-rw-r--.  1 plh plh 3036 8月   7 2018 Filelists.cmake
40 -rw-rw-r--.  1 plh plh 2812 7月  12 2018 Filelists.mk
41 drwxrwxr-x.  5 plh plh  111 12月 23 10:09 ports
42 [plh@localhost build]$ ls -al /tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../ports/unix/port/include
43 总用量 0
44 drwxrwxr-x. 4 plh plh 31 9月  26 2018 .
45 drwxrwxr-x. 4 plh plh 66 9月  26 2018 ..
46 drwxrwxr-x. 2 plh plh 50 9月  26 2018 arch
47 drwxrwxr-x. 2 plh plh 78 9月  26 2018 netif
48 [plh@localhost build]$ ls -al /tmp/LwIP/contrib-2.1.0/ports/unix/example_app/../../../examples/example_app
49 总用量 56
50 drwxrwxr-x.  3 plh plh   139 12月 23 10:33 .
51 drwxrwxr-x. 12 plh plh   142 9月  26 2018 ..
52 -rw-rw-r--.  1 plh plh  1975 7月  12 2018 default_netif.h
53 -rw-rw-r--.  1 plh plh  3113 7月  12 2018 lwipcfg.h
54 -rw-rw-r--.  1 plh plh 12041 9月  26 2018 lwipopts.h
55 -rw-rw-r--.  1 plh plh   667 7月  12 2018 lwippools.h
56 -rw-rw-r--.  1 plh plh   416 7月  12 2018 ppp_settings.h
57 -rw-rw-r--.  1 plh plh 22180 9月  24 2018 test.c
58 drwxrwxr-x.  2 plh plh  4096 9月  26 2018 test_configs
59 [plh@localhost build]$

详细编译log

 

6.记录输出文件的依赖目标关系

6.1记录输出静态库文件liblwipcore.a的依赖目标

技术图片

 1 [ 53%] Linking C static library liblwipcore.a
 2 /usr/bin/ar qc liblwipcore.a 
 3 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/init.c.o 
 4 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/def.c.o 
 5 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/dns.c.o 
 6 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/inet_chksum.c.o 
 7 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ip.c.o 
 8 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/mem.c.o 
 9 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/memp.c.o 
10 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/netif.c.o 
11 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/pbuf.c.o 
12 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/raw.c.o 
13 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/stats.c.o 
14 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/sys.c.o 
15 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/altcp.c.o 
16 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/altcp_alloc.c.o 
17 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/altcp_tcp.c.o 
18 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/tcp.c.o 
19 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/tcp_in.c.o 
20 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/tcp_out.c.o 
21 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/timeouts.c.o 
22 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/udp.c.o 
23 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv4/autoip.c.o
24 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv4/dhcp.c.o 
25 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv4/etharp.c.o 
26 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv4/icmp.c.o 
27 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv4/igmp.c.o 
28 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv4/ip4_frag.c.o 
29 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv4/ip4.c.o 
30 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv4/ip4_addr.c.o 
31 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/dhcp6.c.o 
32 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/ethip6.c.o 
33 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/icmp6.c.o 
34 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/inet6.c.o 
35 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/ip6.c.o 
36 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/ip6_addr.c.o 
37 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/ip6_frag.c.o 
38 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/mld6.c.o 
39 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/core/ipv6/nd6.c.o 
40 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/api_lib.c.o 
41 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/api_msg.c.o 
42 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/err.c.o 
43 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/if_api.c.o 
44 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/netbuf.c.o 
45 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/netdb.c.o 
46 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/netifapi.c.o 
47 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/sockets.c.o 
48 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/api/tcpip.c.o 
49 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ethernet.c.o 
50 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/bridgeif.c.o 
51 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/bridgeif_fdb.c.o 
52 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/slipif.c.o 
53 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/lowpan6_common.c.o 
54 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/lowpan6.c.o 
55 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/lowpan6_ble.c.o 
56 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/zepif.c.o 
57 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/auth.c.o 
58 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/ccp.c.o 
59 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/chap-md5.c.o 
60 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/chap_ms.c.o 
61 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/chap-new.c.o 
62 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/demand.c.o 
63 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/eap.c.o 
64 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/ecp.c.o 
65 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/eui64.c.o 
66 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/fsm.c.o 
67 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/ipcp.c.o 
68 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/ipv6cp.c.o 
69 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/lcp.c.o 
70 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/magic.c.o 
71 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/mppe.c.o 
72 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/multilink.c.o 
73 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/ppp.c.o 
74 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/pppapi.c.o 
75 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/pppcrypt.c.o 
76 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/pppoe.c.o 
77 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/pppol2tp.c.o 
78 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/pppos.c.o 
79 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/upap.c.o 
80 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/utils.c.o 
81 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/vj.c.o 
82 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/polarssl/arc4.c.o 
83 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/polarssl/des.c.o 
84 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/polarssl/md4.c.o 
85 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/polarssl/md5.c.o 
86 CMakeFiles/lwipcore.dir/tmp/LwIP/lwip/src/netif/ppp/polarssl/sha1.c.o
87 /usr/bin/ranlib liblwipcore.a
88 [ 53%] Built target lwipcore

liblwipcore.a

6.2记录输出静态库文件liblwipcontribexamples.a的依赖目标

技术图片

 1 [ 60%] Linking C static library liblwipcontribexamples.a
 2 /usr/bin/ar qc liblwipcontribexamples.a  
 3 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/httpd/fs_example/fs_example.c.o 
 4 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/httpd/ssi_example/ssi_example.c.o 
 5 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/lwiperf/lwiperf_example.c.o 
 6 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/mdns/mdns_example.c.o 
 7 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/mqtt/mqtt_example.c.o 
 8 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/ppp/pppos_example.c.o 
 9 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/snmp/snmp_private_mib/lwip_prvmib.c.o 
10 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/snmp/snmp_v3/snmpv3_dummy.c.o 
11 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/snmp/snmp_example.c.o 
12 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/sntp/sntp_example.c.o 
13 CMakeFiles/lwipcontribexamples.dir/tmp/LwIP/contrib-2.1.0/examples/tftp/tftp_example.c.o
14 /usr/bin/ranlib liblwipcontribexamples.a
15 [ 60%] Built target lwipcontribexamples

liblwipcontribexamples.a

6.3记录输出静态库文件liblwipcontribapps.a的依赖目标

技术图片

 1 [ 67%] Linking C static library liblwipcontribapps.a
 2 /usr/bin/ar qc liblwipcontribapps.a  
 3 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/httpserver/httpserver-netconn.c.o 
 4 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/chargen/chargen.c.o 
 5 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/udpecho/udpecho.c.o 
 6 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/tcpecho/tcpecho.c.o 
 7 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/shell/shell.c.o 
 8 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/udpecho_raw/udpecho_raw.c.o 
 9 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/tcpecho_raw/tcpecho_raw.c.o 
10 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/netio/netio.c.o 
11 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/ping/ping.c.o 
12 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/socket_examples/socket_examples.c.o 
13 CMakeFiles/lwipcontribapps.dir/tmp/LwIP/contrib-2.1.0/apps/rtp/rtp.c.o
14 /usr/bin/ranlib liblwipcontribapps.a
15 [ 67%] Built target lwipcontribapps

liblwipcontribapps.a

6.4记录输出静态库文件liblwipcontribportunix.a的依赖目标

技术图片

[ 72%] Linking C static library liblwipcontribportunix.a
/usr/bin/ar qc liblwipcontribportunix.a  
CMakeFiles/lwipcontribportunix.dir/tmp/LwIP/contrib-2.1.0/ports/unix/port/sys_arch.c.o 
CMakeFiles/lwipcontribportunix.dir/tmp/LwIP/contrib-2.1.0/ports/unix/port/perf.c.o 
CMakeFiles/lwipcontribportunix.dir/tmp/LwIP/contrib-2.1.0/ports/unix/port/netif/tapif.c.o 
CMakeFiles/lwipcontribportunix.dir/tmp/LwIP/contrib-2.1.0/ports/unix/port/netif/list.c.o 
CMakeFiles/lwipcontribportunix.dir/tmp/LwIP/contrib-2.1.0/ports/unix/port/netif/sio.c.o 
CMakeFiles/lwipcontribportunix.dir/tmp/LwIP/contrib-2.1.0/ports/unix/port/netif/fifo.c.o
/usr/bin/ranlib liblwipcontribportunix.a
[ 72%] Built target lwipcontribportunix

liblwipcontribportunix.a

6.5记录输出静态库文件liblwipallapps.a的依赖目标

技术图片

 1 [ 95%] Linking C static library liblwipallapps.a
 2 /usr/bin/ar qc liblwipallapps.a  
 3 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_asn1.c.o 
 4 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_core.c.o 
 5 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_mib2.c.o 
 6 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_mib2_icmp.c.o 
 7 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_mib2_interfaces.c.o 
 8 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_mib2_ip.c.o 
 9 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_mib2_snmp.c.o 
10 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_mib2_system.c.o 
11 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_mib2_tcp.c.o 
12 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_mib2_udp.c.o 
13 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_snmpv2_framework.c.o 
14 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_snmpv2_usm.c.o 
15 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_msg.c.o 
16 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmpv3.c.o 
17 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_netconn.c.o 
18 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_pbuf_stream.c.o 
19 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_raw.c.o 
20 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_scalar.c.o 
21 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_table.c.o 
22 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_threadsync.c.o 
23 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmp_traps.c.o 
24 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/http/altcp_proxyconnect.c.o 
25 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/http/fs.c.o 
26 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/http/http_client.c.o 
27 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/http/httpd.c.o 
28 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/lwiperf/lwiperf.c.o 
29 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/smtp/smtp.c.o 
30 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/sntp/sntp.c.o 
31 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/mdns/mdns.c.o 
32 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/netbiosns/netbiosns.c.o 
33 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/tftp/tftp_server.c.o 
34 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/mqtt/mqtt.c.o 
35 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/altcp_tls/altcp_tls_mbedtls.c.o 
36 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/altcp_tls/altcp_tls_mbedtls_mem.c.o 
37 CMakeFiles/lwipallapps.dir/tmp/LwIP/lwip/src/apps/snmp/snmpv3_mbedtls.c.o
38 /usr/bin/ranlib liblwipallapps.a
39 [ 95%] Built target lwipallapps

liblwipallapps.a

6.6记录输出静态库文件liblwipcontribaddons.a的依赖目标

技术图片

1 /usr/bin/ar qc liblwipcontribaddons.a  
2 CMakeFiles/lwipcontribaddons.dir/tmp/LwIP/contrib-2.1.0/addons/tcp_isn/tcp_isn.c.o 
3 CMakeFiles/lwipcontribaddons.dir/tmp/LwIP/contrib-2.1.0/addons/ipv6_static_routing/ip6_route_table.c.o
4 /usr/bin/ranlib liblwipcontribaddons.a
5 [ 97%] Built target lwipcontribaddons

liblwipcontribaddons.a

6.7记录输出可执行文件example_app的依赖目标

技术图片

 1 [ 98%] Linking C executable example_app
 2 /usr/bin/cc    
 3 CMakeFiles/example_app.dir/tmp/LwIP/contrib-2.1.0/examples/example_app/test.c.o 
 4 CMakeFiles/example_app.dir/default_netif.c.o 
 5 -o example_app 
 6 liblwipcontribexamples.a 
 7 liblwipcontribapps.a 
 8 liblwipcontribaddons.a 
 9 liblwipallapps.a 
10 liblwipcontribportunix.a 
11 liblwipcore.a 
12 /usr/lib64/libutil.so -lpthread /usr/lib64/librt.so
13 [ 98%] Built target example_app

example_app

6.8记录输出可执行文件makefsdata的依赖目标

技术图片

1 [100%] Linking C executable makefsdata
2 /usr/bin/cc    
3 CMakeFiles/makefsdata.dir/tmp/LwIP/lwip/src/apps/http/makefsdata/makefsdata.c.o  
4 -o makefsdata
5 [100%] Built target makefsdata

makefsdata

 

LwIP的编译记录 - 静态库

标签:prototype   提示   auto   frame   net   link   style   des   read   

原文地址:https://www.cnblogs.com/aimmiao/p/14180918.html

版权声明:完美者 发表于 2020-12-29 11:41:15。
转载请注明:LwIP的编译记录 - 静态库 | 完美导航

暂无评论

暂无评论...