Repository: tauri
Issue: [bug] [ios] Cannot build for iOS (building for 'iOS', but linking in object file built for 'zippered(macOS/Catalyst)')
Labels: type: bug,status: needs triage

### Describe the bug

I'm trying to build an existing macOS + Windows Tauri app for iOS as well. I did this by running `pnpm tauri ios init` and `pnpm tauri ios dev`. 

However, I run into:
```
Error: Cannot find module '/Users/venki/src/r2/apps/limitless/ts/src-tauri/gen/apple/tauri'
    at Module._resolveFilename (node:internal/modules/cjs/loader:1144:15)
    at Module._load (node:internal/modules/cjs/loader:985:27)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:135:12)
    at node:internal/main/run_main_module:28:49 {
  code: 'MODULE_NOT_FOUND',
  requireStack: []
}

Node.js v20.10.0
Command PhaseScriptExecution failed with a nonzero exit code

note: Run script build phase 'Build Rust Code' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'limitless-app_iOS' from project 'limitless-app')
** BUILD FAILED **


The following build commands failed:
	PhaseScriptExecution Build\ Rust\ Code /Users/venki/src/r2/apps/limitless/ts/src-tauri/gen/apple/build/limitless-app.build/debug-iphonesimulator/limitless-app_iOS.build/Script-856DF6B869FD769F10065C61.sh (in target 'limitless-app_iOS' from project 'limitless-app')
(1 failure)
    Error command ["xcodebuild"] exited with code 65

```

One note is: I tried to start a new sample iOS app with `create-tauri-app` and that works fine. So there's definitely something odd about this project. I'll try to work on some more of the differences, and figure out a repro, but I'd love any debugging advice to point me to the right direction on how to add iOS to an existing project.

More details about exactly what I ran:
- Be in the root directory (ie: the one containing `src` and `src-tauri`)
- `xcode-select --install`
- `brew install cocoapods`
- `pnpm tauri ios init`
- Modify `vite.config.ts` to add `host: 0.0.0.0`
- I needed to modify `Podfile` to remove the macOS target - strangely I didn't need to do this on the sample repo.
- `pnpm tauri ios dev`

Overall, I'd also appreciate any pointers into the Tauri repo I could investigate better. I don't really get what's trying to access `gen/apple/tauri` that doesn't seem like a real module to me.

### Reproduction

_No response_

### Expected behavior

_No response_

### Full `tauri info` output

```text
[✔] Environment
    - OS: Mac OS 14.4.1 X64
    ✔ Xcode Command Line Tools: installed
    ✔ rustc: 1.76.0 (07dca489a 2024-02-04)
    ✔ cargo: 1.76.0 (c84b36747 2024-01-18)
    ✔ rustup: 1.26.0 (5af9b9484 2023-04-05)
    ✔ Rust toolchain: stable-aarch64-apple-darwin (default)
    - node: 20.10.0
    - pnpm: 8.11.0
    - yarn: 1.22.19
    - npm: 8.1.2

[-] Packages
    - tauri [RUST]: 2.0.0-beta.12
    - tauri-build [RUST]: 2.0.0-beta.10
    - wry [RUST]: 0.37.0
    - tao [RUST]: 0.26.0
    - @tauri-apps/api [NPM]: 2.0.0-beta.0
    - @tauri-apps/cli [NPM]: 2.0.0-beta.11

[-] App
    - build-type: bundle
    - CSP: unset
    - frontendDist: http://localhost:5173/
    - devUrl: http://localhost:5173/
    - framework: React
    - bundler: Vite
```


### Stack trace

_No response_

### Additional context

_No response_