我正在尝试为 MIPS 平台交叉编译 Mono 框架(3.0.6)。我发现的问题很少,所以我想问问社区是否有已知的问题。
我的环境 :Linux 3.2.0-39-generic#62-Ubuntu SMP Thu Feb 28 00:28:53 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
工具链 : Sourcery G++ Lite 4.3-51
命令行 :
./configure --prefix=/home/dev/mono-3.0.6-mips --host=mips-linux-gnu --enable-minimal=profiler,debug,logging,soft_debug --without-mcs-docs --target=mips-linux-gnu --with-moonlight=no --with-tls=pthread --with-sigaltstack=no --with-profile4_5=yes CXXFLAGS="-mips32r2 -march=24kf -mtune=24kf -EL" CFLAGS="-mips32r2 -march=24kf -mtune=24kf -EL" && make
问题 #1 :
当我设法配置它时,编译停止并出现以下错误:
mini-gc.c:2551: error: redefinition of 'mini_gc_enable_gc_maps_for_aot'
mini-gc.c:2518: error: previous definition of 'mini_gc_enable_gc_maps_for_aot' was here
问题 #2 :
在我注释掉 的第二个声明之后mini_gc_enable_gc_maps_for_aot 它已编译但看起来 Sourcery G++ 链接器崩溃了:
/home/dev/mips-4.3/bin/../lib/gcc/mips-linux-gnu/4.3.2/../../../../mips-linux-gnu/bin/ld: BFD (Sourcery G++ Lite 4.3-51) 2.18.50.20080215 assertion fail /scratch/clm/2008q3-lite/obj/binutils-src-4.3-51-mips-linux-gnu-i686-pc-linux-gnu/bfd/elfxx-mips.c:2651
任何人都可以解决这个问题吗?我没有找到任何描述为 MIPS 架构构建 Mono 的文章/信息(至少是一些最近的信息)。根据 this链接,大约一年前添加了对 MIPS 的支持。 Mono 本身应该完全支持 MIPS,因为 3.0.4 version .
最佳答案
我将这个信息发布给所有遇到同样问题的人(为 MIPS 平台构建 Mono):
最后,我能够使用以下命令行为 MIPS 平台构建单声道运行时:
./configure --prefix=/home/dev/mono-3.0.6-mips --host=mips-linux-gnu --enable-minimal=profiler,debug,logging,soft_debug --without-mcs-docs --target=mips-linux-gnu --with-moonlight=no --with-tls=pthread --with-sigaltstack=no --with-profile4_5=yes CXXFLAGS="-mips32r2 -EL" CFLAGS="-mips32r2 -EL" LDFLAGS=-EL CPPFLAGS="-mips32r2 -EL" ASFLAGS=-EL CC="mips-linux-gnu-gcc -EL"
为所有工具指定 -EL 标志修复了使用 ld 进行单声道链接的问题(请参阅我的初始帖子中的问题 #2)。
剩下的最后一个问题是使单声道构建系统构建 mscorlib.dll。调用不同 制作 mcs/class 文件夹中的命令不执行任何操作。
关于mono - 为 MIPS 交叉编译 Mono 框架 3.0.6+,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15614541/