Wine

From HerzbubeWiki
Jump to: navigation, search

This page is about Wine, the software that is not a Windows emulator, and how to use it on Mac OS X.


References


System requirements

  • Intel Mac
  • It is also recommended to install XQuartz before installing Wine (or at least, before you build Wine from source).


How to get it

  • Build it from source, either via the Fink project, or via MacPorts (I prefer Fink)
  • Get it packaged via one of the following projects
  • There are also various commercial products from CodeWeavers, such as CrossOver Games, that include Wine. Pricing at the time of writing is between USD 40 and USD 60, depending on the product type.


Wine Prefixes

It appears to be common practice to have different versions of Wine hanging around so that the right version can be used to run specific programs. Each version of Wine is installed into its own location, specified using the configure option --prefix.

A Wine prefix therefore means simply: A specific Wine version or instance installed in a distinct location.

From the Wine FAQ: "It is also recommended that applications being run with different Wine versions be installed into separate wineprefixes."


How to use it

Wine

TODO


PlayOnMac

First run:

  • This is a little weird...
  • When it is first run, PlayOnMac runs a wizard that performs a few tasks, among them is downloading Microsoft Fonts from an (as yet) unknown source
  • The wizard also tries to start XQuartz, but for some reason this did not work on my system. The same PlayOnMac window appeared over and over again, until I manually launched XQuartz. The wizard noted this and then stopped its "fumbling". Nothing else happened, instead I was left with the PlayOnMac main window...


Storage

  • After rummaging around a bit, I found that PlayOnMac stores its files in ~/Library/PlayOnMac
  • Notably, Wine prefixes are stored under ~/Library/PlayOnMac/wineprefix


Install applications:

  • To get an application installed from a CD-ROM, click the "CD-ROM" button in the application toolbar
  • This launches another wizard which tries to detect the appropriate executable to run on the CD-ROM (usually autorun.exe)
  • One can then select the Wine prefix to install into - the initial prefix that was created automatically is named "playonmac"
  • The installer is then run under Wine


Creating a wrapper:

  • Select an application in the PlayOnMac main window
  • Click the toolbar button "Package"
  • You have the choice to create a standalone package (which copies the entire Windows program and other stuff into the application bundle) or a PlayOnMac package (which depends on PlayOnMac being installed and the Windows program residing at the location when the application bundle was created)
  • The resulting application bundle is always created on the desktop. An application bundle already present is overwritten without warning!!!


WineBottler

A GUI for

  • Managing existing prefixes
  • Installing a few predefined prefixes (notably various versions of Internet Explorer)
  • Creating your own custom prefixes. This obviously is the most interesting part of WineBottler, but it requires a little bit of understanding of Wine. I'll try this later... (here are some docs)

Side note: WineBottler includes winetricks, a "quick and dirty script to download and install various redistributable runtime libraries sometimes needed to run programs in Wine."


Wineskin

Wineskin is "a tool used to make wrappers to run Windows software on Mac OS X. The wrappers are in the form of a normal Mac Application, which can be double clicked and ran just like its native."

The manual.

  • The Wineskin Winery application is used to create and manage wrappers around a Windows program so that it can be run standalone as if it were a regular Mac OS X application
  • A wrapper is formed by combining
    • A version of XQuartz
    • A version of Wine
    • A Wineskin wrapper
    • The Windows program


Engines:

  • A copy of XQuartz and Wine together form a Wineskin engine
  • When the Wineskin Winery application is run for the first time, it doesn't have any engines included, so you need to first download one or more of them
  • By clicking the "+" button, Wineskin Winery connects to the Wineskin website and offers you a number of engines for download
  • For my first attempts I simply fetched the engine with the most recent version of Wine ("WS7Wine1.3.13" at the time of writing)
  • Apparently this is not always the best choice, as some Windows programs may run best with older versions of Wine
  • Engines (and other Wineskin data) are placed under
~/Library/Application Support/Wineskin


