Visual dBase 5.7 for Windows

Questions about Wine on macOS.
Locked
jub
Newbie
Newbie
Posts: 4
Joined: Thu Apr 23, 2015 12:17 pm

Visual dBase 5.7 for Windows

Post by jub »

Hello,
i try to start a database application in wine. It is Visual dBase 5.7 (a 16bit windows application). Installation was flawless. But when i start dbasewin.exe, i get an error "printer error" and the log outputs:

fixme:int31:DOSVM_FreeRMCB callback address: 1001:0000
fixme:toolhelp:InterruptRegister16 (0000, 0x1927050d), stub.
fixme:int31:DOSVM_Int31Handler Real mode segment (1d37) to descriptor: no longer supported

When i delete all printer related entries in win.ini (devices, spooler, windows-device), there is no error and the application starts.

Some hints from experts?
Thank you very much! bye, jub
cheako
Level 2
Level 2
Posts: 19
Joined: Sun Apr 26, 2015 11:33 pm

Re: Visual dBase 5.7 for Windows

Post by cheako »

jub wrote:there is no error and the application starts.
Can you clarify what it is that does not work? Explain what happens and what you expect to happen so that we can clearly understand your question.
stf80
Newbie
Newbie
Posts: 4
Joined: Mon Apr 27, 2015 9:25 pm

Re: Visual dBase 5.7 for Windows

Post by stf80 »

I have the same problem with dBase 5.0 for Windows (German version), but deleting printer related lines in win.ini didn't help as a device= line was added again by Wine each time I started DBASEWIN.EXE. As a workaround I removed my printer in cups before installing dBase in a new .wine directory.

The error that appears with a printer configured is as follows: when starting dBase a message box appears on top of the splash screen that says "Error: printer error" and if you click on "OK" the application exits. I checked the dBase manual but haven't found a reference to this error.

Without a printer, most parts of dBase 5.0 seem to work in Wine but it's not possible to create a new table; creating other types of files seems to work though. When trying to create a table, Wine stops with a program error in winevdm.exe and the console message:

wine: Unhandled page fault on read access to 0x00000004 at address 0x7e5a6689 (thread 0025), starting debugger...

I tried attaching a backtrace of the debugger to this message but the forum software won't let me (extension txt not allowed) >_>

Creating tables works with dBase installed on Windows 98 SE running in a VirtualBox instance, so it is not a program error.

Any suggestions on what I might try to fix or work around this error would be appreciated, as I'd prefer running dBase in Wine over a virtual machine. I am currently using wine 1.4.1 on Debian Wheezy.
jub
Newbie
Newbie
Posts: 4
Joined: Thu Apr 23, 2015 12:17 pm

Re: Visual dBase 5.7 for Windows

Post by jub »

it is exactly like stf80 explained the problem. I am using the German Version too, but i do not believe that this is the reason of the error. As long as there is no printer available (in win.ini), the software is starting correctly. I removed the lines in win.ini and changed the permissions to read only, so there was no automatically added new entry.

