为什么 SQLite 提供其代码的合并?
每次我下载 SQLite 时,我都会发现他们提供了几个不同版本的源代码,这是我实际上从未见过任何其他项目所做的事情。 更重要的是,他们提供了源合并,即将所有文件合并为 3 个文件。 这是什么原因呢? 仅仅是编译速度吗? 或者有一些真正充分的理由吗? 其他项目是否使用源代码合并?
Every time I download SQLite, I come across the fact that they provide several different versions of their source code, which is something I've actually never seen any other project do. And more so they provide Amalgamations of Source, that kind of merge all their files into just 3 files. What's the reason for this? Is it just compilation speed? Or are there some really good reasons for it? Do other projects use Amalgamations of source code?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
正如其有关合并的页面直接所述
我本人认为融入其他项目是最大的好处。 它只是使编译变得更加容易。 没有构建脚本混乱以及拥有大量源文件所带来的任何其他后果。
As stated directly on their page about amalgamation
I myself see's the incorporation into other projects the greatest benefit. It simply makes it much much easier to compile. No build script mess and whatever else follows from having a large collection of source files.
这样做是为了更简单地合并到现有项目中。 将一个 .h 和一个 .c 添加到您的项目中,您就拥有了完整的 SQLite 引擎。
我很感激。 这让我少了一件需要担心的事情。
It's done to make incorporation into existing projects simpler. Add one .h and one .c to your project, and you have the full SQLite engine.
I appreciate it. It's one less thing I have to worry about.
当我在 Windows 下使用 dev c++ 编译器尝试将合并文件分解为单个文件时,我遇到了很多问题。 因为我想让 sqlite 在 RTOS 中工作
名为 DJYOS,从单个文件更改代码比从合并文件更改代码更容易。
When I trid devide amalgamation file to individual files under windows with dev c++ compiler, I got a lots of question. Because I want make sqlite working in a RTOS which
named DJYOS, it's easier to change code from individual files than from amalgamation one.