在64位命令行环境下编译32位Intel OS X二进制文件需要哪些步骤?只需添加
-m32
标志吗?我没有使用Xcode,但如果需要,可以使用它来安装gcc
可用的库。感谢您的建议。-m32
标志吗?我没有使用Xcode,但如果需要,可以使用它来安装gcc
可用的库。感谢您的建议。如果你正在使用苹果实现的GCC在Macintosh电脑上进行编译,其中一个额外的选项是可以传递"-arch
"参数。
man页面上说:
-arch arch
Compile for the specified target architecture arch.
The allowable values are i386, x86_64, ppc and ppc64.
Multiple options work, and direct the compiler to produce "universal"
binaries including object code for each architecture specified with -arch.
This option only works if assembler and libraries are available
for each architecture specified. (APPLE ONLY)