在CMAKE中,我可以从依赖关系图中删除标头吗?

发布于 2025-02-03 21:18:41 字数 188 浏览 2 评论 0原文

我有一个生成的标头文件,其中包含很多源文件,并且当这些源文件中的任何一个都更改时,可能会更改。但是,当一件事改变时,我不想重新编译所有内容。

而且应该不必重新编译。除了更改的一个源文件之外,对此生成的标头的更改应没有任何区别。因此,实际上没有必要具有依赖性。

是否可以从依赖关系图中排除此标头文件,以便源文件在更改时不会自动重新编译?

I have a generated header file that lots of source files include, and that may change when any one of those source files changes. But I don't want to recompile everything when one thing changes.

And it should be unnecessary to recompile. The changes to this generated header should make no difference to anything except the one source file that changed. So it is not actually necessary to have a dependency.

Is there a way to exclude this header file from the dependency graph, so that source files do not automatically recompile when it changes?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文