-
-
Notifications
You must be signed in to change notification settings - Fork 285
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
App force close as soon as xfce4 starts loading #44
Comments
Maybe you can try this command, maybe will not crash before that, close termux x11 app (make sure it not running any session, maybe just force close it), then export XDG_RUNTIME_DIR=${TMPDIR} |
Yes it works, with DISPLAY :0, thank you! |
I had another crash on startup:
from termux:
edit: started fine the second time I tried... after restarting termux and termux:x11 |
Can you please try to start
After that you can start xfce4-session and if it still has problems you will have special log file that you can upload here. |
I am having more force closes after some time using the app (maybe 30min...1h once opened). I do not see nothing relevant in logcat. Can I use the TERMUX_X11_LOG_FILE in some other way since I am not using the starter app? |
This is what it seems to put out on logcat
|
Can you please try again with latest build? |
Hi, i cloned the repo and built the application but it appears i have problems during build. This is the output:
Here is lint-results-debug.txt from Please note that I compiled the app manually due to the fact that I do not use termux-x11 with termux.
I noticed that the apk gets created even if gradle does not complete the build, and installed it on my device, but something does not work. The termux-x11 window app appears but nothing appears inside of it. The wayland-0 socket gets created and Xwayland (inside chroot) starts, but startxfce logs show that applications are Xwayland output:
startxfce4 output:
|
About using starter.
You should simply start my starter from android root shell with |
Do you have any progress? |
Any updates? |
According to this code you get this error because you are not running Xwayland as root. |
Hi, I will have more time to test this evening i think. But what I can say is that just by switching back the termux-x11 version, everything works again. I don't have to change anything in my setup/configuration. Here is a working startfxce session, still running while I am typing this comment, accessed remotely... startxfce4 log:
|
What exactly do you mean here? |
I use as base an older version (looks like 1.02.06 i think), applied manually patch from #45 (comment), #45 (comment), https://github.com/termux/termux-x11/issues/125#issuecomment-1141082618 and https://github.com/termux/termux-x11/issues/125#issuecomment-1223568064 |
I think you can do it a bit later. I found a bug with screen resizing, I am fixing it at the moment. |
Hi. Can you please test latest build? |
Hi, I tried as you suggested:
I call termux-x11 script from my scripts as root as follows:
This is the content of termux-x11 script:
This is the output of termux-x11 script:
Xwayland cannot connect.
I noticed that the socket that gets created in /data/data/com.termux.x11/files/tmp/termux-x11 belongs to root. I dont think this is correct.
Even if I manually chmod 0777 and chown the socket to the user and group of termux-x11 android app (once my main script gets back control from termux-x11 script) Xwayland cannot connect Since you changed the socket name i also |
I'm quite sure it's something wrong with permissions, will do more tests asap. |
Ok... Here is what I modified in starter.c
the socket has to belong to the termux-x11 android app uid/gid. It cannot belong to root. EDIT: chmod 0777 appears to be enough |
Can you please try to |
Initially, I actually tried using the f variants of chmod and chown using the available fd and it did not work. |
The solution I found is to chmod the socket to 0660 instead of 0777 and add into the chroot a group called termux-x11 with gid equal of the gid of the termux-x11 app, and add to this new group the user that runs Xwayland |
It looks like I found a way to fix a dozen of issues and make it much easier to implement two dozens more. I will simply move wayland server to starter. It will be invoked from cli, so it will be able to work with root-owned sockets. Also it will let me add more cli options (it was complicated earlier because I needed to keep starter and main app compatible, now it is not a problem because starter is launched directly from apk of main app) like dpi, resolution, custom wayland or x socket path... And android application will behave like simple client, connecting to wayland server with binder... Can you help me testing this please? |
Hi, yes sure. |
@zanfix Can I close this? |
I think so yes |
Termux:X11 app will force close as soon i start xfce4:
logcat output:
what i did from termux:
The text was updated successfully, but these errors were encountered: