[RF] Add RooFit headers to private CMake filesets - #20533
Conversation
Test Results 23 files 23 suites 3d 17h 2m 44s ⏱️ Results for commit b3730d2. ♻️ This comment has been updated with latest results. |
025f24a to
daf13d3
Compare
daf13d3 to
5b26933
Compare
To improve IDE experience. See also root-project#18419 and root-project#20515 Work towards https://its.cern.ch/jira/browse/ROOT-10915
5b26933 to
65b9f93
Compare
guitargeek
left a comment
There was a problem hiding this comment.
Thank you very much! A few comments inline.
Also, to make this work, you have to drop src/RooXYChi2Var.h from roofit/roofitcore/CMakeLists.txt, because that class doesn't exist anymore.
Co-authored-by: Jonas Rembser <jonas.rembser@cern.ch> Co-authored-by: ferdymercury <ferdymercury@users.noreply.github.com>
guitargeek
left a comment
There was a problem hiding this comment.
LGTM, thanks for this!
In general, I still don't think we should do this for ROOT at a larger scale until the minimum CMake version is raised or we figure out how to do this the right way with CMake macros or functions to we don't duplicate code all over the place.
But for RooFit in particular, I really like this change, because it also helps to harmonize the code with the CMake code in the standalone RooFit repository!
So for now, I would leave it at the existing precedents and come back to this later.
|
Thanks!
In my opinion, I think ROOT should think about this from another perspective. Rather than creating custom macros that outside users / developers find hard to understand, and inside users get often confused (LIBRARIES vs DEPENDENCIES, who chose those two names xD), we should make use of standard CMake nomenclature (PUBLIC vs PRIVATE), no one would get confused here. Here is my proposal for the future, with standard CMake > 3.23 nomenclature: This way, all the information is 'stored' in a standard CMake target. We do not need the annoying "Transform" or "Preprend" macro. Instead, you would need to create a NEW_ROOT_STL_PACKAGE macro that traverses the FILE_SET and generates the dictionaries and so on. No need to pass HEADERS and SOURCES or LINKDEF to that macro. Just the name of the CMake target and the dictionary options. Everything is parsed internally, targets must just correctly define Public or Private file_sets and a special Linkdef header fileset. The old ROOT_STL_PACKAGE can stay of course there for backward compatibility. |
|
I like that direction, that's exactly where I would like to go! So then the next step would be to prototype this new |
Yes, indeed. Retrieving from the defined CMake targets the different file sets is straightforward: In the new ROOT_STL macro, one would no longer need the calls to Main step would then be: and then instead of calling one would rely instead on the standard CMake install step specific for file_sets |
To improve IDE experience.
See also #18419 and #20515
Non-functional change.
Work towards https://its.cern.ch/jira/browse/ROOT-10915