链接问题
error LNK2019 无法解析外部符号 _declspec(dllimport)public:_thiscall DbxFileHeader::DbxFileHeader(class std::basic_istream<char,struct std::char_traits<char>>&)"后面还有一堆东西,然后说在该函数某某中使用
头文件里定义了以下这些东西:
#if defined(WIN32) || defined(_WIN32) || defined(__WIN32__)
#define AS_WIN32
#else
#error "This code is made for windows."
#endif
#define AS_OEDBX_DLL
#if defined(AS_WIN32) && defined(AS_OEDBX_DLL)
#if defined(AS_OE_IMPLEMENTATION)
#define AS_EXPORT __declspec(dllexport)
#else
#define AS_EXPORT __declspec(dllimport)
#endif
#else
#define AS_EXPORT
#endif
class AS_EXPORT DbxFileHeader
{ public :
DbxFileHeader(InStream ins);
int4 GetValue(int4 index) const{return Buffer[index]; }
bool isFolders() const { return (Buffer && (Buffer[1]==0x6f74fdc6)); }
void ShowResults(OutStream outs) const;
private :
// this function is called from the constructor
void readFileHeader(InStream ins);
// stores the data
int4 Buffer[FileHeaderEntries];
};
然后在函数中定义了DbxFileHeader类的实例:
DbxFileHeader fileHeader(ins);