views:

266

answers:

3

One of the only languages that compiles to a high level language such as C, Vala has interested me for quite a bit. I've been wanting to start a small project with it, but I've been wondering how I would distribute it.

The fact is, that it compiles to C code (C99 I suppose).

  • Can I distribute the C code instead of the Vala code?
  • If I do, is the C code compatible with all platforms?
  • Or does it, for example when using sockets, include the appropriate stuff (winsock.h for Windows) automatically?
+1  A: 

From a Vala developer in irc, #vala on irc.gnome.org:

   18:57 < flo> It is of course possible to distribute the C code as
         well. The compiler itself is shiped with vala and C code. We
         actually access C-libraries over an abstract interface with all
         advantages and disadvantages of the libraries we are using,
         including platform dependencies.
Luca Matteis
Ooops, we posted simultaneously. Since I am not a vala programmer, I defer to Lucas, of course (+1). But why not ask the Vala people directly in the first place?
Mawg
There's nothing wrong with asking here on SO as well ;).
Luca Matteis
A: 

Did you google? did you try it out? Does the Valal home page have anything to say? Did you ask on Vala forums? There are only 7 questions tagged Vala on SO (and one of those is "will Vala survive?"), so this might not be the best place to ask.

Why not just compile your vala to C and then run it through a C compiler, preferably on a different PC (for a thorough test, make that 2nd PC one which has never one any development work and install a C compiler specially for your test).

Of course that might prove something for a program, but not for all programs. Perhaps ask the mailing list (http://mail.gnome.org/mailman/listinfo/vala-list), or the devlopers? Jürg Billeter - j at bitron dot ch Raffaele Sandrini - rasa at gmx dot ch

The question, paraphrased, is "how long is a piece of string", the best answer is "suck it, and see", and the caveat is YMMV ;-)g

Mawg
+1  A: 

Automake, as of version 1.10 or 1.11 has Vala support.

Jack