我正试图把一个旧项目从MPLAB V8移动到MPLAB-X V3.45。如果我选择C18作为编译器,并将其转换为MPLAB-X,那么它编译时不会出错。其中有些显示在这里:有人能告诉我这些错误是什么意思吗?我特别困惑所有的消息告诉我,我需要添加编译器宏到项目。C18和XC8是不是需要更大的宏呢????另外,P1错误是什么?我已经修复了一堆错误,编译器无法找到正确的路径到我的头文件。同样,C18完全知道头文件的位置。
以上来自于百度翻译
以下为原文
I am trying to move an old project from MPLAB V8 to MPLAB-X V3.45. If I select C18 as the compiler, and convert it to MPLAB-X, it compiles with no errors.
If I select XC8, v1.38 as the compiler, I get a ton of errors. Some of them are shown here:
../Include/TCPIPConfig.h:151: error: (103) #error: Missing project macro defini
tion to select proper TCPIPConfig.h
(908) exit status = 1
nbproject/Makefile-default.mk:308: recipe for target 'build/default/production/_ext/1472/DHCP.p1' failed
../Include/TCPIPConfig.h:151: error: (103) #error: Missing project macro definition to select proper TCPIPConfig.h
../Include/TCPIPConfig.h:151: error: (103) #error: Missing project macro definition to select proper TCPIPConfig.h
(908) exit status = 1
nbproject/Makefile-default.mk:284: recipe for target 'build/default/production/_ext/1472/Announce.p1' failed
../Include/Compiler.h:173: warning: (163) unexpected text in control line ignored
../Include/Compiler.h:176: warning: (163) unexpected text in control line ignored
../Include/Compiler.h:179: warning: (163) unexpected text in control line ignored
../Include/Compiler.h:182: warning: (163) unexpected text in control line ignored
../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/TCPIPConfig.h:151: error: (103) #error: Missing project macro definition to select proper TCPIPConfig.h
(908) exit status = 1
../Include/../Include/StackTsk.h:67: error: (103) #error: Invalid MAX_UDP_SOCKETS value specified
../Include/../Include/StackTsk.h:72: error: (103) #error: Invalid MAX_HTTP_CONNECTIONS value specified.
nbproject/Makefile-default.mk:316: recipe for target 'build/default/production/_ext/1472/DHCPs.p1' failed
make[2]: *** [build/default/production/_ext/1472/DHCP.p1] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: *** [build/default/production/_ext/1472/Announce.p1] Error 1
make[2]: *** [build/default/production/_ext/1472/DHCPs.p1] Error 1
make[2]: *** [build/default/production/_ext/1472/ARP.p1] Error 1
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/Delay.h:63: error: (103) #error: GetInstructionClock() must be defined.
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
(908) exit status = 1
nbproject/Makefile-default.mk:292: recipe for target 'build/default/production/_ext/1472/ARP.p1' failed
../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/Compiler.h:173: warning: (163) unexpected text in control line ignored
../Include/Compiler.h:176: warning: (163) unexpected text in control line ignored
../Include/Compiler.h:179: warning: (163) unexpected text in control line ignored
../Include/Compiler.h:182: warning: (163) unexpected text in control line ignored
../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/TCPIPConfig.h:151: error: (103) #error: Missing project macro definition to select proper TCPIPConfig.h
../Include/../Include/StackTsk.h:67: error: (103) #error: Invalid MAX_UDP_SOCKETS value specified
../Include/../Include/StackTsk.h:72: error: (103) #error: Invalid MAX_HTTP_CONNECTIONS value specified.
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/Delay.h:63: error: (103) #error: GetInstructionClock() must be defined.
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
../Include/../Include/HardwareProfile.h:190: error: (103) #error: "No extended HWP .h included. Add the appropriate compiler macro to the MPLAB project."
make[2]: *** [build/default/production/_ext/1472/Delay.p1] Error 1
make[2]: *** [build/default/production/_ext/1472/ETH97J60.p1] Error 1
make[1]: *** [.build-conf] Error 2
make: *** [.build-impl] Error 2
(908) exit status = 1
Can someone give me a clue as to what these errors mean? I am especially confused about all the messages telling me I need to add compiler macros to the project. The macros aren't required with C18 and XC8 is supposed to be smarter??? Also, what are the P1 errors?
I have already fixed a bunch of errors where the compiler couldn't find the correct paths to my header files. Again, C18 was fully aware of where the header files were.
0