逐狼2012 发表于 2013-1-22 10:47:11

STM32-USART库函数-编译警告

调试编译出现如下警告,望高手帮忙解决(不屏蔽警告)。
Rebuild target 'Simulator'
compiling stm32f10x_it.c...
myuse.h(128): warning:  #47-D: incompatible redefinition of macro "htons" (declared at line 69 of "C:\Keil\ARM\RV31\INC\RTL.h")
myuse.h(130): warning:  #47-D: incompatible redefinition of macro "htonl" (declared at line 70 of "C:\Keil\ARM\RV31\INC\RTL.h")
myuse.h(134): warning:  #47-D: incompatible redefinition of macro "ntohs" (declared at line 67 of "C:\Keil\ARM\RV31\INC\RTL.h")
myuse.h(135): warning:  #47-D: incompatible redefinition of macro "ntohl" (declared at line 68 of "C:\Keil\ARM\RV31\INC\RTL.h")
compiling main.c...
myuse.h(128): warning:  #47-D: incompatible redefinition of macro "htons" (declared at line 69 of "C:\Keil\ARM\RV31\INC\RTL.h")
myuse.h(130): warning:  #47-D: incompatible redefinition of macro "htonl" (declared at line 70 of "C:\Keil\ARM\RV31\INC\RTL.h")
myuse.h(134): warning:  #47-D: incompatible redefinition of macro "ntohs" (declared at line 67 of "C:\Keil\ARM\RV31\INC\RTL.h")
myuse.h(135): warning:  #47-D: incompatible redefinition of macro "ntohl" (declared at line 68 of "C:\Keil\ARM\RV31\INC\RTL.h")
compiling Retarget.c...
assembling stm32f10x_vector.s...
linking...
Program Size: Code=1868 RO-data=356 RW-data=24 ZI-data=1024 
"..\out\ObjSim\STM32.axf" - 0 Error(s), 8 Warning(s).

发表于 2013-1-23 09:39:03

RE:STM32-USART库函数-编译警告

在RTL.H和MYUSE.h中这几个重复定义了。你看一下。
页: [1]
查看完整版本: STM32-USART库函数-编译警告