Re: [Vala] Making libraries with Vala



        Hi!

Abderrahim, thank you. Your letter helped me a lot.

On 04.09.2009 13:39:53, Abderrahim Kitouni wrote:
2009/9/4 Ildar Mulyukov <ildar users sourceforge net>:
> 1. Valac supports "--library" option, but still cannot build one with one
> shot - it cannot link a library (is it true?)
yes and no,
Vala doesn't know how to compile a library by itself, but you can pass
extra arguments to the C compiler using -X (for example -X -fPIC -X
-shared), but this is not portable.

Yes, that worked.

> 2. Not all of the Vala features are accessible from the program using a > library (This is my guess. I think it's worth to have a document (or wiki
> page) explicitly naming these features)

I don't think so, all vala features should be accecible to whatever
program using them (but I may be wrong).

Sounds true. With headers generated everything seems in place.

> 2a. I found a regression - in-library defined Error Domain is not fully
yes, this has changed in 0.7, you nedd to pass '-H my_lib.h' to valac
to generate a header.

Good addition.

> 3. May be something I just didn't bump in yet.
As an example of a library written in vala, you can take a look at
libgee (or vala itself) to see how this is managed (if you can depend
on automake 1.11, this is even easier).

Thanks a lot.
P.S. I'm using 0.7.4 which works fine.
--
Ildar  Mulyukov,  free SW designer/programmer
================================================
email: ildar users sourceforge net
home: http://tuganger.narod.ru/
ALT Linux Sisyphus
================================================



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