leecher1337 / ntvdmx64

Run Microsoft Windows NTVDM (DOS) on 64bit Editions
820 stars 81 forks source link

Installer asks for missing files and install not working #190

Closed matead92 closed 2 years ago

matead92 commented 2 years ago

Hi. I have had an old version of ntvdmx64 on my Windows 10 system for about a year now and it's been working fine until today when I installed a new update from Microsoft. My system was already updated but it was about 1 week out so whatever Microsoft changed in this last week broke it.

I am now running:

Anyway, I managed to get everything compiled and built fine using autobuild-ccpu-fre.cmd, but when finally getting around to running the installer I was faced with errors like CMOS.RAM and MSHERC.COM missing. To get around that, I made a dummy CMOS.RAM file and I found where MSHERC.COM was hiding so I got that sorted, but after installing everything and rebooting my system, 16-bit programs still fail to run.

I should also mention that during the installer (which I ran as administrator and my Windows Defender was disabled), it failed to find all the debug symbols with an error code of 2 for all of them.

I used the latest code from this repo (I didn't use Autobuild v24.04.2022) from 16 days ago.

Oh, there's also a nasty bug in your script. It deleted EVERYTHING after the compilation script finished (IE: when it says press any key to continue and the command console is green) so I had to re-do the compilation process twice. Might want to look into that.

Any suggestions? I need 16-bit programs to run for my work as all our systems here run Windows 10 64-bit and depend on this amazing workaround.

Thanks.

leecher1337 commented 2 years ago

Interesting that msherc.com didn't get binplaced on build, you can check buildchk.log (as long as you don't press the key after the last puase, as you already found out). It should contain:

    binplace -o . msherc.com 

which normally writes it to the output folder. The binplace happens due to instructions of the minnt\base\mvdm\dos\v86\cmd\qbasic\makefile.sub file. So look if that makefile gets executed:

2>  nmake /fmakefile.sub  ALT_PROJECT=USA  ALT_PROJECT_TARGET=.  PROJECT_INC_PATH=d:\bld3\w\minnt\public\internal\base\inc 

I wonder about cmos.ram, it's not mentioned in any .inf file, so it's usually not installed, so why did you search for it?

Anyway, if loading fails, it's likely to be a problem with the loader ldntvdm.dll I.e. you may be missing symbols for instance. Do check the output of the loader, use Sysinternals DebugView. Also ensure that ldntvdm.dll loaders are present in both System32 and Syswow64 directory, as idiot Antivirus Solutions including Windows' own AV tend to delete or block it.

Regarding the deletion of the work directory after keypress: This is intentionally done so that it is ensured that there will be a complete rebuild upon next execution and nothing cached remains on disk that could interfere with future compilation. That's also why there is a pause in there waiting for a keypress, so that user can cancel before compilation directory gets removed again.

matead92 commented 2 years ago

I searched for CMOS.RAM because it asked for the file when installing from C:\NTVDMBLD\ntvdmpatch\release. I am now however trying C:\NTVDMBLD\ntvdmpatch\releases\usa and it did not ask for any missing files.

What do you mean by check the output of the loader?

EDIT: Okay, I got the log: https://pastebin.com/56WrqMfC I cleared the log history so it was empty and then it filled when I tried to run a 16-bit program (which is the log I saved so it was clean for you and not almost a hundred+ lines). If you require the full log though, let me know.

ldntvdm.dll is both present in System32 and Syswow64

image

It says it installs correctly and the I reboot, but I can't run my previously working 16-bit program :(

matead92 commented 2 years ago

Any suggestions? I have the log above for you.

Screenshot 2022-05-11 070917

leecher1337 commented 2 years ago

There you have your problem: There are no debug symbols availabe for your kernel32.dll on Microsoft Symbol Server, thus it is impossible for the loader to work properly. If it is a brand-new update, you may just need to wait 7-14 days and the symbols may become available. If they are still not available after this timespan, I suggest opening a ticket at Microsoft Support in order to notify them of lacking symbols.

matead92 commented 2 years ago

Dammit Microsoft. Okay I'll email them now. Thanks for your help @leecher1337

matead92 commented 2 years ago

Symbols were updated. It's working again now. Didn't need to uninstall or re-install either just so anyone else who runs into this issue knows.

I highly recommend compiling this amazing program into a GUI based program using C++ or C# for people to use, and adding code so you can then check the symbol servers so you can warn people if they are non-existent for the current Windows update/build.