-->
Previous Table of Contents Next


Chapter 23
Wabi

by Tim Parker

In This Chapter
•   What can Wabi do?
•   Installing Wabi
•   Running Windows 3.x applications

Wabi (Windows Application Binary Interface) is a Linux and UNIX application developed to allow Microsoft Windows 3.X applications to run under X and Motif. Wabi acts as a translator between the Microsoft Windows windowing commands and their counterparts under X. By running Wabi your Linux system gets access to most Windows applications, while still retaining all the features of Linux (including its crash resistance, better performance, and window switching).

Not all Windows applications run properly under Wabi. In order to execute cleanly with Wabi, a Windows application has to be “properly behaved,” meaning that the application conforms to all the standards Microsoft laid down for applications to follow. Most standard applications, such as word processors and spreadsheets, behave properly and work fine under Wabi. A few packages, notably games and some graphics tools, deviate from the Microsoft Windows standards in order to get better performance from graphics cards, and these do not run reliably (if at all) under Wabi. Also, with version 2.1 of Wabi (the current release), you cannot run Windows 95 applications.


Tip:  
A list of applications that have been tested and certified to run properly under Wabi is available from a number of sites, including most Linux FTP sites. One such site is:

http://wabiapps.psgroup.com

Don’t be discouraged that all your favorite applications will not run under Wabi. Most Widows 3.x applications do, with the major exception of games. Want to run CorelDraw under Linux? No problem. Want to run Microsoft Office? Again, no sweat. Essentially, if it’s an office productivity tool, it will run (as these seldom have to deviate from the Windows programming standards).


What Can Wabi Do?

As mentioned, Wabi sits in a layer between the Windows application and the X manager. When a Windows application running under Wabi issues a Windowing request, such as opening a new window, changing a title, or modifying fonts, Wabi intercepts the request and converts it to the X equivalent. When an X Windows process wants to send a message to a Windows application, Wabi converts the X message to a Windows message. As long as an application sticks to standard Windows mechanics, Wabi can handle the conversion and allow the application to run under X.

Wabi doesn’t do much by itself. There’s no real Wabi application you can interact with, except for some configuration tools. However, Wabi does have a ton of features that it allows to be performed under X that you will be familiar with from Windows, Windows-based, such as the following:

  Cut and paste between Windows applications
  Enhanced mode support for CPUs
  DOS format disk access
  OLE (Object Linking and Embedding) between Windows applications
  DDE (Dynamic Data Exchange) between Windows applications
  Network support
  Windows sockets programming

Wabi extends most of these features to include the X environment, too, so you can cut and paste between Windows and X applications, interact with network applications under both, and allow multiple users on the same application.

Perhaps more important to most users is what Wabi won’t do. The list is short but does have some important considerations for some Windows applications. Wabi does not support

  MIDI (Musical Instrument Digital Interface)
  AVI (Audio-Visual Interface)
  IPX/SPX networking
  Shared Wabi directories
  VGA-based video drivers
  DOS-disk formatting
  (VDx) virtual device drivers

A number of these unsupported features, such as IPX/SPX and MIDI, can be provided through other Linux subsystems. Wabi is also being improved with new features all the time, so support for these items may be added in the future.

Wabi does not include Microsoft Windows 3.x due to copyright restrictions, so you need to purchase a supported copy of Windows as well as Wabi (although most users have a copy of Windows somewhere).

Installing Wabi

Wabi requires a minimum of 16MB RAM, although 32MB is recommended. At least 20MB swap space is required, although 40MB is better (and more is ideal). The Wabi directory space is about 25MB depending on the version and supported versions of Windows.

Wabi includes an installation script that takes care of all the manual steps you normally would have to do. Simply answer the installation script prompts, and the Wabi software is properly installed. If you use a tar file obtained from a source other than CD-ROM, untarring the file in an empty temporary directory will give you all the files you need, including the installation script. After Wabi has installed itself, it will prompt you for the Windows 3.x version to use. Both Windows 3.1 and Windows 3.11 are supported.

By default, Wabi installs to the /opt/wabi directory, with all binaries stored in the /opt/wabi/bin directory. You can change these defaults, but it’s best to leave them there. Every time you run the Wabi system a personal directory is used, usually called wabi under your home directory. The personal directory, as the name implies, is unique to each login, and every user has one if they run Wabi. Underneath the wabi directory there will be a windows directory containing the Microsoft Windows 3.x program. This implies that each user has his own copy of Windows and that this application can’t be shared. Although there are ways around this, it’s best to stick to the way Wabi was intended to work. You can think of the wabi and wabi/windows directories as the same as a PC’s C:\ and C:\WINDOWS directories.


Troubleshooting:  
If you are running Metro X 3.1.2 and try to run Wabi, your Metro X session will hang. The problem lies not with Wabis but with that version of Metro X. The more recent version of Metro X, 3.1.5 does not cause these problems. Upgrades are usually available from Metro Link, the Metro X vendor. A workaround that solves most of the problem (but does impose a performance hit) is to start Wabi with the -fs option added at the command line.

The current version of Wabi only supports 8-bit color depth (256 colors), but an unsupported interim release that handles 24-bit color depth is available. You should set your X session to use 8-bit colors for best performance.


Previous Table of Contents Next