将整个程序与复杂的构建过程结合起来

发布于 2024-08-18 08:47:01 字数 115 浏览 1 评论 0原文

我想在我的系统上运行夹板整个程序分析。然而,系统非常大,不同的部分是使用不同的编译器定义和包含路径进行编译的。我可以看到如何将这些信息传递给单个文件的夹板,但我不知道如何为整个程序执行此操作。有谁知道这样做的方法吗?

I want to run splints whole program analysis on my system. However the system is quite large and different parts are compiled with different compiler defines and include paths. I can see how to convey this information to splint for a single file but I can't figure out how to do it for whole program. Does anyone know a way of doing this?

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

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

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

爱给你人给你 2024-08-25 08:47:01

假设您有一个 Makefile,您可以创建一个新目标;然后您将使用 Splint 而不是编译器来完成实际的编译步骤复制它们。

然而,我的建议是反对完整计划的方法。如果您可以将系统隔离为单独的部分,我宁愿从一一检查它们开始。由于您的程序“相当大”,因此您的每个模块都会出现无数警告...。一旦您在源代码中添加了适当的语义注释,您将开始摆脱它们。祝你好运! :)

Assuming you have a Makefile you could create a new target; then you would go through the actual compilation steps to duplicate them using Splint instead of the compiler.

My advice, however, is against the full-program approach. If you can isolate your system into separate parts, I'd rather start by checking them, one by one. Since your program is "quite large", expect a gazillion warnings... for each one of your modules. You will start to get rid of them once you have sprinkled your source code with the appropriate semantic annotations. Good luck! :)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文