[webkit-dev] Reducing / removing use of Makefile based DerivedSources.make
weinig at apple.com
Sun Oct 18 11:01:56 PDT 2020
One direct benefit of moving away from DerivedSources.make would likely be (I say likely, as the details of how it works out are far from certain in my mind) removing at least one place that a IDL file needs to be listed as we would not need to explicitly the list the IDL file in DerivedSources.make, and would only need to ensure it was in some *input.xcfilelist.
But the idea of sharing “input” lists is very compelling. Just focusing on the IDL files themselves, I wonder if we could construct an input file that could serve both CMake and Xcode. It seems like CMake has the ability to read files into variables (https://cmake.org/cmake/help/latest/command/file.html#reading <https://cmake.org/cmake/help/latest/command/file.html#reading>) so perhaps we could construct IDLs.txt that worked both as an input CMake and Xcode.
One issue that I don’t know how to solve in a good way is how to make adding files to the Xcode project easier. Perhaps this is somewhere that a script could help? Rather than adding the files to Sources.txt and then manually adding them to the Xcode project, perhaps we should just have a script that does this for us (either via manually invoking it or with the post processing that generates the xcfilelists?)
> On Oct 18, 2020, at 10:38 AM, Darin Adler <darin at apple.com> wrote:
> It would be wonderful to drastically cut down the repeated mentions of the same filenames. People not on Xcode platforms probably focus primarily on Xcode projects for this frustration. But I find it ridiculous how many places I have to add things. For example, to add AbstractRange I had to add filenames to:
> - Sources.txt: Two source files and one IDL-generated file.
> - CMakeLists.txt: IDL file.
> - Headers.cmake: One source file and one IDL-generated file.
> - DerivedSources.make: IDL file
> - WebCore.xcodeproj/project.pbxproj: IDL file, two source files, and Two IDL-generated files.
> And also, updating these checked-in generated files (that we’d need regardless of build system, due to Apple build requirements):
> - DerivedSources-input.xcfilelist
> - DerivedSources-output.xcfilelist
> It seems like we should have a goal that you should not have to list IDL-generated file names. That will be hard to accomplish in Xcode, though. Maybe the reason we haven’t been so ambitious about getting this right for CMake is that it’s so unreachable a goal for Xcode, given that we want the files to show up in a clean way in the IDE?
> And it would be good to find a way to share the lists of IDL files like we do the list of source files. That seems relevant to this discussion of changing DerivedSources.make.
> — Darin
> webkit-dev mailing list
> webkit-dev at lists.webkit.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the webkit-dev