tauri-apps / tauri

Build smaller, faster, and more secure desktop and mobile applications with a web frontend.
https://tauri.app
Apache License 2.0
85.36k stars 2.58k forks source link

[bug] jenkins in mac studio m1 pro “proc macro panicked” “unknown codegen target null” #11734

Open guguji001 opened 2 days ago

guguji001 commented 2 days ago

Describe the bug

if i into mac studio and build manual, it’s success

but if i build in jenkins,it‘s error。

all environments are the same

error: proc macro panicked
  --> src/main.rs:52:14
   |
52 |         .run(tauri::generate_context!())
   |              ^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = help: message: unknown codegen target null

error: could not compile `app` (bin "app") due to 1 previous error

Reproduction

build-dependencies]
tauri-build = { version = "1.5.1", features = ['codegen']  }

[dependencies]
serde_json = "1.0.108"
serde = { version = "1.0", features = ["derive"] }
tauri = { version = "1.5.4",features = ["api-all"]}
log = { version = "0.4.20", features = ["std", "serde"] }
cmd_lib = "1.9.3"
nom = "3.2.1"
network-interface = "1.1.1"
wifi-rs = "0.2.4"
reqwest = { version = "0.11.23", features = ["json"] }
tokio = { version = "1.35.1", features = ["full"] }
screenshots = "0.5.3"
rusb = "0.9"
edid-rs = "0.1.0"
serde-xml-rs = "0.6.0"
regex = "1.10.5"
wio = "0.2.2"
log4rs = "1.3.0"

[target.'cfg(target_os = "macos")'.dependencies]
core-foundation = "0.9.4"
mach = "0.3.2"
plist = "1.7.0"

Expected behavior

No response

Full tauri info output

yarn run v1.22.19
$ tauri info

[✔] Environment
    - OS: Mac OS 14.4.1 X64
    ✔ Xcode Command Line Tools: installed
    ✔ rustc: 1.80.0 (051478957 2024-07-21)
    ✔ cargo: 1.80.0 (376290515 2024-07-16)
    ✔ rustup: 1.27.1 (54dd3d00f 2024-04-24)
    ✔ Rust toolchain: 1.80.0-aarch64-apple-darwin (default)
    - node: 16.18.1
    - yarn: 1.22.19
    - npm: 8.19.2

[-] Packages
    - tauri [RUST]: 1.8.1
    - tauri-build [RUST]: 1.5.5
    - wry [RUST]: 0.24.11
    - tao [RUST]: 0.16.10
    - @tauri-apps/api [NPM]: 1.5.3
    - @tauri-apps/cli [NPM]: 1.5.9

[-] App
    - build-type: bundle
    - CSP: unset
    - distDir: ../build
    - devPath: http://localhost:3000/
    - framework: React
✨  Done in 5.71s.

Stack trace

No response

Additional context

No response