Wrappers:

  • When the Wineskin Winery application is run for the first time, it doesn't have any wrappers included, so you need to first download one
  • By clicking the "Update" button, Wineskin Winery simply downloads the most up-to-day wrapper available from the Wineskin website ("Wineskin-2.0" at the time of writing)
  • To create an actual wrapper, click the "Create new blank wrapper" button. You are now prompted to specify a wrapper name.
  • After a while there is a question about installing "Wine Gecko". Say "no" here unless you need a browser to access the internet inside the bundle
  • The application bundle is now created under
~/Applications/Wineskin
  • To install software inside the application bundle, simply double click the bundle and select the install option
  • You are then prompted to choose the executable to run, for instance this may be an autorun.exe on a CD-ROM
  • I encountered the following problems on my first install:
    • The keyboard did not work, I had to use copy&paste to enter the license key required by the installer (right-click in the input field and select "Paste" from the context menu)
    • When prompted to insert additional install CD-ROMs, the path detected by the installer was incorrect - I had to manually select the correct CD-ROM drive
  • After the install is done, Wineskin will detect new executable files and prompt you to select one. This selection is what will run when the wrapper is double-clicked in Finder, so it needs to be the programs main executable file. This can be changed later in Wineskin.app under Advanced.
  • If Wineskin.app needs to be run instead of the Windows program, either press the Alt/Option key while double-clicking the bundle, or navigate inside the bundle and run Wineskin.app from there


General Tips

Hybrid CD-ROMS

Hybrid CD-ROMs can be mounted so that they are seen as if on Windows:

  • Insert the CD-ROM
  • After it is mounted automatically, check the device in Terminal:
mount
[...]
/dev/disk1s1s2 on /Volumes/Myth II (hfs, local, nodev, nosuid, read-only, noowners)
/dev/disk1s1 on /Volumes/myth (cd9660, local, read-only)
* As an admin user, unmount the CD-ROM volume
 sudo umount /dev/disk1s1s2
* As an admin user, re-mount the CD-ROM
<pre>
mkdir /Volumes/foo
sudo mount_cd9660 -er /dev/disk1s1 /Volumes/foo
  • Tested on Mac OS X 10.6. On other systems, possibly some "imagination" is needed to choose the correct device
  • Source for this tip was this article on Mac OS X Hints.


Applications

Neverwinter Nights

  • Using Wineskin
  • Keyboard does not work during installation -> license keys must be entered via copy&paste (right click and paste from the context menu)
  • The initial HotU installation does not recognize the CD-ROM, which makes play impossible
  • The update process (1.62 to 1.68 or 1.69) from within the program also does not work because the updater program is unable to connect to the Bioware website
  • This can be fixed, though, by editing the following registry entry: HKEY_LOCAL_MACHINE -> Software -> Bioware -> NWN -> NWUpdate -> Internet Connect = 1 (thanks to doh123 for this!)
  • Now the updater should be able to connect to the Bioware website
  • In my case, the updater did not find a patch file, so I had to manually download and install the patch (NWNGerman1.68HotUUpdate.exe)
  • After the patch was applied, the game suddenly recognized the CD-ROM -> great!
  • The only problem that remains now is that the "movie" sequences are not displayed -> have to press Escape to skip them


SimCity 4

  • Using Wineskin
  • Installer crashes
  • Game also crashes; with a "no CD" patch the game runs but only with resolution 1024x768


Worms 3D

  • Using Wineskin
  • CD-ROM is not recognized


Worms World Party

  • Using Wineskin
  • Game crashes immediately after it's started
  • For possible fixes see the WineHQ AppDB


Myth II

  • Mount the hybrid CD-ROM as a Windows CD-ROM
  • Using Wineskin, perform a full install (be patient while the installer runs its slow course)
  • The game does not run, when it is launched it complains with an error message ("Myth II does not have enough free memory or swap space to launch") and then quits immediately


Sven Zwo

  • Using Wineskin
  • Game crashes immediately after it's started


Carcassonne

  • Using Wineskin
  • Install as per INSTALL.txt (activation must be done via browser)
  • The game runs with a resolution of 1600x1002, but this is quite slow
  • Change Wineskin's screen settings to the following
    • Override Wine control of Screen Settings = true
    • Choose the "Rootless (windowed)" mode
    • Choose "Virtual Desktop"
    • Set the resolution to 1152x864
    • Decorate windows = true
    • Note that any other settings (fullscreen or normal windows mode) cause the game to crash