mirror of https://github.com/zeldaret/mm.git
Update README with python venv instructions (#1372)
This change updates the README to include instructions for setting up a python virtual environment.
This commit is contained in:
parent
7681c97df0
commit
f2347000b0
|
@ -54,3 +54,4 @@ docs/doxygen/
|
||||||
# Per-user configuration
|
# Per-user configuration
|
||||||
.python-version
|
.python-version
|
||||||
.make_options
|
.make_options
|
||||||
|
.*env
|
||||||
|
|
22
README.md
22
README.md
|
@ -68,12 +68,13 @@ The build process has the following package requirements:
|
||||||
* python3
|
* python3
|
||||||
* pip3
|
* pip3
|
||||||
* libpng-dev
|
* libpng-dev
|
||||||
|
* python3-venv
|
||||||
|
|
||||||
Under Debian / Ubuntu (which we recommend using), you can install them with the following commands:
|
Under Debian / Ubuntu (which we recommend using), you can install them with the following commands:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
sudo apt update
|
sudo apt update
|
||||||
sudo apt install make git build-essential binutils-mips-linux-gnu python3 python3-pip libpng-dev
|
sudo apt install make git build-essential binutils-mips-linux-gnu python3 python3-pip libpng-dev python3-venv
|
||||||
```
|
```
|
||||||
|
|
||||||
#### 2. Clone the repository
|
#### 2. Clone the repository
|
||||||
|
@ -94,12 +95,27 @@ cd mm
|
||||||
|
|
||||||
The build process has a few python packages required that are located in `requirements.txt`.
|
The build process has a few python packages required that are located in `requirements.txt`.
|
||||||
|
|
||||||
To install them simply run in a terminal:
|
It is recommend to setup a virtual environment for python to localize all dependencies. To create a virtual environment:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
python3 -m pip install -r requirements.txt
|
python3 -m venv .mm-env
|
||||||
```
|
```
|
||||||
|
|
||||||
|
To activate or deactivate the virtual environment run either:
|
||||||
|
```bash
|
||||||
|
# Activates the mm-env virtual environment
|
||||||
|
source .mm-env/bin/activate
|
||||||
|
# Deactivates the active virtual environment
|
||||||
|
deactivate
|
||||||
|
```
|
||||||
|
|
||||||
|
Once activated you can install the required dependencies:
|
||||||
|
```bash
|
||||||
|
pip install -r requirements.txt # or python3 -m pip if you want
|
||||||
|
```
|
||||||
|
|
||||||
|
**Important:** This virtual environment will need to be activated everytime you enter the repo.
|
||||||
|
|
||||||
#### 4. Prepare a base ROM
|
#### 4. Prepare a base ROM
|
||||||
|
|
||||||
Copy your ROM to inside the root of this new project directory, and rename the file of the baserom to reflect the version of ROM you are using. ex: `baserom.mm.us.rev1.z64`
|
Copy your ROM to inside the root of this new project directory, and rename the file of the baserom to reflect the version of ROM you are using. ex: `baserom.mm.us.rev1.z64`
|
||||||
|
|
Loading…
Reference in New Issue