简体   繁体   English

在windows上交叉编译linux

[英]Cross-compile for linux on windows

I've found little info about cross-compiling Linux binaries in Windows, most questions are about the opposite situation. 我发现在Windows中交叉编译Linux二进制文件的信息很少,大多数问题都是相反的情况。

Has someone any experience or pointers to share? 有人有经验或指点分享?

I'd prefer Mingw over Cygwin, if I can choose. 如果我可以选择的话,我更喜欢Mingw而不是Cygwin。

Assume that the specific Linux target is available: I have the include headers and binaries. 假设特定的Linux目标可用:我有include头和二进制文件。

I haven't done this myself, but have you considered setting up a virtual machine, and compiling on that? 我自己没有这样做,但您是否考虑过设置虚拟机并对其进行编译? You could use a "network" share, so that both the Windows system and Linux virtual system can see the same directories. 您可以使用“网络”共享,以便Windows系统和Linux虚拟系统都可以看到相同的目录。 With the Virtual Machine solution, it becomes much easier to target specific distributions and architectures. 使用虚拟机解决方案,可以更轻松地定位特定的分发和体系结构。

Best of luck, regardless. 祝你好运,无论如何。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM