Skip to content

Sync eng/native with runtime #2789

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

Merged
merged 1 commit into from
Jan 17, 2022

Conversation

am11
Copy link
Member

@am11 am11 commented Dec 26, 2021

There was a breaking change in arcade's eng/common/native/init-compiler.sh which is used by eng/native/build-commons.sh: dotnet/runtime#63126

To avoid blocking the next arcade update, I have rsync'd eng/common/native/ from arcade and eng/native/ from runtime.

@@ -117,7 +117,7 @@ build_native()
scan_build=scan-build
fi

nextCommand="\"$__RepoRootDir/eng/native/gen-buildsys.sh\" \"$cmakeDir\" \"$intermediatesDir\" $platformArch $__Compiler \"$__CompilerMajorVersion\" \"$__CompilerMinorVersion\" $__BuildType \"$generator\" $scan_build $cmakeArgs"
nextCommand="\"$__RepoRootDir/eng/native/gen-buildsys.sh\" \"$cmakeDir\" \"$intermediatesDir\" $platformArch $__Compiler $__BuildType \"$generator\" $scan_build $cmakeArgs"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This (and the changes in gen-buildsys.sh) was the main breaking change, because we are using positional arguments in internal scripts as opposed to named ones. Before, we were splitting up -clang12.2 into "clang" "12" "2" in this script, and passing it to init-compiler.sh. Now we pass the raw value clang12.2 down to init-compiler.sh, which splits the compiler name and version parts autonomously.

Related to these user-facing scenarios:

# LLVM toolchain is default
# uses latest available clang by default. if someone has `clang-8`, `clang-9` and `clang-10`,
# init-compiler picks up clang 10
./build.sh

# same here, find latest version of clang on the system
./build.sh -clang

# find clang 12 explicitly on the machine, and error out if it was not found; no fallback.
# this was an explicit decision made with JanV in 2020. so we don't accidentally build
# with wrong toolchain in official builds.
./build.sh -clang12 / -clang-12

# similarly, for GNU toolchain
# find latest of gcc and use that to compile
./build.sh -gcc

# find gcc 11 on machine, if not found, error out
./build.sh -gcc11 / -gcc-11

cc @mikem8361, @hoyosjs

@mikem8361 mikem8361 requested a review from hoyosjs January 11, 2022 19:05
@mikem8361 mikem8361 merged commit 8f45346 into dotnet:main Jan 17, 2022
@mikem8361
Copy link

@am11, these changes seem to "unsync" some changes that are in runtime/eng/native in the diagnostic repro. I found them in my current PAL/inc file diagnostics repo sync with the runtime repo. Things like removing the clang version parameters from gen-buildsys.sh command and where it is called in build-commons.sh. The runtime eng/native files still pass them. I can go into more detail but I'm curious what branch/commit id you sync'ed too in the runtime repo? I'm sync'ing to the recent main branch commit #2692407f03ce8b648c54daa4d3a3eb534132edc9

@mikem8361
Copy link

Sorry, never mind. I was comparing to the wrong branch.

@github-actions github-actions bot locked and limited conversation to collaborators Jan 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants