Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SCons: Process platform-specific flags earlier #91791

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

akien-mga
Copy link
Member

Some of the logic in SCons depends on flags that get overridden in the platform-specific detect.py, so it needs to be processed first.

For example the Android/iOS/Web platforms override the default target to template_debug, but this was processed too late so e.g. the logic that sets env.editor_build would set it to true due to the default target value in the environment being editor.

@akien-mga akien-mga added bug topic:buildsystem needs testing cherrypick:3.x Considered for cherry-picking into a future 3.x release cherrypick:3.5 Considered for cherry-picking into a future 3.5.x release cherrypick:4.1 Considered for cherry-picking into a future 4.1.x release cherrypick:4.2 Considered for cherry-picking into a future 4.2.x release labels May 10, 2024
@akien-mga akien-mga added this to the 4.3 milestone May 10, 2024
@akien-mga akien-mga requested a review from a team as a code owner May 10, 2024 10:09
@akien-mga akien-mga force-pushed the scons-process-platform-flags-early branch from 3702109 to b439234 Compare May 10, 2024 10:11
@akien-mga
Copy link
Member Author

Seems to break some stuff:

$ scons p=web production=yes
/home/akien/.local/bin/scons p=web production=yes 2>&1
scons: Reading SConscript files ...
Auto-detected 16 CPU cores available for build parallelism. Using 15 cores by default. You can override it with the -j argument.
ERROR: Unsupported CPU architecture "auto" for Web. Supported architectures are: wasm32.

@akien-mga akien-mga marked this pull request as draft May 10, 2024 10:12
@AThousandShips
Copy link
Member

AThousandShips commented May 10, 2024

Related (probably supersedes it):

@akien-mga
Copy link
Member Author

Related (probably supersedes it):

Doesn't supersede it yet, but #91794 should.

@akien-mga akien-mga force-pushed the scons-process-platform-flags-early branch 2 times, most recently from 6e4be05 to c794d7e Compare May 13, 2024 08:17
@akien-mga akien-mga marked this pull request as ready for review May 13, 2024 08:17
@akien-mga akien-mga requested review from a team as code owners May 13, 2024 08:17
Some of the logic in SCons depends on flags that get overridden in the
platform-specific `detect.py`, so it needs to be processed first.

For example the Android/iOS/Web platforms override the default `target`
to `template_debug`, but this was processed too late so e.g. the logic
that sets `env.editor_build` would set it to true due to the default
`target` value in the environment being `editor`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug cherrypick:3.x Considered for cherry-picking into a future 3.x release cherrypick:3.5 Considered for cherry-picking into a future 3.5.x release cherrypick:4.1 Considered for cherry-picking into a future 4.1.x release cherrypick:4.2 Considered for cherry-picking into a future 4.2.x release needs testing topic:buildsystem
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants