Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I target Windows 98?

I have a pressing need to develop an application for Windows 98, and do not have the option of using a different operating system. In this day and age, is there any modern SDK that I can use to develop the application? What would be awesome, is if there was some way to target Windows 98 from Visual Studio 2015 but as far as I know there is no way of doing this.

Can I write and compile an application for Windows 98 using Visual Studio 2015? If not, then what is my next best option?

like image 909
Snoop Avatar asked Sep 08 '25 06:09

Snoop


1 Answers

I assume you are writing native code: Windows 98 uses the Win32-API, like XP and modern Windows versions too. Some things are different, e.g. APIs like VirtualAllocEx() are missing. If you avoid these APIs (https://msdn.microsoft.com has a minimum requirements section for each API) and write native code, your program should run on Windows 98 too. If you have problems with Visual Studio, you can use good old gcc and an IDE like Eclipse, Code::Blocks, etc. Just make sure you don't compile it for the 64-bit plattform. Otherwise you will get a PE+ binary which won't run on Windows 98.

EDIT:

According to the discussion in the comment sections a few updates: Although a PE for 32-Bit (compiled on a modern Windows box) is compatible to Windows 98, there might be problems with Visual Studio due to its runtime library. As an alternative, you could try to

  • compile without runtime
  • use MingW as it uses msvcrt.dll

Nevertheless, it is still tricky to check which Windows version supports certain APIs due to updates in the MSDN. An older copy of the MSDN could help at this point.

like image 122
Christian Ammann Avatar answered Sep 10 '25 07:09

Christian Ammann