Setting up Termux:x11 WAYLAND On An Android Phone

Hello everyone welcome back to my Blog, in today's blog I'm gonna show you how to install X wayland On Termux, If you could remember vividly, I previously made a Tutorial on how to install Xfce Desktop On Termux, you can click the link to read that article if you haven't, as it is going to take an important role in this particular article.

Prerequisites:

Procedures:

Step 1: (Getting Termux ready)

Launch your termux application and update your packages to make sure their all up to date. You can update Termux packages with the command:
  • pkg update 
After updating your packages the next thing you're going to do is install the x11-repo package on Termux. You can install x11-repo with the command:
  • pkg install x11-repo
After that we're going to make some changes to our termux.properties file, as we want termux to allow external apps, to do that type the command;
  • nano .termux/termux.properties
On the text editor, type ctrl+w a search bar should appear above your keyboard, search for allow-external 
Searching for allow-external
Now when the result comes up, uncomment the [hash tag (#) ] from the allow allow-external-apps = true text, just as shown in the sample image below. 
Uncomment the #tag sample image

Step 2: (Download and install the Termux-x11 packages)

Now open your browser and go to the termux-x11 GitHub page and scroll down to the Setup instructions page and click on last successful build 

A new page should open up and you should download your Termux-x11 file from the latest, amongst the list on the new page, which should be the first link.

After clicking on the link, scroll down and locate Artifacts , there you should see the termux-x11 file and should be able to download it. Make sure the file is saved to the download folder in your phone internal storage 

 After downloading the file, launch termux and locate the file through your terminal. Type the command below to navigate to your download folder on Termux.
  • cd storage/downloads
Now copy the termux-x11 file to Termux home directory using the command 
  • cp termux-x11.zip /$HOME
Now go back to your home directory and unzip the file with the command
  • unzip termux-x11.zip
Now you should see three new files on your terminal namely.
  1. termux-x11.deb (the installation file)
  2. app-debug.apk (Termux-x11 Application
  3. Output-metadata.json (file information for app-debug.apk)
The first thing we do is install the termux-x11.deb file on Termux. You can install it with the command:
  • pkg install ./termux-x11.deb
After installation, close termux and go to your file manager and unzip the termux-x11.zip file, now manually install the app-debug.apk from the file manager.

Step 3: (connecting to Termux-x11 Xwayland)

After installing the packages as shown in the previous steps, then we proceed to the setup and connection. To connect to Termux-x11 Xwayland use the command below 
  1. ~ $ export XDG_RUNTIME_DIR=${TMPDIR}
  2. ~ $ termux-x11 :1 &
  3. ~ $ env DISPLAY=:1 xfce4-session
You may replace xfce4-session if you use other than Xfce.

Conclusion:

After entering the commands above, launch the Termux-x11 application and the Xwayland desktop should display on your screen.
If you're done using Termux:X11 just simply exit it through it's notification drawer by expanding the Termux:X11 notification then "Exit"

Watch the video here:


Post a Comment

Previous Post Next Post