# Prerequistites

<p class="callout danger">MacOS installation steps were not tested, proceed at your own risk!</p>

### Rust

Install Rust via rustup — the official Rust toolchain installer.

**All platforms:**<span style="white-space: pre-wrap;"> go to </span>[https://rustup.rs](https://rustup.rs)<span style="white-space: pre-wrap;"> and follow the instructions, or run:</span>

```bash
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
```

After installation, restart your terminal and verify:

```bash
rustc --version
cargo --version
```

### Bun

<span style="white-space: pre-wrap;">Bun is the JavaScript runtime and package manager used for the frontend. </span>

<p class="callout warning"><span style="white-space: pre-wrap;">Using npm or yarn will </span>**not**<span style="white-space: pre-wrap;"> work with the current setup, there are scripts that specifically call for bun.</span></p>

**Linux / macOS:**

```bash
curl -fsSL https://bun.sh/install | bash
```

**Windows:**<span style="white-space: pre-wrap;"> download the installer from </span>[https://bun.sh](https://bun.sh)

Verify:

```bash
bun --version
```

### Tauri CLI prerequisites

Tauri requires some OS-level dependencies in addition to Rust.

**Linux (Ubuntu/Debian):**

```bash
sudo apt update
sudo apt install libwebkit2gtk-4.1-dev libgtk-3-dev \
  libayatana-appindicator3-dev librsvg2-dev patchelf
```

**Windows:**<span style="white-space: pre-wrap;"> install the </span>[Microsoft C++ Build Tools](https://visualstudio.microsoft.com/visual-cpp-build-tools/)<span style="white-space: pre-wrap;"> and </span>[WebView2](https://developer.microsoft.com/en-us/microsoft-edge/webview2/)<span style="white-space: pre-wrap;"> (usually already present on Windows 10/11).</span>

**macOS:**

```bash
xcode-select --install
```

### GStreamer

<span style="white-space: pre-wrap;">GStreamer handles video decoding and streaming. Version </span>**1.22.x**<span style="white-space: pre-wrap;"> is required to match the Rust crate versions (</span>`<span class="editor-theme-code">gstreamer = "0.22"</span>`<span style="white-space: pre-wrap;"> maps to GStreamer 1.22).</span>

**Linux (Ubuntu/Debian):**

```bash
sudo apt install \
  libgstreamer1.0-dev \
  libgstreamer-plugins-base1.0-dev \
  libgstreamer-plugins-bad1.0-dev \
  gstreamer1.0-plugins-base \
  gstreamer1.0-plugins-good \
  gstreamer1.0-plugins-bad \
  gstreamer1.0-plugins-ugly \
  gstreamer1.0-libav \
  gstreamer1.0-tools
```

Verify:

```bash
gst-launch-1.0 --version
```

**Windows:**

1. <span style="white-space: pre-wrap;">Download the </span>**MSVC 64-bit**<span style="white-space: pre-wrap;"> installer for GStreamer 1.22.x from </span>[https://gstreamer.freedesktop.org/download/](https://gstreamer.freedesktop.org/download/)
2. <span style="white-space: pre-wrap;">Download both the </span>**runtime**<span style="white-space: pre-wrap;"> and </span>**development**<span style="white-space: pre-wrap;"> installers</span>
3. <span style="white-space: pre-wrap;">Install both to the default path: </span>`<span class="editor-theme-code">C:\gstreamer\1.0\msvc_x86_64\</span>`
4. Add the GStreamer bin directory to your system PATH:

```
C:\gstreamer\1.0\msvc_x86_64\bin
```

Verify in a new terminal:

```bash
gst-launch-1.0 --version
```

<p class="callout info"><span style="white-space: pre-wrap;">The </span>`<span class="editor-theme-code">GST_PLUGIN_PATH</span>`<span style="white-space: pre-wrap;"> environment variable is set automatically by the app at runtime (in </span>`<span class="editor-theme-code">lib.rs</span>`), so you do not need to set it manually.</p>

**macOS:**

```bash
brew install gstreamer gst-plugins-base gst-plugins-good \
  gst-plugins-bad gst-plugins-ugly gst-libav
```

---