Difference between CPPFLAGS and CXXFLAGS in GNU Make

前端 未结 4 401
面向向阳花
面向向阳花 2020-11-28 18:37

What\'s the difference between CPPFLAGS and CXXFLAGS in GNU Make?

4条回答
  •  天命终不由人
    2020-11-28 19:03

    By default, they're set to something.

    In practice, you need to know what every single project does. Virtually no one uses those defaults built into make, and if you rely on, for example, CPPFLAGS meaning "flags to the C preprocessor" you'll find that the project you care about has used it to mean "flags to the C++ compiler" instead. And does the CFLAGS flag get passed to C++ compile lines? Sometimes. Not always. Etc, etc, etc.

提交回复
热议问题