• Welcome to Overclockers Forums! Join us to reply in threads, receive reduced ads, and to customize your site experience!

How-to: Linux Gaming Explained

Overclockers is supported by our readers. When you click a link to make a purchase, we may earn a commission. Learn More.

Caedis

Linux Gaming Guru
Joined
Jun 22, 2007
Location
Texas, USA
One popular myth I hear often usually revolves around a sliver of old truth. “Linux can’t play games.” This sliver of truth was derived from the day’s not too long ago when playing commercially available mainstream games wasn’t an option to Linux users. Granted there were some exceptions to this rule, like EVE Online, and Doom 3. But this myth has kept many unwitting gamers stuck on windows for all the wrong reasons. Allow me to lift the veil on modern Linux gaming.


Click to enlarge

Linux, and more specifically Ubuntu Linux, has come a long way in a short period of time. Many game developers and freelance Open Source coders are making major strides in gaming tech for us Linux gamers, opening the door on a hidden market that seemed impossible to get into. Much of this success can be attributed to the many developers and supporters of the Wine Project a compatibility environment for Linux that allows Windows programs to run seamlessly in Linux. Wine is actually an acronym that, ironically enough, stands for “Wine Is Not an Emulator.” This is true of it when you launch a program in Wine. It actually runs the program like any other Linux program and as you can see in the many screen shots on the Wine AppDB, the programs are indistinguishable from their Windows installed counterparts. The applications to Linux gaming are limitless with this technology.


Click to enlarge



So how do I get wine Working?


Go to your "Synaptic Package Manager" under System > Administration > Synaptic Package Manager

Then head over to the repositories section:
synaptic1.png


Add one of the following apt lines to your repositories list based on which version of Ubuntu you have installed:

For Ubuntu Jaunty (9.04):
Code:
deb http://wine.budgetdedicated.com/apt jaunty main #WineHQ - Ubuntu 9.04 "Jaunty Jackalope"

For Ubuntu Intrepid (8.10):
Code:
deb http://wine.budgetdedicated.com/apt intrepid main #WineHQ - Ubuntu 8.10 "Intrepid Ibex"

For Ubuntu Hardy (8.04):

Code:
deb http://wine.budgetdedicated.com/apt hardy main #WineHQ - Ubuntu 8.04 "Hardy Heron"
synaptic2.png


Next Download Scott Riche's GPG key here by right clicking and hitting save as... (He is the maintainer of the Ubuntu Wine Repositories)
You'll need to pay careful attention to where the .gpg file is saved as you'll need to navigate to it.

Next you need to actually import the .gpg key file you just downloaded. You've most likely saved the .gpg to your home directory so just navigate to it by clicking "File System" then clicking home > your user name > then the .gpg file.
synaptic3.png


You'll notice the red highlighted area in the picture above, that line is added if you correctly imported the key (minus the red highlighting I added)

At this point you can hit close on everything, even Synaptic itself.

Open a Terminal ( Accessories > Terminal )

Update your sources list
Code:
sudo apt-get update

Then install Wine!
Code:
sudo apt-get install wine

The beauty of this is that Wine will self update and wont require you to do any fancy compiling every time it's updated. You'll be updated to the latest build any time it's pushed out.

Now, the fancy part that you may need to do in order to make some games run.

Still in the terminal type the following to get Winetricks

Code:
wget http://www.kegel.com/wine/winetricks

This next part I must caution anyone using is restricted only to people who own copies of any version of Windows, as it relies on software that is copyrighted by Microsoft. So if you legally own ANY version of Windows your fine.

Code:
sudo apt-get install cabextract
And once that's installed
Code:
sh winetricks vcrun6 allfonts allcodecs dotnet11 dotnet20 directx9 comctl32 comctl32.ocx fontfix mfc40 mfc42 msls31 ole2 pdh urlmon wininet native_mdac

You'll have to set through a long line of windows EULA'S where you sell your soul to Microsoft forever and agree that you have a License of Windows basically. Accept them and just click next and Finish. don't mess with any of the settings as the defaults work fine for all of them. Even the install paths.

After that, for most game you can just install them like you normally do in Windows, using the CD's and standard installers.

If you need to check if a program works, or you are having issues with a game in particular head over to the Wine AppDB and do a search for the game. Most have how-to's. If anyone still cant figure out how to get a game going feel free to reply here or PM me.

