Updates: Jan.’08
1. Preface
Half Life 2 and Counter Strike are two of the most popular First Person Shooters available. These games are available for Windows PCs in first place. A growing number of people uses Linux as their major operating system and does not want to renounce their favored games.
This HOWTO should make it possibly for anybody to get Steam working with Wine.
Please follow every step just as it is described here, unless you’re asked to skip some steps.
2. Preparations
2.1. Downloading Wine binaries
Download the latest Wine from
http://www.winehq.org/site/download
(http://www.winehq.org/site/download-deb for Ubuntu/Debian)
or use your distribution-specific packaging tool to install Wine. For example, Debian and Ubuntu users may just use apt-get install wine after adding Wine repositories (s. above)
Wine versions 0.9.7 to 0.9.10 have an OpenGL regression which may cause bad performance in Half-Life 1 based games. Use the newest version instead (0.9.11 or newer).
Now run wine without any parameters. When wine is run for the first time, it creates all necessary directories, including your fake C: drive, which is per default located in ~/.wine/drive_c.
2.2. Compiling Wine from CVS
Instead of using binaries, you may compile the latest source yourself. You may use WineCVS to compile Wine from CVS.
http://winecvs.linux-gamers.net/
Needed apps, packages, libraries:
wget, fontconfig, freetype2, freetype2-devel, bison, flex, libjpeg, libjpeg-devel, libpng, libpng-devel, zlib, zlib-devel, xorg-x11-devel (resp. XFree86-devel), Mesa (resp. xorg-x11-Mesa, XFree86-Mesa), Mesa-devel (resp. xorg-x11-Mesa-devel, XFree86-Mesa-devel), freeglut, freeglut-devel
Debian or Ubuntu users can just use:
apt-get install cvs build-essential bison flex-old libasound2-dev x-window-system-dev libpng12-dev libjpeg62-dev libfreetype6-dev libxrender-dev libttf2 libttf-dev msttcorefonts libfontconfig1-dev
Change to the location where the WineCVS.sh is lying and start it with:
sh WineCVS.sh
The script downloads with wget a archiv defaults.tar.gz with the need install scripts. After that you should see its installation menu.
Select a profile … follow the steps…
… done!
Compilation and installation successful.
2.3. Downloading Microsoft core fonts
Steam requires the tahoma.ttf font. It is NOT included in the Microsoft core fonts package, so you have to get it separately.
For example, google for “filetype:ttf inurl:tahoma”, download it and put it into your ~/.wine/drive_c/windows/fonts directory.
3. Installation and Login
3.1 Steam
Simply change to the directory where you downloaded SteamInstall.exe and type
wine SteamInstall.exe
If you downloaded the MSI version of Steam installer, type wine msiexec /i SteamInstall.msi
The install should go fine, and after it’s completed and wasted your time “updating” steam (it generated strangely small amounts of network traffic) Steam will launch. Create an account or log in, then add Counter Strike to your list of games.
Steam may crash when updating at 27%. If it does so, follow the instructions described here.
3.2 Half-Life 2
3.2.1. Installing Half-Life 2 from the CD
Just type wine msiexec /i /path/to/HL2/steam.msi and Half-Life 2 will be installed.
4. Login
Start steam by just typing wine Steam.exe after you changed to the directory you installed Steam. Once you are sure that there’re no troubles with Steam and it runs fine, start it like that:
WINEDEBUG=”fixme-all” wine Steam
This suppresses all FIXME’s Wine is trying to print while in normal mode. Steam and Steam games run this way faster (especially Half-Life 2 and its mods).
With latest Wine and Steam you should actually be able to type your login data into steam. If you can’t type in your login, just right-click on the Login edit control in the Steam button and then left-click on it again to make the menu disappear. Voila! You can type your login now.
<!–
4.1 Additional Half-Life 2 settings
If you find that the performance is rather low or encounter any graphic glitches, disable the pixel shaders in winecfg.As of Wine 0.9.12 the performance improvements are minimal and you may get additional graphic glitches without pixel shaders so this option is not recommended anymore.
–> <!–
4.1 Optimizing Steam
If Steam or one of the HL1/2 based games are running very slowly you should try the following command promptnice -n -20 wine “PATHTOSTEAMHERE”
This gives steam top priority before all other apps so it can get the processor power it needs to function correctly.
–>
5. Command Line Options
For a while now, Half-Life has depended on the Steam platform to operate (and HL2 has always depended on this, especially if you didn’t buy the CD edition).
The old “hl.exe -game XXXXXXX” behaviour is no longer appropriate, as all valve-sanctioned mods are now executed with “Steam.exe -applaunch NN”.
Half-Life Mods:
cstrike - applaunch 10 tfc - applaunch 20 dod - applaunch 30 dmc - applaunch 40 op4 - applaunch 50 ricochet - applaunch 60 valve - applaunch 70 czero - applaunch 80
Half-Life 2 Mods:
cstrike - applaunch 240 dod - applaunch 300 hl2mp - applaunch 320
Similar to the way you can add command variables to the Steam Launch Options, you can also add them to a Half Life 2 startup script.
#!/bin/bash WINEDEBUG=fixme-all wine C:/Program\ Files/Steam/Steam.exe -fullscreen \ -width 1024 -height 768 -applaunch 220 \ -heapsize 512000 +map_background none "$@"
The above command line will launch Half Life 2 (-applaunch 220) with a memory allocation of around 500MB (-heapsize 512000), and Half Life 2 will start without a 3D background on the main menu (+map_background none). You can add as many variables as you want :)
Command Line Commands
-heapsize [Kilobytes]: This command tells Half Life 2 to allocate more RAM to the game system heap, where it can be accessed by the game to improve performance by storing more game information in RAM and hence reducing loading pauses. The default heapsize is 64MB, however you can safely allocate around 128MB (i.e. -heapsize 128000) for most systems. You can use higher values if you have more RAM, but I don’t recommend exceeding half your physical RAM (e.g. for 1GB RAM, set heapsize of 512000).
-console: Speeds up the loading of Half Life 2 at startup by not loading up the background 3D graphics on the main menu and instead loading up a blurry background picture and the Half Life 2 console open. Note you can close this console using the ‘~’ key.
-width [pixels] -height [pixels]: Using these two commands you can set a custom resolution in Pixel Width x Pixel Height (e.g. -width 640 height 480 starts HL2 with 640×480 resolution). Make sure you choose a resolution supported by your monitor and with the correct ratio of width to height (usually 4:3).
-dxlevel [version]: Using this command allows you to force Half Life into only using the specified DirectX version for shaders. For example, use -dxlevel 70 to force Hardware DirectX7.0 level support for shaders. This means a reduction in image quality but an increase in performance. Other values include -dxlevel 80 -dxlevel 81 and -dxlevel90. Note that this only works if you choose a DirectX version which is lower than the current one supported by your graphics card. See the Hardware DirectX Version option under the In-Game settings for more details.
-refresh [Hz]: Specifies the refresh rate the game will use upon loading. This is normally not required as your system should already use the optimal refresh rate at your chosen resolution. However if this is not the case you can force it to a specific refresh rate (e.g. -rate 85). Make absolutely certain that the rate you are trying to apply does not exceed your monitor’s capabilities otherwise you may damage your monitor - especially if you change resolutions and forget to change this option.
-novid: Disables the intro video so that Half-Life 2 loads a bit faster.
7. Troubleshooting
Q: When I minimize Steam, my X crashes! I’ve to reboot/do Ctrl-Alt-Bksp. etc.
Don’t minimize Steam. Close it instead, and if you wish to open some window again, use the system tray icon (in Wine-Systray for some desktop environments) to restore the window you want. This is a known bug in Wine versions prior to 0.9.31.
This bug has been fixed in Wine 0.9.31 and newer, so if you are using the latest Wine version (the one you should use anyway), you can safely minimize Steam.
Q: When I start a game Steam is staying on top of the game window!
Start the game and then close Steam windows when you see the “Preparing to launch …” window.
Q: Steam runs fine but the game freezes on start.
Try setting the OSS sound driver in winecfg.
Q: Steam and games run fine, but the sound lags behind! I am already using the OSS driver!
First, make sure that none of the sound daemons like artsd or esd are running. If this still doesn’t help, try setting the Hardware Acceleration setting to Emulation in winecfg.
Q: I’m on Ubuntu Breezy, SuSE 10.0 or another older distro with a kernel 2.6.14 or older. Steam randomly freezes.
Use uname -r to check your kernel version. If it’s older than 2.6.15, upgrade to kernel 2.6.15 or newer.
Q: Steam crashes at 26% of the update with a “Sharing violation”
Run the following command in the console (substitute the path to steam executables with your path)
-
wine SteamTmp.exe SelfUpdate “C:\Program Files\Steam\Steam.exe” 14
-
killall wine
killall wine-preloader
killall wineserver
wineboot
<!– this is redundant and won’t work anymore or
–>
Q: When I try to run Steam following message appears:
-
Steam.exe (main exception): Cannot open blob archive file: CMultiFieldBlob(mem-mapped file): Failed to MapViewOfFile
Sadly, ntfs-3g and/or Wine are currently unable to work with a NTFS-based installation of Steam, so you must move your Steam to another filesystem.
Authors: Andreas ‘GlaDiaC’ Schneider, Leon “kommerck” “leadazide” Freitag, Severin ‘gripir’ Friede
Special thanks to Special thanks to Roderick Colenbrander, Vitaliy Margolen and Wine Team
UPDATE 0.49.x (25.11.07): When loading CS:S you see the loading screen (that with the two CT guys) and then you get a black screen, see the loading screen again and then the game crashes/doesn’t launch, then here is what might help:
1. Launch regedit -> wine regedit
2. Navigate to [HKEY_CURRENT_USER\Software\Wine\Direct3D]
3. Add a String with the name “VideoMemorySize” , and then amount of video RAM you have, ex: 256
Similar & Related Posts:
- Why We Need an Open Source Second Life
- Gaming: Valve’s Source Engine Coming To Linux
- Wine Gaming: Call Of Duty 4 (COD4)
- Wine/Cedega/Crossover Games: Windows Gaming on Linux
- Linden Lab liberates Second Life client software
- Preview: Transgaming Cedega 6.0
- Record a Desktop Video on SLED
- Game Emulation In Linux
- Gaming: Cedega 6.0 “Swordfish” Released
- Quake IV for GNU/Linux





Get FREE daily updates via Email:






