Re: Using OSTree API



Thx for the reply, and I figured out how to replace those calls by
manual deleting. Even so I am still having some memory leaks. The code
(beware, c++11) I am using is in this link:

http://pastebin.com/VqqbPdUm

Yes, I am probably doing some very primary mistake, but could not
figured it out yet :-(

About glibmm, I could not find anything yet , so need to research more.

For now I liked your idea, I'll start with python to get more used to
the API and if necessary migrate to C++.

And I didn't know rpm-ostree daemon. I'll take a look on it.

Thx for the support :-)

On 23 September 2015 at 18:29, Colin Walters <walters verbum org> wrote:
On Wed, Sep 23, 2015, at 02:58 AM, Leandro Santiago wrote:

I checked ostree uses libglnx to manage memory

libglnx just wraps GCC's __attribute__((cleanup)):
http://blog.verbum.org/2012/05/09/__attribute__-cleanup-or-how-i-came-to-love-c-again/

Which then later landed in GLib.

You don't *need* to use this of course, it's just extra convenience.

Awkwardly I found no ways to generate C++ bindings from introspection
files. It's a bit off-toppic Do anyone know if it is possible?

I am not sure if there is a project implementing that - AFAIK the
glibmm bindings still use .defs files, though I may be wrong.

As far as languages, I think dynamic languages are good for prototyping,
but they tend to be heavy on memory usage which matters when you
have a persistent daemon, so C/C++ is likely
your best bet long term, and lowers the impedance mismatch.

That's what we've done with the rpm-ostree daemon.


_______________________________________________
ostree-list mailing list
ostree-list gnome org
https://mail.gnome.org/mailman/listinfo/ostree-list



-- 
Sent from my mind


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