I am curious about the C++ Modules TS. I have played a little around with Clang's implementation. Only one or two files or so at a time.
Now I would like to try something bigger than that. And I would like to use CMake.
Does someone know if there is some good way to use the Clang modules implementation with CMake or are there already some CMake modules which help me with this?
I would really like to know. Otherwise I have to consider using a different build system.
I would suggest you try build2:
https://build2.org/build2/doc/build2-build-system-manual.xhtml#cxx-modules
It supports modules for Visual Studio, gcc and clang. And for gcc there is a package that contains the standard library:
https://build2.org/pkg/hello/libstd-modules?f=full&q=library
Note that Microsoft implementation, as of Visual Studio 2017 update 4, is using the old syntax in the .ixx files (module xyz; instead of export module xyz; where the latter is what the last Modules TS draft mandates)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With