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

Unable to compile #340

Open
Atra99 opened this issue Aug 23, 2024 · 13 comments
Open

Unable to compile #340

Atra99 opened this issue Aug 23, 2024 · 13 comments

Comments

@Atra99
Copy link

Atra99 commented Aug 23, 2024

I'm attempting to compile xorgxrdp in Manjaro Linux. When running make, I get the following error.

rdpClientCon.c: In function 'rdpClientConInit':
rdpClientCon.c:1564:21: error: 'display' undeclared (first use in this function)
1564 |     i = (int)strtol(display, &endptr, 10);
     |                     ^~~~~~~
rdpClientCon.c:1564:21: note: each undeclared identifier is reported only once for each function it app
ears in
make[3]: *** [Makefile:681: rdpClientCon.lo] Error 1

I'm sure I'm doing something wrong, but I can't find any information online about what would be causing this

@matt335672
Copy link
Member

It's a bit obscure.

The variable display is a global X server variable defined in /usr/include/xorg/opaque.h on my (Ubuntu) system. That file is pulled in by #include <xf86_OSproc.h> Maybe there's another opaque.h on your include path(?)

@k9dkq
Copy link

k9dkq commented Dec 9, 2024

I'm having the same issue on Gentoo compiling the latest version. I checked /usr/include/xorg/opaque.h and found it did not include a global variable for 'display'.

@matt335672
Copy link
Member

I don't have a Gentoo install here, but it looks like this might be the problem:-

https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1351

The symbols are now in dix/dix_priv.h. You could try including this for now and see if it fixes the immediate issue. Please report back regardless, and we'll try to find a better solution.

@k9dkq
Copy link

k9dkq commented Dec 10, 2024

It still didn't find "display" defined in the include chain.

@matt335672
Copy link
Member

I don't have a Gentoo installation to hand, and this version of opaque.h hasn't made it to Arch/Manjaro yet (which I do have to hand). I've got 21.1,14 on Manjaro which doesn't have this change.

@Atra99 - did you get to the bottom of the problem on your Manjaro installation?
@k9dkq - can you take a patch? If so, which version of xorgxrdp are you trying to compile?

@k9dkq
Copy link

k9dkq commented Dec 11, 2024

I'm compiling against the latest xrdp-0.10.1 and xorgxrdp-0.2.15. I found the the "display" global variable in dix/dix_priv.h as you specified but I'm had clone the xserver git repository. I'm guessing I'll have to change the Makefile to specify the location of the xserver source.

@jsorg71
Copy link
Contributor

jsorg71 commented Dec 11, 2024

I have noticed the Xorg guys are removing a bunch of exported symbols. They claim they are not used by anyone.
I've been meaning to ask them why they are doing that and how they know no one is using it. It seems that can not know.
I also think they do things like this and see if anyone complains.
Here is an example of one of these commits, there are a lot more.
https://cgit.freedesktop.org/xorg/xserver/commit/?id=1891a8dc147cfaf63b6db0249f1520f2c091fb85

@jsorg71
Copy link
Contributor

jsorg71 commented Dec 11, 2024

display seems to removed here
https://cgit.freedesktop.org/xorg/xserver/commit/?id=06b599edb65c171c4104e4b0977b9be0130f03e8
again, I don't know why they are removing them.

@matt335672
Copy link
Member

@jsorg71 - we can probably remove the dependency on display and use the environment, which will be set by sesman. I agree it's not optimal, but I don't know another way to access the display name at this level.

@matt335672
Copy link
Member

Just opened an issue:-

https://gitlab.freedesktop.org/xorg/xserver/-/issues/1770

@metalefty
Copy link
Member

@k9dkq

I'm compiling against the latest xrdp-0.10.1 and xorgxrdp-0.2.15.

These versions are incompatible BTW.

@k9dkq
Copy link

k9dkq commented Dec 12, 2024

I've gotten a bit further. The original problem I encountered was during the build step for the xorgxrdp package. I tried to install xrdp and xorgxrdp from git which led down a rabbit hole of dependency packages. Finally I nailed the problem down to xrdp_client_info.h. xrdp_client_info.monitorCount has been moved to display_size_dscription in more recent versions. Some how I had the header from an the the most recent version of xrdp in /usr/src. Packages in the repository are based on xrdp 0.10.1 and xorgxrdp 0.2.15.

@matt335672
Copy link
Member

The xorgxrdp package in the repository would seem to be a bit out of date then!

What's the version of the xorg server in your setup?

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

No branches or pull requests

5 participants