Название: при Dedug сборки все ОК, при Release куча unresolved'ов
Отправлено: shender от Ноябрь 19, 2009, 16:45
Народ проблема следующая при сборки библиотеки в режиме Debug все ОК, при попытке сборки Release куча error LNK2001: unresolved external symbol................. Visual Studio Pro 2008 1>Linking... 1> Creating library ..\build\libs\player.lib and object ..\build\libs\player.exp 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol _libvlc_event_attach 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol _libvlc_exception_raised 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol _libvlc_media_player_event_manager 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: static class iLogger * __cdecl iLogger::getInstance(void)" (__imp_?getInstance@iLogger@@SAPAV1@XZ) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "protected: void __thiscall LibVlcEventManager::eventReceived(struct libvlc_event_t *)" (?eventReceived@LibVlcEventManager@@IAEXPAUlibvlc_event_t@@@Z) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall LibVlcEventManager::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@LibVlcEventManager@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall LibVlcEventManager::qt_metacast(char const *)" (?qt_metacast@LibVlcEventManager@@UAEPAXPBD@Z) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall LibVlcEventManager::metaObject(void)const " (?metaObject@LibVlcEventManager@@UBEPBUQMetaObject@@XZ) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "public: static struct QMetaObject const iPlayer::staticMetaObject" (?staticMetaObject@iPlayer@@2UQMetaObject@@B) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol _libvlc_exception_init 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_set_log_verbosity 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_audio_set_volume 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_pause 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_play 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_release 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_log_get_iterator 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_log_iterator_free 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_log_open 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_set_drawable 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_log_iterator_has_next 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_log_close 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_set_media 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_release 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_set_fullscreen 1>libvlcplayer.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall iPlayer::stateChanged(enum iPlayer::PlayerState)" (?stateChanged@iPlayer@@MAEXW4PlayerState@1@@Z) 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_log_clear 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_release 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_stop 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_get_media 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_new 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_audio_get_volume 1>libvlcplayer.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall LibvlcPlayer::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@LibvlcPlayer@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>libvlcplayer.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall LibvlcPlayer::qt_metacast(char const *)" (?qt_metacast@LibvlcPlayer@@UAEPAXPBD@Z) 1>libvlcplayer.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall LibvlcPlayer::metaObject(void)const " (?metaObject@LibvlcPlayer@@UBEPBUQMetaObject@@XZ) 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_log_iterator_next 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_audio_set_mute 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_new 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_media_player_can_pause 1>libvlcplayer.obj : error LNK2001: unresolved external symbol _libvlc_new 1>player.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall iPlayer::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@iPlayer@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>player.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall iPlayer::qt_metacast(char const *)" (?qt_metacast@iPlayer@@UAEPAXPBD@Z) 1>player.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall iPlayer::metaObject(void)const " (?metaObject@iPlayer@@UBEPBUQMetaObject@@XZ) 1>PlayerDestroyPolicy.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: __thiscall DefaultLogWriter::DefaultLogWriter(int,class QString)" (__imp_??0DefaultLogWriter@@QAE@HVQString@@@Z) 1>PlayerDestroyPolicy.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall PlayerDestroyPolicy::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@PlayerDestroyPolicy@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>PlayerDestroyPolicy.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall PlayerDestroyPolicy::qt_metacast(char const *)" (?qt_metacast@PlayerDestroyPolicy@@UAEPAXPBD@Z) 1>PlayerDestroyPolicy.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall PlayerDestroyPolicy::metaObject(void)const " (?metaObject@PlayerDestroyPolicy@@UBEPBUQMetaObject@@XZ) 1>VLCactiveX.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall VLCactiveX::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@VLCactiveX@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>VLCactiveX.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall VLCactiveX::qt_metacast(char const *)" (?qt_metacast@VLCactiveX@@UAEPAXPBD@Z) 1>VLCactiveX.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall VLCactiveX::metaObject(void)const " (?metaObject@VLCactiveX@@UBEPBUQMetaObject@@XZ) 1>..\build\libs\player.dll : fatal error LNK1120: 49 unresolved externals
Название: Re: при Dedug сборки все ОК, при Release куча unresolved'ов
Отправлено: SASA от Ноябрь 19, 2009, 17:05
По-моему не отмокались h файлы. Если пользуешся инегратором, то просто удали h-файл и все его моки из проекта , а потом добавь только h-файл. Моки должны добавится в проект автоматом.
Название: Re: при Dedug сборки все ОК, при Release куча unresolved'ов
Отправлено: fightcat от Ноябрь 19, 2009, 17:15
Вы уверены, что нужные библиотеки подключены в релизной конфигурации? Проверьте настройки проекта
Название: Re: при Dedug сборки все ОК, при Release куча unresolved'ов
Отправлено: shender от Ноябрь 19, 2009, 17:25
да все подключил ошибок в 2 раза меньше но остались 1>Linking... 1> Creating library ..\build\libs\player.lib and object ..\build\libs\player.exp 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "protected: void __thiscall LibVlcEventManager::eventReceived(struct libvlc_event_t *)" (?eventReceived@LibVlcEventManager@@IAEXPAUlibvlc_event_t@@@Z) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall LibVlcEventManager::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@LibVlcEventManager@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall LibVlcEventManager::qt_metacast(char const *)" (?qt_metacast@LibVlcEventManager@@UAEPAXPBD@Z) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall LibVlcEventManager::metaObject(void)const " (?metaObject@LibVlcEventManager@@UBEPBUQMetaObject@@XZ) 1>LibvlcEventManager.obj : error LNK2001: unresolved external symbol "public: static struct QMetaObject const iPlayer::staticMetaObject" (?staticMetaObject@iPlayer@@2UQMetaObject@@B) 1>PlayerDestroyPolicy.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall PlayerDestroyPolicy::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@PlayerDestroyPolicy@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>PlayerDestroyPolicy.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall PlayerDestroyPolicy::qt_metacast(char const *)" (?qt_metacast@PlayerDestroyPolicy@@UAEPAXPBD@Z) 1>PlayerDestroyPolicy.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall PlayerDestroyPolicy::metaObject(void)const " (?metaObject@PlayerDestroyPolicy@@UBEPBUQMetaObject@@XZ) 1>VLCactiveX.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall VLCactiveX::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@VLCactiveX@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>VLCactiveX.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall VLCactiveX::qt_metacast(char const *)" (?qt_metacast@VLCactiveX@@UAEPAXPBD@Z) 1>VLCactiveX.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall VLCactiveX::metaObject(void)const " (?metaObject@VLCactiveX@@UBEPBUQMetaObject@@XZ) 1>VLCactiveX.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall iPlayer::stateChanged(enum iPlayer::PlayerState)" (?stateChanged@iPlayer@@MAEXW4PlayerState@1@@Z) 1>libvlcplayer.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall LibvlcPlayer::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@LibvlcPlayer@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>libvlcplayer.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall LibvlcPlayer::qt_metacast(char const *)" (?qt_metacast@LibvlcPlayer@@UAEPAXPBD@Z) 1>libvlcplayer.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall LibvlcPlayer::metaObject(void)const " (?metaObject@LibvlcPlayer@@UBEPBUQMetaObject@@XZ) 1>player.obj : error LNK2001: unresolved external symbol "public: virtual int __thiscall iPlayer::qt_metacall(enum QMetaObject::Call,int,void * *)" (?qt_metacall@iPlayer@@UAEHW4Call@QMetaObject@@HPAPAX@Z) 1>player.obj : error LNK2001: unresolved external symbol "public: virtual void * __thiscall iPlayer::qt_metacast(char const *)" (?qt_metacast@iPlayer@@UAEPAXPBD@Z) 1>player.obj : error LNK2001: unresolved external symbol "public: virtual struct QMetaObject const * __thiscall iPlayer::metaObject(void)const " (?metaObject@iPlayer@@UBEPBUQMetaObject@@XZ) 1>..\build\libs\player.dll : fatal error LNK1120: 18 unresolved externals 1>Build log was saved at "file://c:\Documents and Settings\Pavel\Рабочий стол\111PIX_HDIP\build\libs\.player\BuildLog.htm" 1>player - 19 error(s), 0 warning(s)
Название: Re: при Dedug сборки все ОК, при Release куча unresolved'ов
Отправлено: fightcat от Ноябрь 19, 2009, 17:36
Вот это уже совсем похоже на то, что сказал SASA.
Название: Re: при Dedug сборки все ОК, при Release куча unresolved'ов
Отправлено: shender от Ноябрь 19, 2009, 17:41
нет интегратором не пользуюсь, при Debug все moc перекомпиливаются, при Release такого нету
Название: Re: при Dedug сборки все ОК, при Release куча unresolved'ов
Отправлено: fuCtor от Ноябрь 19, 2009, 19:44
нет интегратором не пользуюсь, при Debug все moc перекомпиливаются, при Release такого нету
Значит не настроены параметры компиляции для заголовочных файлов для RELEASE сборки. Если не используете интегратор придется вручную их прописывать.
Название: Re: при Dedug сборки все ОК, при Release куча unresolved'ов
Отправлено: shender от Ноябрь 19, 2009, 20:07
все ок была запары в pro файле
|