Bug 27585 - Mono compilations fail with gmcs.exe: MZ▒▒▒▒@▒▒▒: not found on Zynq
Summary: Mono compilations fail with gmcs.exe: MZ▒▒▒▒@▒▒▒: not found on Zynq
Status: NEW
Alias: None
Product: Runtime
Classification: Mono
Component: General (show other bugs)
Version: unspecified
Hardware: Other Linux
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2015-03-03 02:55 UTC by Ales Ruda
Modified: 2016-04-16 10:13 UTC (History)
4 users (show)

See Also:
Tags:
Is this bug a regression?: ---
Last known good build:


Attachments

Description Ales Ruda 2015-03-03 02:55:03 UTC
I'm try to compile mono on Zedboard (Xilinx Zynq - armhf). Compilation fails with strange error gmcs.exe: MZ▒▒▒▒@▒▒▒: not found.

I folows instruction for Rapsbary PI (is armhf) in http://www.logview.info/lvstudio/Linux_Preparation_with_Mono.pdf

I'm use:

git clone git://github.com/mono/mono.git
cd mono
./autogen.sh --prefix=/usr/local
make get-monolite-latest
cd mcs/class/lib/monolite
cp basic.exe gmcs.exe
cd /usr/src/mono/mono
SKIP_AOT=true make EXTERNAL_MCS="/usr/src/mono/mono/mcs/class/lib/monolite/gmcs.exe"

Last log lines:

if test -w /usr/src/mono/mono/mcs; then :; else chmod -R +w /usr/src/mono/mono/mcs; fi
cd /usr/src/mono/mono/mcs && make --no-print-directory -s NO_DIR_CHECK=1 PROFILES='net_4_0 net_4_5 xbuild_12 xbuild_14   ' CC='gcc' all-profiles
mkdir -p -- build/deps
/usr/src/mono/mono/mcs/class/lib/monolite/gmcs.exe: 1: /usr/src/mono/mono/mcs/class/lib/monolite/gmcs.exe: MZ▒▒▒▒@▒▒▒: not found
/usr/src/mono/mono/mcs/class/lib/monolite/gmcs.exe: 36: /usr/src/mono/mono/mcs/class/lib/monolite/gmcs.exe: Syntax error: word unexpected (expecting ")")
make[6]: *** [build/deps/basic-profile-check.exe] Error 2
*** The compiler '/usr/src/mono/mono/mcs/class/lib/monolite/gmcs.exe' doesn't appear to be usable.
*** Trying the 'monolite' directory.
Stacktrace:

  at <unknown> <0xffffffff>
  at System.Collections.Generic.Dictionary`2<IKVM.Reflection.Assembly, int>..ctor (int,System.Collections.Generic.IEqualityComparer`1<IKVM.Reflection.Assembly>) <0x0005b>
  at System.Collections.Generic.Dictionary`2<IKVM.Reflection.Assembly, int>..ctor () <0x0001b>
  at IKVM.Reflection.Emit.ModuleBuilder..ctor (IKVM.Reflection.Emit.AssemblyBuilder,string,string,bool) <0x002db>
  at IKVM.Reflection.Emit.AssemblyBuilder.DefineDynamicModule (string,string,bool) <0x0004b>
  at Mono.CSharp.AssemblyDefinition.CreateModuleBuilder () <0x0003f>
  at Mono.CSharp.AssemblyDefinitionStatic.Create (IKVM.Reflection.Universe) <0x0007b>
  at Mono.CSharp.Driver.Compile () <0x00493>
  at Mono.CSharp.Driver.Main (string[]) <0x00153>
  at (wrapper runtime-invoke) <Module>.runtime_invoke_int_object (object,intptr,intptr,intptr) <0xffffffff>

Native stacktrace:


Debug info from gdb:

[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
[New Thread 0x403eb440 (LWP 28959)]
0x400cf384 in __libc_do_syscall () from /lib/arm-linux-gnueabihf/libpthread.so.0
  Id   Target Id         Frame
  2    Thread 0x403eb440 (LWP 28959) "Finalizer" 0x400cf384 in __libc_do_syscall () from /lib/arm-linux-gnueabihf/libpthread.so.0
* 1    Thread 0x400294f0 (LWP 28945) "mono" 0x400cf384 in __libc_do_syscall () from /lib/arm-linux-gnueabihf/libpthread.so.0

Thread 2 (Thread 0x403eb440 (LWP 28959)):
#0  0x400cf384 in __libc_do_syscall () from /lib/arm-linux-gnueabihf/libpthread.so.0
#1  0x400cc6da in do_futex_wait () from /lib/arm-linux-gnueabihf/libpthread.so.0
#2  0x400cc756 in sem_wait@@GLIBC_2.4 () from /lib/arm-linux-gnueabihf/libpthread.so.0
#3  0x00159b84 in mono_sem_wait (sem=0x2227d0, alertable=1) at mono-semaphore.c:101
#4  0x001077b6 in finalizer_thread (unused=<optimized out>) at gc.c:1074
#5  0x000f685e in start_wrapper_internal (data=<optimized out>) at threads.c:664
#6  start_wrapper (data=<optimized out>) at threads.c:711
#7  0x0015cd20 in inner_start_thread (arg=<optimized out>) at mono-threads-posix.c:92
#8  0x400c7ed2 in start_thread () from /lib/arm-linux-gnueabihf/libpthread.so.0
#9  0x4017ec98 in ?? () from /lib/arm-linux-gnueabihf/libc.so.6
#10 0x4017ec98 in ?? () from /lib/arm-linux-gnueabihf/libc.so.6
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

Thread 1 (Thread 0x400294f0 (LWP 28945)):
#0  0x400cf384 in __libc_do_syscall () from /lib/arm-linux-gnueabihf/libpthread.so.0
#1  0x400ce336 in waitpid () from /lib/arm-linux-gnueabihf/libpthread.so.0
#2  0x00076f6e in mono_handle_native_sigsegv (signal=<optimized out>, ctx=<optimized out>, info=<optimized out>) at mini-exceptions.c:2347
#3  0x0002333e in mono_sigsegv_signal_handler (_dummy=11, _info=0xbece2110, context=0xbece2190) at mini-runtime.c:2655
#4  <signal handler called>
#5  0x41a8e000 in ?? ()
#6  0x4025c660 in ?? ()
#7  0x4025c660 in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================

Aborted (core dumped)
make[8]: *** [build/deps/basic-profile-check.exe] Error 134
*** The contents of your 'monolite' directory may be out-of-date
*** You may want to try 'make get-monolite-latest'
make[8]: *** [do-profile-check-monolite] Error 1
make[7]: *** [do-profile-check] Error 2
make[6]: *** [do-profile-check-monolite] Error 2
make[5]: *** [do-profile-check] Error 2
make[4]: *** [profile-do--basic--all] Error 2
make[3]: *** [profiles-do--all] Error 2
make[2]: *** [all-local] Error 2
make[2]: Leaving directory `/usr/src/mono/mono/runtime'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/mono/mono'
make: *** [all] Error 2


Can anybody help me?


Thanks

Note You need to log in before you can comment on or make changes to this bug.