Thank you! When you say having an export set that the other exports then depend on, do you mean the COMPONENT option of the install(EXPORT) signature, or something else? (Sadly the project I’m working with is still on CMake 3.4.3, whose documentation says something very different for the COMPONENT option than the latest version, but I’ll cross that bridge when I get to it.)
From: Craig Scott <craig.sc...@crascit.com> Date: Saturday, June 15, 2019 at 10:43 PM To: Shoaib Meenai <smee...@fb.com> Cc: "cmake@cmake.org" <cmake@cmake.org> Subject: Re: [CMake] Multiple exports for a target installation On Sat, Jun 15, 2019 at 9:03 PM Shoaib Meenai <smee...@fb.com<mailto:smee...@fb.com>> wrote: Is it possible to associate a target with multiple exports? For example, if I'm building a project where I want to create multiple export sets, but there's some overlap in targets between those sets. I tried passing multiple EXPORT options to the install(TARGETS) signature but I just got an error: install TARGETS given unknown argument "EXPORT". Typically, you'd want your export sets to not be overlapping and to contain no cyclic dependencies. If you have a target in multiple export sets, it suggests that you probably should factor out that target to a separate export set that other exports then depend on. That said, if you have a scenario that legitimately requires a target in multiple export sets, then you would need to use multiple install() commands to achieve this, specifying a different export set for each one. -- Craig Scott Melbourne, Australia https://crascit.com<https://urldefense.proofpoint.com/v2/url?u=https-3A__crascit.com&d=DwMFaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=o3kDXzdBUE3ljQXKeTWOMw&m=on4z0WGnwFnkVmDOCqIFdWlFaYpovsd4phHIcUgPrpk&s=xtBD4V4zZnM8lf5f41WOQ8MblhgMCye_s3uF7xbq_Hc&e=> Get the hand-book for every CMake user: Professional CMake: A Practical Guide<https://urldefense.proofpoint.com/v2/url?u=https-3A__crascit.com_professional-2Dcmake_&d=DwMFaQ&c=5VD0RTtNlTh3ycd41b3MUw&r=o3kDXzdBUE3ljQXKeTWOMw&m=on4z0WGnwFnkVmDOCqIFdWlFaYpovsd4phHIcUgPrpk&s=_55JCkwuEWq36iPA22_aJhSbndgvG-h07aMzraCTUuw&e=>
-- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: https://cmake.org/mailman/listinfo/cmake