Skip to content

Fix macOS native tool selection for Apple Silicon and Intel - #5

Open
kimdongup wants to merge 4 commits into
maze-mei:mainfrom
kimdongup:main
Open

kimdongup wants to merge 4 commits into
maze-mei:mainfrom
kimdongup:main

Conversation

@kimdongup

Copy link
Copy Markdown
Contributor

Apple Silicon과 Intel Mac에서 각각 맞는 scrcpy와 ADB proxy 바이너리를 선택하도록 수정
Rosetta 없이 Apple Silicon에서 실행 실패하던 문제 해결
아키텍처별 fallback 및 테스트 추가

직접 Apple Silicon과 Intel Mac에서 수행해 보고 올려 드립니다. 수정은 별거 없어요. tools 폴더에 아키텍처별로 수행되게 고쳤네요.

DeX launch failed on Apple Silicon Macs without Rosetta because the bundled
tools were x86_64 only: scrcpy exited before its window was ready. The
repository now ships scrcpy per architecture and the ADB proxy under
tools/adb-proxy/osx-arm64 and tools/adb-proxy/osx-x64, so the Mac build has
to pick the slice that matches the running CPU.

- MacPathProvider resolves ADB, scrcpy and the ADB proxy for the running CPU
  and prefers the architecture specific scrcpy folder over the legacy
  x86_64 build.
- MacExecutableInspector reads thin and universal Mach-O headers so a
  bundled binary is only selected when this Mac can execute it.
- AdbProxyLocator is shared by FileTransferCoordinator and
  EnvironmentCheckService so managed file transfer launches the proxy that
  matches the running CPU, with the previous fallback order kept for
  Windows and for machines without an architecture folder.
- InteractiveHost re-resolves stored ADB and scrcpy paths that cannot run
  on this Mac.
- Tests cover the architecture ordered candidates, Mach-O inspection and
  the proxy fallback.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant