Skip to content

Install pkgconfig files from CMake installation #215

@metthal

Description

@metthal

We were discussing this with Paul on gerrit here but to sum it up.

Right now, all popular Linux distributions package re2 from GNU make build which installs pkgconfig pc files. However this is not an ideal situation for people who use CMake in their projects. They can't do find_package(re2) in their project out of the box. The usual approach then is to write your own finder that will use pkgconfig to generate CMake targets but it's much better if projects provide their own. CMake build system in RE2 already generate all the necessary files for doing just find_package(re2) but it does not install pkgconfig files. That way, package maintainers for Fedora, Ubuntu, Arch, ... can't really use CMake and not break existing packages which rely on pkgconfig. I have provided patch for that but Paul asked me to write this issue to start the discussion regarding this matter.

There is also another thing which is that Red Hat based distributions should have 64-bit libraries installed in /usr/lib64 but through CMake, RE2 installs itself into /usr/lib. Therefore we also need GNUInstallDirs which work just find even on Windows and macOS.

cc @SuperWig

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions