Re: [Vala] why valac says "error: Failed to execute child process (Exec format error)"



currently, the following command line creates EXE file in my msys
without problem as Dmitry says
[quote]
$ valac hello.vala
error: Failed to execute child process (Exec format error)
error: Failed to execute child process (Exec format error)
error: Failed to execute child process (Exec format error)
Compilation failed: 3 error(s), 0 warning(s)

$ gcc -o hello.exe hello.vala.c `pkg-config --cflags --libs glib-2.0`

#or "gcc -o hello.exe hello.vala.c `pkg-config --cflags --libs glib`
", since there is both glib.pc and glib-2.0.pc

$ ./hello.exe
hello
[/quote]
but obviously it is not so automatic

Another way relies on https://sourceforge.net/projects/valainstaller/,
but I don't know how to compile cloned master vala code

C U
Lee June

2016-06-17 19:39 GMT+08:00 Dmitry Golovin <dima golovin in>:
Hi,

I had similar problem and solved it just by first generating C code (valac -C ...) and then compiling 
resulting code with GCC.

Regards,
Dmitry

15.06.2016, 18:42, "oyster" <lepto python gmail com>:
I am using mingw + msys on win7 64bits. The gcc can compile to produce
EXE file, and pkg-config can run no problem

I can compile vala_0.32.0 without problem

but when I try to use "valac -v hello.vala" to compile any vala source, I find
[quote]
Loaded package `E:\msys\opt\windows_32\vala-my-build\share/vala-0.32/vapi/glib-2.0.vapi'
Loaded package `E:\msys\opt\windows_32\vala-my-build\share/vala-0.32/vapi/gobject-2.0.vapi'
error: Failed to execute child process (Exec format error)
...
Compilation failed: 3 error(s), 0 warning(s)
[/quote]

Any hints to find what is the problem? Thanks
_______________________________________________
vala-list mailing list
vala-list gnome org
https://mail.gnome.org/mailman/listinfo/vala-list


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]