|
| 1 | +--- |
| 2 | +title: Installation on Windows |
| 3 | +layout: home |
| 4 | +nav_exclude: true |
| 5 | +--- |
| 6 | + |
| 7 | +# Installation on Windows |
| 8 | +{: .fs-10 .fw-700 .text-center } |
| 9 | + |
| 10 | +## Windows Subsystem for Linux (WSL) |
| 11 | +{: .fs-4 .fw-700 } |
| 12 | + |
| 13 | +On Windows the PSPDEV toolchain is run on Ubuntu running on Microsoft's WSL. This is very easy to set up and will offer us the full power of Linux from a Windows machine. |
| 14 | + |
| 15 | +To set up WSL with Ubuntu in it run the following commands in a Powershell window started as administrator (right click run as administrator on Powershell in the start menu): |
| 16 | + |
| 17 | +```powershell |
| 18 | +wsl --install |
| 19 | +``` |
| 20 | + |
| 21 | +After this is done, Ubuntu can be selected from the start menu to open a terminal. This will be used for all commands going forward. |
| 22 | + |
| 23 | +Files in Ubuntu can be accessed through a network share. In `This Computer` right click on the background and select `Map network drive`. Set the folder to `\\wsl$` to make it easily accessible. |
| 24 | + |
| 25 | +## Dependencies |
| 26 | +{: .fs-6 .fw-700 } |
| 27 | + |
| 28 | +The PSPDEV toolchain requires a couple of dependencies to be installed before use. To install them, run the following command from an Ubuntu terminal: |
| 29 | + |
| 30 | +```shell |
| 31 | +sudo apt-get update |
| 32 | +``` |
| 33 | + |
| 34 | +```shell |
| 35 | +sudo apt-get install build-essential cmake pkgconf libreadline8 libusb-0.1 libgpgme11 libarchive-tools fakeroot |
| 36 | +``` |
| 37 | + |
| 38 | +### Toolchain |
| 39 | +{: .fs-6 .fw-700 } |
| 40 | + |
| 41 | +Installing the PSPDEV toolchain itself can be done with the following steps: |
| 42 | + |
| 43 | +1. Download [the latest version of the toolchain here](https://github.com/pspdev/pspdev/releases/latest/download/pspdev-ubuntu-latest-x86_64.tar.gz). |
| 44 | +2. Extract the downloaded archive into your `\\wsl$\home\YOURUSERNAME\`, resulting in `\\wsl$\home\YOURUSERNAME\pspdev` being created. Replace `YOURUSERNAME` with the existing one. This can be done using |
| 45 | +3. To make the toolchain usable, some environment variables need to be set. The first step in doing so it to open the `~/.bashrc` file with the `nano` text editor using the following command from an Ubuntu terminal: |
| 46 | + ```shell |
| 47 | + nano ~/.bashrc |
| 48 | + ``` |
| 49 | +4. Add the following lines at the bottom of the file in the text editor: |
| 50 | + ```shell |
| 51 | + export PSPDEV="~/pspdev" |
| 52 | + export PATH="$PATH:$PSPDEV/bin" |
| 53 | + ``` |
| 54 | +5. Now save and exit by pressing `Ctrl`+`X`, then `Y` and then enter/return. |
| 55 | +6. Close the current Ubuntu terminal and open a new one. |
| 56 | +7. From the new Ubuntu terminal, run the following command to confirm everything is set up correctly: |
| 57 | + ```shell |
| 58 | + psp-config --pspdev-path |
| 59 | + ``` |
| 60 | + |
| 61 | +That's it, now the PSPDEV toolchain can be used to build PSP software. Check out the [Basic Programs](../basic_programs.html) page to for examples on what you can do with it. |
0 commit comments