本文介绍了如何解决“dllmain.obj:错误LNK2019:未解析的外部符号”public"制作DLL项目时出错?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 大家好吧 我想为软件制作一个插件。为了制作插件,我应该制作一个dll文件(带有dll扩展名的文件),但是我遇到了很多关于制作它的挑战。我的系统是Windows 7,我使用Microsoft Visual Studio 2010作为IDE。我做了一个dll项目并制作了两个源文件和一个头文件,然后我构建了解决方案,但是我遇到了以下错误,(在构建解决方案之前,我添加了软件的include和lib目录的路径)。如果有人可以帮我解决这个问题,我将不胜感激。 Hi every bodyI want to make a plugin for a software. In order to make the plugin, I should make a dll file (a file with dll extension) but I have faced many challenges about making it . my system is windows 7 and I'm using Microsoft visual studio 2010 as an IDE. I made a dll project and made two source files, and one header file and then I build the solution but I encountered the following errors, (before building the solution I added the path of include and lib directories of the software). I would appreciate if someone could help me with this problem.::FERegisterClass_T<class FENeoHookeanPI>(unsigned int,char const *)" (??0?$FERegisterClass_T@VFENeoHookeanPI@@@@QAE@IPBD@Z)1>dllmain.obj : error LNK2019: unresolved external symbol "public: static class FECoreKernel & __cdecl FECoreKernel::GetInstance(void)" (?GetInstance@FECoreKernel@@SAAAV1@XZ) referenced in function "public: __thiscall FERegisterClass_T<class FENeoHookeanPI>::FERegisterClass_T<class FENeoHookeanPI>(unsigned int,char const *)" (??0?$FERegisterClass_T@VFENeoHookeanPI@@@@QAE@IPBD@Z)1>dllmain.obj : error LNK2019: unresolved external symbol "public: __thiscall FECoreFactory::FECoreFactory(unsigned int,char const *)" (??0FECoreFactory@@QAE@IPBD@Z) referenced in function "public: __thiscall FERegisterClass_T<class FENeoHookeanPI>::FERegisterClass_T<class FENeoHookeanPI>(unsigned int,char const *)" (??0?$FERegisterClass_T@VFENeoHookeanPI@@@@QAE@IPBD@Z)1>dllmain.obj : error LNK2019: unresolved external symbol "public: __thiscall FEElasticMaterial::FEElasticMaterial(class FEModel *)" (??0FEElasticMaterial@@QAE@PAVFEModel@@@Z) referenced in function "public: __thiscall FENeoHookeanPI::FENeoHookeanPI(class FEModel *)" (??0FENeoHookeanPI@@QAE@PAVFEModel@@@Z)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual class FEParam * __thiscall FEMaterial::GetParameter(class ParamString const &)" (?GetParameter@FEMaterial@@UAEPAVFEParam@@ABVParamString@@@Z)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall FEMaterial::Serialize(class DumpFile &)" (?Serialize@FEMaterial@@UAEXAAVDumpFile@@@Z)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual bool __thiscall FEElasticMaterial::SetAttribute(char const *,char const *)" (?SetAttribute@FEElasticMaterial@@UAE_NPBD0@Z)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall FEMaterial::Properties(void)" (?Properties@FEMaterial@@UAEHXZ)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual class FECoreBase * __thiscall FEMaterial::GetProperty(int)" (?GetProperty@FEMaterial@@UAEPAVFECoreBase@@H@Z)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall FEMaterial::FindPropertyIndex(char const *)" (?FindPropertyIndex@FEMaterial@@UAEHPBD@Z)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual bool __thiscall FEMaterial::SetProperty(int,class FECoreBase *)" (?SetProperty@FEMaterial@@UAE_NHPAVFECoreBase@@@Z)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual double __thiscall FESolidMaterial::Density(void)" (?Density@FESolidMaterial@@UAENXZ)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual void __thiscall FEElasticMaterial::SetLocalCoordinateSystem(class FEElement &,int,class FEMaterialPoint &)" (?SetLocalCoordinateSystem@FEElasticMaterial@@UAEXAAVFEElement@@HAAVFEMaterialPoint@@@Z)1>dllmain.obj : error LNK2001: unresolved external symbol "public: virtual double __thiscall FEElasticMaterial::StrainEnergyDensity(class FEMaterialPoint &)" (?StrainEnergyDensity@FEElasticMaterial@@UAENAAVFEMaterialPoint@@@Z)1>dllmain.obj : error LNK2019: unresolved external symbol "public: __thiscall FEElasticMaterialPoint::FEElasticMaterialPoint(void)" (??0FEElasticMaterialPoint@@QAE@XZ) referenced in function "public: virtual class FEMaterialPoint * __thiscall FEElasticMaterial::CreateMaterialPointData(void)" (?CreateMaterialPointData@FEElasticMaterial@@UAEPAVFEMaterialPoint@@XZ)1>dllmain.obj : error LNK2019: unresolved external symbol "public: virtual __thiscall FEElasticMaterial::~FEElasticMaterial(void)" (??1FEElasticMaterial@@UAE@XZ) referenced in function "public: virtual __thiscall FENeoHookeanPI::~FENeoHookeanPI(void)" (??1FENeoHookeanPI@@UAE@XZ)1>FENeoHookeanPI.obj : error LNK2019: unresolved external symbol "protected: void __thiscall FEParamContainer::AddParameter(void *,enum FEParamType,int,class RANGE,char const *)" (?AddParameter@FEParamContainer@@IAEXPAXW4FEParamType@@HVRANGE@@PBD@Z) referenced in function "protected: virtual void __thiscall FENeoHookeanPI::BuildParamList(void)" (?BuildParamList@FENeoHookeanPI@@MAEXXZ)1>FENeoHookeanPI.obj : error LNK2019: unresolved external symbol "protected: virtual void __thiscall FESolidMaterial::BuildParamList(void)" (?BuildParamList@FESolidMaterial@@MAEXXZ) referenced in function "protected: virtual void __thiscall FENeoHookeanPI::BuildParamList(void)" (?BuildParamList@FENeoHookeanPI@@MAEXXZ)1>FENeoHookeanPI.obj : error LNK2019: unresolved external symbol "public: virtual void __thiscall FEElasticMaterial::Init(void)" (?Init@FEElasticMaterial@@UAEXXZ) referenced in function "public: virtual void __thiscall FENeoHookeanPI::Init(void)" (?Init@FENeoHookeanPI@@UAEXXZ)1>FENeoHookeanPI.obj : error LNK2019: unresolved external symbol "public: class mat3ds __thiscall FEElasticMaterialPoint::LeftCauchyGreen(void)" (?LeftCauchyGreen@FEElasticMaterialPoint@@QAE?AVmat3ds@@XZ) referenced in function "public: virtual class mat3ds __thiscall FENeoHookeanPI::Stress(class FEMaterialPoint &)" (?Stress@FENeoHookeanPI@@UAE?AVmat3ds@@AAVFEMaterialPoint@@@Z)1>C:\Users\pars\Desktop\example\FEneohookean\Debug\FEneohookean.dll : fatal error LNK1120: 21 unresolved externals1>1>Build FAILED.1>"> 谢谢, Faezeh 我尝试了什么: 我查了一下目录和库我也问过人们Thanks,FaezehWhat I have tried:I have checked the directories and libraries and I have also asked people推荐答案 谢谢, Faezeh 我尝试了什么: 我查了一下目录和图书馆,我也问过人Thanks,FaezehWhat I have tried:I have checked the directories and libraries and I have also asked people 这篇关于如何解决“dllmain.obj:错误LNK2019:未解析的外部符号”public"制作DLL项目时出错?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 11-02 21:08