我現在實現3DES,我得到的錯誤是這樣的:
日誌:其中未定義的引用用戶定義的函數
Compiling 'ReadTag_new' for 'Arduino Uno PN532.cpp.o:In function PN532::example()' PN532.cpp:undefined reference to des3_set2key_dec' PN532.cpp:undefined reference to des3_set2key_enc' PN532.cpp:undefined reference to des3_crypt_cbc Error creating .elf
des3_set2key_dec
,des3_set2key_enc
,des3_cypt_cbc
是在des.c
文件中執行的功能和在des.h
文件中定義的功能和在PN532.cpp
文件中我也包含的des.h
文件,並且我相信我包含了正確的文件因爲我可以使用從該文件定義的struct
。
我不知道這裏有什麼問題嗎?我在谷歌上搜索,它談到了鏈接器,就像兩個文件生成不同的.o
文件,並且它們應該鏈接在一起,但我不確定我是否在這種情況下
我正在使用Visual Studio 2012,我該怎麼做? –