From Gentoo Wiki
Jump to: navigation, search

Steam is an Internet-based digital distribution, digital rights management (DRM), multiplayer, and social networking platform developed by Valve Corporation. Steam provides the user with installation and automatic updating of games on multiple computers, and community features such as friends lists and groups, cloud saving, and in-game voice and chat functionality. - Wikipedia, the free encyclopedia



Steam is a 32-bit application and requires a multilib profile on amd64, unless a chroot is used.


This section can be skipped when using the steam-launcher ebuild from an overlay.
The following dependencies may be outdated and require verification. Some of the libraries may be provided by the Steam runtime, in which case the system library will not be used.

The following packages are required for Steam:

FILE /etc/portage/sets/steam

The following packages are optional for Steam:

FILE /etc/portage/sets/steam

Install the Steam set:

root #emerge --ask @steam

USE flags

The following USE flags are required for Steam on amd64:

FILE /etc/portage/package.use/steam
dev-db/sqlite abi_x86_32
dev-libs/expat abi_x86_32
dev-libs/glib abi_x86_32
dev-libs/libffi abi_x86_32
dev-libs/libpthread-stubs abi_x86_32
dev-libs/nspr abi_x86_32
dev-libs/nss abi_x86_32
dev-util/pkgconfig abi_x86_32
media-libs/libtxc_dxtn abi_x86_32
media-libs/mesa abi_x86_32
sys-devel/llvm abi_x86_32
sys-fs/udev abi_x86_32
sys-libs/gpm abi_x86_32
sys-libs/ncurses abi_x86_32
sys-libs/readline abi_x86_32
sys-libs/zlib abi_x86_32
virtual/libffi abi_x86_32
virtual/libiconv abi_x86_32
virtual/libudev abi_x86_32
virtual/pkgconfig abi_x86_32
x11-libs/libdrm abi_x86_32
x11-libs/libpciaccess abi_x86_32
x11-libs/libX11 abi_x86_32
x11-libs/libXau abi_x86_32
x11-libs/libxcb abi_x86_32
x11-libs/libXdamage abi_x86_32
x11-libs/libXdmcp abi_x86_32
x11-libs/libXext abi_x86_32
x11-libs/libXfixes abi_x86_32
x11-libs/libxshmfence abi_x86_32
x11-libs/libXxf86vm abi_x86_32
x11-proto/damageproto abi_x86_32
x11-proto/dri2proto abi_x86_32
x11-proto/dri3proto abi_x86_32
x11-proto/fixesproto abi_x86_32
x11-proto/glproto abi_x86_32
x11-proto/inputproto abi_x86_32
x11-proto/kbproto abi_x86_32
x11-proto/presentproto abi_x86_32
x11-proto/xcb-proto abi_x86_32
x11-proto/xextproto abi_x86_32
x11-proto/xf86bigfontproto abi_x86_32
x11-proto/xf86driproto abi_x86_32
x11-proto/xf86vidmodeproto abi_x86_32
x11-proto/xproto abi_x86_32

Update the system:

root #emerge --ask --changed-use --deep @world


Steam expects that /dev/shm, which requires kernel tmpfs support, is mounted prior to being started. /dev/shm should be mounted automatically by OpenRC and systemd during boot, but can also be explicitly mounted via /etc/fstab:

FILE /etc/fstab
# to limit the size add e.g. size=768M to opts (default is 50%)
#<fs>      <mountpoint>    <type>	<opts>		     <dump/pass>
shm        /dev/shm        tmpfs        nodev,nosuid,noexec  0 0


Currently Steam only supports Ubuntu 12.04+. Attempting to run Steam on any other distribution may cause issues. Refer to client and games troubleshooting for details.

The Steam installer downloads and installs the Steam client to the users home directory. This prevents Portage from managing the Steam client updates or the software installed by it. The Steam client is solely responsible for managing software installation and updates.


Fetch and extract the Steam installer:

user $tar -xvzpf steam_latest.tar.gz

Run the Steam installer:

user $cd steam
user $./steam

