The saga continues!
I've gotten my modified version of the PostScript driver to load, but it seems to causing/exposing another problem.
WINPROC_GetPtr is being called befor WINPROC_Init during Wine initialization. The call to WINPROC_GetPtr results from a call to LoadLibraryExA ("COMCTL32.DLL" ...); here is the stack:
#0 HEAP_GetPtr (heap=0) at heap.c:217 #1 0x40093514 in HeapValidate (heap=0, flags=0, block=0x408ffc67) at heap.c:1508 #2 0x4081c93f in WINPROC_GetPtr () from /usr/lib/wine/libuser32.so #3 0x4081cbaa in WINPROC_SetProc () from /usr/lib/wine/libuser32.so #4 0x407e280d in RegisterClassA () from /usr/lib/wine/libuser32.so #5 0x40900058 in ANIMATE_Register () from /usr/lib/wine/libcomctl32.so #6 0x40906412 in COMCTL32_LibMain () from /usr/lib/wine/libcomctl32.so #7 0x400814e8 in PE_InitDLL () from /usr/lib/wine/libntdll.so #8 0x4007d0f9 in MODULE_InitDLL () from /usr/lib/wine/libntdll.so #9 0x4007d216 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #10 0x4007f364 in LoadLibraryExA () from /usr/lib/wine/libntdll.so #11 0x4007f916 in LoadLibraryA () from /usr/lib/wine/libntdll.so #12 0x40975772 in WINSPOOL_EntryPoint () from /usr/lib/wine/libwinspool.drv.so #13 0x400814e8 in PE_InitDLL () from /usr/lib/wine/libntdll.so #14 0x4007d0f9 in MODULE_InitDLL () from /usr/lib/wine/libntdll.so #15 0x4007d216 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #16 0x4007d1f0 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #17 0x4007f364 in LoadLibraryExA () from /usr/lib/wine/libntdll.so #18 0x4007f916 in LoadLibraryA () from /usr/lib/wine/libntdll.so #19 0x4087206b in MAIN_GdiInit () from /usr/lib/wine/libgdi32.so #20 0x400814e8 in PE_InitDLL () from /usr/lib/wine/libntdll.so #21 0x4007d0f9 in MODULE_InitDLL () from /usr/lib/wine/libntdll.so #22 0x4007d216 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #23 0x4007d1f0 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #24 0x4007d1f0 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #25 0x4007d1f0 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #26 0x4007d1f0 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #27 0x4007d1f0 in MODULE_DllProcessAttach () from /usr/lib/wine/libntdll.so #28 0x400c758c in start_process () from /usr/lib/wine/libntdll.so #29 0x400caeed in SYSDEPS_DoCallOnStack () from /usr/lib/wine/libntdll.so #30 0x400caf97 in SYSDEPS_CallOnStack () from /usr/lib/wine/libntdll.so #31 0x400cb03a in SYSDEPS_SwitchToThreadStack () from /usr/lib/wine/libntdll.so #32 0x400c79d7 in PROCESS_InitWine () from /usr/lib/wine/libntdll.so #33 0x804b213 in main () #34 0x4027ff55 in __libc_start_main (main=0x804b1f8 <main>, argc=1, ubp_av=0xbffff9d4, init=0x8048728 <_init>, fini=0x804b25c <_fini>, rtld_fini=0x4000e3e4 <_dl_fini>, stack_end=0xbffff9cc) at ../sysdeps/generic/libc-start.c:129
This is way out of my depth!
Ian Pilcher wrote:
basically, before your patch you had: winspool.drv and wineps didn't depend on each others on startup, gdi/gdi32 loads wineps
since you added a dep between wineps and winspool.drv, the later also gets called while loading wineps, still in the init of gdi/gdi32 however, the WINPROC_Init should be done in the init of user/user32 as user/user32 depends on gdi/gdi32, it's not called until gdi/gdi32 is initialized... you're stuck
solutions may include using delay loading (which only defers when the DLL is actually loaded)
A+