G
Guest
I'm porting an old project to use .NET. When I try to link in a static library (.lib) that has a single managed class in it. I get the following errors:
LINK : error LNK2020: unresolved token (0600000E) PatInfo::.ctor
LINK : error LNK2020: unresolved token (0600000F) PatInfo::Finalize
LINK : fatal error LNK1120: 2 unresolved externals
I've striped everything out of this library except for the single class which has an empty constructor and an empty destructor. I have one header file with the class definition and one source file, which has the empty functions in it. Any idea how to get rid of these errors?
Another strange thing I've found. I was trying to see if it was simply not linking the library so I created a global function and called it from my application project. When I did this, not only did the global function load correctly, but the class functions did as well.
The library project is listed as a dependancy for the application project and some of the application source files include the the library header file.
Anyone know how to get past these errors and link static libraries that contain managed classes?
LINK : error LNK2020: unresolved token (0600000E) PatInfo::.ctor
LINK : error LNK2020: unresolved token (0600000F) PatInfo::Finalize
LINK : fatal error LNK1120: 2 unresolved externals
I've striped everything out of this library except for the single class which has an empty constructor and an empty destructor. I have one header file with the class definition and one source file, which has the empty functions in it. Any idea how to get rid of these errors?
Another strange thing I've found. I was trying to see if it was simply not linking the library so I created a global function and called it from my application project. When I did this, not only did the global function load correctly, but the class functions did as well.
The library project is listed as a dependancy for the application project and some of the application source files include the the library header file.
Anyone know how to get past these errors and link static libraries that contain managed classes?