分开“调试”和“释放”构建? [英] Separate 'debug' and 'release' builds?

查看:123
本文介绍了分开“调试”和“释放”构建?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我认为最好发布开发人员实际测试的软件版本;因此,我倾向于从项目/ makefile中删除调试目标,因此只有一个版本可以构建(测试和调试,并发布)。

I think it's better to release the version of the software which your developers actually tested; I therefore tend to delete the 'debug' target from the project/makefile, so that there's only one version that can be built (and tested, and debugged, and released).

出于类似的原因,我不使用'断言'(另见断言总是坏的? ...)。

For a similar reason, I don't use 'assertions' (see also Are assertions always bad? ...).

一个人认为调试版本的原因是调试更容易:但是,认为您可能最终希望支持和​​调试您发布的任何内容,因此您需要构建一个可以在必要时调试的版本...这可能意味着启用调试符号,并禁用某些优化,即使在发布'build。

One person there argued that the reason for a 'debug' version is that it's easier to debug: but, I counter-argued that you may eventually want to support and debug whatever it is you released, and so you need to build a release which you can if necessary debug ... this may mean enabling debug symbols, and disabling some optimizations, even in the 'release' build.

有人说这是一个坏主意;这是我几年前演变的一种政策,被烧毁:

Someone else said that "this is such a bad idea"; it's a policy I evolved some years ago, having been burned by:


  • 一些开发人员测试他们的调试,但没有发布版本

  • 一些开发者编写的错误仅在发行版本中显示

  • 该公司在测试不足之后发布版本(是 >完全足够?)

  • 正在调用发布版本

  • Some developers' testing their debug but not release versions
  • Some developers' writing bugs which show up only in the release version
  • The company's releasing the release version after inadequate testing (is it ever entirely adequate?)
  • Being called on to debug the release version

从那时起您已经看到一个以上的开发商店遵循这种做法(即没有单独的调试和发布版本)。

Since then I've seen more than one other development shop follow this practice (i.e. not have separate debug and release builds).

您的政策是什么?

推荐答案

这可能很小,但这与其他人在这里所说的相同。拥有QA测试版本的优点之一是,随着时间的推移,您的软件的内置调试和日志记录功能将由于需要确定QA中出现问题的开发人员的需求而前进。

This might be minor, but it adds up to what others have said here. One of the advantages of having QA test release builds is that over time the built in debugging and logging capabilities of your software will advance due to the needs of developers who need to figure out why things are going wrong in QA.

开发人员需要调试发布版本的程度越多,客户开始出现问题后,将会有更好的工具。
当然,开发人员没有理由在开发周期中发布版本。

The more the developers need to debug release builds, the better tools you'll have later when customers start having issues. Of course, no reason for developers to work on release builds as part of the development cycle.

此外,我不知道有任何软件公司足够长的周期,以便在版本的测试期间提供从调试到发布QA的开销。做完全质量保证周期是很少发生的事情。

Also, I don't know any software company that has long enough cycles to afford the overhead of switching QA from debug to release builds halfway through a version's testing period. Having to do a full QA cycle is something that all too often happens pretty rarely.

这篇关于分开“调试”和“释放”构建?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