csgo-osx-linux icon indicating copy to clipboard operation
csgo-osx-linux copied to clipboard

can no longer run cs2 under wayland with the latest update 4/10/2023

Open pollux78 opened this issue 3 years ago • 72 comments

Your system information

  • System information from steam (Steam -> Help -> System Information) in a gist:
  • Have you checked for system updates?: [Yes/No]

Please describe your issue in as much detail as possible:

Describe what you expected should happen and what did happen. Please link any large pastes as a Github Gist.

Steps for reproducing this issue:

  1. install cs2
  2. try to launch cs2 under wayland kwin on the latest kde plasma desktop
  3. closes after a wayland shortcut comes up for a few seconds

⚠️⚠️WE ADVICE USERS TO USE THIS AS A LAST RESORT BEFORE TRYING EVERYTHING ELSE TO GET CS2 WORKING⚠️⚠️

⚠️⚠️WHEN THIS IS FIXED, REMOVE THESE LAUNCH COMMANDS TO RUN CS PROPERLY UNDER WAYLAND ⚠️⚠️

For Wayland to work use this environment variable

SDL_VIDEO_DRIVER=x11 %command%

Or this one aswell

WAYLAND_DISPLAY= %command%

This will force sdl into thinking that cs2 or dota 2 is in x11

If you're using flatpak steam just disable Wayland socket in flatseal

pollux78 avatar Oct 04 '23 22:10 pollux78

i was playing just before under wayland then after the newest update i can longer launch it under wayland, x11 works fine

pollux78 avatar Oct 04 '23 22:10 pollux78

I have the same issues aswell. Just went from wayland to x11 and it works. I was playing on wayland right before the update

tbergman99 avatar Oct 04 '23 22:10 tbergman99

Same for me. Didn't try on X11, but I was playing fine, stopped the game, installed the update, and it doesn't work anymore.

All I see is

/games/SteamLibrary/steamapps/common/Counter-Strike Global Offensive/game/cs2.sh: line 115: 8973 Segmentation fault (core dumped) ${STEAM_RUNTIME_PREFIX} ${GAME_DEBUGGER} "${GAMEROOT}"/${GAMEEXE} "$@"

EDIT: I do have zenity: symbol lookup error: /lib/x86_64-linux-gnu/libgtk-3.so.0: undefined symbol: pango_font_family_get_face as well

lou-perret avatar Oct 04 '23 22:10 lou-perret

I believe this is the real problem:

zenity: symbol lookup error: /lib/x86_64-linux-gnu/libgtk-3.so.0: undefined symbol: pango_font_family_get_face

vaxerski avatar Oct 04 '23 22:10 vaxerski

Same, running on up-to-date arch system using Hyprland (wayland compositor), havent tried in X11. get this error symbol lookup error: /lib/x86\_64-linux-gnu/libgtk-3.so.0: undefined symbol: pango\_font\_family\_get\_face

gegnep avatar Oct 04 '23 22:10 gegnep

same for me, updated the game, and then it's gone

droyd9 avatar Oct 04 '23 22:10 droyd9

Same in Wayland GNOME, Fedora 37

gerelef avatar Oct 04 '23 23:10 gerelef

[ 1302.313677] dota2[23761]: segfault at 0 ip 00007f9e78a33d1b sp 00007fff2771aef0 error 4 in libc.so.6[7f9e78a10000+158000] likely on CPU 15 (core 15, socket 0)

[ 1429.728651] cs2[25965]: segfault at 0 ip 00007fd3ea3c1d1b sp 00007ffc86658810 error 4 in libc.so.6[7fd3ea39e000+158000] likely on CPU 11 (core 11, socket 0)

Segfault occurs for both dota2 and cs2, so it's probably an engine update that broke things.

Zer0-One avatar Oct 04 '23 23:10 Zer0-One

found a temp fix, unsetting the WAYLAND_DISPLAY env variable lets the game launch. example, my launch options that worked: WAYLAND_DISPLAY= %command% -vulkan -nojoy -language textmod

gegnep avatar Oct 04 '23 23:10 gegnep

right. That works. Odd that SDL_VIDEODRIVER=x11 does not. Did valve try to hardcode wayland support and fail? lol

vaxerski avatar Oct 04 '23 23:10 vaxerski

found a temp fix, unsetting the WAYLAND_DISPLAY env variable lets the game launch. example, my launch options that worked: WAYLAND_DISPLAY= %command% -vulkan -nojoy -language textmod

yep now it works, thank you.

my launch command at the moment is this KWIN_DRM_NO_AMS=1 WAYLAND_DISPLAY= %command%

love the linux community

pollux78 avatar Oct 04 '23 23:10 pollux78

right. That works. Odd that SDL_VIDEODRIVER=x11 does not. Did valve try to hardcode wayland support and fail? lol

SDL_VIDEODRIVER is the old variable, SDL_VIDEO_DRIVER=x11 works and yes they seem to try to default to wayland now I guess

BananaWorks07 avatar Oct 04 '23 23:10 BananaWorks07

right. That works. Odd that SDL_VIDEODRIVER=x11 does not. Did valve try to hardcode wayland support and fail? lol

SDL_VIDEODRIVER is the old variable, SDL_VIDEO_DRIVER=x11 works and yes they seem to try to default to wayland now I guess

At least they're trying 😂

pollux78 avatar Oct 04 '23 23:10 pollux78

Also had this issue and the fix above works.

rcannizzaro avatar Oct 05 '23 00:10 rcannizzaro

SDL3 defaults to wayland unless the application requests otherwise Also the undefined symbol: pango_font_family_get_face is weird because my libgtk-3.so.0 has that symbol

antipsychotics avatar Oct 05 '23 02:10 antipsychotics

@pollux56 Edit in the temporary workaround SDL_VIDEO_DRIVER=x11 to your original post. This will help people who come here newly.

Valve probably accidentally enabled Wayland on the SDL build and the game won't start anymore since it doesn't have proper Wayland support.

alou-S avatar Oct 05 '23 02:10 alou-S

@pollux56 Edit in the temporary workaround SDL_VIDEO_DRIVER=x11 to your original post. This will help people who come here newly.

Valve probably accidentally enabled Wayland on the SDL build and the game won't start anymore.

Is the SDL_VIDEO_DRIVER=x11 a fix for running it under Wayland as well or is it for x11?

pollux78 avatar Oct 05 '23 02:10 pollux78

@pollux56 Edit in the temporary workaround SDL_VIDEO_DRIVER=x11 to your original post. This will help people who come here newly. Valve probably accidentally enabled Wayland on the SDL build and the game won't start anymore.

Is the SDL_VIDEO_DRIVER=x11 a fix for running it under Wayland as well?

Yes SDL_VIDEO_DRIVER=x11 forces SDL to use the x11 driver instead of the wayland driver.

WAYLAND_DISPLAY= unsets the the parameter fooling SDL into thinking that its a x11 system hence starting with the x11 video driver.

Only one of either envar's are required. The first one preferably.

alou-S avatar Oct 05 '23 02:10 alou-S

@kisak-valve, can we get a beta branch for CS2 and DOTA 2? We are having pushes every day to both lately, earlier we had another SDL bug with audio and now with video. I would absolutely use the beta and report in the appropriate channels when a problem arises, but having this on the stable releases is just frustrating.

wizardlink avatar Oct 05 '23 02:10 wizardlink

Valve probably accidentally enabled Wayland on the SDL build and the game won't start anymore since it doesn't have proper Wayland support.

That sounds right, I compiled SDL3 with Wayland support & replaced it the other day and got the same exact error.

sameer avatar Oct 05 '23 02:10 sameer