Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rsx: Make X11 optional on Linux #7018

Merged
merged 5 commits into from Dec 20, 2019
Merged

Conversation

linkmauve
Copy link
Contributor

This makes it possible to build rpcs3 on a pure Wayland system, without the Xlib installed.

@arabek
Copy link
Contributor

arabek commented Nov 21, 2019

[ on branch (master) ]$ gitcopr 7018
remote: Enumerating objects: 25, done.
remote: Counting objects: 100% (25/25), done.
remote: Compressing objects: 100% (19/19), done.
remote: Total 25 (delta 6), reused 23 (delta 6), pack-reused 0
Unpacking objects: 100% (25/25), done.
From https://github.com/RPCS3/rpcs3
 * branch                refs/pull/7018/merge -> FETCH_HEAD
Switched to a new branch '7018'
[ on branch (7018) ]$ make-rpcs3 
(…)
[100%] Linking CXX executable ../bin/rpcs3
[100%] Built target rpcs3

Builds just fine on X11

@amayra
Copy link

amayra commented Nov 21, 2019

there any different between pure Wayland and X11 or XWayland build ?

@linkmauve
Copy link
Contributor Author

So, Wayland is a protocol, X11 is a protocol. Xwayland is a build of the Xorg server allowing you to run any X11 program on a Wayland compositor.

This PR only makes it so a user using only Wayland can build rpcs3 without having to drag all of the X11 dependencies. Both will work on Wayland and X11, but when no X11 headers are found the resulting binary will only work on Wayland.

@escalade
Copy link

You need X11 libraries/headers to build Mesa with OpenGL support. What we really need is optional OpenGL support.

#6740

@linkmauve
Copy link
Contributor Author

No you don’t, since glvnd introduced the new libOpenGL ABI you can build Mesa with desktop OpenGL support without depending on libGLX or X11 libraries.

#6835 would be nice to fix though, I might give it a try after that.

@escalade
Copy link

escalade commented Nov 22, 2019

With latest Mesa and libglvnd git:

meson.build:396:4: ERROR: Problem encountered: Cannot build GLX support without X11 platform support and at least one OpenGL API

EDIT: I suppose GLX isn't needed at all anymore. Will try this out.

rpcs3/Emu/RSX/VK/VKHelpers.h Outdated Show resolved Hide resolved
rpcs3/Emu/RSX/VK/VKHelpers.h Outdated Show resolved Hide resolved
@kd-11
Copy link
Contributor

kd-11 commented Nov 29, 2019

The check for either wayland or X11 is still missing too. You should require at least one of them; else no compilation. You need to add it to cmake file since X11 is now not required.

Copy link
Contributor

@kd-11 kd-11 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes it possible to build rpcs3 on a pure Wayland system, without
the Xlib installed.
@linkmauve
Copy link
Contributor Author

Hi, this should be all done now. :)

Sorry for not reacting earlier, I’ve been pretty busy organising for the general strike in France lately.

@kd-11
Copy link
Contributor

kd-11 commented Dec 15, 2019

No rush really, its understandable you may have more important things to do. Will review as soon as possible.

@AniLeo AniLeo merged commit e30173a into RPCS3:master Dec 20, 2019
@linkmauve linkmauve deleted the conditional-x11 branch December 20, 2019 12:02
@kd-11 kd-11 mentioned this pull request Dec 20, 2019
@Megamouse Megamouse added the Build and CI Anything related to the build process and continuous integration label Feb 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build and CI Anything related to the build process and continuous integration OS: Linux
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants