Close
0%
0%

Modern tools for Windows 3.11 software development

An IDE package with integrated Win 3.11/95 emulation (automatically installed from your diskettes), compilers, cross-platform GUI libraries

Public Chat
Similar projects worth following
This is an IDE installer which creates a pre-configured environment that allows rapid GUI application development for Windows 3.11/Win32s (!), Windows 9x or modern targets, even with cross-platform capabilities. It uses a bunch of configuration files, installation scripts, compilers, frameworks, sample C++ projects and wizard templates. This project heavily relies on CodeBlocks and wxWidgets framework.

The main idea was to simplify the process of making simple applications for legacy systems as much as possible (you can create and run a test application for Windows 3.11 in less than a minute thanks to built-in configuration wizard). And thanks to wxWidgets, which miraculously can work with Win32s-extended Windows 3.11, this solution allows you to avoid writing platform-specific code for an ancient system.

Another reason to make this was to just have "fun" (never again) because of 30th anniversary of Windows 3.11 this November.

This package uses your own Windows 3.11 and 95 installation files and a bunch of automated installation script in order to create a programming environment which allows you to run your newly-built C++ software directly in Windows 3.11 with a single mouse click.

Project repository and release files are available here: https://github.com/adbrt/cb-legacy-dev

Video overview and tutorial:

Features:

  • Automatic installer (single batch file)
  • Pre-configured CodeBlocks IDE
  • Windows 3.11 and Windows 95 integrated with IDE (using DOSBox-X): you can build and run the application in Win 3.11/95 with a single mouse click
  • Automatic Windows 3.11/95 installation in DOSBox-X: you provide your own genuine installation disks/CD
  • Mouse and network integration between Win 3.11/95 guests and host system
  • Easy GUI development thanks to wxWidgets and easy-to-use configuration wizards
  • wxWidgets modified to work with Win 3.11 targets (version 2.8.12), version 3.0.5 modified to work with Win 95
  • Unicode for Win 9x targets thanks to MSLU/Unicows (works with wxWidgets 3.0.5)
  • TDM-GCC 4.7.1 for Win9x+ targets, BCC5.5 compiler (needs to be downloaded separately) for Win 3.11/Win32s targets
  • MinGW-w64 and wxWidgets 3.2 for modern 64-bit targets
  • As a bonus: DJGPP and OpenWatcom compilers for DOS (with DOSBox integration)

Cross-platform capabilities:

  • Thanks to the cross-platform nature of GUI framework used here (wxWidgets), you can use the same codebase to build applications for Windows 3.11, 9x or even modern 64-bit Windows. You can even use this code for Linux and macOS apps (however you need to do this manually at the current stage)

Prerequisites:

  • Windows for Workgroups 3.11 English version installation disks - for Win 3.11 IDE integration
  • Windows 95 OSR2 English installation CD (WIN95 subdirectory) - for Win 95 IDE integration
  • free Borland 5.5 C++ compiler - installation script will try to download it automatically
  • drivers and updates for Win 3.11/Win 95 - installation script will try to download them automatically

  • Some tests

    Wojciech "adalbert" J11/19/2023 at 19:46 0 comments

    This is one of the included sample projects: a simple TCP client/server, working on a real Win 3.11 machine and a Windows 11 laptop:

    Here we have a test of a cross-platform application (not quite complete yet). I was able to build a macOS variant using the same code as for Windows 3.11, however that does require manual compilation of wxWidgets and the application files on a Mac. It's not as easy and automated as building for Windows, but it is still possible.

    It's even possible to create a video player for Windows 3.11 (another included sample project):

    It's worth noting that we have mouse and network integration between host and emulated machine, which really simplifies the process of testing Windows 3.11 applications:

    Here is a test of Windows 95 build target, we have automatic execution, mouse and network integration in the same manner as in Windows 3.11:

    There is also working code completion, so this is a huge upgrade compared to some ancient, native programming tools:

