[build-script]Rebuilding Swift 5.4 is still troublesome?

Following:
My previous post in this forum

swift/README.md
swift/GettingStarted

My steps:

git clone git@github.com:apple/swift.git
cd swift
utils/update-checkout --clone
utils/update-checkout --scheme release/5.4

Now , from my understanding here, during the clone stage, since swift/ is still on main, it tried to clone swift-atomics, nice.
However, when I'm switching scheme back to release/5.4, I got a KeyError or something when handling atomics, which I guess is because atomics is not available in 5.4 as shown in update-checkout-config.json

NDK has a nice little step-by-step guide to rebuild any release, may I suggest we provide the same?

So I assume the "correct" approach (which seemed to work for me at least) would be

utils/update-checkout --scheme release/5.4
utils/update-checkout --clone
utils/update-checkout --scheme release/5.4

which the first scheme command resets swift itself to 5.4 and thus avoiding creating unwanted swift-atomics ? I'm dumb so any confirmation would be much appreciated

This errors out too:

naville@MB0 [15:57:06] [~/Development/AppleLLVM2/swift] [heads/swift-5.4-RELEASE]
-> % git checkout main
Updating files: 100% (4685/4685), done.
Switched to branch 'main'
Your branch is up to date with 'origin/main'.

-> % utils/update-checkout --tag swift-5.4-RELEASE
You don't have all swift sources. Call this script with --clone to get them.
Running ``update_single_repository`` with up to 24 processes.
Updating '/Users/naville/Development/AppleLLVM2/swift'
/Users/naville/Development/AppleLLVM2/swift
+ git checkout swift-5.4-RELEASE
warning: refname 'swift-5.4-RELEASE' is ambiguous.
Switched to branch 'swift-5.4-RELEASE'

/Users/naville/Development/AppleLLVM2/swift
+ git fetch --recurse-submodules=yes --tags

/Users/naville/Development/AppleLLVM2/swift
+ git rebase FETCH_HEAD
Auto-merging lib/IRGen/IRGen.cpp
CONFLICT (content): Merge conflict in lib/IRGen/IRGen.cpp
error: could not apply 6d3dceaf472... [master-next] Reapply "[IRGen] The "default" LLVM code model is now Small."
Resolve all conflicts manually, mark them as resolved with
"git add/rm <conflicted_files>", then run "git rebase --continue".
You can instead skip this commit: run "git rebase --skip".
To abort and get back to the state before "git rebase", run "git rebase --abort".
Could not apply 6d3dceaf472... [master-next] Reapply "[IRGen] The "default" LLVM code model is now Small."

Error on repo "/Users/naville/Development/AppleLLVM2/swift": Traceback (most recent call last):
  File "/Users/naville/Development/AppleLLVM2/swift/utils/update_checkout/update_checkout/update_checkout.py", line 208, in update_single_repository
  File "/Users/naville/Development/AppleLLVM2/swift/utils/swift_build_support/swift_build_support/shell.py", line 244, in run
    if fail_count == 0:
Exception: ['git', 'rebase', 'FETCH_HEAD']

======UPDATE FAILURES======
/Users/naville/Development/AppleLLVM2/swift failed (ret=1): ['git', 'rebase', 'FETCH_HEAD']
error: could not apply 6d3dceaf472... [master-next] Reapply "[IRGen] The "default" LLVM code model is now Small."
Resolve all conflicts manually, mark them as resolved with
"git add/rm <conflicted_files>", then run "git rebase --continue".
You can instead skip this commit: run "git rebase --skip".
To abort and get back to the state before "git rebase", run "git rebase --abort".
Could not apply 6d3dceaf472... [master-next] Reapply "[IRGen] The "default" LLVM code model is now Small."

update-checkout failed, fix errors and try again

Terms of Service

Privacy Policy

Cookie Policy