Skip to content

Allow not forcibly setting CMAKE_C_FLAGS and CMAKE_CXX_FLAGS #198

Open
@anderslanglands

Description

@anderslanglands

I hit the same issue as #133

The reason is that even if no cflags or cxxflags are specified in the Config, it will still forcibly set those in the cfg, even if no_default_flags is forced to true (in that case CMAKE_C(XX)_FLAGS is just set to empty).

This causes some libraries to fail to build on windows because of the missing /EHsc flag that CMake sets by default, but is apparently not in the list that Config pulls from cc.

I would expect that if I don't supply any flags to Config, then I should get the exact same result as calling cmake in the terminal, which is not what happens currently. Is there a way we can change this behaviour?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions