64位Windows上的16位Windows(Windows 1.x、2.x、3.0、3.1等)
16-bit Windows (Windows 1.x, 2.x, 3.0, 3.1, etc.) on 64-bit Windows

原始链接: https://github.com/otya128/winevdm

otvdm(winevdm)是一个修改后的模拟器,可让 64 位 Windows 运行 16 位 Windows 程序和部分 DOS 可执行文件。它可下载,或使用 Visual Studio 2017/CMake 从源代码构建;随后可通过 install.inf 安装,通过 uninstall.reg 卸载;注册表重新初始化可能需要重新安装。它直接执行 Win16 二进制文件,将 Win16 调用转换为 Win32,处理 16/32 位句柄转换,模拟 DOS,并将对 %WINDIR% .ini 文件的写入重定向。它还钩住 64 位 Windows 的 16 位安装程序检测以启动替代方案。DOS 支持不完整;建议使用 DOSBox 或 MS-DOS Player,VDMDOSVER 设置 DOS 版本。命令行用法包括 winevdm.exe [--app-name app.exe]。

黑客新闻 新 | 过去 | 评论 | 提问 | 展示 | 工作 | 提交 登录 64 位 Windows 上的 16 位 Windows(Windows 1.x、2.x、3.0、3.1 等) (github.com/otya128) 4 点 由 doener 16 分钟前 | 隐藏 | 过去 | 收藏 | 1 条评论 帮助 orionblastar 9 分钟前 [–] 终于,64 位 Windows 支持 16 位 Windows 了。 回复 考虑申请 YC 2027 冬季批次!申请开放至 11 月 2 日。 指南 | 常见问题 | 列表 | API | 安全 | 法律 | 申请加入 YC | 联系 搜索:
相关文章

原文

screenshot

Download stable version

Download latest version (unstable)

16-bit Windows (Windows 1.x, 2.x, 3.0, 3.1, etc.) on 64-bit Windows

An altered version of winevdm (a 16-bit Windows emulator), ported to 64-bit Windows.

  • Download or compile
  • Run "install" shortcut or right-click on install.inf and select "Install"
  • You can execute Win16 binaries directly!

If the registry is initialized by Windows Update, perform the above procedure again.

You can uninstall it by running uninstall.reg.

See otvdm.ini.

  • Install Visual Studio 2017
  • Edit PropertySheet.props
  • Compile
git clone https://github.com/otya128/winevdm.git
cd winevdm
mkdir build
cd build
cmake ..
make

This program contains the following items

  • CPU Emulator
    • 64-bit Windows cannot modify LDT(NtSetInformationProcess(,ProcessLdtInformation,,) always returns error)
  • wine based Win16->Win32 conversion codes:
    BOOL16 WINAPI DestroyWindow16( HWND16 hwnd )
    {
        return DestroyWindow( WIN_Handle32(hwnd) );
    }
    Relay routines from 16-bit to 32-bit are autogenerated by convspec
    53  pascal -ret16 DestroyWindow(word) DestroyWindow16
  • DOS emulation for Win16
  • 16-bit <=> native HANDLE conversion
  • Fix compatibility problems, fix compatibility problems

When 64-bit Windows detects a 16-bit installer, it has a mechanism to start an alternative installer which is not 16-bit. This program uses it.

WINDOWS directory redirection

Some Win16 programs try to save their settings in %WINDIR%<filename>.ini

In recent Windows, it is not allowed to save to %WINDIR%, so it redirects.

winevdm.exe [--app-name app.exe] command line
winevdm.exe CALC.EXE

It can also run DOS executables (DOS emulator-like). You can set the DOS version with the VDMDOSVER environment variable.

DOS emulation is incomplete and it is recommended to use DOSBox or MS-DOS Player.

联系我们 contact @ memedata.com