nazmulidris / tauri-demo

Get Tauri to run on Linux

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Tauri and Linux

Prerequisites for Linux

1. Basics

Install the following from docs:

sudo apt update
sudo apt install libwebkit2gtk-4.0-dev \
    build-essential \
    curl \
    wget \
    file \
    libssl-dev \
    libgtk-3-dev \
    libayatana-appindicator3-dev \
    librsvg2-dev

2. gtk-rs

Also need gtk-rs from docs to remove this warning error: could not find system library 'webkit2gtk-4.1' required by the 'webkit2gtk-sys' crate.

sudo apt-get install -y libwebkit2gtk-4.1-dev build-essential

More info here: blog post.

3. xapp

Also need xapp from docs to remove this warning Failed to load module "xapp-gtk3-module".

sudo apt install xapp

4. WebKit driver

Also need WebKitWebDriver binary from docs.

sudo apt install webkit2gtk-driver

5. libsoup

Also need libsoup from here to remove this warning error: could not find system library 'libsoup-3.0' required by the 'soup3-sys' crate.

sudo apt -y install libsoup-3.0-common

More info here: blog post.

6. Tauri CLI

Also install the Tauri CLI dev tools

  • Via npm:

    npm install --save-dev @tauri-apps/cli
  • Via cargo:

    cargo install tauri-cli --locked --version 2.0.0-alpha.11

Run

Run with npx:

cd src-tauri
npx tauri dev

Run with cargo.

cd src-tauri
cargo tauri dev

Docs and References

About

Get Tauri to run on Linux


Languages

Language:Rust 46.3%Language:CSS 21.5%Language:HTML 16.2%Language:JavaScript 16.0%