2016-10-11 6 views
0

Я составил QT динамический с -mt (изменить конфигурационный файл)использование QT с DLL скомпилирована с -mt грохотом

мой код, как это (моя программа режим расцепитель с MT тоже):

int main(int argc, char *argv[]) 

{ 
    int ret = 0; 

    if(0 == ret) 
    { 
     QApplication a(argc, argv); 
     { 
      test01 w; 
      w.show(); 
      ret = a.exec(); 
     } 
    } 

    return ret; 
} 

test01 is very simple like this: 

class test01 : public QMainWindow 

{ 
    Q_OBJECT 

public: 
    test01(QWidget *parent = 0); 
    ~test01(); 

private: 
    Ui::test01Class ui; 
}; 

все нормально, но когда оставить основную функцию, он разбился:

[enter image description here][1] 

Любой поможет мне?

+0

Изображение не добавлено – pableiros

ответ

0
[enter image description here][1] 

[email protected]() Неизвестный [email protected]() Неизвестный

qwindows.dll! _free_base (недействительными * блок = 0x00425dc0) Линия 112 C++ qwindows.dll! бесплатно (недействительными * блок = 0x00425dc0) Строка 30 C++ qwindows.dll! оператор удаления (аннулируются * блок = 0x00425dc0, неподписанных INT формальный = 8) линия 15 C++ qwindows.dll! QWindowsIntegrationPlugin :: scalar deleting destructor'(unsigned int) C++ Qt5Core.dll!QLibraryPrivate::unload(QLibraryPrivate::UnloadFlag flag=UnloadSys) Line 558 C++ Qt5Core.dll!QFactoryLoaderPrivate::~QFactoryLoaderPrivate() Line 87 C++ Qt5Core.dll!QFactoryLoaderPrivate:: скалярная удаление destructor '(unsigned int) C++ Qt5Core.dll! Q Object :: ~ QObject() Строка 1049 C++ Qt5Core.dll! QFactoryLoader :: ~ QFactoryLoader() Строка 209 C++ Qt5Gui.dll! `` Анонимное пространство имен ':: Q_QGS_loader :: innerFunction' :: 2':: динамический дескриптор atexit для ' держатель ''() C++ Qt5Gui.dll _execute_onexit_table :: __ l2:! :() Line 206 C++ Qt5Gui.dll __ crt_seh_guarded_call :: оператор() <, Int (аннулируются) &,> (__ acrt_lock_and_call :: __ l2 :: & & setup = {...}, _execute_onexit_table :: __ l2 :: int (void) & action = int (void) {...}, __acrt_lock_and_call :: __ l2 :: & & cleanup = {...}) Строка 204 C++ Qt5Gui.dll! __ acrt_lock_and_call (void)> (const __acrt_lock_id lock_id = __ acrt_exit_lock, _execute_o nexit_table :: __ l2 :: Int (аннулируются) & & действие = INT (аннулируются) {...}) Линия 912 C++ Qt5Gui.dll _execute_onexit_table (_onexit_table_t * таблица = 0x0f873798) Линия 160 C++ Qt5Gui.dll common_exit!: : __ l2: :() линия 215 C++ Qt5Gui.dll __ crt_seh_guarded_call :: оператор() <, недействительным (недействительными) &,> (__ acrt_lock_and_call :: __ l2 :: & & установка = {...}, common_exit :: __ l2! :: void (void) & action = void (void) {...}, __acrt_lock_and_call :: __ l2 :: & & cleanup = {...}) Строка 225 C++ Qt5Gui.dll! __ acrt_lock_and_call (void)> (const __acrt_lock_id lock_id = __ acrt_exit_lock, common_exit :: __ l2 :: void (void) & & действие = недействительным (недействительными) {...}) Линия 912 C++ Qt5Gui.dll! Common_exit (Const INT код_возврата = 0, Const _crt_exit_cleanup_mode cleanup_mode = _crt_exit_full_cleanup, Const _crt_exit_return_mode return_mode = _crt_exit_return_to_caller) Линия 263 C++ Qt5Gui.dll! _cexit() линия 298 C++ Qt5Gui.dll! dllmain_crt_process_detach (Const BOOL is_terminating = истина) линия 109 C++ Qt5Gui.dll! dllmain_crt_dispatch (HINSTANCE * Const экземпляр = 0x0f4f0000, сопзЬ неподписанных долго причина = 0, аннулируются * Const зарезервирован = 0x00000001) Строка 134 C++ Qt5Gui.dll! Dllmain_dispatch (HINSTANCE__ * const instance = 0x0f4f0000, const unsigned long reason = 0, void * const reserved = 0x00000001) Строка 207 C++ Qt5Gui.dll! _DllMainCRTStartup (HINSTANCE__ * const instance = 0x0f4f0000, const unsigned long reason = 0, void * const reserved = 0x00000001) Строка 248 C++ ntdll.dll!_LdrpCallInitRoutine @ 16() Неизвестный [email protected]() Неизвестный [email protected]() Неизвестный [email protected]() Неизвестный qt_template.exe! Exit_or_terminate_process (сопзЬ неподписанных Int код_возврата) линия 129 C++ qt_template.exe! common_exit (Const INT код_возврата = 0, Const _crt_exit_cleanup_mode cleanup_mode = _crt_exit_full_cleanup, Const _crt_exit_return_mode return_mode = _crt_exit_terminate_process) линия 218 C++ qt_template.exe! выход (интермедиат код_возврата = 0) Строка 282 C++ qt_template. exe! __ scrt_common_main_seh() Строка 262 C++ kernel32.dll! @ BaseThreadInitThunk @ 12() Неизвестно ntdll.dll! ___ RtlUserThreadStart @ 8() Неизвестно ntdll.dll! __ RtlUserThrea dStart @ 8() Неизвестно