Skip to content

Conversation

matt335672
Copy link
Member

@matt335672 matt335672 commented Feb 10, 2025

Fixes #340
Fixes #362

Draft PR for now. It isn't clear that we need this yet, as the change which has precipitated this has not yet appeared in any mainline distros. Devel versions of the X server do not contain the global string variable 'display' in opaque.h. See #340 for more information.

This commit works around that by extracting the required information from the DISPLAY variable.
Edit: 2025-02-12 We've been provided with a new function in the DIX layer to get the display name. This PR uses that function if it is available

@jsorg71 - I'd appreciate your thoughts on this. I can't find a better way to do this at the moment. Would it be better to set a variable in sesman for the whole socket path do you think?

Also, it might be better to use the Xorg version to test for the getter function, as we do this elsewhere. At the moment this isn't possible, as we don't know what the version will be.

Devel versions of the X server do not contain the global
string variable 'display' in opaque.h. It has been replaced
by the getter function dixGetDisplayName()
@matt335672 matt335672 changed the title Get display number from the environment Get display number from the DIX layer rather than a global Feb 12, 2025
@matt335672 matt335672 marked this pull request as ready for review February 12, 2025 10:36
@matt335672 matt335672 requested a review from jsorg71 February 13, 2025 14:03
@matt335672
Copy link
Member Author

@jsorg71 - are you happy with the way I'm detecting the getter function, or would you rather do a check against the Xorg version, when we know what it's going to be?

@jsorg71
Copy link
Contributor

jsorg71 commented Feb 13, 2025

I think that looks fine @matt335672 thanks and thanks @metux

@matt335672 matt335672 merged commit e4d8468 into neutrinolabs:devel Feb 14, 2025
8 checks passed
@matt335672 matt335672 deleted the check_display branch February 14, 2025 10:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Workaround for missing "display" var (removed from xserver) Unable to compile
2 participants