Commit Graph

26 Commits

Author SHA1 Message Date
Colin Walters
9e2763106b lib: Use sd_journal directly (optionally)
This was the last caller of libgsystem that isn't
`gs_file_get_path_cached()`.  I think the use case ostree has where
the same code can be called via command line and via a shared library
*and* via a daemon is rather unusual, so let's just copy the code for
logging from libgsystem into here.

For example rpm-ostree hard depends on a daemon mode, so it'll just
use `sd_journal` directly.

Closes: #341
Approved by: jlebon
2016-06-21 18:24:17 +00:00
Matthew Barnes
ceacc57206 libotutil: Establish a place for GPG utilities
Add ot-gpg-utils.[ch] and move _ostree_gpg_error_to_gio_error() here.
2015-05-01 10:20:34 -04:00
Giuseppe Scrivano
c70abfd43c src: Move ot-tool-util from ostree/ to libotutil/
These utilities are not actually specific to the ostree commandline.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2015-03-06 18:45:38 +01:00
Giuseppe Scrivano
479b5ab4fc libotutil: remove ot-waitable-queue.
The module is not not used anymore.  It can be restored from git if
needed again.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2015-03-06 18:45:38 +01:00
Colin Walters
965a304a17 Use libglnx
Starting down the path of not using libgsystem.  The main win here
will be code sharing between ostree/rpm-ostree as well as going down
the path of not using GFile * for local files.
2015-02-22 21:02:27 -05:00
Colin Walters
b756a13a65 Extract opendirat() helper function into libotutil
We were duplicating the code to do an opendirat() in a few places.
2014-09-16 11:34:39 -04:00
Colin Walters
1bdabda5f3 Use external libgsystem 2014.2
It's been split off for a while, let's kill the code duplication.

Among other things, this fixes the systemd detection for the journal
logging.
2014-04-04 16:52:37 -04:00
Colin Walters
26cef497a6 Remove built in "triggers"
Originally, the idea was that clients would replicate "OS/tree"s from
a build server, but we'd run things like "ldconfig" on the client.
This was to allow adding e.g. the nVidia binary driver.

However, the triggers were the only thing in the system at the moment
that really had expected knowledge of the *contents* of the OS, like
the location of binaries.

For now, it's architecturally cleaner if we move the burden of
triggers to the tree builder (e.g. gnome-ostree or RPM).  Eventually
we may want OSTree to assist with this type of thing (perhaps
something like RPM %ghost), but this is the right thing to do now.
2013-07-07 14:37:59 -04:00
Colin Walters
4b170d656c Switch to libgsystem local allocation macros
And drop our compatibility wrapper.
2013-07-07 12:27:44 -04:00
Colin Walters
bac4d7a0d2 pull: Rework threading communication model
Previously, I've observed bugs where we either:
1) Exit too early, leaving undownloaded objects
2) Hang while downloading

This rewrite hopefully fixes both.
2013-04-01 18:56:38 -04:00
Colin Walters
5c1dc390ae pull: Asynchronous metadata fetch
Create a worker thread for processing metadata, reserving the main
thread for HTTP requests.

This can create a very significant efficiency win for large pull
requests since we are much more likely to keep a full pipeline open.

The status display is also nicer now.
2012-10-03 22:35:33 -04:00
Colin Walters
31153913ff Extract keyfile helpers into libotutil
Will be used by ostree-pull too soon.
2012-09-15 11:20:56 -04:00
Colin Walters
c63cca53d7 build: Add --enable-triggers-only
For bootstrapping gnome-ostree, we need to install the triggers early
on, before we actually build the real ostree binary.
2012-08-26 13:58:23 -04:00
Colin Walters
da43fb6db5 Hard require GLib 2.34
Anyone wanting to build against an earlier version can use the
embedded-dependencies system.
2012-07-15 18:22:41 -04:00
Colin Walters
464f4a81c9 Add libgsystem as git external
Don't replace ot_lfree and stuff yet though...to much code churn.
2012-07-15 11:59:05 -04:00
Colin Walters
78b0d99238 Support building with embedded glib 2012-06-14 13:45:59 -04:00
Colin Walters
18b6f5fd0c ostadmin: Initial code 2012-05-07 20:43:03 -04:00
Colin Walters
f15c184584 core: Clean up checksumming
Don't expose GChecksum in APIs.  Add a new stream class which allows
us to pass an input stream somewhere, but gather a checksum as it's
read.

Move some bits of the internals towards binary csums.
2012-04-11 22:04:06 -04:00
Colin Walters
ca08ad6c5e core: Add macros for local allocation
This is GCC-specific, but it makes the code significantly
cleaner.
2012-04-09 15:56:28 -04:00
Colin Walters
e8865af09e core: Split pull functionality into separate ostree-pull binary
This is to avoid everything depending on libsoup.
2011-11-30 09:21:14 -05:00
Colin Walters
18f0b537a4 build: Move sources into src/ again
This is necessary if we want to build when srcdir == builddir,
otherwise we blow up because "ostree" is a source directory and a
binary.
2011-11-14 15:39:38 -05:00
Colin Walters
f5cf1a54de Switch to using explicit WARN_CFLAGS
The rationale is documented well in the automake manual.
2011-11-11 06:55:14 -05:00
Colin Walters
659c99417c Switch to LGPLv2+ for most code
Since we're making a shared library, it should be usable by non-GPL
apps.

To allow more code sharing between the core and the tests, move them
to the LGPLv2+ too.

A few bits of test and other code are still GPL.  See the new COPYING
file for more information.
2011-11-10 13:17:04 -05:00
Colin Walters
ed90bf77cc core: Make compose commits contain metadata about their composition
This allows tracking of their history better.
2011-11-04 15:59:08 -04:00
Colin Walters
8bca739315 Some work on ostree-build 2011-11-03 16:25:35 -04:00
Colin Walters
21c7ff74b6 De-recursify source tree 2011-11-02 15:45:32 -04:00