浏览代码

fix(core): compilation error on older Linux versions, fixes #5684 (#5697)

Fabian-Lars 2 年之前
父节点
当前提交
b490308c88
共有 3 个文件被更改,包括 10 次插入4 次删除
  1. 6 0
      .changes/linux-webkitgtk-version.md
  2. 2 2
      core/tauri-runtime-wry/Cargo.toml
  3. 2 2
      core/tauri/Cargo.toml

+ 6 - 0
.changes/linux-webkitgtk-version.md

@@ -0,0 +1,6 @@
+---
+'tauri': 'patch'
+'tauri-runtime-wry': 'patch'
+---
+
+Fix compatibility with older Linux distributions.

+ 2 - 2
core/tauri-runtime-wry/Cargo.toml

@@ -29,7 +29,7 @@ webview2-com = "0.19.1"
 
 [target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"openbsd\", target_os = \"netbsd\"))".dependencies]
 gtk = { version = "0.15", features = [ "v3_20" ] }
-webkit2gtk = { version = "0.18.2", features = [ "v2_36" ] }
+webkit2gtk = { version = "0.18.2", features = [ "v2_22" ] }
 percent-encoding = "2.1"
 
 [target."cfg(any(target_os = \"ios\", target_os = \"macos\"))".dependencies]
@@ -47,4 +47,4 @@ macos-private-api = [
 objc-exception = [ "wry/objc-exception" ]
 global-shortcut = [ "tauri-runtime/global-shortcut" ]
 clipboard = [ "tauri-runtime/clipboard" ]
-linux-headers = [ "wry/linux-headers" ]
+linux-headers = [ "wry/linux-headers", "webkit2gtk/v2_36" ]

+ 2 - 2
core/tauri/Cargo.toml

@@ -93,7 +93,7 @@ notify-rust = { version = "4.5", default-features = false, features = [ "d" ], o
 [target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"openbsd\", target_os = \"netbsd\"))".dependencies]
 gtk = { version = "0.15", features = [ "v3_20" ] }
 glib = "0.15"
-webkit2gtk = { version = "0.18.2", features = [ "v2_36" ] }
+webkit2gtk = { version = "0.18.2", features = [ "v2_22" ] }
 
 [target."cfg(target_os = \"macos\")".dependencies]
 embed_plist = "1.2"
@@ -129,7 +129,7 @@ default = [ "wry", "compression", "objc-exception" ]
 compression = [ "tauri-macros/compression", "tauri-utils/compression" ]
 wry = [ "tauri-runtime-wry" ]
 objc-exception = [ "tauri-runtime-wry/objc-exception" ]
-linux-protocol-headers = [ "tauri-runtime-wry/linux-headers" ]
+linux-protocol-headers = [ "tauri-runtime-wry/linux-headers", "webkit2gtk/v2_36" ]
 isolation = [ "tauri-utils/isolation", "tauri-macros/isolation" ]
 custom-protocol = [ "tauri-macros/custom-protocol" ]
 updater = [