4

When we build a project, we can define that under which subsystem we want to run our program in windows. But how it would affect the output exe file. Or in other words when we call a CreateProcess() API we just pass it an exe file, So which header inside the exe file, it checks to determine that which subsystem going to handle this process? Or it uses some other method in order to accomplish it?

4

2 回答 2

0

在可执行文件的主要标头中,存在该信息。当您谈论 .exe(或者更确切地说是二进制文件)时,会执行链接器阶段。链接器是操作系统的一部分,每个操作系统都有一个代码号,通过它可以识别为它的二进制文件。

与 windows 和 CreateProcess() 一样,请考虑阅读此内容

于 2013-09-13T05:07:05.113 回答