0

ライブラリ A と B の 2 つのライブラリがあります。ライブラリ B は自分のライブラリであり、その中に「windows.h」が必要です。また、一部の機能については、サードパーティのライブラリ A を使用する必要があります。A は Google ロギング ライブラリを使用しており、ここに問題があります。

最初のエラーは次のとおりです。

Severity Code Description Project File Line Error C1189 #error:  ERROR macro is defined. Define GLOG_NO_ABBREVIATED_SEVERITIES before including logging.h

「あ」の前に GLOG_NO_ABBREVIATED_SEVERITIES を定義したのですが、その後、奇妙なリンク エラーが発生しました。ここで提案されているすべてのソリューションをテストしましたが、どれも機能しません。

「windows.h」を使用するプロジェクトで glog を使用する他の方法はありますか?

編集 :

リンカー エラーは次のとおりです。

 error LNK2019: unresolved external symbol "__declspec(dllimport) public: char __thiscall std::basic_ios<char,struct std::char_traits<char> >::fill(char)" (__imp_?fill@?$basic_ios@DU?$char_traits@D@std@@@std@@QAEDD@Z) referenced in function "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl std::operator<<<char,struct std::char_traits<char>,char>(class std::basic_ostream<char,struct std::char_traits<char> > &,struct std::_Fillobj<char> const &)" (??$?6DU?$char_traits@D@std@@D@std@@YAAAV?$basic_ostream@DU?$char_traits@D@std@@@0@AAV10@ABU?$_Fillobj@D@0@@Z)

 error LNK2019: unresolved external symbol "__declspec(dllimport) public: class std::basic_ostream<char,struct std::char_traits<char> > & __thiscall std::basic_ostream<char,struct std::char_traits<char> >::operator<<(class std::ios_base & (__cdecl*)(class std::ios_base &))" (__imp_??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@P6AAAVios_base@1@AAV21@@Z@Z) referenced in function _getHtsLables

 error LNK2019: unresolved external symbol "__declspec(dllimport) public: class std::basic_ostream<char,struct std::char_traits<char> > & __thiscall std::basic_ostream<char,struct std::char_traits<char> >::operator<<(double)" (__imp_??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QAEAAV01@N@Z) referenced in function "public: virtual void __thiscall AD3::FactorDense::Print(class std::basic_ostream<char,struct std::char_traits<char> > &)" (?Print@FactorDense@AD3@@UAEXAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@@Z)

 fatal error LNK1120: 3 unresolved externals
4

2 に答える 2