[PATCH] D27396: Install the LLVM header module.modulemaps
Eric Fiselier via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Dec 4 15:58:08 PST 2016
EricWF created this revision.
EricWF added reviewers: rsmith, beanz, v.g.vassilev, aprantl.
EricWF added subscribers: llvm-commits, rsmith.
Herald added subscribers: mgorny, dschuff, sanjoy, jfb.
Currently the LLVM module.modulemap files are not installed along side the headers. This is because these module maps only work during in-tree builds where some of the headers are in the build directory. Once those generated headers are installed with the in-tree headers the module maps no longer work.
This patch adds a new map called `module.modulemap.install` which correctly handles the LLVM headers in their install configuration. The changes needed to support that are:
1. Build `llvm/Support/DataTypes.h` as a separate module instead of as part of LLVM_Utils. This is required to avoid a cyclic dependency between the LLVM_C and LLVM_Utils modules.
2. Add the generated `Config/*.def` headers to the LLVM_Config module.
3. Handle the `IR/Attributes.gen` and `IR/Intrinsics.gen` headers so that the LLVM_IR umbrella is complete.
Unfortunately I don't think there is a way to modify the existing `module.modulemap` file so that it works with both in-tree and installed headers. @rsmith is there a better way to handle this?
https://reviews.llvm.org/D27396
Files:
CMakeLists.txt
include/llvm/module.modulemap.install
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D27396.80216.patch
Type: text/x-patch
Size: 10860 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161204/5e541499/attachment.bin>
More information about the llvm-commits
mailing list