Steam can be subsequently started with:

user $~/steam/steam
The following is recommend with a dedicated Steam user account, to prevent Steam (or the software it depends on) from interfering with the regular user account.

To avoid restarting or running two X servers in parallel, su to the Steam user, and use x11-apps/xauth to give the Steam user access to the running X server. Refer to bash-steam-launcher for details.

Manual with alternative installer script

The following instructions are almost identical to the manual instructions, except that an alternative Steam installer script is used.

Fetch the Steam installer and extract the required files:

user $tar -xvzf steam_latest.tar.gz steam/bootstraplinux_ubuntu12_32.tar.xz
user $tar -xvzf steam_latest.tar.gz steam/steam.desktop

Fetch and run Julian Ospald's (hasufell) Steam installer script:


The steam-launcher ebuild is available from the Gentoo Gamers overlay or anyc's Steam overlay.


It is possible to run Steam in a 32-bit chroot on amd64 without relying on multilib, or the emul-linux-x86-* packages (which are masked and scheduled for removal[1]).

Create the chroot directory:

root #mkdir /usr/local/steam32
root #cd /usr/local/steam32

Fetch and extract the stage tarball:

Copy DNS information:

root #cp -L /etc/resolv.conf etc

Create the Portage directory:

root #mkdir usr/portage

Mount the necessary filesystems:

root #mount -R /dev dev
root #mount -R /sys sys
root #mount -t proc proc proc
root #mount -R /usr/portage usr/portage

Chroot with linux32, which is provided by the sys-apps/util-linux package, and reload the environment:

root #linux32 chroot .
root #source /etc/profile && env-update

Create the Steam user:

root #useradd -m -G audio,video steam

Next, install Steam from one of the above installation methods. When complete, create the following wrapper script to setup the chroot, su to the Steam user, and start Steam.

FILE /usr/local/bin/steam32
mount -R /dev "${CHROOT_DIR}/dev"
mount -R /sys "${CHROOT_DIR}/sys"
mount -t proc proc "${CHROOT_DIR}/proc"
mount -R /usr/portage "${CHROOT_DIR}/usr/portage"
[ -f $CHROOT_DIR/var/run/ ] || chroot "${CHROOT_DIR}" dbus-launch --system
chroot "${CHROOT_DIR}" su steam -c "dbus-launch steam"
umount -l "${CHROOT_DIR}/dev"
umount -l "${CHROOT_DIR}/sys"
umount -l "${CHROOT_DIR}/proc"
umount -l "${CHROOT_DIR}/usr/portage"

Although the above script uses D-Bus, it is possible to run Steam without it, but a manual method is required to connect the X server from within the chroot.

Client troubleshooting

Video drivers

  • nvidia-drivers: You will need to unmask latest x11-drivers/nvidia-drivers.
  • Starting some games (TF, CS:S) on legacy ATI drivers will give this error: "Required OpenGL extension "GL_EXT_texture_sRGB_decode" is not supported. Please update your OpenGL driver." Workaround is here.

OpenGL GLX context is not using direct rendering

If steam is complaining about a lack of 3D capability and you do have a 3D drivers, libraries (eselect opengl list) all setup (glxinfo | grep "direct rendering" # direct rendering: Yes), steam is accessing the wrong libGL. This was caused by a recent update of app-eselect/eselect-opengl to version 1.3.0. Temporary workaround:

  • Nvidia
user $LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/lib32/opengl/nvidia/lib" ~/.local/share/Steam/
  • ATI
user $LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/lib32/opengl/ati/lib" ~/.local/share/Steam/


Some people seem to have problems with missing fonts. A user reported it being solved by emerging media-fonts/font-bitstream-100dpi.

Sometimes Xorg does not recognize the new fonts installed. To fix this temp. run:

user $xset +fp /usr/share/fonts/100dpi/
user $./

You may also need media-fonts/corefonts if fonts don't appear to be rendering correctly.

The game Stealth Bastard Deluxe will segfault if media-fonts/font-misc-misc is not installed [1], specifically the game will request the fonts "9x15"/"9x15b", so check with x11-apps/xlsfonts if those are available, otherwise add them to the fontpath and possibly add an alias in e.g. /usr/share/fonts/misc/fonts.alias:

FILE /usr/share/fonts/misc/fonts.aliasAliases for misc fonts
9x15  -misc-fixed-medium-r-normal--15-140-75-75-c-90-iso10646-1
9x15B -misc-fixed-bold-r-normal--15-140-75-75-c-90-iso10646-1

Mouse cursor

If your WM/DE does not set a mouse pointer theme, then Steam will overwrite the default X11 cursor theme, often resulting in a reversed pointer from left to right.

To fix this, just install and enable a compatible cursor theme via your WM/DE (e.g. x11-themes/vanilla-dmz-xcursors).

You can also enable the installed theme manually with the following method:

user $mkdir ~/.icons
user $ln -s /usr/share/cursors/xorg-x11/Vanilla-DMZ ~/.icons/default
This fix will not work if you will try to symlink a KDE cursor theme (eg: Oxygen_White).

If the mouse cursor gets stuck pointing in the wrong direction after exiting steam you can work around that via:

user $xsetroot -cursor_name left_ptr

Flashplayer on amd64

Get the 32bit flashplayer from adobe and extract to your current working dir. Now run:

user $mkdir <path-to-steam-installation>/ubuntu12_32/plugins
user $mv <path-to-steam-installation>/ubuntu12_32/plugins/
user $chmod +x <path-to-steam-installation>/ubuntu12_32/plugins/

Typically the path located in ~/.local/share/Steam. Alternatively emerge www-plugins/adobe-flash with abi_x86_32 option enabled and run:

user $mkdir <path-to-steam-installation>/ubuntu12_32/plugins
user $ln -s /usr/lib32/nsbrowser/plugins/ <path-to-steam-installation>/ubuntu12_32/plugins/

Memory corruption on startup

You might get an error like this:

user $steam
*** glibc detected *** zenity: malloc(): memory corruption: 0x00000000016cf020 ***

Try to emerge x11-libs/libXi and it should work.

Hardened Gentoo

It looks like the steam binary has rwx bits in it. You will need to mark the binary with the following to get it working on a hardened system.

user $paxctl-ng -m ~/.local/share/Steam/ubuntu12_32/steam

Binaries of most games also should be paxmarked, for ex.:

user $paxctl-ng -m ~/.local/share/Steam/SteamApps/common/"World of Goo/WorldOfGoo"
user $paxctl-ng -m ~/.local/share/Steam/SteamApps/common/Uplink/uplink.bin.x86_64
user $paxctl-ng -m ~/.local/share/Steam/steamapps/common/Team\ Fortress\ 2/hl2_linux

Failure to perform these paxmarkings will result in the game failing to run with little information given. You can check if the game needs to be paxmarked by running the game's startup script or binary file (found under ~/.local/share/Steam/steamapps or ~/.local/share/Steam/steamapps/common) under a debugger. This can be accomplished with some of Valve's provided startup scripts by passing in gdb in a GAME_DEBUGGER environment variable, for ex.:

user $env GAME_DEBUGGER=gdb ./

If the binary needs to be paxmarked, gdb should output something similar to "warning: Cannot call inferior functions, Linux kernel PaX protection forbids return to non-executable pages!" and/or "Cannot access memory at address 0x80486c6."

After latest update (around Jul 2013) steam also need paxmarked sh when the openGL libraries require RWX markings or it fail to run games from steam client (see for details):

user $sudo paxctl-ng -m /bin/bash

However, this causes bash to not run. Also as it is a security issue you are strongly encouraged to try without paxmarking it. If it works for you when using proprietary nvidia drivers please report it back.

Steam runtime

By default, Valve bundles their own libraries with the steam package and uses them instead of installed system libraries. This behavior can be changed by setting the environment variable STEAM_RUNTIME=0.


It is not recommended to deactivate Steam runtime. This can lead to numerous problems, including runtime and missing 32-bit libraries.

Steam reset

If you want to wipe out your current steam installation which includes your installed games and reinstall steam without losing their data, you can use the --reset command line option:

user $steam --reset

Steam without D-Bus

When running Steam without D-Bus, do not select the Remember my password option at the Steam login dialog, otherwise Steam will segfault the next time it is run [2]. If Steam is segfaulting as a result of this option being selected, run the following to fix the issue:

user $rm -fr ~/.local/share/Steam/config

Taskbar buttons persist when Steam is minimzed to the system tray

Depending on your DE, you might have a taskbar button showing for Steam all the time, even when the main window is closed or minimized to the systray. To stop this behavior, add this to /etc/environment.

FILE /etc/environmentBasic Environment Variables for all Processes

You will need to logout and back in to enact the changes.

Games troubleshooting

Texture compression

Many games, especially those that use the Source engine, require S3 Texture Compression (S3TC) support. Without S3TC support, these games will usually have black or missing textures, or fail to start.

  • Enable S3TC support:

The following USE flags are required for amd64:

FILE /etc/portage/package.use/steam
media-libs/libtxc_dxtn abi_x86_32

Install the media-libs/libtxc_dxtn package:

root #emerge --ask media-libs/libtxc_dxtn

Next, confirm if S3TC support is enabled with glxinfo, which is provided by the x11-apps/mesa-progs package:

root #glxinfo | grep GL_EXT_texture_compression_s3tc

If S3TC support is not enabled, ensure that the VIDEO_CARDS variable in /etc/portage/make.conf is set to the correct value, and update the video driver to most recent version.

If S3TC support is enabled, but games fail to start with the following error:

This system does not support the OpenGL extension GL_EXT_texture_compression_s3tc

Run the following before starting Steam:

user $export force_s3tc_enable=true

If nouveau drivers are being used, installing x11-libs/gtkglarea may be required to stop the above error.

Dota 2

  • If a red screen is visible during start and textures are missing in-game, refer to texture compression for details[5].

Left 4 Dead 2

Rust (legacy)

  • If the launcher fails to start, adding LD_LIBRARY_PATH="/usr/lib:$LD_LIBRARY_PATH" %command% to the launch options in Library->Rust->Properties->General->Set launch options.., may fix the issue.


  • If the launcher fails to start with the following error:
This application failed to start because it could not find or load the Qt platform plugin "xcb".

Available platform plugins are: xcb.

Reinstalling the application may fix this problem.

Adding $(dirname %command%)/starbound to the launch options in Library->Starbound->Properties->General->Set launch options.., may fix the issue.

Team Fortress 2

  • If a black screen is visible for 1-2 seconds, adding -nojoy to the launch options in Library->Team Fortress 2->Properties->General->Set launch options.., may fix the issue.

X3: Terran Conflict and X3: Albion Prelude

  • If red, green and blue stripes are visible, or the launcher fails to start, refer to texture compression for details[6].

Asking for help

The best place to ask for help is the Steam thread on the Gentoo Forums. If a solution to an issue is confirmed by others, add it to this page. Please do not remove content without discussion, unless it is obviously wrong.

External resources


  1. Michał Górny. True multilib support on amd64, Gentoo, March 28th, 2015. Retrieved on May 25th, 2015.
  2. Shished. Steam segfaults when "remember my password" is checked, Steam for Linux, July 28th, 2014. Retrieved on May 25th, 2015.
  3. arkrost. Black texture, Dota 2 Linux and Mac client, August 14th, 2013. Retrieved on May 26th, 2015.
  4. michaelsudnick. Black ground texture on Gentoo amd64, radeonsi open source driver, Dota 2 Linux and Mac client, July 12th, 2014. Retrieved on May 26th, 2015.
  5. proatx. Red-screen and no textures, Dota 2 Linux and Mac client, December 16th, 2013. Retrieved on May 26th, 2015.
  6. timon37. X³: TC and AP - Linux support thread, X Universe Forums, April 13th, 2013. Retrieved on May 26th, 2015.