Link to debug runtime?

Talk about code development, features, specific bugzilla bugs, enhancements, patches, and other highly technical things.

Moderator: satrow

Forum rules
Please keep everything here strictly on-topic.
This board is meant for Pale Moon source code development related subjects only like code snippets, patches, specific referenced Bugzilla bugs, mercurial, etc.

This is not for tech support! Please do not post tech support questions in the "Development" board!
Please make sure not to use this board for support questions. Most "bug reports" do not belong in this board and should initially be posted in Community Support or other relevant support boards.

Please keep things on-topic as this forum will be used for reference for Pale Moon development. Expect topics that aren't relevant as such to be moved or deleted.
roytam1
Moonbather
Moonbather
Posts: 74
Joined: Wed Mar 11, 2015 7:01 am
Location: Hong Kong

Link to debug runtime?

Postby roytam1 » Thu Dec 07, 2017 7:06 am

It seems that I can't link compiled dlls to debug version of C runtime even I have --enable-debug flag set:

Code: Select all

16:43.54 mozcrt.lib(newaop_s.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MD_DynamicRelease' doesn't match value 'MDd_DynamicDebug' in Unified_cpp_angle_src_libGLESv20.obj
16:43.54 mozcrt.lib(locale0_implib.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MD_DynamicRelease' doesn't match value 'MDd_DynamicDebug' in Unified_cpp_angle_src_libGLESv20.obj


Did I miss something?

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 20065
Joined: Sun Aug 28, 2011 5:27 pm
Location: 58.5°N 15.5°E
Contact:

Re: Link to debug runtime?

Postby Moonchild » Thu Dec 07, 2017 9:15 am

Are you manually trying to link things? When do you get this error? Are you using the normal build system? Did you clobber when changing the debug option? (it's recommended never to build non-debug and debug in the same objdir)
Improving Mozilla code: You know you're on the right track with code changes when you spend the majority of your time deleting code.

roytam1
Moonbather
Moonbather
Posts: 74
Joined: Wed Mar 11, 2015 7:01 am
Location: Hong Kong

Re: Link to debug runtime?

Postby roytam1 » Thu Dec 07, 2017 11:31 am

Moonchild wrote:Are you manually trying to link things?

No, all done by mach build. I need goanna libraries linking with debug version of C runtime. I specified "-MDd" optimize option in mozconfig.

Moonchild wrote:When do you get this error? Are you using the normal build system?

When mach build is building GL libraries, and also the stub executable.

It seems that mozcrt is not patching debug version of import library?

Moonchild wrote:Did you clobber when changing the debug option? (it's recommended never to build non-debug and debug in the same objdir)

I use new folder for debug build in mozconfig:

Code: Select all

mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-dbg-@CONFIG_GUESS@

so release build and debug build are separated.

roytam1
Moonbather
Moonbather
Posts: 74
Joined: Wed Mar 11, 2015 7:01 am
Location: Hong Kong

Re: Link to debug runtime?

Postby roytam1 » Fri Dec 08, 2017 4:19 am

I'm trying to play with old WinEmbed, and xul.dll accessing 0x00000000 and crashes. mTransactionIdAllocator is NULL here.

Code: Select all

>    xul.dll!mozilla::layers::ClientLayerManager::ForwardTransaction(bool aScheduleComposite) Line 557   C++
   xul.dll!mozilla::layers::ClientLayerManager::EndTransaction(void (mozilla::layers::PaintedLayer *, gfxContext *, const nsIntRegion &, mozilla::layers::DrawRegionClip, const nsIntRegion &, void *) * aCallback, void * aCallbackData, mozilla::layers::LayerManager::EndTransactionFlags aFlags) Line 320   C++
    xul.dll!nsWebBrowser::PaintWindow(nsIWidget * aWidget, nsIntRegion aRegion) Line 1634   C++
    xul.dll!nsWindow::OnPaint(HDC__ * aDC, unsigned int aNestingLevel) Line 530   C++
    xul.dll!nsWindow::ProcessMessage(unsigned int msg, unsigned int & wParam, long & lParam, long * aRetValue) Line 4830   C++
    xul.dll!nsWindow::WindowProcInternal(HWND__ * hWnd, unsigned int msg, unsigned int wParam, long lParam) Line 4382   C++
    xul.dll!CallWindowProcCrashProtected(long (HWND__ *, unsigned int, unsigned int, long) * aWndProc, HWND__ * aHWnd, unsigned int aMsg, unsigned int aWParam, long aLParam) Line 24   C++
    xul.dll!nsWindow::WindowProc(HWND__ * hWnd, unsigned int msg, unsigned int wParam, long lParam) Line 4334   C++
    user32.dll!_InternalCallWinProc@20()   Unknown
    user32.dll!_UserCallWinProcCheckWow@32()   Unknown
    user32.dll!_DispatchClientMessage@24()   Unknown
    user32.dll!___fnDWORD@4()   Unknown
    ntdll.dll!_KiUserCallbackDispatcher@12()   Unknown
    user32.dll!_NtUserDispatchMessage@4()   Unknown
    user32.dll!_DispatchMessageWorker@8()   Unknown
    user32.dll!_DispatchMessageW@4()   Unknown
    winEmbed.exe!AppCallbacks::RunEventLoop(int & aRunCondition) Line 1164   C++
    winEmbed.exe!main(int argc, char * * argv) Line 274   C++
    winEmbed.exe!__tmainCRTStartup() Line 626   C
    kernel32.dll!@BaseThreadInitThunk@12()   Unknown
    ntdll.dll!___RtlUserThreadStart@8()   Unknown
    ntdll.dll!__RtlUserThreadStart@8()   Unknown


Return to “Development (discussion)”

Who is online

Users browsing this forum: LimboSlam and 5 guests