From 9f46f39f48d3acf4806473b331b654111a6e2084 Mon Sep 17 00:00:00 2001 From: Javier Date: Mon, 30 Nov 2026 12:53:58 +0100 Subject: mousew16: found a way to use the same binary in both 2.x and >3.x What was missing is to use mark.exe (same as the MEMORY option in wlink) to mark the 2.0 executable as being "protected mode compatible". Thanks to Pietrek's Windows Internals book and their description of what LoadModule is doing. --- makefile | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'makefile') diff --git a/makefile b/makefile index 99c3a44..a3f17e7 100644 --- a/makefile +++ b/makefile @@ -64,17 +64,13 @@ mousmain.obj: mousmain.c .AUTODEPEND $(compile_dos) # Windows 3.x mouse driver -vbmouse.drv: mousew16.lnk $(mousew16_objs) +vbmouse.drv: mousew16.lnk dosstub.exe $(mousew16_objs) *wlink @$[@ name $@ file { $(mousew16_objs) } mousew16.obj: mousew16.c .AUTODEPEND $(compile_w16dll) -# Windows 2.x version -# TODO 2.x setup.exe expects an exactly 400byte long stub (option stub=...) -vbmouse2.drv: mousew16.lnk mousew2.lnk dosstub.exe $(mousew16_objs) - *wlink @mousew16.lnk @mousew2.lnk name $@ file { $(mousew16_objs) } - +# stub/fake DOS exec header used in vbmouse.drv, see mousew16.lnk dosstub.exe: dosstub.asm .AUTODEPEND *wcl -fo=$^@ $[@ -\"option fullheader\" -- cgit v1.2.3