Skip to content

Conversation

@aenewton
Copy link
Contributor

The version of cmake currently listed in the docs is too low. It's possible that we could use a version somewhere between 3.19.6
and 3.24.3, but I chose the latest version that I tested successfully.

Resolves #62023

@AnthonyLatsis
Copy link
Collaborator

3.21.3 worked for me the other day. Do you remember which 3.21 patch version you had?

@aenewton
Copy link
Contributor Author

I don't remember, unfortunately.

@AnthonyLatsis
Copy link
Collaborator

3.21.3 worked for me the other day.

Worked for me just now. Do you mind bumping it to that instead?

@aenewton
Copy link
Contributor Author

I just found some logs that showed my previous version was 3.21.4. I might try doing some testing to see what exactly was going on. I wonder if there was a regression in 3.21.4

@AnthonyLatsis
Copy link
Collaborator

AnthonyLatsis commented Nov 17, 2022

Was update-checkout run in between building with the old vs. upgraded CMake? If so, it could have just been an LLVM issue.

@aenewton
Copy link
Contributor Author

Some test results:
I just did a fresh update checkout, then reinstalled cmake 3.21.3/4/5. All of those failed. I can bisect cmake versions to see which one fixes it

@AnthonyLatsis
Copy link
Collaborator

AnthonyLatsis commented Nov 17, 2022

I just did a fresh update checkout, then reinstalled cmake 3.21.3/4/5. All of those failed.

Could you also try utils/build-script --xcode --swift-darwin-supported-archs "$(uname -m) since that’s the recommended invocation from the tutorial (don’t forget to delete the build/Xcode-* directory before rebuilding)?

@aenewton
Copy link
Contributor Author

I'm actually getting different errors with that command. I'll keep poking around to see if I can narrow down what's truly the issue here. Thanks for helping me debug. I'll report back with any new findings.

@AnthonyLatsis
Copy link
Collaborator

I really appreciate the effort! Pinning down these nasty build errors is super helpful.

@LucianoPAlmeida
Copy link
Contributor

Some test results:
I just did a fresh update checkout, then reinstalled cmake 3.21.3/4/5. All of those failed. I can bisect cmake versions to see which one fixes it

Are all failing with the same error? The one from the forums thread?
Also, I'm on 3.22.2 and it works fine

@AnthonyLatsis
Copy link
Collaborator

Since 3.21.3 works for me but not Adam given the same checkout revision, I suspect it has something to do with the tools that ship with Xcode (I’ve got an older Xcode). The best we can do at this point is weed out the minimum version that cooperates with the latest Xcode release.

@AnthonyLatsis
Copy link
Collaborator

AnthonyLatsis commented Nov 20, 2022

@aenewton Giving you a heads-up that --xcode is (to our surprise) busted since Friday for some other reason, so no use debugging this right now.

@aenewton
Copy link
Contributor Author

Hi @AnthonyLatsis thanks for the heads up. I haven't had time to dig in anymore and I'll continue to hold off. Is there a GitHub issue number I can follow for the current --xcode problems?

@AnthonyLatsis
Copy link
Collaborator

I’m using #62205 to track it.

@AnthonyLatsis
Copy link
Collaborator

AnthonyLatsis commented Dec 1, 2022

@LucianoPAlmeida Does CMake 3.22.2 work for you on macOS 13, or an older OS?

@LucianoPAlmeida
Copy link
Contributor

@LucianoPAlmeida Does CMake 3.22.2 work for you on macOS 13, or an older OS?

Yeah, I'm on 13.0.1 (22A400) with Cmake 3.22.2 and up to beginning of the week it was all fine

@AnthonyLatsis
Copy link
Collaborator

I just did a fresh update checkout, then reinstalled cmake 3.21.3/4/5. All of those failed. I can bisect cmake versions to see which one fixes it

@aenewton By the way, was it a clean build each of those times?

@xedin
Copy link
Contributor

xedin commented Jan 14, 2023

Is this still viable?

@AnthonyLatsis
Copy link
Collaborator

Is this still viable?

Yes, it started happening to me as well after updating to Xcode 14.x. I suggest we bump the CMake version to 3.22.2 for macOS + Xcode specifically until we crack the bug. @LucianoPAlmeida Are you running Xcode 14.x too?

@LucianoPAlmeida
Copy link
Contributor

Yes, it started happening to me as well after updating to Xcode 14.x. I suggest we bump the CMake version to 3.22.2 for macOS + Xcode specifically until we crack the bug.

Sounds good

@LucianoPAlmeida Are you running Xcode 14.x too?

Yes, recently updated to 14.2

Copy link
Collaborator

@AnthonyLatsis AnthonyLatsis left a comment

Choose a reason for hiding this comment

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

@aenewton Are you up for wrapping this up?

@LucianoPAlmeida
Copy link
Contributor

@aenewton There is a conflict, so I think you have to rebase with main before we proceed with this =]

@AnthonyLatsis
Copy link
Collaborator

AnthonyLatsis commented Jan 18, 2023

Don’t forget to squash the commits and update the commit message to reflect what we have settled on!

Co-authored-by: Anthony Latsis <aqamoss3fan2010@gmail.com>
@aenewton
Copy link
Contributor Author

Okay, I think it's ready now. Thanks for all the comments!

@LucianoPAlmeida
Copy link
Contributor

@swift-ci Please smoke test

@LucianoPAlmeida
Copy link
Contributor

@swift-ci Please smoke test Linux Platform

@LucianoPAlmeida LucianoPAlmeida merged commit 4cd9877 into swiftlang:main Jan 19, 2023
@LucianoPAlmeida
Copy link
Contributor

I just hit an issue after update-checkout today trying to run --xcode

CMake Error at CMakeLists.txt:6 (project): The CMAKE_C_COMPILER: ${workspace}/build/Ninja-ReleaseAssert/llvm-macosx-arm64/bin/clang is not a full path to an existing compiler tool. Tell CMake where to find the compiler by setting either the environment variable "CC" or the CMake cache entry CMAKE_C_COMPILER to the full path to the compiler, or to the compiler name if it is in the PATH. 

After updating to cmake to 3.25.2 it seems to fixed.
Have any of you experienced that @AnthonyLatsis @xedin

@AnthonyLatsis
Copy link
Collaborator

Have any of you experienced that

I’m still running an older CMake because I was hoping the look into the earlier issue. Any ideas as to what caused this? Any software updates? Which CMakeLists file is this error pointing at?

@LucianoPAlmeida
Copy link
Contributor

I’m still running an older CMake because I was hoping the look into the earlier issue. Any ideas as to what caused this? Any software updates? Which CMakeLists file is this error pointing at?

Sorry, I didn't really investigate the issue, it initially looks like a recent change was using a variable that was not available in the cmake version(so I just updated). I can downgrade back and investigate further over the weekend.

Which CMakeLists file is this error pointing at?

Sorry, I don't remember seeing any. It just logged variables but I didn't search for them. I do remember thinking this was LLVM and not swift changes tho.
I can give more info if I manage a repro soon =]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment