1. Install Spotify in the usual way: ```sh curl -fsSL https://download.spotify.com/debian/pubkey_5E3C45D7B312C643.gpg | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/spotify.gpg sudo apt update && sudo apt install spotify-client ``` 2. Compile stubs for X-specific calls that Spotify makes: ```c $ cat xstub.c #include #define X_FN(f) int f() { puts("called"); return 0; } X_FN(XInternAtoms) X_FN(XChangeProperty) X_FN(XGetGeometry) X_FN(XInternAtom) X_FN(XMoveResizeWindow) X_FN(XSendEvent) X_FN(XSetClassHint) X_FN(XSetErrorHandler) X_FN(XSetIOErrorHandler) X_FN(XStoreName) X_FN(XTranslateCoordinates) ``` ```sh $ cc xstub.c -o xstub.so -shared $ sudo mv xstub.so /usr/local/lib/spotify-xstub.so && sudo chmod 644 /usr/local/lib/spotify-xstub.so ``` 3. Invoke Spotify in this way: ```sh LD_PRELOAD=/usr/local/lib/spotify-xstub.so spotify --enable-features=UseOzonePlatform --ozone-platform=wayland ```