google/riegeli

Supporting CMake build

Opened this issue · 3 comments

Hi dear maintainer,

First I would like to express my gratitude for your open sourcing this library. As an ex-googler I am getting pretty used to recordio and this is exactly what I need in my use cases.

In one of my recent project I need to add this library as a cmake dependency. Tried to search in the issues but seems no one is mentioning having CMake support. I personally think CMake is still popular among the open source world and it might be good if the library support it so that more projects can enjoy the benefit of this library.

Thanks!

I agree that CMake support would be useful.

If CMake files can be generated semiautomatically from BUILD files, then this needs someone (probably me) to learn CMake and do the initial work.

I see that Abseil does that manually. There is a presubmit check that a CMakeLists.txt file is modified whenever the corresponding BUILD file is, but I see no traces of automatic conversion. But the structure of CMakeLists.txt mirrors BUILD files closely, so it should be possible to convert automatically.

Yep, I looked at abseil as well and I like the approach that abseil is taking - creating CMake functions/macros to mimic bazel's syntax and concepts.

If CMake files can be generated semiautomatically from BUILD files

Like the idea, and maybe that can be a good starlark project to work on! Although I doubt the incentive because in most cases we are doing the other way around (CMake -> Bazel).

Any updates on this ? ex-googler here too