The Tauri v1 pre-requisite libwebkit2gtk-4.0-dev is not available in Ubuntu 24 repositories. This causes an error when installing the pre-requisites specified here, and when running cargo tauri dev on Ubuntu 24.
Note: libwebkit2gtk-4.1-dev is available but doesn't help with Tauri 1.
E: Unable to locate package libwebkit2gtk-4.0-dev
E: Couldn't find any package by glob 'libwebkit2gtk-4.0-dev'
And cargo tauri dev:
The following warnings were emitted during compilation:
warning: javascriptcore-rs-sys@0.4.0:
error: failed to run custom build command for `javascriptcore-rs-sys v0.4.0`
Caused by:
process didn't exit successfully: `/home/mrh/src/safe-browser/awe/src-tauri/target/debug/build/javascriptcore-rs-sys-855dc84908b0218c/build-script-build` (exit status: 1)
--- stdout
cargo:rerun-if-env-changed=JAVASCRIPTCOREGTK_4.0_NO_PKG_CONFIG
cargo:rerun-if-env-changed=PKG_CONFIG_x86_64-unknown-linux-gnu
cargo:rerun-if-env-changed=PKG_CONFIG_x86_64_unknown_linux_gnu
cargo:rerun-if-env-changed=HOST_PKG_CONFIG
cargo:rerun-if-env-changed=PKG_CONFIG
cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64-unknown-linux-gnu
cargo:rerun-if-env-changed=PKG_CONFIG_PATH_x86_64_unknown_linux_gnu
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
cargo:rerun-if-env-changed=PKG_CONFIG_PATH
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64-unknown-linux-gnu
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_x86_64_unknown_linux_gnu
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64-unknown-linux-gnu
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_x86_64_unknown_linux_gnu
cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR
cargo:warning=
pkg-config exited with status code 1
> PKG_CONFIG_PATH=/home/mrh/.gvm/pkgsets/go1.15/global/overlay/lib/pkgconfig: PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1 pkg-config --libs --cflags javascriptcoregtk-4.0 javascriptcoregtk-4.0 >= 2.24
The system library `javascriptcoregtk-4.0` required by crate `javascriptcore-rs-sys` was not found.
The file `javascriptcoregtk-4.0.pc` needs to be installed and the PKG_CONFIG_PATH environment variable must contain its parent directory.
PKG_CONFIG_PATH contains the following:
- /home/mrh/.gvm/pkgsets/go1.15/global/overlay/lib/pkgconfig
-
HINT: you may need to install a package such as javascriptcoregtk-4.0, javascriptcoregtk-4.0-dev or javascriptcoregtk-4.0-devel.
warning: build failed, waiting for other jobs to finish...
Workaround
I worked around this by adding the following line to /etc/apt/sources.list:
deb http://gb.archive.ubuntu.com/ubuntu jammy main
Describe the bug
The Tauri v1 pre-requisite
libwebkit2gtk-4.0-dev
is not available in Ubuntu 24 repositories. This causes an error when installing the pre-requisites specified here, and when runningcargo tauri dev
on Ubuntu 24.Note:
libwebkit2gtk-4.1-dev
is available but doesn't help with Tauri 1.Reproduction
Run:
reports:
And
cargo tauri dev
:Workaround
I worked around this by adding the following line to /etc/apt/sources.list:
deb http://gb.archive.ubuntu.com/ubuntu jammy main
Then doing:
Expected behavior
no errors
Full
tauri info
outputStack trace
No response
Additional context
No response