mesonbuild / mesonbuild/meson

xcode backend builds for wrong CPU architecture

Open
#8,552 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

backend:xcode
Dominant language
Python
Stars
6.6k
Forks
1.9k
Avg merge
2d 6h
Merged PRs (30d)
33

Description

Describe the bug
After upgrading xcode to version 12.4, meson's xcode backend seems to try to build for all CPU architectures (e.g. arm64 and intel), instead of just the one that the user specifies. Unfortunately, when building for arm64, I get compile error (because the 3rd-party libs are compiled for intel) and the build fails.

To Reproduce
Upgrade to xcode 12.4 or newer, and try building an example project using meson, on a PC with intel CPU

Expected behavior
Meson should honor the "host" cpu param

system parameters
Native build
Mac OS Catalina
meson version 0.57.1
python version 3.9.2

** output **:

warning: ONLY_ACTIVE_ARCH=YES requested with multiple ARCHS and no run destination to provide an active architecture; building for all applicable architectures

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the example project with Meson's Xcode backend on an Intel Mac using Xcode 12.4 or newer, with the host CPU parameter set. Inspect the Xcode backend's architecture handling and verify that the generated build honors the requested host architecture rather than building for arm64 and Intel.

Written by the indexing model from the issue text.

Assessment

Tech stack
macos, python
Domain
build-system, operating-systems
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.