As far as i understand from other comments, Visual dBase is a 16 bit application, which uses the 16 bit drivers (or mechanisms) for printing (https://www.winehq.org/pipermail/wine-d ... 24392.html)
It seems, that there is a wineps16.dll or .drv, but i did not understand all the relevant parts changing win.ini, or the registry...
User avatar
dimesio
Moderator
Moderator
Posts: 13367
Joined: Tue Mar 25, 2008 10:30 pm

Re: Visual dBase 5.7 for Windows

Post by dimesio »

stf80 wrote: I am currently using wine 1.4.1 on Debian Wheezy.
That version is almost 3 years old and no longer supported. Upgrade to the latest development release.
stf80
Newbie
Newbie
Posts: 4
Joined: Mon Apr 27, 2015 9:25 pm

Re: Visual dBase 5.7 for Windows

Post by stf80 »

I've now build and installed Wine version 1.7.41 but the error is the same, when trying to create a new table in dBase (e.g. through the menu option File / New / Table), Wine reports a program error in winevdm.exe. The backtrace looks like this:

Code: Select all

Unhandled exception: page fault on read access to 0x00000004 in 32-bit code (0x7e7d00c9).
Register dump:
 CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b
 EIP:7e7d00c9 ESP:007ee108 EBP:007ee108 EFLAGS:00010202(  R- --  I   - - - )
 EAX:00000000 EBX:00000736 ECX:003cdb20 EDX:00000333
 ESI:f76f0c40 EDI:00000001
Stack dump:
0x007ee108:  007ee128 7e7bd71d 003cdb20 00000000
0x007ee118:  00000000 7e7bdae0 7e7bd6f1 00000000
0x007ee128:  007ee158 7ea60ef6 7e7d00c0 003cdb18
0x007ee138:  7ea61227 00000023 007ee620 7eab3c60
0x007ee148:  199fe472 007ee254 0000000e 7ead4b30
0x007ee158:  007ee1d8 7eab4771 007ee254 0000000e
Backtrace:
=>0 0x7e7d00c9 (0x007ee108)
  1 0x7e7bd71d (0x007ee128)
  2 0x7ea60ef6 (0x007ee158)
  3 0x16c7:0x3a05 (0x199f:0xdfee)
  4 0x16c7:0x3592 (0x199f:0xe0a6)
  5 0x0118:0x0f16 (0x199f:0xe0e6)
  6 0x0018:0x8701 (0x199f:0xe124)
  7 0x5c13:0xd702 (0x199f:0xe134)
  8 0xb613:0xd705 (0x199f:0xe142)
  9 0xb614:0x4f13 (0x199f:0xe182)
  10 0x3e18:0x8f0d (0x199f:0xe376)
  11 0x3618:0x8f06 (0x199f:0xe392)
  12 0x3615:0x6f23 (0x199f:0xe3bc)
  13 0x3613:0x570f (0x199f:0xe3d2)
  14 0x3615:0x6f1c (0x199f:0xe3fc)
  15 0x3615:0x6f01 (0x199f:0xe442)
  16 0x3615:0x6f03 (0x199f:0xe462)
  17 0x0010:0x1f04 (0x199f:0xe49c)
0x7e7d00c9: movl	0x4(%eax),%edx
Modules:
Module	Address			Debug info	Name (21 modules)
PE	7b820000-7b9bc000	Deferred        kernel32
PE	7bc10000-7bc14000	Deferred        ntdll
PE	7d580000-7d583000	Deferred        usp10
PE	7dca0000-7dca4000	Deferred        uxtheme
PE	7deb0000-7deb4000	Deferred        winex11
PE	7df40000-7df4a000	Deferred        winspool
PE	7df80000-7dfaf000	Deferred        comctl32
PE	7e090000-7e098000	Deferred        shlwapi
PE	7e110000-7e26e000	Deferred        shell32
PE	7e340000-7e3d9000	Deferred        comdlg32
PE	7e470000-7e479000	Deferred        msacm32
PE	7e4a0000-7e4a4000	Deferred        rpcrt4
PE	7e540000-7e548000	Deferred        ole32
PE	7e670000-7e6e6000	Deferred        winmm
PE	7e780000-7e78a000	Deferred        mpr
PE	7e860000-7e864000	Deferred        imm32
PE	7eb00000-7eb04000	Deferred        advapi32
PE	7eb80000-7eb87000	Deferred        gdi32
PE	7eca0000-7ecdb000	Deferred        user32
PE	7edf0000-7edf3000	Deferred        winevdm
PE	7eff0000-7eff4000	Deferred        version
Threads:
process  tid      prio (all id:s are in hex)
0000000e services.exe
	00000043    0
	0000001c    0
	00000014    0
	00000010    0
	0000000f    0
00000012 winedevice.exe
	0000001b    0
	00000018    0
	00000017    0
	00000013    0
00000019 plugplay.exe
	0000001f    0
	0000001e    0
	0000001a    0
00000040 (D) C:\windows\system32\winevdm.exe
	0000001d    0 <==
	00000042    0
00000034 explorer.exe
	00000035    0
System information:
    Wine build: wine-1.7.41
    Platform: i386
    Host system: Linux
    Host version: 3.2.0-4-amd64
The backtrace for the older Wine version showed some more information, specifically that the exception occured in CopyRect16() in user.exe16:

Code: Select all

Unhandled exception: page fault on read access to 0x00000004 in 32-bit code (0x7e5af689).
Register dump:
 CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b
 EIP:7e5af689 ESP:007ed7a8 EBP:007ed7a8 EFLAGS:00010206(  R- --  I   - -P- )
 EAX:00000000 EBX:00000d82 ECX:003cd842 EDX:00000333
 ESI:f7762600 EDI:00000001
Stack dump:
0x007ed7a8:  007ed7c8 7e59e7cd 003cd842 00000000
0x007ed7b8:  00000000 7e59eb90 7e59e7a1 00000000
0x007ed7c8:  007ed7f8 7ead319e 7e5af680 003cd83a
0x007ed7d8:  7ead34cf 00000023 007edcc0 7eb22a90
0x007ed7e8:  199fe258 0000000e 00000000 7eb43ff4
0x007ed7f8:  007ed868 7eb2345c 007ed8d0 0000000e
Backtrace:
=>0 0x7e5af689 CopyRect16+0x9() in user.exe16 (0x007ed7a8)
  1 0x7e59e7cd in user.exe16 (+0xe7cc) (0x007ed7c8)
  2 0x7ead319e in krnl386.exe16 (+0x1319d) (0x007ed7f8)
  3 0x16c7:0x3a05 (0x199f:0xdd30)
  4 0x16c7:0x3592 (0x199f:0xdde8)
  5 0x0118:0x0f16 (0x199f:0xde28)
  6 0x0018:0x8701 (0x199f:0xde66)
  7 0x9e13:0xd702 (0x199f:0xde76)
  8 0xb613:0xd705 (0x199f:0xde84)
  9 0xb614:0x4f13 (0x199f:0xdec4)
  10 0x3e18:0x8f0d (0x199f:0xe0b8)
  11 0x3613:0xef20 (0x199f:0xe18e)
  12 0x1e15:0x6f23 (0x199f:0xe1b8)
  13 0x1e15:0x6f1c (0x199f:0xe1e2)
  14 0x1e15:0x6f01 (0x199f:0xe228)
  15 0x1e15:0x6f03 (0x199f:0xe248)
  16 0x0010:0x1f04 (0x199f:0xe282)
  17 0x7eb2345c K32WOWCallback16Ex+0xbb() in krnl386.exe16 (0x007ed868)
0x7e5af689 CopyRect16+0x9 in user.exe16: movl	0x4(%eax),%edx
Modules:
Module	Address			Debug info	Name (127 modules)
ELF	7b800000-7ba3a000	Deferred        kernel32<elf>
  \-PE	7b810000-7ba3a000	\               kernel32
ELF	7bc00000-7bcd4000	Deferred        ntdll<elf>
  \-PE	7bc10000-7bcd4000	\               ntdll
ELF	7bf00000-7bf04000	Deferred        <wine-loader>
ELF	7d6cf000-7d709000	Deferred        usp10<elf>
  \-PE	7d6e0000-7d709000	\               usp10
ELF	7d74f000-7d764000	Deferred        ctl3dv2.dll16.so
PE	7d750000-7d764000	Deferred        ctl3dv2.dll16
ELF	7d764000-7d77e000	Deferred        olecli.dll16.so
PE	7d770000-7d77e000	Deferred        olecli.dll16
ELF	7d77e000-7d795000	Deferred        toolhelp.dll16.so
PE	7d780000-7d795000	Deferred        toolhelp.dll16
ELF	7d795000-7d7ae000	Deferred        shell.dll16.so
PE	7d7a0000-7d7ae000	Deferred        shell.dll16
ELF	7d7ae000-7d7c4000	Deferred        ddeml.dll16.so
PE	7d7b0000-7d7c4000	Deferred        ddeml.dll16
ELF	7d8c4000-7d8d0000	Deferred        libnss_files.so.2
ELF	7d8d0000-7d8db000	Deferred        libnss_nis.so.2
ELF	7d8db000-7d8f2000	Deferred        libnsl.so.1
ELF	7d8f2000-7d8fa000	Deferred        libnss_compat.so.2
ELF	7d8fa000-7d903000	Deferred        librt.so.1
ELF	7d903000-7d907000	Deferred        libgpg-error.so.0
ELF	7d907000-7d953000	Deferred        libdbus-1.so.3
ELF	7d953000-7d965000	Deferred        libp11-kit.so.0
ELF	7d965000-7d9ea000	Deferred        libgcrypt.so.11
ELF	7d9ea000-7d9fc000	Deferred        libtasn1.so.3
ELF	7d9fc000-7da10000	Deferred        libresolv.so.2
ELF	7da10000-7da19000	Deferred        libkrb5support.so.0
ELF	7da19000-7da43000	Deferred        libk5crypto.so.3
ELF	7da43000-7db15000	Deferred        libkrb5.so.3
ELF	7db15000-7db27000	Deferred        libavahi-client.so.3
ELF	7db27000-7db35000	Deferred        libavahi-common.so.3
ELF	7db35000-7dbfe000	Deferred        libgnutls.so.26
ELF	7dbfe000-7dc3c000	Deferred        libgssapi_krb5.so.2
ELF	7dc3c000-7dc92000	Deferred        libcups.so.2
ELF	7dca1000-7dcb6000	Deferred        win87em.dll16.so
PE	7dcb0000-7dcb6000	Deferred        win87em.dll16
ELF	7dce4000-7dd1a000	Deferred        uxtheme<elf>
  \-PE	7dcf0000-7dd1a000	\               uxtheme
ELF	7dd1a000-7dd57000	Deferred        winspool<elf>
  \-PE	7dd20000-7dd57000	\               winspool
ELF	7dd57000-7de59000	Deferred        comctl32<elf>
  \-PE	7dd60000-7de59000	\               comctl32
ELF	7de59000-7e080000	Deferred        shell32<elf>
  \-PE	7de70000-7e080000	\               shell32
ELF	7e080000-7e164000	Deferred        comdlg32<elf>
  \-PE	7e090000-7e164000	\               comdlg32
ELF	7e1c7000-7e23b000	Deferred        shlwapi<elf>
  \-PE	7e1e0000-7e23b000	\               shlwapi
ELF	7e23b000-7e252000	Deferred        commdlg.dll16.so
PE	7e240000-7e252000	Deferred        commdlg.dll16
ELF	7e271000-7e286000	Deferred        sound.drv16.so
PE	7e280000-7e286000	Deferred        sound.drv16
ELF	7e286000-7e2b0000	Deferred        msacm32<elf>
  \-PE	7e290000-7e2b0000	\               msacm32
ELF	7e2b0000-7e330000	Deferred        rpcrt4<elf>
  \-PE	7e2c0000-7e330000	\               rpcrt4
ELF	7e330000-7e45a000	Deferred        ole32<elf>
  \-PE	7e350000-7e45a000	\               ole32
ELF	7e45a000-7e50b000	Deferred        winmm<elf>
  \-PE	7e460000-7e50b000	\               winmm
ELF	7e50b000-7e536000	Deferred        mmsystem.dll16.so
PE	7e510000-7e536000	Deferred        mmsystem.dll16
ELF	7e536000-7e54a000	Deferred        mouse.drv16.so
PE	7e540000-7e54a000	Deferred        mouse.drv16
ELF	7e54a000-7e55f000	Deferred        keyboard.drv16.so
PE	7e550000-7e55f000	Deferred        keyboard.drv16
ELF	7e55f000-7e586000	Deferred        mpr<elf>
  \-PE	7e570000-7e586000	\               mpr
ELF	7e586000-7e5d4000	Dwarf           user.exe16.so
PE	7e590000-7e5d4000	DIA             user.exe16
ELF	7e5d4000-7e605000	Deferred        gdi.exe16.so
PE	7e5e0000-7e605000	Deferred        gdi.exe16
ELF	7e605000-7e60b000	Deferred        libxfixes.so.3
ELF	7e60b000-7e615000	Deferred        libxcursor.so.1
ELF	7e617000-7e61c000	Deferred        libkeyutils.so.1
ELF	7e61c000-7e621000	Deferred        libcom_err.so.2
ELF	7e621000-7e637000	Deferred        display.drv16.so
PE	7e630000-7e637000	Deferred        display.drv16
ELF	7e6ab000-7e6d3000	Deferred        libexpat.so.1
ELF	7e6d3000-7e709000	Deferred        libfontconfig.so.1
ELF	7e709000-7e718000	Deferred        libxi.so.6
ELF	7e718000-7e73c000	Deferred        imm32<elf>
  \-PE	7e720000-7e73c000	\               imm32
ELF	7e73c000-7e75f000	Deferred        libxcb.so.1
ELF	7e75f000-7e897000	Deferred        libx11.so.6
ELF	7e897000-7e8a9000	Deferred        libxext.so.6
ELF	7e8a9000-7e8c2000	Deferred        libice.so.6
ELF	7e8c2000-7e95e000	Deferred        winex11<elf>
  \-PE	7e8d0000-7e95e000	\               winex11
ELF	7e95e000-7e977000	Deferred        libz.so.1
ELF	7e977000-7ea13000	Deferred        libfreetype.so.6
ELF	7ea37000-7ea4c000	Deferred        comm.drv16.so
PE	7ea40000-7ea4c000	Deferred        comm.drv16
ELF	7ea4c000-7ea6c000	Deferred        libtinfo.so.5
ELF	7ea6c000-7ea90000	Deferred        libncurses.so.5
ELF	7ea94000-7ea97000	Deferred        libxcomposite.so.1
ELF	7ea97000-7ea9f000	Deferred        libxrandr.so.2
ELF	7ea9f000-7eab4000	Deferred        system.drv16.so
PE	7eaa0000-7eab4000	Deferred        system.drv16
ELF	7eab4000-7eb5f000	Dwarf           krnl386.exe16.so
PE	7eac0000-7eb5f000	DIA             krnl386.exe16
ELF	7eb5f000-7ebcb000	Deferred        advapi32<elf>
  \-PE	7eb70000-7ebcb000	\               advapi32
ELF	7ebcb000-7ec98000	Deferred        gdi32<elf>
  \-PE	7ebe0000-7ec98000	\               gdi32
ELF	7ec98000-7edec000	Deferred        user32<elf>
  \-PE	7ecb0000-7edec000	\               user32
ELF	7edec000-7ee03000	Deferred        winevdm<elf>
  \-PE	7edf0000-7ee03000	\               winevdm
ELF	7efb6000-7efdc000	Deferred        libm.so.6
ELF	7efdc000-7efe6000	Deferred        libxrender.so.1
ELF	7efe6000-7f000000	Deferred        version<elf>
  \-PE	7eff0000-7f000000	\               version
ELF	f74a0000-f74a6000	Deferred        libxxf86vm.so.1
ELF	f74a6000-f74a9000	Deferred        libxinerama.so.1
ELF	f74a9000-f74af000	Deferred        libxdmcp.so.6
ELF	f74b0000-f74b4000	Deferred        libdl.so.2
ELF	f74b4000-f7618000	Deferred        libc.so.6
ELF	f7619000-f7632000	Deferred        libpthread.so.0
ELF	f7632000-f7775000	Dwarf           libwine.so.1
ELF	f7777000-f777a000	Deferred        libxau.so.6
ELF	f777a000-f7780000	Deferred        libuuid.so.1
ELF	f7791000-f7799000	Deferred        libsm.so.6
ELF	f779b000-f77b9000	Deferred        ld-linux.so.2
ELF	f77b9000-f77ba000	Deferred        [vdso].so
Threads:
process  tid      prio (all id:s are in hex)
0000000e services.exe
	00000032    0
	0000001e    0
	00000018    0
	00000017    0
	00000015    0
	00000010    0
	0000000f    0
00000012 winedevice.exe
	0000001c    0
	00000019    0
	00000014    0
	00000013    0
0000001a plugplay.exe
	00000020    0
	0000001d    0
	0000001b    0
00000025 explorer.exe
	00000026    0
00000033 (D) C:\windows\system32\winevdm.exe
	00000035    0 <==
	00000034    0
System information:
    Wine build: wine-1.4.1
    Platform: i386
    Host system: Linux
    Host version: 3.2.0-4-amd64
stf80
Newbie
Newbie
Posts: 4
Joined: Mon Apr 27, 2015 9:25 pm

Re: Visual dBase 5.7 for Windows

Post by stf80 »

I fixed the crash when creating a new table, I simply changed the function CopyRect16() in the wine source file wine-1.7.41/dlls/user.exe16/user.c from

Code: Select all

BOOL16 WINAPI CopyRect16( RECT16 *dest, const RECT16 *src )
{
	*dest = *src;
	return TRUE;
}
to

Code: Select all

BOOL16 WINAPI CopyRect16( RECT16 *dest, const RECT16 *src )
{
    if (dest != NULL && src != NULL)
	{
		*dest = *src;
		return TRUE;
	}
	return FALSE;
}
and then one can create new tables in dBase just like on Windows 98 SE. I'm not sure what the function is supposed to do if dest or src is NULL but returning FALSE seems to work so far; maybe someone can take a look at the original API documentation from Windows?
jub
Newbie
Newbie
Posts: 4
Joined: Thu Apr 23, 2015 12:17 pm

Re: Visual dBase 5.7 for Windows

Post by jub »

Congrats, that you solved the problem, perhaps i will need that patch too.
i have also build a new wine version from git (wine-1.7.41-148-gabd673b) on a mac.
I figured out, that when i start notepad and try to print, i receive this error:

Code: Select all

err:commdlg:PRINTDLG_ChangePrinterW DocumentProperties fails on L"CUPS_PDF"
fixme:commdlg:PRINTDLG_UpdatePrintDlgW No lpdm ptr?
fixme:commdlg:PRINTDLG_WMCommandW Update printdlg was not successful!
i see a printer dialoge, the printers from the mac are listed, but i cannot click ok to accept it.
I will try to tweak the registry...
stf80
Newbie
Newbie
Posts: 4
Joined: Mon Apr 27, 2015 9:25 pm

Re: Visual dBase 5.7 for Windows

Post by stf80 »

I managed to succesfully print to the cups_pdf printer on Debian Wheezy from notepad. cups_pdf created the output directory ~/PDF with wrong permissions, so I had to do a "chown <myusername>:<myusergroup> /home/<myusername>/PDF -R" as root but then it worked as expected.

Did you start with a clean wine prefix (located at ~/.wine on Linux)? If not try to move the old .wine dir, then run winecfg (the 1.7.41 version you built) to create a new one. The first time I ran the new winecfg it asked me whether to download gecko and some other package, which I confirmed. I left all other options in winecfg at their defaults.

I noticed another problem with dBase, btw. For some windows the decorations (title bar and borders) are not properly drawn, e.g. when opening an existing .DBF file. The windows can still be resized and the buttons in the title bar can be clicked on and are drawn when doing so, so this is more of a cosmetic problem. Changing the graphics option in winecfg did not seem to have any effect. The window decorations are always drawn on Windows 98 SE (running in a VirtualBox instance). The types of windows affected are tables, queries, forms and windows opened through the menu options, but not others, e.g. the control center and command window, graphics and catalogs. The console message from Wine that appears when opening some (but not all) of the affected windows is:

Code: Select all

fixme:commdlg:GetOpenFileName16 custom templates no longer supported, using default
fixme:commdlg:GetOpenFileName16 custom hook 0x15670000 no longer supported
jub
Newbie
Newbie
Posts: 4
Joined: Thu Apr 23, 2015 12:17 pm

Re: Visual dBase 5.7 for Windows

Post by jub »

Starting with a new .wine directory as you mentioned was the right thing.

But visual dBase has other problems. I used dosbox and trief to combone wine and dosbox (or install win 3.11). But no changes
Locked