\Windows\ 与 \Windows\System32 - 文件位置约定

发布于 2024-07-21 07:52:23 字数 546 浏览 4 评论 0原文

对于 \Windows\ 中的文件类型与 \Windows\System32 中的文件类型是否有标准约定?

我正在开发一个 SDK,它包含各种 DLL、一个帮助程序 exe 和一个 Windows 服务 exe。 之前编写代码的人将两个 exe 文件放在 \Windows\ 中,将 DLL 放在 \Windows\System32\ 中,但在我看来,它们可能都应该放在 \Windows\System32\ 中,

你会怎么做?

编辑: 我并不是想争论他们是否应该去那里的优点。 很多应用程序都会将东西安装到 System32...尤其是服务或驱动程序(我正在处理这两者)。 当然,我并不是说这是正确的......正如我所说,我最初并不是为了这个问题而创建的。 如果这些是您唯一的选择...什么会去哪里?

编辑: 好的,我已经接受了。 我真的不认为我能够说服这个项目的“架构师”将它们移出这两个目录中的任何一个......但在这一点上我会更加努力。 同意...这些文件夹中不应放置任何内容。

Is there a standard convention for the types of files that go in \Windows\ versus those that go in \Windows\System32 ??

I'm working on an SDK that has a variety of DLLs a helper exe, and a Windows service exe. The previous guy who worked on the code put the two exe files in \Windows\ and the DLLs in \Windows\System32\ But it seems to me that they should likely all go in \Windows\System32\

Which would you do?

Edit: I am NOT trying to debate the merits of if they should go there at all. Plenty of apps install things to System32...especially for services or drivers (both of which I'm dealing with). Granted, I'm not saying it's right...as I said, I didn't create this initially...for the sake of this question. If those were your only choices...what goes where?

Edit: OK, point taken. I didn't really think I was going to be able to convince the "architect" of this project to move them out of either of those two directories... but at this point I'll try harder. Agreed...nothing should be put in those folders.

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

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

发布评论

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

评论(2

悲欢浪云 2024-07-28 07:52:23

他们也不应该进去! 在任何情况下,您的应用程序文件都位于您的应用程序目录中,而不是 Windows 目录中 - 这些目录是供 i 操作系统使用的,而不是供您使用。

无论您的应用程序是否正在安装可执行文件、DLL、驱动程序、字体、配置文件等等,都无关紧要。 它们不进入 Windows 目录。 事实上,一些设计糟糕和编写糟糕的应用程序确实安装了无法执行的东西。

They shouldn't go in either! Your application files go in your application directory, not in the Windows directories under any circumstances - those are for the ioperating system to use, not you.

And it doesn't matter whether your application is installing executables, DLLs, drivers, fonts, configuration files, whatever. They do not go in the Windows directories. The fact that a few badly designed and badly written applications do install things there is no execuse.

阳光下的泡沫是彩色的 2024-07-28 07:52:23

我会将这些文件放在它们所属的程序文件下。 Windows 和 Windows\System32 仅供操作系统使用。

I would put the files under Program Files where they belong. Windows and Windows\System32 are for the operating system's use only.

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