GoGreen PC Tune-Up™
Learn More

this is how we code sign our software and ssl encrypt our websites from our affiliate partner SSL.com
MTNCOMP | List | Table


myBlog Home


Microsoft Windows Linux Tux

Linux - WSL2 gui apps on Windows 10 via sourceforge and stackoverflow

by Mountain Computers Inc., Publication Date: Saturday, September 4, 2021
View Count: 588, Keywords: Linux, WSL2, GUI, Source Forge, Stack Exchange, Ubuntu, Hashtags: #Linux #WSL2 #GUI #SourceForge #StackExchange #Ubuntu

of all the WSL2 examples to get GUI app support --- worked like a charm.... of course nautilus did not work so well, and gimp, blew up ... yet most of the minor x11 gui apps were fine.
REF: https://stackoverflow.com/questions/61110603/how-to-set-up-working-x11-forwarding-on-wsl2/66645230#66645230

XServer Windows - WSL2 (Ubuntu):

Install X-Server Windows


Set Display forward in WSL Distro

export DISPLAY=$(awk '/nameserver / {print $2; exit}' /etc/resolv.conf 2>/dev/null):0export LIBGL_ALWAYS_INDIRECT=1

sudo apt update
sudo apt install x11-apps

Start XLaunch on Windows

Test it

In wsl: enter xcalc - Calculator should open in Windows10

Add it to autostart

  1. Run Dialog see Start XLaunch on Windows
  2. Save configuration
  3. Press Windows + R
  4. Enter: shell:startup
  5. Copy saved configuration: *.launch (Generated in step 2) to this folder (step 4)

Now the XServer will be started with windows startup.

I’m using it for ROS. Works for me.

My XServer isn’t available over internet so its okay to disable access control.

more to come... 

*** windows logo +R type "shell:startup" and "shell:common startup" was a cool find!!

if you found this article helpful, consider contributing $10, 20 an Andrew Jackson or so..to the author. more authors coming soon
FYI we use paypal or patreon, patreon has 3x the transaction fees, so we don't, not yet.

© 2023 myBlog™ v1.1 All rights reserved. We count views as reads, so let's not over think it.