Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Dockerfile #93

Merged
merged 3 commits into from
Oct 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
FROM ubuntu:jammy

RUN apt-get update -y
RUN apt-get install -y \
git \
build-essential \
pkg-config \
python3 \
python3-venv \
python3-pip \
python-is-python3 \
wget
RUN dpkg --add-architecture i386
RUN mkdir -pm755 /etc/apt/keyrings
RUN wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key
RUN wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/jammy/winehq-jammy.sources
RUN apt-get update -y
RUN apt-get install -y --install-recommends winehq-stable
RUN python -m venv .venv
RUN . .venv/bin/activate
RUN pip install meson ninja
COPY tools/cw/license.dat /etc/mwerks/license.dat
ENV LM_LICENSE_FILE=/etc/mwerks/license.dat
RUN hash -r

CMD [ "/bin/sh" ]
12 changes: 11 additions & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ These can be installed using Homebrew; if you do not have Homebrew installed, re

```
brew update
brew install meson
brew install meson
brew install --cask wine-stable
```

Expand Down Expand Up @@ -153,3 +153,13 @@ To build the rom, run:

If everything works, then the following ROM should be built:
- [build/pokeplatinum.us.nds](https://datomatic.no-intro.org/index.php?page=show_record&s=28&n=3541) `sha1: ce81046eda7d232513069519cb2085349896dec7`

# 4. Docker

A Dockerfile is provided for your convenience. To begin, setup docker on your local machine following the instructions at https://docs.docker.com/desktop/. Then, run

./clean.sh # because we are switching environments
docker build . -t pret/pokeplatinum
docker run -u $USER -w /rom -v .:/rom pret/pokeplatinum ./config.sh # first time only
docker run -u $USER -w /rom -v .:/rom pret/pokeplatinum ./build.sh
docker run -u $USER -w /rom -v .:/rom pret/pokeplatinum ./clean.sh # before switching environments
Loading