View project log

  • 1
    Installation

    You can follow the video tutorial (part 04:24-05:55), or follow written instructions.

    To start, you need to:

    • download the latest release of IDE package from GitHub: https://github.com/adbrt/cb-legacy-dev/releases
      it will contain the installation script, required configuration files and a bunch of FOSS software and required frameworks (CodeBlocks, TDM-GCC, MinGW-w64, wxWidgets, DJGPP, OpenWatcom, DOSBox-X)
    • prepare your Windows 3.11 for Workgroups (English version) and Windows 95 (OSR2 English version - WIN95 subdirectory) installation files in order to run the built-in emulation. You can skip the installation of either of these systems if you don't need it.

    Now unpack the installation files to the directory where you want it to be installed, and execute the SetupCodeBlocks_AllInOne.bat file and follow the on-screen instructions.

    The installer will create a portable installation, everything will be placed into a single directory.

    It will automatically extract included files and download any necessary dependencies. Free Borland C++ 5.5 compiler will be downloaded from Embarcadero website - it is the only not open-source (but still freeware) compiler that will be used. For Windows 95+ applications MinGW can be used instead. CodeBlocks, wxWidgets, utilities, wizards, templates and configuration files will be extracted.

    At some point you will be prompted to paste your Windows 3.11 installation files - a window will pop up:

    Place these files (they can be in a form of disk images) into the directory and press any key to continue. The installer will automatically download updates and drivers for Windows 3.11: Win32S (PW1118.exe), TCP32B (tcp32b.exe), Video for Windows (wv1160.exe), Windows Media Player (MPSetup.exe), WingG 1.0 (wing10.exe), S3 driver (w3117004.zip).

    The same will happen for Windows 95 in the next step, you will need to paste the contents of your WIN95 directory.
    The installer will aslo download necessary drivers and updates for Windows 95: DirectX 7.0A (DX7Aeng.exe), DCOM95 (dcom95.exe), Year 2000 patch (w95y2k.exe), Windows Media Player 6.4 (mpfull.exe), Winsock 2 Update (W95WS2setup.exe), 3Dfx Voodoo Graphics driver (vg-w9x-q3.exe), S3 Graphics driver (w9521103.zip).

    During Windows 95 installation a DOSBox-X window with some automated scripts running will appear, please do not interfere, the Windows system files structure is being created:

    This should be the last step.

    After the installation is done, a file runCodeBlocks.bat will apppear - you can use it to run the IDE.

  • 2
    Creating your first Windows 3.11 application

    This will be a Win32s application, which requires Win32s addon on the Windows 3.11 (already pre-installed in the emulator).
    You can follow the video tutorial (part 05:47-08:54), or follow written instructions.

    Open the IDE by clicking runCodeBlocks.bat.

    Now click "Create a new project":

     Select a wxWidget project template and choose wxWidgets 2.8.x, then the option to execute in Win 3.11:

    Select where you want to save your project:

    Select wxSmith and a Frame Based application with sample elements

    Configure the project as shown here:
    Borland C++ Compiler, Release configuration, no Unicode, other options not selected

    Now you can see a simple GUI for a test application:

    If you want to edit the code, you can double click on the control you want to interact with in your application (e.g. a button), and the editor will appear:

    To build and run the application in Windows 3.11, just press the red Debug button:

    It should execute automatically:
    ** NOTE:  if it doesn't, try saving and reopening the project - this may sometimes happen when the project is first created **

    If you want to run the application on the host machine instead, just press the "Build and run" button:

    You can also add new build targets, either for Windows 95 or modern 64-bit systems by pressing File -> New -> Build target and choosing appropriate frameworks and compilers. Then, you can switch the targets from the drop-down list next to the "Build and run" button.

View all instructions

Enjoy this project?

Share

Discussions

Dan Maloney wrote 11/20/2023 at 19:38 point

Seeing Windows 3.11 like that brings back some memories. Especially those first few VisualBasic 1.0 programs -- like magic! Thanks for posting!

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates