Chapter 5. Using CrossOver Linux

Table of Contents

Running Windows applications
Running from the menu
Running a Windows command
Running Windows applications from the command line
Stopping misbehaving programs

Running Windows applications

Running from the menu

An example of the Applications/CrossOver folder in your home directory is shown below. You can navigate inside of this folder and launch applications just as you would from any other Finder window on your Mac.

On most operating systems and desktops, Windows application installers will create links in your application menu. On KDE you will be able to run CrossOver applications from the "K" menu, on GNOME by clicking on the "foot", and on Red Hat by clicking on the hat.

Windows applications (Word, Excel, etc.) will appear in your Windows Applications menu. Additionally, you will have entries for CrossOver-specific applications in your CrossOver menu, in particular: Install Windows Software, Terminate Windows Applications and Manage Bottles.

If no menu entries are created, you will still have the option of running applications from the command line. You may be able to associate these command lines with the menu yourself, using whatever menu-editing tools are provided by your particular system.

Running a Windows command

The Run a Windows Command menu provides a simple way to run a Windows command-line in CrossOver. This can be a useful way to run standard Wine tools such as regedit or notepad, and can also be used to run applications which fail to create icons or shortcuts.

This tool is available in your system menu, or you can run it from the command line:

$ ~/cxoffice/bin/cxrun

or, for multi-user installs:

$ /opt/cxoffice/bin/cxrun
[Important]

This feature is especially important when there are multiple bottles present. When run from the command-line Wine generally operates on the default bottle. Cxrun provides a simple way to specify an alternative bottle.

Running Windows applications from the command line

Using command line shortcuts

For some Windows applications CrossOver can create simple command-line shortcuts to start the application. If CrossOver is installed in your account you will find them in ~/cxoffice/bin. So for instance if you installed Microsoft Word you would be able to start it by running:

$ ~/cxoffice/bin/winword

For private bottles you will also find these shortcuts in the directories specified in the PrivateShortcutDirs configuration setting, which typically includes $HOME/bin. For published bottles check out the ManagedShortcutDirs configuration setting. It will usually include /usr/bin.

If the Windows application allows it, you will also be able to open documents using these shortcuts by specifying the document path as an argument. For instance:

$ ~/cxoffice/bin/winword letter.doc

For a complete list of the shortcuts available, type the command

$ grep -l desktopdata/cxmenu ~/cxoffice/bin/*
[Tip]

If you install the same application in more than one bottle, the resulting script will point to the most recent installation. So if you install Word 2003 in a bottle and then Word 2007 in another, the winword shortcut will start Word 2007.

Using "wine --cx-app"

You can also start Windows applications by using the wine script with the --cx-app option and specifying the name of the application's executable. So, for instance, Microsoft Word's executable is called winword.exe so you could start it by running:

$ /opt/cxoffice/bin/wine --cx-app winword.exe

Or, if CrossOver is installed for a single user:

$ ~/cxoffice/bin/wine --cx-app winword.exe

Similarly, to open a document in Word you would run:

$ ~/cxoffice/bin/wine --cx-app winword.exe letter.doc

For a complete list of applications that will work with the --cx-app argument, try this:

$ find "~/.cxoffice" -iname "*.exe"
[Tip]

There will be many .exe files on your system that are either system tools or subcomponents of other applications. Running some of these programs could cause unpredictable or destructive things to happen. It's never a good idea to run a Windows applications unless you have a good understanding of where it came from and what it does.

[Important]

Note that Wine will search and run the command in the default bottle unless told otherwise. To run a wine command in a different bottle, specify the bottle like this:

$ ~/cxoffice/bin/wine --bottle bottle-name --cx-app winword.exe