Page MenuHomePhabricator

[lldb][CMake] Generating Xcode projects
ClosedPublic

Authored by sgraenitz on Aug 6 2019, 3:24 AM.

Details

Summary

Print a warning if the wrong cache script is used when generating a Xcode project, because it's too easy to confuse with Apple-lldb-macOS.cmake

When building with Xcode, we recommend using the corresponding cache
script.  If this was a mistake, clean your lean build directory and re-run
CMake with:

  -C /path/to/llvm-project/lldb/cmake/caches/Apple-lldb-Xcode.cmake

See: https://lldb.llvm.org/resources/build.html#cmakegeneratedxcodeproject

Also set the generator inside the cache script.

Diff Detail

Repository
rL LLVM

Event Timeline

sgraenitz created this revision.Aug 6 2019, 3:24 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 6 2019, 3:24 AM
Herald added a subscriber: mgorny. · View Herald Transcript
JDevlieghere accepted this revision.Aug 6 2019, 8:50 AM

Small comment about the working, but the change itself LGTM.

lldb/cmake/modules/LLDBConfig.cmake
77 ↗(On Diff #213564)

[bikeshedding] I think we should say something like:

When building with Xcode, we recommend using the corresponding cache script. If this was a mistake, clean your lean your build directory and re-run CMake with:

This revision is now accepted and ready to land.Aug 6 2019, 8:50 AM
sgraenitz updated this revision to Diff 213637.Aug 6 2019, 9:18 AM
sgraenitz marked an inline comment as done.

Improve warning message

sgraenitz edited the summary of this revision. (Show Details)Aug 6 2019, 9:19 AM

Thanks for doing this. Looks okay to me just one typo... But I don't know CMake well enough to comment on substance...

lldb/cmake/modules/LLDBConfig.cmake
78 ↗(On Diff #213637)

This should work not just for Jack Spratt but also his wife! "LEAN build directory"

Closed by commit rL368066: [lldb][CMake] Generating Xcode projects (authored by stefan.graenitz, committed by ). · Explain WhyAug 6 2019, 10:21 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptAug 6 2019, 10:21 AM
sgraenitz marked an inline comment as done.Aug 6 2019, 10:22 AM