當我試圖建立我的項目中MPLAB,我得到這個編譯錯誤信息..Microchip的鏈接問題
Clean: Deleting intermediary and output files.
Clean: Deleted file "M:\12 CCP PWM\12 CCP PWM.o".
Clean: Done.
Executing: "C:\MCC18\bin\mcc18.exe" -p=18F46K20 "12 CCP PWM.c" -fo="12 CCP PWM.o" -Ou- -Ot- -Ob- -Op- -Or- -Od- -Opa-
MPLAB C18 v3.20 (feature limited)
Copyright 1999-2005 Microchip Technology Inc.
This version of MPLAB C18 does not support the extended mode
and will not perform all optimizations. To purchase a full
copy of MPLAB C18, please contact your local distributor or
visit buy.microchip.com.
Executing: "C:\MCC18\bin\mplink.exe" /l"C:\MCC18\lib" "C:\MCC18\lkr\18f46k20i.lkr" "12 CCP PWM.o" /u_CRUNTIME /o"12 CCP PWM.cof" /M"12 CCP PWM.map" /W
MPLINK 4.20, Linker
Copyright (c) 2008 Microchip Technology Inc.
Error - could not find definition of symbol 'main' in file 'C:\MCC18\lib/c018i.o'.
Errors : 1
Link step failed.
----------------------------------------------------------------------
Release build of project `M:\12 CCP PWM\12 CCP PWM.mcp' failed.
Thu Apr 16 14:34:41 2009
----------------------------------------------------------------------
BUILD FAILED
我已經檢查了路徑鏈接庫correct.I懷疑它是處理我的源代碼...任何幫助都非常感謝。
這裏是我的源代碼.. http://cl1p.net/mplabc18
如果這是您的第一次嘗試,或者您習慣於看到事情的工作,這將有所幫助。而且,如果這個例子在破解之前正在工作。 – gbarry 2009-04-17 20:57:25
您可以從c編譯器生成一個列表或asm文件嗎?或者查看鏈接器是否在地圖文件中生成了任何信息。 然後查看是否有任何主標籤。 – simon 2009-04-30 00:45:53