RoM 0 Denunciar post Postado Março 21, 2010 Estou fazendo uma lib para um programa opensource aqui. Eu estava compilando a lib no Dev-C++, mas devido a alguns problemas de compatibilidade, tive que passar para o você++. No Dev-C++ estava compilando normalmente e eu estava até usando a lib no programa funcionando, só que no você++ estou tendo estes problemas no Linker: 1>market.obj : warning LNK4248: unresolved typeref token (01000012) for 'Sql'; image may not run 1>market.obj : error LNK2028: unresolved token (0A000015) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2028: unresolved token (0A000019) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2020: unresolved token (0A00001B) "struct Sql * mmysql_handle" (?mmysql_handle@@3PAUSql@@A) 1>market.obj : error LNK2020: unresolved token (0A00001E) "struct map_data * map" (?map@@3PAUmap_data@@A) 1>market.obj : error LNK2028: unresolved token (0A00001F) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2028: unresolved token (0A000026) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2028: unresolved token (0A000028) "int __cdecl Sql_Connect(struct Sql *,char const *,char const *,char const *,unsigned short,char const *)" (?Sql_Connect@@$$FYAHPAUSql@@PBD11G1@Z) referenced in function "void __cdecl market_init(void)" (?market_init@@$$FYAXXZ) 1>market.obj : error LNK2028: unresolved token (0A00002A) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2028: unresolved token (0A000033) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2028: unresolved token (0A000034) "int __cdecl Sql_NextRow(struct Sql *)" (?Sql_NextRow@@$$FYAHPAUSql@@@Z) referenced in function "bool __cdecl market_auth(void)" (?market_auth@@$$FYA_NXZ) 1>market.obj : error LNK2028: unresolved token (0A000038) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2028: unresolved token (0A000039) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2028: unresolved token (0A00003A) "struct item_data * __cdecl itemdb_search(int)" (?itemdb_search@@$$FYAPAUitem_data@@H@Z) referenced in function "char * __cdecl market_nm(int)" (?market_nm@@$$FYAPADH@Z) 1>market.obj : error LNK2028: unresolved token (0A00003B) "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2028: unresolved token (0A00003E) "struct Sql * __cdecl Sql_Malloc(void)" (?Sql_Malloc@@$$FYAPAUSql@@XZ) referenced in function "void __cdecl market_init(void)" (?market_init@@$$FYAXXZ) 1>market.obj : error LNK2028: unresolved token (0A000049) "int __cdecl Sql_GetData(struct Sql *,unsigned int,char * *,unsigned int *)" (?Sql_GetData@@$$FYAHPAUSql@@IPAPADPAI@Z) referenced in function "bool __cdecl market_auth(void)" (?market_auth@@$$FYA_NXZ) 1>market.obj : error LNK2028: unresolved token (0A00004D) "unsigned int __cdecl MakeDWord(unsigned short,unsigned short)" (?MakeDWord@@$$FYAIGG@Z) referenced in function "char * __cdecl market_char(int,int)" (?market_char@@$$FYAPADHH@Z) 1>market.obj : error LNK2019: unresolved external symbol "struct item_data * __cdecl itemdb_search(int)" (?itemdb_search@@$$FYAPAUitem_data@@H@Z) referenced in function "char * __cdecl market_nm(int)" (?market_nm@@$$FYAPADH@Z) 1>market.obj : error LNK2019: unresolved external symbol "int __cdecl Sql_GetData(struct Sql *,unsigned int,char * *,unsigned int *)" (?Sql_GetData@@$$FYAHPAUSql@@IPAPADPAI@Z) referenced in function "bool __cdecl market_auth(void)" (?market_auth@@$$FYA_NXZ) 1>market.obj : error LNK2019: unresolved external symbol "int __cdecl Sql_NextRow(struct Sql *)" (?Sql_NextRow@@$$FYAHPAUSql@@@Z) referenced in function "bool __cdecl market_auth(void)" (?market_auth@@$$FYA_NXZ) 1>market.obj : error LNK2019: unresolved external symbol "int __cdecl Sql_Query(struct Sql *,char const *,...)" (?Sql_Query@@$$FYAHPAUSql@@PBDZZ) referenced in function "void __cdecl market_update(struct map_session_data *)" (?market_update@@$$FYAXPAUmap_session_data@@@Z) 1>market.obj : error LNK2019: unresolved external symbol "unsigned int __cdecl MakeDWord(unsigned short,unsigned short)" (?MakeDWord@@$$FYAIGG@Z) referenced in function "char * __cdecl market_char(int,int)" (?market_char@@$$FYAPADHH@Z) 1>market.obj : error LNK2001: unresolved external symbol "struct Sql * mmysql_handle" (?mmysql_handle@@3PAUSql@@A) 1>market.obj : error LNK2019: unresolved external symbol "int __cdecl Sql_Connect(struct Sql *,char const *,char const *,char const *,unsigned short,char const *)" (?Sql_Connect@@$$FYAHPAUSql@@PBD11G1@Z) referenced in function "void __cdecl market_init(void)" (?market_init@@$$FYAXXZ) 1>market.obj : error LNK2019: unresolved external symbol "struct Sql * __cdecl Sql_Malloc(void)" (?Sql_Malloc@@$$FYAPAUSql@@XZ) referenced in function "void __cdecl market_init(void)" (?market_init@@$$FYAXXZ) 1>market.obj : error LNK2001: unresolved external symbol "struct map_data * map" (?map@@3PAUmap_data@@A) Estas funções mensionadas pelo linker, são funções do programa que estou fazendo a lib, e todas elas foram declaradas pelos arquivos de cabeçalho que inclui: #include "vending.h" // 's_vending' struct #include "itemdb.h" // 'CARDX' define #include "map.h" // 'mmysql_handle', 'map_session_data' struct #include "pc.h" // 'map_session_data' pointers #include "clif.h" // 'clif_cartlist' #include "../common/cbasetypes.h" #include "../common/mmo.h" // 'item' struct #include "../common/nullpo.h" #include "../common/sql.h" // 'Sql' functions #include "../common/utils.h" // retrieve char_id Eu dei uma pesquisada na internet, mas tudo que encontrei era o pessoal esquecendo de incluir as libs das funções que eles usavam, mas esse não é o meu caso, não tenho uma lib para estas funções... Compartilhar este post Link para o post Compartilhar em outros sites
_Isis_ 202 Denunciar post Postado Março 23, 2010 Já viu se elas estáo no LIBPATH? Compartilhar este post Link para o post Compartilhar em outros sites