From cc0e2c487789587149e766be6e8eabefdd7fc385 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Kurlbaum?= Date: Thu, 24 Feb 2022 14:32:43 +0100 Subject: [PATCH] Add options for compilation on systems that lack libappindicator3 --- Cargo.toml | 1 + docs/guide/src/hello_world.md | 9 +++++++-- docs/guide/src/setup.md | 6 ++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index d4d3f874e..26ced24cb 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -38,6 +38,7 @@ html = ["dioxus-html"] ssr = ["dioxus-ssr"] web = ["dioxus-web"] desktop = ["dioxus-desktop"] +ayatana = ["dioxus-desktop/ayatana"] router = ["dioxus-router"] [workspace] diff --git a/docs/guide/src/hello_world.md b/docs/guide/src/hello_world.md index 32cdab4a9..6bcc77e30 100644 --- a/docs/guide/src/hello_world.md +++ b/docs/guide/src/hello_world.md @@ -81,6 +81,13 @@ $ cargo add dioxus --features desktop It's very important to add `dioxus` with the `desktop` feature for this example. The `dioxus` crate is a batteries-include crate that combines a bunch of utility crates together, ensuring compatibility of the most important parts of the ecosystem. Under the hood, the `dioxus` crate configures various renderers, hooks, debug tooling, and more. The `desktop` feature ensures the we only depend on the smallest set of required crates to compile and render. +If you system does not provide the `libappindicator3` library, like Debian/bullseye, you can enable the replacement `ayatana` with an additional flag: + +```shell +$ # On Debian/bullseye use: +$ cargo add dioxus --features desktop --features ayatana +``` + If you plan to develop extensions for the `Dioxus` ecosystem, please use the `dioxus` crate with the `core` feature to limit the amount of dependencies your project brings in. ### Our first app @@ -143,5 +150,3 @@ For now, just know that `Scope` lets you store state with hooks and render eleme ## Moving on Congrats! You've built your first desktop application with Dioxus. Next, we're going to learn about the basics of building interactive user interfaces. - - diff --git a/docs/guide/src/setup.md b/docs/guide/src/setup.md index 75cfc6606..1bbcec213 100644 --- a/docs/guide/src/setup.md +++ b/docs/guide/src/setup.md @@ -52,6 +52,12 @@ Webview Linux apps require WebkitGtk. When distributing, this can be part of you sudo apt install libwebkit2gtk-4.0-dev libgtk-3-dev libappindicator3-dev ``` +When using Debian/bullseye `libappindicator3-dev` is no longer available but replaced by `libayatana-appindicator3-dev`. + +``` +# on Debian/bullseye use: +sudo apt install libwebkit2gtk-4.0-dev libgtk-3-dev libayatanta-appindicator3-dev +``` If you run into issues, make sure you have all the basics installed, as outlined in the [Tauri docs](https://tauri.studio/en/docs/get-started/setup-linux).