This is an archive of the discontinued LLVM Phabricator instance.

build: extract LLVM distribution target handling
ClosedPublic

Authored by compnerd on Jun 6 2019, 2:31 PM.

Details

Summary

This extracts the LLVM distribution target handling into a support module. Extraction will enable us to restructure the builds to support multiple distribution configurations (e.g. developer and user) to permit us to build the development package and the user package at once.

Diff Detail

Repository
rL LLVM

Event Timeline

compnerd created this revision.Jun 6 2019, 2:31 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 6 2019, 2:31 PM
Herald added a subscriber: mgorny. · View Herald Transcript

This looks good, but what were you envisioning the interface would look like for configuring multiple distributions? It'd be a lot easier to judge with that context.

cmake/modules/LLVMDistributionSupport.cmake
1

License header?

This is technically a behavior change because with the old code, you wouldn't run any of the distribution code if LLVM_DISTRIBUTION_COMPONENTS was empty, even if LLVM_RUNTIME_DISTRIBUTION_COMPONENTS was non-empty. The new behavior seems more correct though.

What I am imagining is basically having a variable which specifies the distribution targets, and having variables which will be constructed based upon those names (similar to how variables for the runtimes are passed today).

smeenai accepted this revision.Jun 12 2019, 7:26 PM

Ah, so just having variables to hold the different distribution sets? Makes sense ... you'd need to adjust the CMake exporting logic, and I'm not quite sure how that'll play out yet, but we can see when we get to that.

This LGTM.

cmake/modules/LLVMDistributionSupport.cmake
1

Never mind, looks like we don't usually put the license header in build files.

This revision is now accepted and ready to land.Jun 12 2019, 7:26 PM
compnerd closed this revision.Jun 14 2019, 11:25 AM

SVN r363440