If you don't use Ubuntu Linux you can see specific Wine instructions here.

I have the following games running on Ultra High settings at ~60+FPS
  • Fallout 3
  • Spore
  • Left 4 Dead
  • Counter Strike: Source
  • Half-Life 2
  • Garry's Mod
  • The Elder Scrolls: Oblivion
  • The Elder Scrolls: Morrowind
  • World of Warcraft
  • Guild Wars
  • City of Heroes
  • Starcraft :)

TIP: Pulse audio wrapper
I learned about this recently from a freind.

If you are having the common issue that you can't listen to music or watch videos with sound while a WINE game is running append "padsp" before wine calls to wrap the wine program in a pulse audio wrapper. This let's it play nice with other Linux apps. I have no clue why this isn't implemented by default in Wine, but it works, and it works GREAT.

This is how I launch steam so all my steam apps are in the wrapper:
Code:
padsp wine /home/caedis/games/Steam/Steam.exe


All benchmarks pertain to my Sig Rig. This is the first set of benchmarks I'll be posting. Once I have my dual terrabyte array I'll install windows on my old (Current) 300GB hard drive and run benchmarks of a few popular Windows games that have benchmarking software built in. (Like Source games and a few others)

For directions on how to install and use this benchmark, click here





A word on GPU Manufacturers
While great strides have been made on the GPU drivers side most Linux Gamers agree that at this time ATi is lackluster in comparison to Nvidia's support. I personally know a few friends that attempted to install Ubuntu using the same methods I described above and were experiencing crashes and artifacts sporadically while playing games that my Lower powered Nvidia GPU had no issues with. ATi has made their drivers open source but that doesn't help when no one is there to develop them. Whereas one can easily download the Nvidia drivers directly from their site and quickly install them without problems. So at this time if you have the option, avoid ATi for Linux gaming as you'll be getting less than positive results.

Links:




Original excerpts from this thread located on my blog at Caedis.net
 
Last edited:
I intent to try this and see how it works out. I haven't done wine tricks or whatnot just regular old wine. maybe tomorow i will crack open some windows games and see whats up
 
Yeah, winetricks is the best kept secret in Linux gaming and it is the single most important part. Most games require DirectX, so it makes sense that you'd have to have DX installed in order to play them. Also the fonts are key in making some picky games work properly (Like EVE and the Source Engine)

Also make sure you have Wine 1.1.20 the development version. I have seen pointed improvements in Wine on this version.
 
Last edited:
Maybe this is a tad premature but I may smell Sticky...

I will be giving this a try later this week or first of next. I think Halo and FarCry will be my test subject's.

What about DirectX... where is that installed....or is OpenGL being utilized??
 
Maybe this is a tad premature but I may smell Sticky...

I will be giving this a try later this week or first of next. I think Halo and FarCry will be my test subject's.

What about DirectX... where is that installed....or is OpenGL being utilized??

If you look closely at the wine tricks line it installs DX9.

Also, check with the AppDB on any program you may want to install as it could save you a tone of headaches.

I know for a fact that Halo 1 is Platinum and Halo 2 is Bricked by Microsoft.

Also, I am working with Farcry at this time to get it to work. In all honesty I got sidetracked when I got Fallout 3 working. So FarCry took a backseat for a while.

If you have issues with FarCry let me know. I'll see if I can get it working.
 
What about DirectX... where is that installed....or is OpenGL being utilized??

Sorry forgot to answer the second half of that question. Yes, and no.

OpenGL is preferred when a application has the option to run in that mode out of the box. (Like World of Warcraft)

BUT, if a game is strictly DX only then wine essentially just translates the function calls to what ends up being openGL. Sounds crazy, i know. But it's clear to see that though this sounds like an emulator, it really isn't. This isn't virtual box or VMware either. it really just translates the calls to hardware into Linux friendly calls in real time. If a program has messy code and requires random DLL's found only in strange parts of the OS designed to validate that your running windows, obviously the program wont work right, or at all. But if the program is tightly coded then it's relatively trivial to play it in Wine.
 
Oh, most defiantly. But I think there's a sticky listing those and other native binaries for Linux. I wanted to communicate to people that linux is just as capable of playing Windows games as any other Vista install. Of course its more involved but, IMHO, the system wide benefits of using Linux outweigh the temporary discomfort of getting a game working. I get so tired of the masses stating so confidently that "Linux is just not a viable gaming platform"


- - - - - - - - - - - - - - - - - - - - -
Posted from my Blackberry
 
Last edited:
As a side note, some setup.exe's need to be run in a virtual desktop
From the wine configuration menu, add an application, point to the setup file, click on the graphics tab,
Emulate virtual desktop, then choose your resolution.

For example, fear would not take my full cd key until i did this
 

Attachments

  • Screenshot.jpg
    Screenshot.jpg
    41.6 KB · Views: 4,203
This is true for some games but not all. as always check the AppDB first to see if the game has anything above a "Garbage" Rating, attempt to install and play, if that doesn't work, check the AppDB again for work arounds. If that doesn't work, well, were here.
 
"Video memory is critically low. This application will now quit, it is recommended that you restart you computer"

Getting that error when loading up a scrapbooking program for my wife. I imagine that it would also show up if I tried to load a game which would require a bit more from my 9800gt.

Suggestions?
 
"Video memory is critically low. This application will now quit, it is recommended that you restart you computer"

Getting that error when loading up a scrapbooking program for my wife. I imagine that it would also show up if I tried to load a game which would require a bit more from my 9800gt.

Suggestions?

Actually... no.

Each program is a case by case issue. If your having problems with one particular app it has very little chance of being the same problem with anther. The only caveat would be in the case of a poorly compiled install, or faulty Linux system driver, etc. In which case the same problem would appear most likely.

So don't let a scrapbooking app stop you (or anyone else) from trying out your favorite games in Linux.

What is the name of the scrapbooking app thats causing you problems?
 
Actually... no.

Each program is a case by case issue. If your having problems with one particular app it has very little chance of being the same problem with anther. The only caveat would be in the case of a poorly compiled install, or faulty Linux system driver, etc. In which case the same problem would appear most likely.

So don't let a scrapbooking app stop you (or anyone else) from trying out your favorite games in Linux.

What is the name of the scrapbooking app thats causing you problems?

Oh trust me, not much, if anything could stop me from using Linux for everything I could possibly do with it. Windows and its crap isn't worth putting up with just to game.

The program is called "Art Explosion Scrapbook Factory Deluxe" Was a Valentines/Thanks for letting me spend 1700 bucks on my new i7 gift to my wife. Its pretty much the only reason we keep windows on this rig.
 
Update: Added an enhanced winetricks script for greater application compatibility.
 
ATi has made their drivers open source but that doesn't help when no one is there to develop them. Whereas one can easily download the Nvidia drivers directly from their site and quickly install them without problems.

Both of those phrases are utterly wrong. There have been and still are tons of various issues with nvidia drivers (especially when a new kernel or X or mesa-glx comes out) and ATI has not opensourced a single line of driver code but they have released documentation for their chips, something nvidia has not. And there are people developing ATI drivers (radeon and formerly radeonhd) based on this documentation.
 
Caedis, with your how-to guides, I am finally going to make the leap into linux, especially since you have made this one. Thanks a ton and I will be putting linux (probably ubuntu) on my comp soon. :beer::beer::beer:
 
The only thing I'd like to point out, is that by installing the dll for directx and all you've made your install "dirty", aka you no longer are using completely open source software. The wine project is attempting to rewrite all the dll from scratch, having never seen any microsoft source code. They are moving along very nicely but they aren't there yet. I personally, even though I own a copy of window, don't use wine tricks for installing any microsoft software. (Although I recently installed .net 2 as I'm helping Harlam with his folding monitor in linux via wine, but soon we'll be switching to mono).

Great guide, but I just don't like how you make it seem like using directX is a simply no need to think about it thing. By installing it you are giving up your free as in speech software, for that small portion. Also it's wine's policy that in the appdb it should all be based on internal dll's and not how does it run with microsoft dll's installed. So ymmv when reading the appdb, when following this approach. (More apps should work that might be listed as not working)
 
Getting the following error on the last step.
HTML:
0[21b1f0]: nsNativeModuleLoader::LoadModule("C:\windows\gecko\0.9.1\wine_gecko\js3250.dll") - Symbol NSGetModule not found
err:rundll32:WinMain Unable to load L"streamci"
err:rundll32:WinMain Unable to load L"streamci"
err:rundll32:WinMain Unable to load L"streamci"
err:rundll32:WinMain Unable to load L"streamci"
err:rundll32:WinMain Unable to load L"streamci"
 
Back