Selaa lähdekoodia

remove __TAURI_WORKSPACE__ workaround

Lucas Nogueira 2 vuotta sitten
vanhempi
sitoutus
84b2dcfe3c
2 muutettua tiedostoa jossa 0 lisäystä ja 29 poistoa
  1. 0 2
      .cargo/config
  2. 0 27
      core/tauri/build.rs

+ 0 - 2
.cargo/config

@@ -1,2 +0,0 @@
-[env]
-__TAURI_WORKSPACE__ = "true"

+ 0 - 27
core/tauri/build.rs

@@ -57,14 +57,6 @@ fn main() {
   )
   .expect("failed to write checked_features file");
 
-  // workaround needed to prevent `STATUS_ENTRYPOINT_NOT_FOUND` error
-  // see https://github.com/tauri-apps/tauri/pull/4383#issuecomment-1212221864
-  let target_env = std::env::var("CARGO_CFG_TARGET_ENV");
-  let is_tauri_workspace = std::env::var("__TAURI_WORKSPACE__").map_or(false, |v| v == "true");
-  if is_tauri_workspace && target_os == "windows" && Ok("msvc") == target_env.as_deref() {
-    add_manifest();
-  }
-
   if target_os == "android" {
     if let Ok(kotlin_out_dir) = std::env::var("WRY_ANDROID_KOTLIN_FILES_OUT_DIR") {
       fn env_var(var: &str) -> String {
@@ -132,22 +124,3 @@ fn main() {
     }
   }
 }
-
-fn add_manifest() {
-  static WINDOWS_MANIFEST_FILE: &str = "window-app-manifest.xml";
-
-  let manifest = std::env::current_dir()
-    .unwrap()
-    .join("../tauri-build/src")
-    .join(WINDOWS_MANIFEST_FILE);
-
-  println!("cargo:rerun-if-changed={}", manifest.display());
-  // Embed the Windows application manifest file.
-  println!("cargo:rustc-link-arg=/MANIFEST:EMBED");
-  println!(
-    "cargo:rustc-link-arg=/MANIFESTINPUT:{}",
-    manifest.to_str().unwrap()
-  );
-  // Turn linker warnings into errors.
-  println!("cargo:rustc-link-arg=/WX");
-}