Skip to content

Commit 3e3a3ab

Browse files
committed
Update WSL readmes
1 parent 77d550d commit 3e3a3ab

File tree

2 files changed

+14
-12
lines changed

2 files changed

+14
-12
lines changed

INSTALL-McStas-2.x/Windows/WSL/README.md

+6-10
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Installation of McStas 2.X on Windows 64 bit systems - using WSL
1+
# Installation of McStas 2.7.2 on Windows 64 bit systems - using WSL
22
*(WSL is the Windows Subsystem for Linux, aka. bash on Ubuntu on Windows)*
33

44

@@ -12,21 +12,20 @@
1212
* Let the machine reboot if necessary
1313
* Open the Windows store
1414
* Search for Ubuntu
15-
* Install Ubuntu 16.04 LTS or 18.04 LTS (other Linuxes are also
15+
* Install e.g. Ubuntu 22.04 LTS (other Linuxes are also
1616
available, but we recommend Ubuntu)
1717
* Click Launch to run the app and follow on-screen instructions
1818
* To open it again later, simply issue bash in a terminal or through
1919
the start menu
2020

21-
## Install the McStas 2.X Debian packages
21+
## Install the McStas 2.7.2 Debian packages
2222
* Follow the
2323
[normal Debian installation instructions](../../Linux/debian/README.md)
24-
- essentially a matter of sudo apt-get install mcstas-suite-python mcstas-suite-perl
24+
- essentially a matter of sudo apt-get install mcstas-suite-python mcstas-suite-python
2525

2626
## Install Xming or another X11 server application
2727
* Download and install Xming via https://sourceforge.net/projects/xming/
2828
* Windows store also provides a $-ware called X410 from "Choung Networks"
29-
* If you are using wsl 2 ensure that the correct ip for you wsl session
3029

3130
## Optionally add a few commands at the end of your .bashrc:
3231
```bash
@@ -38,10 +37,7 @@ user name
3837
```bash
3938
# cd to the home dir of your windows user
4039
cd /mnt/c/Users/pwill
41-
```
42-
If you installed wsl version 1
43-
```
44-
# Add the DISPLAY variable to talk to Xming for wsl version 1
40+
# Add the DISPLAY variable to talk to Xming
4541
export DISPLAY=:0.0
4642
```
4743
if you installed wsl version 2 your ubuntu session has a unique ip
@@ -59,7 +55,7 @@ DISPLAY=:0.0)
5955

6056
## Configuring McStas to use the Windows browser
6157
* Ensure the package ubuntu-wsl (or equivalent) is installed
62-
* Set the BROWSER="wslview" in your /usr/share/mcstas/3.0/tools/Python/mccodelib/mccode_config.py
58+
* Set the BROWSER="wslview" in your /usr/share/mcstas/2.7.2/tools/Python/mccodelib/mccode_config.py
6359

6460
## In case of issues
6561
Please report any trouble with the repository to [mcstas-users](mailto:[email protected])

INSTALL-McStas-3.x/Windows/WSL/README.md

+8-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
* Let the machine reboot if necessary
1313
* Open the Windows store
1414
* Search for Ubuntu
15-
* Install Ubuntu 16.04 LTS or 18.04 LTS (other Linuxes are also
15+
* Install e.g. Ubuntu 22.04 LTS (other Linuxes are also
1616
available, but we recommend Ubuntu)
1717
* Click Launch to run the app and follow on-screen instructions
1818
* To open it again later, simply issue bash in a terminal or through
@@ -21,7 +21,7 @@ the start menu
2121
## Install the McStas 3.2 Debian packages
2222
* Follow the
2323
[normal Debian installation instructions](../../Linux/debian/README.md)
24-
- essentially a matter of sudo apt-get install mcstas-suite-python mcstas-suite-perl
24+
- essentially a matter of sudo apt-get install mcstas-suite-python mcstas-suite-python-ng
2525

2626
## Install Xming or another X11 server application
2727
* Download and install Xming via https://sourceforge.net/projects/xming/
@@ -40,6 +40,12 @@ cd /mnt/c/Users/pwill
4040
# Add the DISPLAY variable to talk to Xming
4141
export DISPLAY=:0.0
4242
```
43+
if you installed wsl version 2 your ubuntu session has a unique ip
44+
```
45+
# Add the DISPLAY variable to talk to Xming for wsl version 2
46+
export DISPLAY=$(awk '/nameserver / {print $2; exit}' /etc/resolv.conf 2>/dev/null):0
47+
export LIBGL_ALWAYS_INDIRECT=1
48+
```
4349

4450
## Start mcgui
4551
* Ensure your X11 server is running

0 commit comments

Comments
 (0)