diff --git a/Makefile-boot.am b/Makefile-boot.am index e42e5180..90f98048 100644 --- a/Makefile-boot.am +++ b/Makefile-boot.am @@ -41,6 +41,7 @@ systemdsystemunit_DATA = src/boot/ostree-prepare-root.service \ src/boot/ostree-boot-complete.service \ src/boot/ostree-finalize-staged.service \ src/boot/ostree-finalize-staged.path \ + src/boot/ostree-finalize-staged-hold.service \ $(NULL) systemdtmpfilesdir = $(prefix)/lib/tmpfiles.d dist_systemdtmpfiles_DATA = src/boot/ostree-tmpfiles.conf @@ -70,6 +71,7 @@ EXTRA_DIST += src/boot/dracut/module-setup.sh \ src/boot/ostree-finalize-staged.path \ src/boot/ostree-remount.service \ src/boot/ostree-finalize-staged.service \ + src/boot/ostree-finalize-staged-hold.service \ src/boot/grub2/grub2-15_ostree \ src/boot/grub2/ostree-grub-generator \ $(NULL) diff --git a/Makefile-libostree.am b/Makefile-libostree.am index f93f712a..ea5e8ed5 100644 --- a/Makefile-libostree.am +++ b/Makefile-libostree.am @@ -284,12 +284,8 @@ EXTRA_DIST += src/libostree/README-gpg src/libostree/bupsplit.h \ src/libostree/ostree-enumtypes.c.template \ src/libostree/ostree-deployment-private.h \ src/libostree/ostree-repo-deprecated.h \ - src/libostree/ostree-version.h \ - src/libostree/s390x-se-luks-gencpio + src/libostree/ostree-version.h install-mkdir-remotes-d-hook: mkdir -p $(DESTDIR)$(sysconfdir)/ostree/remotes.d INSTALL_DATA_HOOKS += install-mkdir-remotes-d-hook - -# Secure Execution: script for creating new initramdisk with LUKS key and config -pkglibexec_SCRIPTS += src/libostree/s390x-se-luks-gencpio diff --git a/Makefile-tests.am b/Makefile-tests.am index c87893ee..1ad660bf 100644 --- a/Makefile-tests.am +++ b/Makefile-tests.am @@ -107,6 +107,7 @@ _installed_or_uninstalled_test_scripts = \ tests/test-admin-deploy-nomerge.sh \ tests/test-admin-deploy-none.sh \ tests/test-admin-deploy-bootid-gc.sh \ + tests/test-admin-deploy-whiteouts.sh \ tests/test-osupdate-dtb.sh \ tests/test-admin-instutil-set-kargs.sh \ tests/test-admin-upgrade-not-backwards.sh \ diff --git a/Makefile.in b/Makefile.in index 7e54c0f1..938fb264 100644 --- a/Makefile.in +++ b/Makefile.in @@ -2048,6 +2048,7 @@ am__EXEEXT_23 = tests/test-basic.sh \ tests/test-admin-deploy-nomerge.sh \ tests/test-admin-deploy-none.sh \ tests/test-admin-deploy-bootid-gc.sh \ + tests/test-admin-deploy-whiteouts.sh \ tests/test-osupdate-dtb.sh \ tests/test-admin-instutil-set-kargs.sh \ tests/test-admin-upgrade-not-backwards.sh \ @@ -2416,28 +2417,24 @@ EXTRA_DIST = $(all_dist_test_scripts) $(all_dist_test_data) autogen.sh \ src/libostree/ostree-enumtypes.c.template \ src/libostree/ostree-deployment-private.h \ src/libostree/ostree-repo-deprecated.h \ - src/libostree/ostree-version.h \ - src/libostree/s390x-se-luks-gencpio \ - src/ostree/parse-datetime.y buildutil/tap-driver.sh \ - buildutil/tap-test tests/glib.supp tests/ostree.supp $(NULL) \ - $(am__append_69) $(am__append_72) tests/libtest.sh \ - $(am__append_73) $(am__append_78) tests/libostreetest.h \ - tests/libtest.sh $(NULL) src/boot/dracut/module-setup.sh \ - src/boot/dracut/ostree.conf src/boot/mkinitcpio \ - src/boot/ostree-boot-complete.service \ + src/libostree/ostree-version.h src/ostree/parse-datetime.y \ + buildutil/tap-driver.sh buildutil/tap-test tests/glib.supp \ + tests/ostree.supp $(NULL) $(am__append_69) $(am__append_72) \ + tests/libtest.sh $(am__append_73) $(am__append_78) \ + tests/libostreetest.h tests/libtest.sh $(NULL) \ + src/boot/dracut/module-setup.sh src/boot/dracut/ostree.conf \ + src/boot/mkinitcpio src/boot/ostree-boot-complete.service \ src/boot/ostree-prepare-root.service \ src/boot/ostree-finalize-staged.path \ src/boot/ostree-remount.service \ src/boot/ostree-finalize-staged.service \ + src/boot/ostree-finalize-staged-hold.service \ src/boot/grub2/grub2-15_ostree \ src/boot/grub2/ostree-grub-generator $(NULL) $(am__append_87) \ $(am__append_91) bin_SCRIPTS = lib_LTLIBRARIES = libostree-1.la - -# Secure Execution: script for creating new initramdisk with LUKS key and config -pkglibexec_SCRIPTS = src/libostree/s390x-se-luks-gencpio \ - $(am__append_83) +pkglibexec_SCRIPTS = $(am__append_83) noinst_LTLIBRARIES = $(am__append_1) libglnx.la libbsdiff.la \ libotutil.la libbupsplit.la libostreetest.la privlibdir = $(pkglibdir) @@ -2935,6 +2932,7 @@ _installed_or_uninstalled_test_scripts = tests/test-basic.sh \ tests/test-admin-deploy-nomerge.sh \ tests/test-admin-deploy-none.sh \ tests/test-admin-deploy-bootid-gc.sh \ + tests/test-admin-deploy-whiteouts.sh \ tests/test-osupdate-dtb.sh \ tests/test-admin-instutil-set-kargs.sh \ tests/test-admin-upgrade-not-backwards.sh \ @@ -3152,6 +3150,7 @@ tests_test_commit_sign_sh_ext_LDADD = $(TESTS_LDADD) @BUILDOPT_SYSTEMD_TRUE@ src/boot/ostree-boot-complete.service \ @BUILDOPT_SYSTEMD_TRUE@ src/boot/ostree-finalize-staged.service \ @BUILDOPT_SYSTEMD_TRUE@ src/boot/ostree-finalize-staged.path \ +@BUILDOPT_SYSTEMD_TRUE@ src/boot/ostree-finalize-staged-hold.service \ @BUILDOPT_SYSTEMD_TRUE@ $(NULL) @BUILDOPT_SYSTEMD_TRUE@systemdtmpfilesdir = $(prefix)/lib/tmpfiles.d @@ -8601,6 +8600,13 @@ tests/test-admin-deploy-bootid-gc.sh.log: tests/test-admin-deploy-bootid-gc.sh --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) +tests/test-admin-deploy-whiteouts.sh.log: tests/test-admin-deploy-whiteouts.sh + @p='tests/test-admin-deploy-whiteouts.sh'; \ + b='tests/test-admin-deploy-whiteouts.sh'; \ + $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ + --log-file $$b.log --trs-file $$b.trs \ + $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ + "$$tst" $(AM_TESTS_FD_REDIRECT) tests/test-osupdate-dtb.sh.log: tests/test-osupdate-dtb.sh @p='tests/test-osupdate-dtb.sh'; \ b='tests/test-osupdate-dtb.sh'; \ diff --git a/README.md b/README.md index 6a51482b..7073cbda 100644 --- a/README.md +++ b/README.md @@ -73,6 +73,8 @@ their host system as well as Flatpak. [Liri OS](https://liri.io/download/silverblue/) has the option to install their distribution using ostree. +[TorizonCore](https://developer.toradex.com/torizon/working-with-torizon/torizoncore-technical-overview/) is a Linux distribution for embedded systems that updates via OSTree images delivered via [Uptane](https://uptane.github.io/) and [aktualizr](https://github.com/uptane/aktualizr/). + ## Distribution build tools [meta-updater](https://github.com/advancedtelematic/meta-updater) is @@ -85,6 +87,10 @@ which uses libostree. The [BuildStream](https://gitlab.com/BuildStream/buildstream) build and integration tool supports importing and exporting from libostree repos. +[fedora-iot/otto](https://github.com/fedora-iot/otto) is a tool that helps +ship ostree commits inside Docker/OCI containers and run a webserver +to serve the commits. + Fedora [coreos-assembler](https://github.com/coreos/coreos-assembler) is the build tool used to generate Fedora CoreOS derivatives. @@ -109,6 +115,8 @@ use the "libostree host system" aspects (e.g. bootloader management), just the "git-like hardlink dedup". For example, Flatpak supports a per-user OSTree repository. +[aktualizr](https://github.com/uptane/aktualizr/) is an [Uptane](https://uptane.github.io/)-conformant software update client library intended for use in automotive and other security-sensitive embedded devices. It uses OSTree to manage the OS of the host device by default. + ## Language bindings libostree is accessible via [GObject Introspection](https://gi.readthedocs.io/en/latest/); @@ -134,7 +142,7 @@ However, in order to build from a git clone, you must update the submodules. If you're packaging OSTree and want a tarball, I recommend using a "recursive git archive" script. There are several available online; -[this code](https://github.com/ostreedev/ostree/blob/main/packaging/Makefile.dist-packaging#L11) +[this code](https://github.com/ostreedev/ostree/blob/main/ci/Makefile.dist-packaging#L18) in OSTree is an example. Once you have a git clone or recursive archive, building is the diff --git a/aclocal.m4 b/aclocal.m4 index 94c6e7fc..463dd160 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -702,7 +702,7 @@ AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE], ]) # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- -# serial 11 (pkg-config-0.29.1) +# serial 12 (pkg-config-0.29.2) dnl Copyright © 2004 Scott James Remnant . dnl Copyright © 2012-2015 Dan Nicholson @@ -744,7 +744,7 @@ dnl dnl See the "Since" comment for each macro you use to see what version dnl of the macros you require. m4_defun([PKG_PREREQ], -[m4_define([PKG_MACROS_VERSION], [0.29.1]) +[m4_define([PKG_MACROS_VERSION], [0.29.2]) m4_if(m4_version_compare(PKG_MACROS_VERSION, [$1]), -1, [m4_fatal([pkg.m4 version $1 or higher is required but ]PKG_MACROS_VERSION[ found])]) ])dnl PKG_PREREQ @@ -845,7 +845,7 @@ AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl pkg_failed=no -AC_MSG_CHECKING([for $1]) +AC_MSG_CHECKING([for $2]) _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) _PKG_CONFIG([$1][_LIBS], [libs], [$2]) @@ -855,11 +855,11 @@ and $1[]_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details.]) if test $pkg_failed = yes; then - AC_MSG_RESULT([no]) + AC_MSG_RESULT([no]) _PKG_SHORT_ERRORS_SUPPORTED if test $_pkg_short_errors_supported = yes; then $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1` - else + else $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1` fi # Put the nasty error message in config.log where it belongs @@ -876,7 +876,7 @@ installed software in a non-standard prefix. _PKG_TEXT])[]dnl ]) elif test $pkg_failed = untried; then - AC_MSG_RESULT([no]) + AC_MSG_RESULT([no]) m4_default([$4], [AC_MSG_FAILURE( [The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full @@ -977,74 +977,6 @@ AS_VAR_COPY([$1], [pkg_cv_][$1]) AS_VAR_IF([$1], [""], [$5], [$4])dnl ])dnl PKG_CHECK_VAR -dnl PKG_WITH_MODULES(VARIABLE-PREFIX, MODULES, -dnl [ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND], -dnl [DESCRIPTION], [DEFAULT]) -dnl ------------------------------------------ -dnl -dnl Prepare a "--with-" configure option using the lowercase -dnl [VARIABLE-PREFIX] name, merging the behaviour of AC_ARG_WITH and -dnl PKG_CHECK_MODULES in a single macro. -AC_DEFUN([PKG_WITH_MODULES], -[ -m4_pushdef([with_arg], m4_tolower([$1])) - -m4_pushdef([description], - [m4_default([$5], [build with ]with_arg[ support])]) - -m4_pushdef([def_arg], [m4_default([$6], [auto])]) -m4_pushdef([def_action_if_found], [AS_TR_SH([with_]with_arg)=yes]) -m4_pushdef([def_action_if_not_found], [AS_TR_SH([with_]with_arg)=no]) - -m4_case(def_arg, - [yes],[m4_pushdef([with_without], [--without-]with_arg)], - [m4_pushdef([with_without],[--with-]with_arg)]) - -AC_ARG_WITH(with_arg, - AS_HELP_STRING(with_without, description[ @<:@default=]def_arg[@:>@]),, - [AS_TR_SH([with_]with_arg)=def_arg]) - -AS_CASE([$AS_TR_SH([with_]with_arg)], - [yes],[PKG_CHECK_MODULES([$1],[$2],$3,$4)], - [auto],[PKG_CHECK_MODULES([$1],[$2], - [m4_n([def_action_if_found]) $3], - [m4_n([def_action_if_not_found]) $4])]) - -m4_popdef([with_arg]) -m4_popdef([description]) -m4_popdef([def_arg]) - -])dnl PKG_WITH_MODULES - -dnl PKG_HAVE_WITH_MODULES(VARIABLE-PREFIX, MODULES, -dnl [DESCRIPTION], [DEFAULT]) -dnl ----------------------------------------------- -dnl -dnl Convenience macro to trigger AM_CONDITIONAL after PKG_WITH_MODULES -dnl check._[VARIABLE-PREFIX] is exported as make variable. -AC_DEFUN([PKG_HAVE_WITH_MODULES], -[ -PKG_WITH_MODULES([$1],[$2],,,[$3],[$4]) - -AM_CONDITIONAL([HAVE_][$1], - [test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"]) -])dnl PKG_HAVE_WITH_MODULES - -dnl PKG_HAVE_DEFINE_WITH_MODULES(VARIABLE-PREFIX, MODULES, -dnl [DESCRIPTION], [DEFAULT]) -dnl ------------------------------------------------------ -dnl -dnl Convenience macro to run AM_CONDITIONAL and AC_DEFINE after -dnl PKG_WITH_MODULES check. HAVE_[VARIABLE-PREFIX] is exported as make -dnl and preprocessor variable. -AC_DEFUN([PKG_HAVE_DEFINE_WITH_MODULES], -[ -PKG_HAVE_WITH_MODULES([$1],[$2],[$3],[$4]) - -AS_IF([test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"], - [AC_DEFINE([HAVE_][$1], 1, [Enable ]m4_tolower([$1])[ support])]) -])dnl PKG_HAVE_DEFINE_WITH_MODULES - # Copyright (C) 2002-2021 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation diff --git a/apidoc/html/home.png b/apidoc/html/home.png index 9346b336..3966a915 100644 Binary files a/apidoc/html/home.png and b/apidoc/html/home.png differ diff --git a/apidoc/html/index.html b/apidoc/html/index.html index 65ccc6f8..0b1b5865 100644 --- a/apidoc/html/index.html +++ b/apidoc/html/index.html @@ -14,7 +14,7 @@
-

for OSTree 2022.5

+

for OSTree 2022.6


diff --git a/apidoc/html/left-insensitive.png b/apidoc/html/left-insensitive.png index 3269393a..2cd8c169 100644 Binary files a/apidoc/html/left-insensitive.png and b/apidoc/html/left-insensitive.png differ diff --git a/apidoc/html/left.png b/apidoc/html/left.png index 2abde032..1ca1664c 100644 Binary files a/apidoc/html/left.png and b/apidoc/html/left.png differ diff --git a/apidoc/html/ostree-Core-repository-independent-functions.html b/apidoc/html/ostree-Core-repository-independent-functions.html index 52089ce1..81d0df44 100644 --- a/apidoc/html/ostree-Core-repository-independent-functions.html +++ b/apidoc/html/ostree-Core-repository-independent-functions.html @@ -46,7 +46,7 @@ -const GVariantType * +const GVariantType * ostree_metadata_variant_type () @@ -54,7 +54,7 @@ -gboolean +gboolean ostree_validate_checksum_string () @@ -62,7 +62,7 @@ -gboolean +gboolean ostree_validate_collection_id () @@ -70,7 +70,7 @@ -guchar * +guchar * ostree_checksum_to_bytes () @@ -78,7 +78,7 @@ -GVariant * +GVariant * ostree_checksum_to_bytes_v () @@ -117,14 +117,14 @@ -const guchar * +const guchar * ostree_checksum_bytes_peek () -const guchar * +const guchar * ostree_checksum_bytes_peek_validate () @@ -140,7 +140,7 @@ -guchar * +guchar * ostree_checksum_b64_to_bytes () @@ -172,7 +172,7 @@ -gboolean +gboolean ostree_validate_rev () @@ -180,7 +180,7 @@ -gboolean +gboolean ostree_validate_remote_name () @@ -188,7 +188,7 @@ -gboolean +gboolean ostree_parse_refspec () @@ -211,7 +211,7 @@ -guint +guint ostree_hash_object_name () @@ -219,7 +219,7 @@ -GVariant * +GVariant * ostree_object_name_serialize () @@ -251,7 +251,7 @@ -gboolean +gboolean ostree_content_stream_parse () @@ -259,7 +259,7 @@ -gboolean +gboolean ostree_content_file_parse () @@ -267,7 +267,7 @@ -gboolean +gboolean ostree_content_file_parse_at () @@ -275,7 +275,7 @@ -gboolean +gboolean ostree_raw_file_to_archive_z2_stream () @@ -283,7 +283,7 @@ -gboolean +gboolean ostree_raw_file_to_archive_z2_stream_with_options () @@ -291,7 +291,7 @@ -gboolean +gboolean ostree_raw_file_to_content_stream () @@ -299,7 +299,7 @@ -gboolean +gboolean ostree_break_hardlink () @@ -307,7 +307,7 @@ -gboolean +gboolean ostree_checksum_file_from_input () @@ -315,7 +315,7 @@ -gboolean +gboolean ostree_checksum_file () @@ -323,7 +323,7 @@ -gboolean +gboolean ostree_checksum_file_at () @@ -339,7 +339,7 @@ -gboolean +gboolean ostree_checksum_file_async_finish () @@ -347,7 +347,7 @@ -GVariant * +GVariant * ostree_fs_get_all_xattrs () @@ -355,7 +355,7 @@ -GVariant * +GVariant * ostree_fs_get_all_xattrs_at () @@ -363,7 +363,7 @@ -GVariant * +GVariant * ostree_create_directory_metadata () @@ -371,7 +371,7 @@ -gboolean +gboolean ostree_validate_structureof_objtype () @@ -379,7 +379,7 @@ -gboolean +gboolean ostree_validate_structureof_csum_v () @@ -387,7 +387,7 @@ -gboolean +gboolean ostree_validate_structureof_checksum_string () @@ -395,7 +395,7 @@ -gboolean +gboolean ostree_validate_structureof_file_mode () @@ -403,7 +403,7 @@ -gboolean +gboolean ostree_validate_structureof_commit () @@ -411,7 +411,7 @@ -gboolean +gboolean ostree_validate_structureof_dirtree () @@ -419,7 +419,7 @@ -gboolean +gboolean ostree_validate_structureof_dirmeta () @@ -427,7 +427,7 @@ -gchar * +gchar * ostree_commit_get_parent () @@ -435,7 +435,7 @@ -guint64 +guint64 ostree_commit_get_timestamp () @@ -443,7 +443,7 @@ -gboolean +gboolean ostree_commit_metadata_for_bootable () @@ -451,7 +451,7 @@ -gchar * +gchar * ostree_commit_get_content_checksum () @@ -459,7 +459,7 @@ -gboolean +gboolean ostree_commit_get_object_sizes () @@ -491,7 +491,7 @@ -gboolean +gboolean ostree_check_version () @@ -575,11 +575,11 @@

Description

These functions implement repository-independent algorithms for operating on the core OSTree data formats, such as converting -GFileInfo into a GVariant.

+GFileInfo into a GVariant.

There are 4 types of objects; file, dirmeta, tree, and commit. The last 3 are metadata, and the file object is the only content object type.

-

All metadata objects are stored as GVariant (big endian). The +

All metadata objects are stored as GVariant (big endian). The rationale for this is the same as that of the ext{2,3,4} family of filesystems; most developers will be using LE, and so it's better to continually test the BE->LE swap.

@@ -608,21 +608,21 @@ to continually test the BE->LE swap.

Returns

-

TRUE if object type is metadata

+

TRUE if object type is metadata


ostree_metadata_variant_type ()

-
const GVariantType *
+
const GVariantType *
 ostree_metadata_variant_type (OstreeObjectType objtype);

ostree_validate_checksum_string ()

-
gboolean
+
gboolean
 ostree_validate_checksum_string (const char *sha256,
-                                 GError **error);
+ GError **error);

Use this function to see if input strings are checksums.

Parameters

@@ -648,19 +648,19 @@ ostree_validate_checksum_string (const

Returns

-

TRUE if sha256 -is a valid checksum string, FALSE otherwise

+

TRUE if sha256 +is a valid checksum string, FALSE otherwise


ostree_validate_collection_id ()

-
gboolean
+
gboolean
 ostree_validate_collection_id (const char *collection_id,
-                               GError **error);
+ GError **error);

Check whether the given collection_id is valid. Return an error if it is -invalid or NULL.

+invalid or NULL.

Valid collection IDs are reverse DNS names:

  • They are composed of 1 or more elements separated by a period (.) character. @@ -696,16 +696,16 @@ begin with a digit.

Returns

-

TRUE if collection_id -is a valid collection ID, FALSE if it is invalid -or NULL

+

TRUE if collection_id +is a valid collection ID, FALSE if it is invalid +or NULL

Since: 2018.6


ostree_checksum_to_bytes ()

-
guchar *
+
guchar *
 ostree_checksum_to_bytes (const char *checksum);

Parameters

@@ -725,14 +725,14 @@ ostree_checksum_to_bytes (const c

Returns

Binary checksum from checksum -of length 32; free with g_free().

+of length 32; free with g_free().

[transfer full][array fixed-size=32]


ostree_checksum_to_bytes_v ()

-
GVariant *
+
GVariant *
 ostree_checksum_to_bytes_v (const char *checksum);

Parameters

@@ -751,7 +751,7 @@ ostree_checksum_to_bytes_v (const

Returns

-

New GVariant of type ay with length 32.

+

New GVariant of type ay with length 32.

[transfer full]

@@ -759,7 +759,7 @@ ostree_checksum_to_bytes_v (const

ostree_checksum_from_bytes ()

char *
-ostree_checksum_from_bytes (const guchar *csum);
+ostree_checksum_from_bytes (const guchar *csum);

Parameters

@@ -786,7 +786,7 @@ ostree_checksum_from_bytes (const

ostree_checksum_from_bytes_v ()

char *
-ostree_checksum_from_bytes_v (GVariant *csum_v);
+ostree_checksum_from_bytes_v (GVariant *csum_v);

Parameters

@@ -797,7 +797,7 @@ ostree_checksum_from_bytes_v (GVa - +

csum_v

GVariant of type ay

GVariant of type ay

 
@@ -813,7 +813,7 @@ ostree_checksum_from_bytes_v (GVa

ostree_checksum_inplace_from_bytes ()

void
-ostree_checksum_inplace_from_bytes (const guchar *csum,
+ostree_checksum_inplace_from_bytes (const guchar *csum,
                                     char *buf);

Overwrite the contents of buf with stringified version of csum @@ -847,7 +847,7 @@ ostree_checksum_inplace_from_bytes (const

ostree_checksum_inplace_to_bytes ()

void
 ostree_checksum_inplace_to_bytes (const char *checksum,
-                                  guchar *buf);
+ guchar *buf);

Convert checksum from a string to binary in-place, without allocating memory. Use this function in hot code paths.

@@ -877,8 +877,8 @@ allocating memory. Use this function in hot code paths.


ostree_checksum_bytes_peek ()

-
const guchar *
-ostree_checksum_bytes_peek (GVariant *bytes);
+
const guchar *
+ostree_checksum_bytes_peek (GVariant *bytes);

Parameters

@@ -889,7 +889,7 @@ ostree_checksum_bytes_peek (GVari - +

bytes

GVariant of type ay

GVariant of type ay

 
@@ -898,16 +898,16 @@ ostree_checksum_bytes_peek (GVari

Returns

Binary checksum data in bytes ; do not free. If bytes -does not have the correct length, return NULL.

+does not have the correct length, return NULL.

[transfer none][array fixed-size=32][element-type guint8]


ostree_checksum_bytes_peek_validate ()

-
const guchar *
-ostree_checksum_bytes_peek_validate (GVariant *bytes,
-                                     GError **error);
+
const guchar *
+ostree_checksum_bytes_peek_validate (GVariant *bytes,
+                                     GError **error);

Like ostree_checksum_bytes_peek(), but also throws error .

@@ -921,7 +921,7 @@ ostree_checksum_bytes_peek_validate (

bytes

-

GVariant of type ay

+

GVariant of type ay

  @@ -942,7 +942,7 @@ ostree_checksum_bytes_peek_validate (

ostree_checksum_b64_from_bytes ()

char *
-ostree_checksum_b64_from_bytes (const guchar *csum);
+ostree_checksum_b64_from_bytes (const guchar *csum);

Parameters

@@ -971,7 +971,7 @@ character is used.


ostree_checksum_b64_to_bytes ()

-
guchar *
+
guchar *
 ostree_checksum_b64_to_bytes (const char *checksum);

Parameters

@@ -1001,7 +1001,7 @@ ostree_checksum_b64_to_bytes (const

ostree_checksum_b64_inplace_from_bytes ()

void
 ostree_checksum_b64_inplace_from_bytes
-                               (const guchar *csum,
+                               (const guchar *csum,
                                 char *buf);

Overwrite the contents of buf with modified base64 encoding of csum @@ -1037,7 +1037,7 @@ character is used.

ostree_checksum_b64_inplace_to_bytes ()

void
 ostree_checksum_b64_inplace_to_bytes (const char *checksum,
-                                      guint8 *buf);
+ guint8 *buf);

Overwrite the contents of buf with stringified version of csum .

@@ -1069,8 +1069,8 @@ ostree_checksum_b64_inplace_to_bytes (const

ostree_cmp_checksum_bytes ()

int
-ostree_cmp_checksum_bytes (const guchar *a,
-                           const guchar *b);
+ostree_cmp_checksum_bytes (const guchar *a, + const guchar *b);

Compare two binary checksums, using memcmp().

Parameters

@@ -1098,9 +1098,9 @@ ostree_cmp_checksum_bytes (const

ostree_validate_rev ()

-
gboolean
+
gboolean
 ostree_validate_rev (const char *rev,
-                     GError **error);
+ GError **error);

Parameters

@@ -1125,16 +1125,16 @@ ostree_validate_rev (const char

Returns

-

TRUE if rev +

TRUE if rev is a valid ref string


ostree_validate_remote_name ()

-
gboolean
+
gboolean
 ostree_validate_remote_name (const char *remote_name,
-                             GError **error);
+ GError **error);

Parameters

@@ -1159,7 +1159,7 @@ ostree_validate_remote_name (const

Returns

-

TRUE if remote_name +

TRUE if remote_name is a valid remote name

Since: 2017.8

@@ -1167,20 +1167,20 @@ is a valid remote name


ostree_parse_refspec ()

-
gboolean
+
gboolean
 ostree_parse_refspec (const char *refspec,
                       char **out_remote,
                       char **out_ref,
-                      GError **error);
+ GError **error);

Split a refspec like gnome-ostree:gnome-ostree/buildmain or just gnome-ostree/buildmain into two parts. In the first case, out_remote will be set to gnome-ostree, and out_ref to gnome-ostree/buildmain. In the second case (a local ref), out_remote - will be NULL, and out_ref + will be NULL, and out_ref -will be gnome-ostree/buildmain. In both cases, TRUE will be returned.

+will be gnome-ostree/buildmain. In both cases, TRUE will be returned.

Parameters

@@ -1198,7 +1198,7 @@ will be gnome-ostree/buildmain. In both cases, +or NULL if the refspec refs to a local ref.

@@ -1216,7 +1216,7 @@ or NULL if the refspec refs to a local ref.

Returns

-

TRUE on successful parsing, FALSE otherwise

+

TRUE on successful parsing, FALSE otherwise


@@ -1267,9 +1267,9 @@ ostree_object_type_from_string (const

ostree_hash_object_name ()

-
guint
-ostree_hash_object_name (gconstpointer a);
-

Use this function with GHashTable and ostree_object_name_serialize().

+
guint
+ostree_hash_object_name (gconstpointer a);
+

Use this function with GHashTable and ostree_object_name_serialize().

Parameters

out_remote

Return location for the remote name, -or NULL if the refspec refs to a local ref.

[out][nullable][optional]
@@ -1280,7 +1280,7 @@ ostree_hash_object_name (gconstpo - +

a

A GVariant containing a serialized object

A GVariant containing a serialized object

 
@@ -1289,7 +1289,7 @@ ostree_hash_object_name (gconstpo

ostree_object_name_serialize ()

-
GVariant *
+
GVariant *
 ostree_object_name_serialize (const char *checksum,
                               OstreeObjectType objtype);
@@ -1316,7 +1316,7 @@ ostree_object_name_serialize (const

Returns

-

A new floating GVariant containing checksum string and objtype.

+

A new floating GVariant containing checksum string and objtype.

[transfer floating]

@@ -1324,7 +1324,7 @@ ostree_object_name_serialize (const

ostree_object_name_deserialize ()

void
-ostree_object_name_deserialize (GVariant *variant,
+ostree_object_name_deserialize (GVariant *variant,
                                 const char **out_checksum,
                                 OstreeObjectType *out_objtype);

Reverse ostree_object_name_serialize(). Note that out_checksum @@ -1342,7 +1342,7 @@ only valid for the lifetime of variant

variant

-

A GVariant of type (su)

+

A GVariant of type (su)

  @@ -1400,7 +1400,7 @@ and a stringifed version of objtype

ostree_object_from_string ()

void
 ostree_object_from_string (const char *str,
-                           gchar **out_checksum,
+                           gchar **out_checksum,
                            OstreeObjectType *out_objtype);

Reverse ostree_object_to_string().

@@ -1434,16 +1434,16 @@ ostree_object_from_string (const

ostree_content_stream_parse ()

-
gboolean
-ostree_content_stream_parse (gboolean compressed,
-                             GInputStream *input,
-                             guint64 input_length,
-                             gboolean trusted,
-                             GInputStream **out_input,
-                             GFileInfo **out_file_info,
-                             GVariant **out_xattrs,
-                             GCancellable *cancellable,
-                             GError **error);
+
gboolean
+ostree_content_stream_parse (gboolean compressed,
+                             GInputStream *input,
+                             guint64 input_length,
+                             gboolean trusted,
+                             GInputStream **out_input,
+                             GFileInfo **out_file_info,
+                             GVariant **out_xattrs,
+                             GCancellable *cancellable,
+                             GError **error);

The reverse of ostree_raw_file_to_content_stream(); this function converts an object content stream back into components.

@@ -1472,7 +1472,7 @@ converts an object content stream back into components.

trusted

-

If TRUE, assume the content has been validated

+

If TRUE, assume the content has been validated

  @@ -1507,15 +1507,15 @@ converts an object content stream back into components.


ostree_content_file_parse ()

-
gboolean
-ostree_content_file_parse (gboolean compressed,
-                           GFile *content_path,
-                           gboolean trusted,
-                           GInputStream **out_input,
-                           GFileInfo **out_file_info,
-                           GVariant **out_xattrs,
-                           GCancellable *cancellable,
-                           GError **error);
+
gboolean
+ostree_content_file_parse (gboolean compressed,
+                           GFile *content_path,
+                           gboolean trusted,
+                           GInputStream **out_input,
+                           GFileInfo **out_file_info,
+                           GVariant **out_xattrs,
+                           GCancellable *cancellable,
+                           GError **error);

A thin wrapper for ostree_content_stream_parse(); this function converts an object content stream back into components.

@@ -1539,7 +1539,7 @@ converts an object content stream back into components.

trusted

-

If TRUE, assume the content has been validated

+

If TRUE, assume the content has been validated

  @@ -1574,16 +1574,16 @@ converts an object content stream back into components.


ostree_content_file_parse_at ()

-
gboolean
-ostree_content_file_parse_at (gboolean compressed,
+
gboolean
+ostree_content_file_parse_at (gboolean compressed,
                               int parent_dfd,
                               const char *path,
-                              gboolean trusted,
-                              GInputStream **out_input,
-                              GFileInfo **out_file_info,
-                              GVariant **out_xattrs,
-                              GCancellable *cancellable,
-                              GError **error);
+ gboolean trusted, + GInputStream **out_input, + GFileInfo **out_file_info, + GVariant **out_xattrs, + GCancellable *cancellable, + GError **error);

A thin wrapper for ostree_content_stream_parse(); this function converts an object content stream back into components.

@@ -1612,7 +1612,7 @@ converts an object content stream back into components.

trusted

-

If TRUE, assume the content has been validated

+

If TRUE, assume the content has been validated

  @@ -1647,13 +1647,13 @@ converts an object content stream back into components.


ostree_raw_file_to_archive_z2_stream ()

-
gboolean
-ostree_raw_file_to_archive_z2_stream (GInputStream *input,
-                                      GFileInfo *file_info,
-                                      GVariant *xattrs,
-                                      GInputStream **out_input,
-                                      GCancellable *cancellable,
-                                      GError **error);
+
gboolean
+ostree_raw_file_to_archive_z2_stream (GInputStream *input,
+                                      GFileInfo *file_info,
+                                      GVariant *xattrs,
+                                      GInputStream **out_input,
+                                      GCancellable *cancellable,
+                                      GError **error);

Convert from a "bare" file representation into an OSTREE_OBJECT_TYPE_FILE stream suitable for ostree pull.

@@ -1703,15 +1703,15 @@ OSTREE_OBJECT_TYPE_FILE stream suitable for ostree pull.


ostree_raw_file_to_archive_z2_stream_with_options ()

-
gboolean
+
gboolean
 ostree_raw_file_to_archive_z2_stream_with_options
-                               (GInputStream *input,
-                                GFileInfo *file_info,
-                                GVariant *xattrs,
-                                GVariant *options,
-                                GInputStream **out_input,
-                                GCancellable *cancellable,
-                                GError **error);
+ (GInputStream *input, + GFileInfo *file_info, + GVariant *xattrs, + GVariant *options, + GInputStream **out_input, + GCancellable *cancellable, + GError **error);

Like ostree_raw_file_to_archive_z2_stream(), but supports an extensible set of flags. The following flags are currently defined:

  • compression-level (i): Level of compression to use, 0–9, with 0 being @@ -1768,14 +1768,14 @@ the least compression, and <0 giving the default level (currently 6).

  • ostree_raw_file_to_content_stream ()

    -
    gboolean
    -ostree_raw_file_to_content_stream (GInputStream *input,
    -                                   GFileInfo *file_info,
    -                                   GVariant *xattrs,
    -                                   GInputStream **out_input,
    -                                   guint64 *out_length,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    +
    gboolean
    +ostree_raw_file_to_content_stream (GInputStream *input,
    +                                   GFileInfo *file_info,
    +                                   GVariant *xattrs,
    +                                   GInputStream **out_input,
    +                                   guint64 *out_length,
    +                                   GCancellable *cancellable,
    +                                   GError **error);

    Convert from a "bare" file representation into an OSTREE_OBJECT_TYPE_FILE stream. This is a fundamental operation for writing data to an OstreeRepo.

    @@ -1830,12 +1830,12 @@ for writing data to an

    ostree_break_hardlink ()

    -
    gboolean
    +
    gboolean
     ostree_break_hardlink (int dfd,
                            const char *path,
    -                       gboolean skip_xattrs,
    -                       GCancellable *cancellable,
    -                       GError **error);
    + gboolean skip_xattrs, + GCancellable *cancellable, + GError **error);

    In many cases using libostree, a program may need to "break" hardlinks by performing a copy. For example, in order to logically append to a file.

    @@ -1885,14 +1885,14 @@ care of synchronization.


    ostree_checksum_file_from_input ()

    -
    gboolean
    -ostree_checksum_file_from_input (GFileInfo *file_info,
    -                                 GVariant *xattrs,
    -                                 GInputStream *in,
    +
    gboolean
    +ostree_checksum_file_from_input (GFileInfo *file_info,
    +                                 GVariant *xattrs,
    +                                 GInputStream *in,
                                      OstreeObjectType objtype,
    -                                 guchar **out_csum,
    -                                 GCancellable *cancellable,
    -                                 GError **error);
    + guchar **out_csum, + GCancellable *cancellable, + GError **error);

    Compute the OSTree checksum for a given input.

    Parameters

    @@ -1915,7 +1915,7 @@ ostree_checksum_file_from_input (

    in

    -

    File content, should be NULL for symbolic links.

    +

    File content, should be NULL for symbolic links.

    [allow-none] @@ -1945,12 +1945,12 @@ ostree_checksum_file_from_input (

    ostree_checksum_file ()

    -
    gboolean
    -ostree_checksum_file (GFile *f,
    +
    gboolean
    +ostree_checksum_file (GFile *f,
                           OstreeObjectType objtype,
    -                      guchar **out_csum,
    -                      GCancellable *cancellable,
    -                      GError **error);
    + guchar **out_csum, + GCancellable *cancellable, + GError **error);

    Compute the OSTree checksum for a given file.

    Parameters

    @@ -1993,15 +1993,15 @@ ostree_checksum_file (GFile

    ostree_checksum_file_at ()

    -
    gboolean
    +
    gboolean
     ostree_checksum_file_at (int dfd,
                              const char *path,
                              struct stat *stbuf,
                              OstreeObjectType objtype,
                              OstreeChecksumFlags flags,
                              char **out_checksum,
    -                         GCancellable *cancellable,
    -                         GError **error);
    + GCancellable *cancellable, + GError **error);

    Compute the OSTree checksum for a given file. This is an fd-relative version of ostree_checksum_file() which also takes flags and fills in a caller allocated buffer.

    @@ -2063,12 +2063,12 @@ allocated buffer.

    ostree_checksum_file_async ()

    void
    -ostree_checksum_file_async (GFile *f,
    +ostree_checksum_file_async (GFile *f,
                                 OstreeObjectType objtype,
                                 int io_priority,
    -                            GCancellable *cancellable,
    -                            GAsyncReadyCallback callback,
    -                            gpointer user_data);
    + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data);

    Asynchronously compute the OSTree checksum for a given file; complete with ostree_checksum_file_async_finish().

    @@ -2118,11 +2118,11 @@ complete with

    ostree_checksum_file_async_finish ()

    -
    gboolean
    -ostree_checksum_file_async_finish (GFile *f,
    -                                   GAsyncResult *result,
    -                                   guchar **out_csum,
    -                                   GError **error);
    +
    gboolean
    +ostree_checksum_file_async_finish (GFile *f,
    +                                   GAsyncResult *result,
    +                                   guchar **out_csum,
    +                                   GError **error);

    Finish computing the OSTree checksum for a given file; see ostree_checksum_file_async().

    @@ -2161,10 +2161,10 @@ ostree_checksum_file_async_finish (

    ostree_fs_get_all_xattrs ()

    -
    GVariant *
    +
    GVariant *
     ostree_fs_get_all_xattrs (int fd,
    -                          GCancellable *cancellable,
    -                          GError **error);
    + GCancellable *cancellable, + GError **error);

    Retrieve all extended attributes in a canonical (sorted) order from the given file descriptor.

    @@ -2203,11 +2203,11 @@ the given file descriptor.


    ostree_fs_get_all_xattrs_at ()

    -
    GVariant *
    +
    GVariant *
     ostree_fs_get_all_xattrs_at (int dfd,
                                  const char *path,
    -                             GCancellable *cancellable,
    -                             GError **error);
    + GCancellable *cancellable, + GError **error);

    Retrieve all extended attributes in a canonical (sorted) order from the given path, relative to the provided directory file descriptor. The target path will not be dereferenced. Currently on Linux, this @@ -2255,9 +2255,9 @@ with fgetxattr().


    ostree_create_directory_metadata ()

    -
    GVariant *
    -ostree_create_directory_metadata (GFileInfo *dir_info,
    -                                  GVariant *xattrs);
    +
    GVariant *
    +ostree_create_directory_metadata (GFileInfo *dir_info,
    +                                  GVariant *xattrs);

    Parameters

    @@ -2269,7 +2269,7 @@ ostree_create_directory_metadata ( - + @@ -2282,16 +2282,16 @@ ostree_create_directory_metadata (

    Returns

    -

    A new GVariant containing OSTREE_OBJECT_TYPE_DIR_META.

    +

    A new GVariant containing OSTREE_OBJECT_TYPE_DIR_META.

    [transfer full][not nullable]


    ostree_validate_structureof_objtype ()

    -
    gboolean
    -ostree_validate_structureof_objtype (guchar objtype,
    -                                     GError **error);
    +
    gboolean
    +ostree_validate_structureof_objtype (guchar objtype,
    +                                     GError **error);

    Parameters

    dir_info

    a GFileInfo containing directory information

    a GFileInfo containing directory information

     
    @@ -2309,16 +2309,16 @@ ostree_validate_structureof_objtype (

    Returns

    -

    TRUE if objtype +

    TRUE if objtype represents a valid object type


    ostree_validate_structureof_csum_v ()

    -
    gboolean
    -ostree_validate_structureof_csum_v (GVariant *checksum,
    -                                    GError **error);
    +
    gboolean
    +ostree_validate_structureof_csum_v (GVariant *checksum,
    +                                    GError **error);

    Parameters

    @@ -2330,7 +2330,7 @@ ostree_validate_structureof_csum_v (

    checksum

    -
    + @@ -2343,17 +2343,17 @@ ostree_validate_structureof_csum_v (

    Returns

    -

    TRUE if checksum +

    TRUE if checksum is a valid binary SHA256 checksum


    ostree_validate_structureof_checksum_string ()

    -
    gboolean
    +
    gboolean
     ostree_validate_structureof_checksum_string
                                    (const char *checksum,
    -                                GError **error);
    + GError **error);

    Parameters

    a GVariant of type "ay"

    a GVariant of type "ay"

     
    @@ -2378,16 +2378,16 @@ ostree_validate_structureof_checksum_string

    Returns

    -

    TRUE if checksum +

    TRUE if checksum is a valid ASCII SHA256 checksum


    ostree_validate_structureof_file_mode ()

    -
    gboolean
    -ostree_validate_structureof_file_mode (guint32 mode,
    -                                       GError **error);
    +
    gboolean
    +ostree_validate_structureof_file_mode (guint32 mode,
    +                                       GError **error);

    Parameters

    @@ -2412,16 +2412,16 @@ ostree_validate_structureof_file_mode (

    Returns

    -

    TRUE if mode +

    TRUE if mode represents a valid file type and permissions


    ostree_validate_structureof_commit ()

    -
    gboolean
    -ostree_validate_structureof_commit (GVariant *commit,
    -                                    GError **error);
    +
    gboolean
    +ostree_validate_structureof_commit (GVariant *commit,
    +                                    GError **error);

    Use this to validate the basic structure of commit , independent of any other objects it references.

    @@ -2449,16 +2449,16 @@ any other objects it references.

    Returns

    -

    TRUE if commit +

    TRUE if commit is structurally valid


    ostree_validate_structureof_dirtree ()

    -
    gboolean
    -ostree_validate_structureof_dirtree (GVariant *dirtree,
    -                                     GError **error);
    +
    gboolean
    +ostree_validate_structureof_dirtree (GVariant *dirtree,
    +                                     GError **error);

    Use this to validate the basic structure of dirtree , independent of any other objects it references.

    @@ -2486,16 +2486,16 @@ any other objects it references.

    Returns

    -

    TRUE if dirtree +

    TRUE if dirtree is structurally valid


    ostree_validate_structureof_dirmeta ()

    -
    gboolean
    -ostree_validate_structureof_dirmeta (GVariant *dirmeta,
    -                                     GError **error);
    +
    gboolean
    +ostree_validate_structureof_dirmeta (GVariant *dirmeta,
    +                                     GError **error);

    Use this to validate the basic structure of dirmeta .

    @@ -2522,15 +2522,15 @@ ostree_validate_structureof_dirmeta (

    Returns

    -

    TRUE if dirmeta +

    TRUE if dirmeta is structurally valid


    ostree_commit_get_parent ()

    -
    gchar *
    -ostree_commit_get_parent (GVariant *commit_variant);
    +
    gchar *
    +ostree_commit_get_parent (GVariant *commit_variant);

    Parameters

    @@ -2549,15 +2549,15 @@ ostree_commit_get_parent (GVarian

    Returns

    Checksum of the parent commit of commit_variant -, or NULL +, or NULL if none


    ostree_commit_get_timestamp ()

    -
    guint64
    -ostree_commit_get_timestamp (GVariant *commit_variant);
    +
    guint64
    +ostree_commit_get_timestamp (GVariant *commit_variant);

    Parameters

    @@ -2582,11 +2582,11 @@ ostree_commit_get_timestamp (GVar

    ostree_commit_metadata_for_bootable ()

    -
    gboolean
    -ostree_commit_metadata_for_bootable (GFile *root,
    -                                     GVariantDict *dict,
    -                                     GCancellable *cancellable,
    -                                     GError **error);
    +
    gboolean
    +ostree_commit_metadata_for_bootable (GFile *root,
    +                                     GVariantDict *dict,
    +                                     GCancellable *cancellable,
    +                                     GError **error);

    Update provided dict with standard metadata for bootable OSTree commits.

    @@ -2616,8 +2616,8 @@ ostree_commit_metadata_for_bootable (

    ostree_commit_get_content_checksum ()

    -
    gchar *
    -ostree_commit_get_content_checksum (GVariant *commit_variant);
    +
    gchar *
    +ostree_commit_get_content_checksum (GVariant *commit_variant);

    There are use cases where one wants a checksum just of the content of a commit. OSTree commits by default capture the current timestamp, and may have additional metadata, which means that re-committing identical content @@ -2644,7 +2644,7 @@ root "dirmeta" checksum (both in binary form, not hexadecimal).

    Returns

    -

    A SHA-256 hex string, or NULL if commit_variant +

    A SHA-256 hex string, or NULL if commit_variant is not well-formed.

    [nullable]

    @@ -2653,15 +2653,15 @@ is not well-formed.


    ostree_commit_get_object_sizes ()

    -
    gboolean
    -ostree_commit_get_object_sizes (GVariant *commit_variant,
    -                                GPtrArray **out_sizes_entries,
    -                                GError **error);
    +
    gboolean
    +ostree_commit_get_object_sizes (GVariant *commit_variant,
    +                                GPtrArray **out_sizes_entries,
    +                                GError **error);

    Reads a commit's "ostree.sizes" metadata and returns an array of OstreeCommitSizesEntry in out_sizes_entries . Each element represents an object in the commit. If the commit does not contain -the "ostree.sizes" metadata, a G_IO_ERROR_NOT_FOUND error will be +the "ostree.sizes" metadata, a G_IO_ERROR_NOT_FOUND error will be returned.

    Parameters

    @@ -2696,10 +2696,10 @@ returned.

    ostree_commit_sizes_entry_new ()

    OstreeCommitSizesEntry *
    -ostree_commit_sizes_entry_new (const gchar *checksum,
    +ostree_commit_sizes_entry_new (const gchar *checksum,
                                    OstreeObjectType objtype,
    -                               guint64 unpacked,
    -                               guint64 archived);
    + guint64 unpacked, + guint64 archived);

    Create a new OstreeCommitSizesEntry for representing an object in a commit's "ostree.sizes" metadata.

    @@ -2798,9 +2798,9 @@ ostree_commit_sizes_entry_free (

    ostree_check_version ()

    -
    gboolean
    -ostree_check_version (guint required_year,
    -                      guint required_release);
    +
    gboolean
    +ostree_check_version (guint required_year,
    +                      guint required_release);

    Parameters

    @@ -2825,7 +2825,7 @@ ostree_check_version (guint

    Returns

    -

    TRUE if current libostree has at least the requested version, FALSE otherwise

    +

    TRUE if current libostree has at least the requested version, FALSE otherwise

    Since: 2017.4

    @@ -3071,7 +3071,7 @@ entry corresponds to an object in the associated commit.

    - + @@ -3081,12 +3081,12 @@ entry corresponds to an object in the associated commit.

    - + - + diff --git a/apidoc/html/ostree-GPG-signature-verification-results.html b/apidoc/html/ostree-GPG-signature-verification-results.html index d6c94bec..722b7620 100644 --- a/apidoc/html/ostree-GPG-signature-verification-results.html +++ b/apidoc/html/ostree-GPG-signature-verification-results.html @@ -41,7 +41,7 @@ +, or NULL.

    @@ -248,22 +248,22 @@ signed by key_id

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure


    ostree_gpg_verify_result_get ()

    -
    GVariant *
    +
    GVariant *
     ostree_gpg_verify_result_get (OstreeGpgVerifyResult *result,
    -                              guint signature_index,
    +                              guint signature_index,
                                   OstreeGpgSignatureAttr *attrs,
    -                              guint n_attrs);
    -

    Builds a GVariant tuple of requested attributes for the GPG signature at + guint n_attrs);

    +

    Builds a GVariant tuple of requested attributes for the GPG signature at signature_index in result . See the OstreeGpgSignatureAttr description -for the GVariantType of each available attribute.

    +for the GVariantType of each available attribute.

    It is a programmer error to request an invalid OstreeGpgSignatureAttr or an invalid signature_index . Use ostree_gpg_verify_result_count_all() to @@ -304,30 +304,30 @@ array

    Returns

    -

    a new, floating, GVariant tuple.

    +

    a new, floating, GVariant tuple.

    [transfer floating]


    ostree_gpg_verify_result_get_all ()

    -
    GVariant *
    +
    GVariant *
     ostree_gpg_verify_result_get_all (OstreeGpgVerifyResult *result,
    -                                  guint signature_index);
    -

    Builds a GVariant tuple of all available attributes for the GPG signature + guint signature_index);

    +

    Builds a GVariant tuple of all available attributes for the GPG signature at signature_index in result .

    -

    The child values in the returned GVariant tuple are ordered to match the +

    The child values in the returned GVariant tuple are ordered to match the OstreeGpgSignatureAttr enumeration, which means the enum values can be -used as index values in functions like g_variant_get_child(). See the -OstreeGpgSignatureAttr description for the GVariantType of each +used as index values in functions like g_variant_get_child(). See the +OstreeGpgSignatureAttr description for the GVariantType of each available attribute.

    The OstreeGpgSignatureAttr enumeration may be extended in the future - with new attributes, which would affect the GVariant tuple returned by + with new attributes, which would affect the GVariant tuple returned by this function. While the position and type of current child values in - the GVariant tuple will not change, to avoid backward-compatibility + the GVariant tuple will not change, to avoid backward-compatibility issues please do not depend on the tuple's overall size or type signature.

    @@ -360,7 +360,7 @@ available attribute.

    Returns

    -

    a new, floating, GVariant tuple.

    +

    a new, floating, GVariant tuple.

    [transfer floating]

    @@ -369,9 +369,9 @@ available attribute.

    ostree_gpg_verify_result_describe ()

    void
     ostree_gpg_verify_result_describe (OstreeGpgVerifyResult *result,
    -                                   guint signature_index,
    -                                   GString *output_buffer,
    -                                   const gchar *line_prefix,
    +                                   guint signature_index,
    +                                   GString *output_buffer,
    +                                   const gchar *line_prefix,
                                        OstreeGpgSignatureFormatFlags flags);

    Appends a brief, human-readable description of the GPG signature at signature_index @@ -410,7 +410,7 @@ format. Currently must be 0.

    - + @@ -432,11 +432,11 @@ format. Currently must be 0.

    ostree_gpg_verify_result_describe_variant ()

    void
     ostree_gpg_verify_result_describe_variant
    -                               (GVariant *variant,
    -                                GString *output_buffer,
    -                                const gchar *line_prefix,
    +                               (GVariant *variant,
    +                                GString *output_buffer,
    +                                const gchar *line_prefix,
                                     OstreeGpgSignatureFormatFlags flags);
    -

    Similar to ostree_gpg_verify_result_describe() but takes a GVariant of +

    Similar to ostree_gpg_verify_result_describe() but takes a GVariant of all attributes for a GPG signature instead of an OstreeGpgVerifyResult and signature index.

    The variant @@ -453,12 +453,12 @@ and signature index.

    - + - + @@ -478,14 +478,14 @@ and signature index.


    ostree_gpg_verify_result_require_valid_signature ()

    -
    gboolean
    +
    gboolean
     ostree_gpg_verify_result_require_valid_signature
                                    (OstreeGpgVerifyResult *result,
    -                                GError **error);
    + GError **error);

    Checks if the result contains at least one signature from the trusted keyring. You can call this function immediately after ostree_repo_verify_summary() or ostree_repo_verify_commit_ext() - -it will handle the NULL result +it will handle the NULL result and filled error too.

    @@ -504,7 +504,7 @@ it will handle the NULL
    - + @@ -512,9 +512,9 @@ it will handle the NULL

    Returns

    -

    TRUE if result -was not NULL and had at least one -signature from trusted keyring, otherwise FALSE

    +

    TRUE if result +was not NULL and had at least one +signature from trusted keyring, otherwise FALSE

    Since: 2016.6

    @@ -594,7 +594,7 @@ sign it has been revoked. Since: 2020.1.

    enum OstreeGpgSignatureAttr

    Signature attributes available from an OstreeGpgVerifyResult. -The attribute's GVariantType is shown in brackets.

    +The attribute's GVariantType is shown in brackets.

    Members

    gchar *checksum;

    gchar *checksum;

    object checksum.

    [not nullable]
     

    guint64 unpacked;

    guint64 unpacked;

    unpacked object size

     

    guint64 archived;

    guint64 archived;

    compressed object size

     
    -guint +guint ostree_gpg_verify_result_count_all () @@ -49,7 +49,7 @@
    -guint +guint ostree_gpg_verify_result_count_valid () @@ -57,7 +57,7 @@
    -gboolean +gboolean ostree_gpg_verify_result_lookup () @@ -65,7 +65,7 @@
    -GVariant * +GVariant * ostree_gpg_verify_result_get () @@ -73,7 +73,7 @@
    -GVariant * +GVariant * ostree_gpg_verify_result_get_all () @@ -97,7 +97,7 @@
    -gboolean +gboolean ostree_gpg_verify_result_require_valid_signature () @@ -150,7 +150,7 @@ or get all signature details with

    Functions

    ostree_gpg_verify_result_count_all ()

    -
    guint
    +
    guint
     ostree_gpg_verify_result_count_all (OstreeGpgVerifyResult *result);

    Counts all the signatures in result .

    @@ -177,7 +177,7 @@ ostree_gpg_verify_result_count_all (

    ostree_gpg_verify_result_count_valid ()

    -
    guint
    +
    guint
     ostree_gpg_verify_result_count_valid (OstreeGpgVerifyResult *result);

    Counts only the valid signatures in result .

    @@ -204,17 +204,17 @@ ostree_gpg_verify_result_count_valid (

    ostree_gpg_verify_result_lookup ()

    -
    gboolean
    +
    gboolean
     ostree_gpg_verify_result_lookup (OstreeGpgVerifyResult *result,
    -                                 const gchar *key_id,
    -                                 guint *out_signature_index);
    + const gchar *key_id, + guint *out_signature_index);

    Searches result for a signature signed by key_id . If a match is found, -the function returns TRUE and sets out_signature_index +the function returns TRUE and sets out_signature_index so that further signature details can be obtained through ostree_gpg_verify_result_get(). -If no match is found, the function returns FALSE and leaves +If no match is found, the function returns FALSE and leaves out_signature_index unchanged.

    @@ -240,7 +240,7 @@ If no match is found, the function returns FALSE an

    out_signature_index

    return location for the index of the signature signed by key_id -, or NULL.

    [out]

    output_buffer

    a GString to hold the description

    a GString to hold the description

     

    variant

    a GVariant from ostree_gpg_verify_result_get_all()

    a GVariant from ostree_gpg_verify_result_get_all()

     

    output_buffer

    a GString to hold the description

    a GString to hold the description

     

    error

    A GError

    A GError

     
    @@ -607,56 +607,56 @@ The attribute's GVariantType is shown in brackets.

    @@ -664,7 +664,7 @@ expiration)

    @@ -672,7 +672,7 @@ the signature

    @@ -680,14 +680,14 @@ signature

    @@ -695,7 +695,7 @@ user

    @@ -713,7 +713,7 @@ expiration or if the key is missing)

    - + @@ -410,11 +410,11 @@ does not exist in the tree


    ostree_mutable_tree_ensure_dir ()

    -
    gboolean
    +
    gboolean
     ostree_mutable_tree_ensure_dir (OstreeMutableTree *self,
                                     const char *name,
                                     OstreeMutableTree **out_subdir,
    -                                GError **error);
    + GError **error);

    Returns the subdirectory of self with filename name , creating an empty one it if it doesn't exist.

    @@ -444,7 +444,7 @@ it if it doesn't exist.

    - + @@ -454,12 +454,12 @@ it if it doesn't exist.


    ostree_mutable_tree_lookup ()

    -
    gboolean
    +
    gboolean
     ostree_mutable_tree_lookup (OstreeMutableTree *self,
                                 const char *name,
                                 char **out_file_checksum,
                                 OstreeMutableTree **out_subdir,
    -                            GError **error);
    + GError **error);

    Parameters

    OSTREE_GPG_SIGNATURE_ATTR_VALID

    -

    [G_VARIANT_TYPE_BOOLEAN] Is the signature valid?

    +

    [G_VARIANT_TYPE_BOOLEAN] Is the signature valid?

     

    OSTREE_GPG_SIGNATURE_ATTR_SIG_EXPIRED

    -

    [G_VARIANT_TYPE_BOOLEAN] Has the signature expired?

    +

    [G_VARIANT_TYPE_BOOLEAN] Has the signature expired?

     

    OSTREE_GPG_SIGNATURE_ATTR_KEY_EXPIRED

    -

    [G_VARIANT_TYPE_BOOLEAN] Has the signing key expired?

    +

    [G_VARIANT_TYPE_BOOLEAN] Has the signing key expired?

     

    OSTREE_GPG_SIGNATURE_ATTR_KEY_REVOKED

    -

    [G_VARIANT_TYPE_BOOLEAN] Has the signing key been revoked?

    +

    [G_VARIANT_TYPE_BOOLEAN] Has the signing key been revoked?

     

    OSTREE_GPG_SIGNATURE_ATTR_KEY_MISSING

    -

    [G_VARIANT_TYPE_BOOLEAN] Is the signing key missing?

    +

    [G_VARIANT_TYPE_BOOLEAN] Is the signing key missing?

     

    OSTREE_GPG_SIGNATURE_ATTR_FINGERPRINT

    -

    [G_VARIANT_TYPE_STRING] Fingerprint of the signing key

    +

    [G_VARIANT_TYPE_STRING] Fingerprint of the signing key

     

    OSTREE_GPG_SIGNATURE_ATTR_TIMESTAMP

    -

    [G_VARIANT_TYPE_INT64] Signature creation Unix timestamp

    +

    [G_VARIANT_TYPE_INT64] Signature creation Unix timestamp

     

    OSTREE_GPG_SIGNATURE_ATTR_EXP_TIMESTAMP

    -

    [G_VARIANT_TYPE_INT64] Signature expiration Unix timestamp (0 if no +

    [G_VARIANT_TYPE_INT64] Signature expiration Unix timestamp (0 if no expiration)

     

    OSTREE_GPG_SIGNATURE_ATTR_PUBKEY_ALGO_NAME

    -

    [G_VARIANT_TYPE_STRING] Name of the public key algorithm used to create +

    [G_VARIANT_TYPE_STRING] Name of the public key algorithm used to create the signature

     

    OSTREE_GPG_SIGNATURE_ATTR_HASH_ALGO_NAME

    -

    [G_VARIANT_TYPE_STRING] Name of the hash algorithm used to create the +

    [G_VARIANT_TYPE_STRING] Name of the hash algorithm used to create the signature

     

    OSTREE_GPG_SIGNATURE_ATTR_USER_NAME

    -

    [G_VARIANT_TYPE_STRING] The name of the signing key's primary user

    +

    [G_VARIANT_TYPE_STRING] The name of the signing key's primary user

     

    OSTREE_GPG_SIGNATURE_ATTR_USER_EMAIL

    -

    [G_VARIANT_TYPE_STRING] The email address of the signing key's primary +

    [G_VARIANT_TYPE_STRING] The email address of the signing key's primary user

     

    OSTREE_GPG_SIGNATURE_ATTR_FINGERPRINT_PRIMARY

    -

    [G_VARIANT_TYPE_STRING] Fingerprint of the signing key's primary key +

    [G_VARIANT_TYPE_STRING] Fingerprint of the signing key's primary key (will be the same as OSTREE_GPG_SIGNATURE_ATTR_FINGERPRINT if the the signature is already from the primary key rather than a subkey, and will be the empty string if the key is missing.)

    @@ -705,7 +705,7 @@ and will be the empty string if the key is missing.)

    OSTREE_GPG_SIGNATURE_ATTR_KEY_EXP_TIMESTAMP

    -

    [G_VARIANT_TYPE_INT64] Key expiration Unix timestamp (0 if no +

    [G_VARIANT_TYPE_INT64] Key expiration Unix timestamp (0 if no expiration or if the key is missing)

     

    OSTREE_GPG_SIGNATURE_ATTR_KEY_EXP_TIMESTAMP_PRIMARY

    -

    [G_VARIANT_TYPE_INT64] Key expiration Unix timestamp of the signing key's +

    [G_VARIANT_TYPE_INT64] Key expiration Unix timestamp of the signing key's primary key (will be the same as OSTREE_GPG_SIGNATURE_ATTR_KEY_EXP_TIMESTAMP if the signing key is the primary key and 0 if no expiration or if the key is missing)

    diff --git a/apidoc/html/ostree-In-memory-modifiable-filesystem-tree.html b/apidoc/html/ostree-In-memory-modifiable-filesystem-tree.html index 5d7386d4..4d808697 100644 --- a/apidoc/html/ostree-In-memory-modifiable-filesystem-tree.html +++ b/apidoc/html/ostree-In-memory-modifiable-filesystem-tree.html @@ -65,7 +65,7 @@
    -gboolean +gboolean ostree_mutable_tree_check_error () @@ -103,7 +103,7 @@
    -gboolean +gboolean ostree_mutable_tree_replace_file () @@ -111,7 +111,7 @@
    -gboolean +gboolean ostree_mutable_tree_remove () @@ -119,7 +119,7 @@
    -gboolean +gboolean ostree_mutable_tree_ensure_dir () @@ -127,7 +127,7 @@
    -gboolean +gboolean ostree_mutable_tree_lookup () @@ -135,7 +135,7 @@
    -gboolean +gboolean ostree_mutable_tree_ensure_parent_dirs () @@ -143,7 +143,7 @@
    -gboolean +gboolean ostree_mutable_tree_walk () @@ -151,7 +151,7 @@
    -GHashTable * +GHashTable * ostree_mutable_tree_get_subdirs () @@ -159,7 +159,7 @@
    -GHashTable * +GHashTable * ostree_mutable_tree_get_files () @@ -167,7 +167,7 @@
    -gboolean +gboolean ostree_mutable_tree_fill_empty_from_dirtree () @@ -215,7 +215,7 @@ ostree_mutable_tree_new (voidOstreeMutableTree * ostree_mutable_tree_new_from_commit (OstreeRepo *repo, const char *rev, - GError **error); + GError **error);

    Creates a new OstreeMutableTree with the contents taken from the given commit. The data will be loaded from the repo lazily as needed.

    @@ -293,9 +293,9 @@ and checksums. The data will be loaded from the repo lazily as needed.


    ostree_mutable_tree_check_error ()

    -
    gboolean
    +
    gboolean
     ostree_mutable_tree_check_error (OstreeMutableTree *self,
    -                                 GError **error);
    + GError **error);

    In some cases, a tree may be in a "lazy" state that loads data in the background; if an error occurred during a non-throwing API call, it will have been cached. This function checks for a @@ -354,20 +354,20 @@ ostree_mutable_tree_get_contents_checksum


    ostree_mutable_tree_replace_file ()

    -
    gboolean
    +
    gboolean
     ostree_mutable_tree_replace_file (OstreeMutableTree *self,
                                       const char *name,
                                       const char *checksum,
    -                                  GError **error);
    + GError **error);

    ostree_mutable_tree_remove ()

    -
    gboolean
    +
    gboolean
     ostree_mutable_tree_remove (OstreeMutableTree *self,
                                 const char *name,
    -                            gboolean allow_noent,
    -                            GError **error);
    + gboolean allow_noent, + GError **error);

    Remove the file or subdirectory named name from the mutable tree self .

    @@ -399,7 +399,7 @@ does not exist in the tree

    error

    a GError

    a GError

     

    error

    a GError

    a GError

     
    @@ -491,7 +491,7 @@ ostree_mutable_tree_lookup (

    error

    -
    + @@ -501,13 +501,13 @@ ostree_mutable_tree_lookup (

    ostree_mutable_tree_ensure_parent_dirs ()

    -
    gboolean
    +
    gboolean
     ostree_mutable_tree_ensure_parent_dirs
                                    (OstreeMutableTree *self,
    -                                GPtrArray *split_path,
    +                                GPtrArray *split_path,
                                     const char *metadata_checksum,
                                     OstreeMutableTree **out_parent,
    -                                GError **error);
    + GError **error);

    Create all parent trees necessary for the given split_path to exist.

    @@ -542,7 +542,7 @@ exist.

    - + @@ -552,12 +552,12 @@ exist.


    ostree_mutable_tree_walk ()

    -
    gboolean
    +
    gboolean
     ostree_mutable_tree_walk (OstreeMutableTree *self,
    -                          GPtrArray *split_path,
    -                          guint start,
    +                          GPtrArray *split_path,
    +                          guint start,
                               OstreeMutableTree **out_subdir,
    -                          GError **error);
    + GError **error);

    Traverse start number of elements starting from split_path ; the @@ -605,7 +605,7 @@ child will be returned in out_subdir


    ostree_mutable_tree_get_subdirs ()

    -
    GHashTable *
    +
    GHashTable *
     ostree_mutable_tree_get_subdirs (OstreeMutableTree *self);

    Returns

    @@ -616,7 +616,7 @@ ostree_mutable_tree_get_subdirs (

    ostree_mutable_tree_get_files ()

    -
    GHashTable *
    +
    GHashTable *
     ostree_mutable_tree_get_files (OstreeMutableTree *self);

    Returns

    @@ -627,7 +627,7 @@ ostree_mutable_tree_get_files (

    ostree_mutable_tree_fill_empty_from_dirtree ()

    -
    gboolean
    +
    gboolean
     ostree_mutable_tree_fill_empty_from_dirtree
                                    (OstreeMutableTree *self,
                                     OstreeRepo *repo,
    diff --git a/apidoc/html/ostree-OstreeRepo.html b/apidoc/html/ostree-OstreeRepo.html
    index 74dea759..0d46d913 100644
    --- a/apidoc/html/ostree-OstreeRepo.html
    +++ b/apidoc/html/ostree-OstreeRepo.html
    @@ -41,7 +41,7 @@
     
    - - -

    a GError

    a GError

     

    error

    a GError

    a GError

     
    -gboolean +gboolean ostree_repo_mode_from_string () @@ -81,7 +81,7 @@
    -gboolean +gboolean ostree_repo_open () @@ -97,7 +97,7 @@
    -gboolean +gboolean ostree_repo_get_disable_fsync () @@ -105,7 +105,7 @@
    -gboolean +gboolean ostree_repo_is_system () @@ -113,7 +113,7 @@
    -gboolean +gboolean ostree_repo_is_writable () @@ -129,21 +129,21 @@
    -gboolean +gboolean ostree_repo_create ()
    const gchar * +const gchar * ostree_repo_get_collection_id ()
    const gchar * +const gchar * ostree_repo_get_bootloader () @@ -151,7 +151,7 @@
    -GFile * +GFile * ostree_repo_get_path () @@ -167,7 +167,7 @@
    -gboolean +gboolean ostree_repo_get_min_free_space_bytes () @@ -175,7 +175,7 @@
    -GKeyFile * +GKeyFile * ostree_repo_get_config () @@ -190,7 +190,7 @@
    const gchar * const * +const gchar * const * ostree_repo_get_default_repo_finders () @@ -198,7 +198,7 @@
    -gboolean +gboolean ostree_repo_lock_pop () @@ -206,7 +206,7 @@
    -gboolean +gboolean ostree_repo_lock_push () @@ -230,7 +230,7 @@
    -guint +guint ostree_repo_hash () @@ -238,7 +238,7 @@
    -gboolean +gboolean ostree_repo_equal () @@ -246,7 +246,7 @@
    -GKeyFile * +GKeyFile * ostree_repo_copy_config () @@ -254,7 +254,7 @@
    -gboolean +gboolean ostree_repo_remote_add () @@ -262,7 +262,7 @@
    -gboolean +gboolean ostree_repo_remote_delete () @@ -270,7 +270,7 @@
    -gboolean +gboolean ostree_repo_remote_change () @@ -286,7 +286,7 @@
    -gboolean +gboolean ostree_repo_remote_list_collection_refs () @@ -294,7 +294,7 @@
    -gboolean +gboolean ostree_repo_remote_get_url () @@ -302,7 +302,7 @@
    -gboolean +gboolean ostree_repo_remote_get_gpg_verify () @@ -310,7 +310,7 @@
    -gboolean +gboolean ostree_repo_remote_get_gpg_verify_summary () @@ -318,7 +318,7 @@
    -gboolean +gboolean ostree_repo_remote_get_gpg_keys () @@ -326,7 +326,7 @@
    -gboolean +gboolean ostree_repo_remote_gpg_import () @@ -334,7 +334,7 @@
    -gboolean +gboolean ostree_repo_remote_fetch_summary () @@ -342,7 +342,7 @@
    -gboolean +gboolean ostree_repo_remote_fetch_summary_with_options () @@ -350,7 +350,7 @@
    -gboolean +gboolean ostree_repo_reload_config () @@ -358,7 +358,7 @@
    -gboolean +gboolean ostree_repo_get_remote_boolean_option () @@ -366,7 +366,7 @@
    -gboolean +gboolean ostree_repo_get_remote_list_option () @@ -374,7 +374,7 @@
    -gboolean +gboolean ostree_repo_get_remote_option () @@ -390,7 +390,7 @@
    -gboolean +gboolean ostree_repo_write_config () @@ -398,7 +398,7 @@
    -gboolean +gboolean ostree_repo_scan_hardlinks () @@ -406,7 +406,7 @@
    -gboolean +gboolean ostree_repo_prepare_transaction () @@ -414,7 +414,7 @@
    -gboolean +gboolean ostree_repo_commit_transaction () @@ -422,7 +422,7 @@
    -gboolean +gboolean ostree_repo_abort_transaction () @@ -454,7 +454,7 @@
    -gboolean +gboolean ostree_repo_set_ref_immediate () @@ -462,7 +462,7 @@
    -gboolean +gboolean ostree_repo_set_alias_ref_immediate () @@ -470,7 +470,7 @@
    -gboolean +gboolean ostree_repo_set_cache_dir () @@ -478,7 +478,7 @@
    -gboolean +gboolean ostree_repo_set_collection_id () @@ -486,7 +486,7 @@
    -gboolean +gboolean ostree_repo_set_collection_ref_immediate () @@ -494,7 +494,7 @@
    -gboolean +gboolean ostree_repo_sign_delta () @@ -502,7 +502,7 @@
    -gboolean +gboolean ostree_repo_has_object () @@ -510,7 +510,7 @@
    -gboolean +gboolean ostree_repo_mark_commit_partial () @@ -518,7 +518,7 @@
    -gboolean +gboolean ostree_repo_mark_commit_partial_reason () @@ -526,7 +526,7 @@
    -gboolean +gboolean ostree_repo_write_metadata () @@ -542,7 +542,7 @@
    -gboolean +gboolean ostree_repo_write_metadata_finish () @@ -550,7 +550,7 @@
    -gboolean +gboolean ostree_repo_write_content () @@ -582,7 +582,7 @@
    -gboolean +gboolean ostree_repo_write_metadata_trusted () @@ -590,7 +590,7 @@
    -gboolean +gboolean ostree_repo_write_metadata_stream_trusted () @@ -598,7 +598,7 @@
    -gboolean +gboolean ostree_repo_write_content_trusted () @@ -614,7 +614,7 @@
    -gboolean +gboolean ostree_repo_write_content_finish () @@ -622,7 +622,7 @@
    -gboolean +gboolean ostree_repo_resolve_rev () @@ -630,7 +630,7 @@
    -gboolean +gboolean ostree_repo_resolve_rev_ext () @@ -638,7 +638,7 @@
    -gboolean +gboolean ostree_repo_list_refs () @@ -646,7 +646,7 @@
    -gboolean +gboolean ostree_repo_list_refs_ext () @@ -654,7 +654,7 @@
    -gboolean +gboolean ostree_repo_list_collection_refs () @@ -662,7 +662,7 @@
    -gboolean +gboolean ostree_repo_remote_list_refs () @@ -670,7 +670,7 @@
    -gboolean +gboolean ostree_repo_resolve_collection_ref () @@ -678,7 +678,7 @@
    -gboolean +gboolean ostree_repo_load_variant () @@ -686,7 +686,7 @@
    -gboolean +gboolean ostree_repo_load_commit () @@ -694,7 +694,7 @@
    -gboolean +gboolean ostree_repo_load_variant_if_exists () @@ -702,7 +702,7 @@
    -gboolean +gboolean ostree_repo_load_file () @@ -710,7 +710,7 @@
    -gboolean +gboolean ostree_repo_load_object_stream () @@ -718,7 +718,7 @@
    -gboolean +gboolean ostree_repo_query_object_storage_size () @@ -726,7 +726,7 @@
    -gboolean +gboolean ostree_repo_import_object_from () @@ -734,7 +734,7 @@
    -gboolean +gboolean ostree_repo_import_object_from_with_trust () @@ -742,7 +742,7 @@
    -gboolean +gboolean ostree_repo_import_archive_to_mtree () @@ -750,7 +750,7 @@
    -gboolean +gboolean ostree_repo_export_tree_to_archive () @@ -758,7 +758,7 @@
    -gboolean +gboolean ostree_repo_delete_object () @@ -766,7 +766,7 @@
    -gboolean +gboolean ostree_repo_fsck_object () @@ -790,7 +790,7 @@
    -GVariant * +GVariant * (*OstreeRepoCommitModifierXattrCallback) () @@ -814,7 +814,7 @@
    -gboolean +gboolean ostree_repo_commit_modifier_set_sepolicy_from_commit () @@ -870,7 +870,7 @@
    -GType +GType ostree_repo_devino_cache_get_type () @@ -878,7 +878,7 @@
    -gboolean +gboolean ostree_repo_write_directory_to_mtree () @@ -886,7 +886,7 @@
    -gboolean +gboolean ostree_repo_write_dfd_to_mtree () @@ -894,7 +894,7 @@
    -gboolean +gboolean ostree_repo_write_archive_to_mtree () @@ -902,7 +902,7 @@
    -gboolean +gboolean ostree_repo_write_archive_to_mtree_from_fd () @@ -910,7 +910,7 @@
    -gboolean +gboolean ostree_repo_write_mtree () @@ -918,7 +918,7 @@
    -gboolean +gboolean ostree_repo_write_commit () @@ -926,7 +926,7 @@
    -gboolean +gboolean ostree_repo_write_commit_with_time () @@ -934,7 +934,7 @@
    -gboolean +gboolean ostree_repo_read_commit_detached_metadata () @@ -942,7 +942,7 @@
    -gboolean +gboolean ostree_repo_write_commit_detached_metadata () @@ -958,7 +958,7 @@
    -gboolean +gboolean ostree_repo_checkout_tree () @@ -966,7 +966,7 @@
    -gboolean +gboolean ostree_repo_checkout_tree_at () @@ -974,7 +974,7 @@
    -gboolean +gboolean ostree_repo_checkout_at () @@ -982,7 +982,7 @@
    -gboolean +gboolean ostree_repo_checkout_gc () @@ -990,7 +990,7 @@
    -gboolean +gboolean ostree_repo_read_commit () @@ -998,7 +998,7 @@
    -gboolean +gboolean ostree_repo_list_objects () @@ -1006,7 +1006,7 @@
    -gboolean +gboolean ostree_repo_list_commit_objects_starting_with () @@ -1014,7 +1014,7 @@
    -gboolean +gboolean ostree_repo_list_static_delta_names () @@ -1022,7 +1022,7 @@
    -gboolean +gboolean ostree_repo_list_static_delta_indexes () @@ -1030,7 +1030,7 @@
    -gboolean +gboolean ostree_repo_static_delta_reindex () @@ -1038,7 +1038,7 @@
    -gboolean +gboolean ostree_repo_static_delta_generate () @@ -1046,7 +1046,7 @@
    -gboolean +gboolean ostree_repo_static_delta_execute_offline_with_signature () @@ -1054,7 +1054,7 @@
    -gboolean +gboolean ostree_repo_static_delta_execute_offline () @@ -1062,7 +1062,7 @@
    -gboolean +gboolean ostree_repo_static_delta_verify_signature () @@ -1070,7 +1070,7 @@
    -GHashTable * +GHashTable * ostree_repo_traverse_new_reachable () @@ -1078,7 +1078,7 @@
    -GHashTable * +GHashTable * ostree_repo_traverse_new_parents () @@ -1094,7 +1094,7 @@
    -gboolean +gboolean ostree_repo_traverse_commit () @@ -1102,7 +1102,7 @@
    -gboolean +gboolean ostree_repo_traverse_commit_union () @@ -1110,7 +1110,7 @@
    -gboolean +gboolean ostree_repo_traverse_commit_union_with_parents () @@ -1118,7 +1118,7 @@
    -gboolean +gboolean ostree_repo_traverse_commit_with_flags () @@ -1158,7 +1158,7 @@
    -gboolean +gboolean ostree_repo_commit_traverse_iter_init_commit () @@ -1166,7 +1166,7 @@
    -gboolean +gboolean ostree_repo_commit_traverse_iter_init_dirtree () @@ -1182,7 +1182,7 @@
    -gboolean +gboolean ostree_repo_prune () @@ -1190,7 +1190,7 @@
    -gboolean +gboolean ostree_repo_prune_static_deltas () @@ -1198,7 +1198,7 @@
    -gboolean +gboolean ostree_repo_traverse_reachable_refs () @@ -1206,7 +1206,7 @@
    -gboolean +gboolean ostree_repo_prune_from_reachable () @@ -1214,7 +1214,7 @@
    -gboolean +gboolean ostree_repo_pull () @@ -1222,7 +1222,7 @@
    -gboolean +gboolean ostree_repo_pull_one_dir () @@ -1230,7 +1230,7 @@
    -gboolean +gboolean ostree_repo_pull_with_options () @@ -1246,7 +1246,7 @@
    -gboolean +gboolean ostree_repo_sign_commit () @@ -1254,7 +1254,7 @@
    -gboolean +gboolean ostree_repo_append_gpg_signature () @@ -1262,7 +1262,7 @@
    -gboolean +gboolean ostree_repo_add_gpg_signature_summary () @@ -1270,7 +1270,7 @@
    -gboolean +gboolean ostree_repo_gpg_sign_data () @@ -1286,7 +1286,7 @@
    -gboolean +gboolean ostree_repo_signature_verify_commit_data () @@ -1294,7 +1294,7 @@
    -gboolean +gboolean ostree_repo_verify_commit () @@ -1326,7 +1326,7 @@
    -gboolean +gboolean ostree_repo_regenerate_summary () @@ -1482,10 +1482,10 @@ collection IDs, see

    Functions

    ostree_repo_mode_from_string ()

    -
    gboolean
    +
    gboolean
     ostree_repo_mode_from_string (const char *mode,
                                   OstreeRepoMode *out_mode,
    -                              GError **error);
    + GError **error);

    Parameters

    @@ -1507,7 +1507,7 @@ ostree_repo_mode_from_string (const

    error

    -
    + @@ -1520,8 +1520,8 @@ ostree_repo_mode_from_string (const OstreeRepo * ostree_repo_open_at (int dfd, const char *path, - GCancellable *cancellable, - GError **error); + GCancellable *cancellable, + GError **error);

    This combines ostree_repo_new() (but using fd-relative access) with ostree_repo_open(). Use this when you know you should be operating on an already extant repository. If you want to create one, use ostree_repo_create_at().

    @@ -1560,7 +1560,7 @@ already extant repository. If you want to create one, use

    ostree_repo_new ()

    OstreeRepo *
    -ostree_repo_new (GFile *path);
    +ostree_repo_new (GFile *path);

    Parameters

    a GError if the string is not a valid mode

    a GError if the string is not a valid mode

     
    @@ -1587,8 +1587,8 @@ ostree_repo_new (GFile *pa

    ostree_repo_new_for_sysroot_path ()

    OstreeRepo *
    -ostree_repo_new_for_sysroot_path (GFile *repo_path,
    -                                  GFile *sysroot_path);
    +ostree_repo_new_for_sysroot_path (GFile *repo_path, + GFile *sysroot_path);

    Creates a new OstreeRepo instance, taking the system root path explicitly instead of assuming "/".

    @@ -1639,17 +1639,17 @@ Otherwise use the path in the OSTREE_REPO environment variable

    ostree_repo_open ()

    -
    gboolean
    +
    gboolean
     ostree_repo_open (OstreeRepo *self,
    -                  GCancellable *cancellable,
    -                  GError **error);
    + GCancellable *cancellable, + GError **error);

    ostree_repo_set_disable_fsync ()

    void
     ostree_repo_set_disable_fsync (OstreeRepo *self,
    -                               gboolean disable_fsync);
    + gboolean disable_fsync);

    Disable requests to fsync() to stable storage during commits. This option should only be used by build system tools which are creating disposable virtual machines, or have higher level mechanisms for @@ -1670,7 +1670,7 @@ ensuring data consistency.

    - + @@ -1680,7 +1680,7 @@ ensuring data consistency.


    ostree_repo_get_disable_fsync ()

    -
    gboolean
    +
    gboolean
     ostree_repo_get_disable_fsync (OstreeRepo *self);

    For more information see ostree_repo_set_disable_fsync().

    @@ -1706,7 +1706,7 @@ ostree_repo_get_disable_fsync (

    ostree_repo_is_system ()

    -
    gboolean
    +
    gboolean
     ostree_repo_is_system (OstreeRepo *repo);

    Parameters

    @@ -1725,15 +1725,15 @@ ostree_repo_is_system (

    Returns

    -

    TRUE if this repository is the root-owned system global repository

    +

    TRUE if this repository is the root-owned system global repository


    ostree_repo_is_writable ()

    -
    gboolean
    +
    gboolean
     ostree_repo_is_writable (OstreeRepo *self,
    -                         GError **error);
    + GError **error);

    Returns whether the repository is writable by the current user. If the repository is not writable, the error indicates why.

    @@ -1753,7 +1753,7 @@ If the repository is not writable, the error<
    - + @@ -1761,7 +1761,7 @@ If the repository is not writable, the error<

    Returns

    -

    TRUE if this repository is writable

    +

    TRUE if this repository is writable


    @@ -1771,9 +1771,9 @@ If the repository is not writable, the error< ostree_repo_create_at (int dfd, const char *path, OstreeRepoMode mode, - GVariant *options, - GCancellable *cancellable, - GError **error); + GVariant *options, + GCancellable *cancellable, + GError **error);

    This is a file-descriptor relative version of ostree_repo_create(). Create the underlying structure on disk for the repository, and call ostree_repo_open_at() on the result, preparing it for use.

    @@ -1838,11 +1838,11 @@ the mode or configuration (repo/config) of an exist

    ostree_repo_create ()

    -
    gboolean
    +
    gboolean
     ostree_repo_create (OstreeRepo *self,
                         OstreeRepoMode mode,
    -                    GCancellable *cancellable,
    -                    GError **error);
    + GCancellable *cancellable, + GError **error);

    Create the underlying structure on disk for the repository, and call ostree_repo_open() on the result, preparing it for use.

    Since version 2016.8, this function will succeed on an existing @@ -1890,7 +1890,7 @@ this function on a repository initialized via

    ostree_repo_get_collection_id ()

    -
    const gchar *
    +
    const gchar *
     ostree_repo_get_collection_id (OstreeRepo *self);

    Get the collection ID of this repository. See collection IDs.

    @@ -1918,7 +1918,7 @@ ostree_repo_get_collection_id (

    ostree_repo_get_bootloader ()

    -
    const gchar *
    +
    const gchar *
     ostree_repo_get_bootloader (OstreeRepo *self);

    Get the bootloader configured. See the documentation for the "sysroot.bootloader" config key.

    @@ -1947,7 +1947,7 @@ ostree_repo_get_bootloader (

    ostree_repo_get_path ()

    -
    GFile *
    +
    GFile *
     ostree_repo_get_path (OstreeRepo *self);

    Note that since the introduction of ostree_repo_open_at(), this function may return a process-specific path in /proc if the repository was created using @@ -1982,10 +1982,10 @@ ostree_repo_get_mode (

    ostree_repo_get_min_free_space_bytes ()

    -
    gboolean
    +
    gboolean
     ostree_repo_get_min_free_space_bytes (OstreeRepo *self,
    -                                      guint64 *out_reserved_bytes,
    -                                      GError **error);
    + guint64 *out_reserved_bytes, + GError **error);

    Determine the number of bytes of free disk space that are reserved according to the repo config and return that number in out_reserved_bytes . See the @@ -2012,7 +2012,7 @@ core.min-free-space-percent repo config options.

    - + @@ -2020,14 +2020,14 @@ core.min-free-space-percent repo config options.

    Returns

    -

    TRUE on success, FALSE otherwise.

    +

    TRUE on success, FALSE otherwise.

    Since: 2018.9


    ostree_repo_get_config ()

    -
    GKeyFile *
    +
    GKeyFile *
     ostree_repo_get_config (OstreeRepo *self);

    Returns

    @@ -2069,7 +2069,7 @@ repository (to see whether a ref was written).


    ostree_repo_get_default_repo_finders ()

    -
    const gchar * const *
    +
    const gchar * const *
     ostree_repo_get_default_repo_finders (OstreeRepo *self);

    Get the set of default repo finders configured. See the documentation for the "core.default-repo-finders" config key.

    @@ -2090,7 +2090,7 @@ the "core.default-repo-finders" config key.

    Returns

    -

    NULL-terminated array of strings.

    +

    NULL-terminated array of strings.

    [array zero-terminated=1][element-type utf8]

    Since: 2018.9

    @@ -2098,11 +2098,11 @@ the "core.default-repo-finders" config key.


    ostree_repo_lock_pop ()

    -
    gboolean
    +
    gboolean
     ostree_repo_lock_pop (OstreeRepo *self,
                           OstreeRepoLockType lock_type,
    -                      GCancellable *cancellable,
    -                      GError **error);
    + GCancellable *cancellable, + GError **error);

    Release a lock of type lock_type from the lock state. If the lock state becomes empty, the repository is unlocked. Otherwise, the lock state only @@ -2116,10 +2116,10 @@ lock-timeout-secs configuration. When lock-timeout-secs is -1, a blocking lock i attempted. Otherwise, the lock is removed non-blocking and ostree_repo_lock_pop() will sleep synchronously up to lock-timeout-secs seconds attempting to remove the lock. If the lock cannot be removed within the -timeout, a G_IO_ERROR_WOULD_BLOCK error is returned.

    +timeout, a G_IO_ERROR_WOULD_BLOCK error is returned.

    If self is not writable by the user, then no unlocking is attempted and -TRUE is returned.

    +TRUE is returned.

    Parameters

    disable_fsync

    If TRUE, do not fsync

    If TRUE, do not fsync

     

    error

    a GError

    a GError

     

    error

    Return location for a GError

    Return location for a GError

     
    @@ -2141,12 +2141,12 @@ timeout, a G_IO_ERROR_WOULD_BLOCK error is returned - + - + @@ -2154,7 +2154,7 @@ timeout, a G_IO_ERROR_WOULD_BLOCK error is returned

    Returns

    -

    TRUE on success, otherwise FALSE with error +

    TRUE on success, otherwise FALSE with error set

    Since: 2021.3

    @@ -2162,11 +2162,11 @@ set


    ostree_repo_lock_push ()

    -
    gboolean
    +
    gboolean
     ostree_repo_lock_push (OstreeRepo *self,
                            OstreeRepoLockType lock_type,
    -                       GCancellable *cancellable,
    -                       GError **error);
    + GCancellable *cancellable, + GError **error);

    Takes a lock on the repository and adds it to the lock state. If lock_type is OSTREE_REPO_LOCK_SHARED, a shared lock is taken. If lock_type @@ -2181,10 +2181,10 @@ lock-timeout-secs configuration. When lock-timeout-secs is -1, a blocking lock i attempted. Otherwise, the lock is taken non-blocking and ostree_repo_lock_push() will sleep synchronously up to lock-timeout-secs seconds attempting to acquire the lock. If the lock cannot be acquired within the -timeout, a G_IO_ERROR_WOULD_BLOCK error is returned.

    +timeout, a G_IO_ERROR_WOULD_BLOCK error is returned.

    If self is not writable by the user, then no locking is attempted and -TRUE is returned.

    +TRUE is returned.

    Parameters

    cancellable

    a GCancellable

    a GCancellable

     

    error

    a GError

    a GError

     
    @@ -2206,12 +2206,12 @@ timeout, a G_IO_ERROR_WOULD_BLOCK error is returned - + - + @@ -2219,7 +2219,7 @@ timeout, a G_IO_ERROR_WOULD_BLOCK error is returned

    Returns

    -

    TRUE on success, otherwise FALSE with error +

    TRUE on success, otherwise FALSE with error set

    Since: 2021.3

    @@ -2230,10 +2230,10 @@ set

    OstreeRepoAutoLock *
     ostree_repo_auto_lock_push (OstreeRepo *self,
                                 OstreeRepoLockType lock_type,
    -                            GCancellable *cancellable,
    -                            GError **error);
    + GCancellable *cancellable, + GError **error);

    Like ostree_repo_lock_push(), but for usage with OstreeRepoAutoLock. The -intended usage is to declare the OstreeRepoAutoLock with g_autoptr() so +intended usage is to declare the OstreeRepoAutoLock with g_autoptr() so that ostree_repo_auto_lock_cleanup() is called when it goes out of scope. This will automatically release the lock if it was acquired successfully.

    @@ -2276,12 +2276,12 @@ This will automatically release the lock if it was acquired successfully.

    - + - + @@ -2290,7 +2290,7 @@ This will automatically release the lock if it was acquired successfully.

    Returns

    self -on success, otherwise NULL with error +on success, otherwise NULL with error set

    Since: 2021.3

    @@ -2302,7 +2302,7 @@ set

    ostree_repo_auto_lock_cleanup (OstreeRepoAutoLock *lock);

    A cleanup handler for use with ostree_repo_auto_lock_push(). If lock is -not NULL, ostree_repo_lock_pop() will be called on it. If +not NULL, ostree_repo_lock_pop() will be called on it. If ostree_repo_lock_pop() fails, a critical warning will be emitted.

    [skip]

    @@ -2325,7 +2325,7 @@ not NULL,

    ostree_repo_hash ()

    -
    guint
    +
    guint
     ostree_repo_hash (OstreeRepo *self);

    Calculate a hash value for the given open repository, suitable for use when putting it into a hash table. It is an error to call this on an OstreeRepo @@ -2356,14 +2356,14 @@ the repository is open and the inode of its root directory has been loaded.


    ostree_repo_equal ()

    -
    gboolean
    +
    gboolean
     ostree_repo_equal (OstreeRepo *a,
                        OstreeRepo *b);

    Check whether two opened repositories are the same on disk: if their root directories are the same inode. If a or b are not open yet (due to -ostree_repo_open() not being called on them yet), FALSE will be returned.

    +ostree_repo_open() not being called on them yet), FALSE will be returned.

    Parameters

    cancellable

    a GCancellable

    a GCancellable

     

    error

    a GError

    a GError

     

    cancellable

    a GCancellable

    a GCancellable

     

    error

    a GError

    a GError

     
    @@ -2388,16 +2388,16 @@ directories are the same inode. If a

    Returns

    -

    TRUE if a +

    TRUE if a and b -are the same repository on disk, FALSE otherwise

    +are the same repository on disk, FALSE otherwise

    Since: 2017.12


    ostree_repo_copy_config ()

    -
    GKeyFile *
    +
    GKeyFile *
     ostree_repo_copy_config (OstreeRepo *self);

    Returns

    @@ -2408,24 +2408,24 @@ ostree_repo_copy_config (

    ostree_repo_remote_add ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_add (OstreeRepo *self,
                             const char *name,
                             const char *url,
    -                        GVariant *options,
    -                        GCancellable *cancellable,
    -                        GError **error);
    + GVariant *options, + GCancellable *cancellable, + GError **error);

    Create a new remote named name pointing to url . If options is -provided, then it will be mapped to GKeyFile entries, where the +provided, then it will be mapped to GKeyFile entries, where the GVariant dictionary key is an option string, and the value is mapped as follows:

    Parameters

    @@ -2473,11 +2473,11 @@ mapped as follows:


    ostree_repo_remote_delete ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_delete (OstreeRepo *self,
                                const char *name,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    Delete the remote named name . It is an error if the provided remote does not exist.

    @@ -2517,15 +2517,15 @@ remote does not exist.


    ostree_repo_remote_change ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_change (OstreeRepo *self,
    -                           GFile *sysroot,
    +                           GFile *sysroot,
                                OstreeRepoRemoteChange changeop,
                                const char *name,
                                const char *url,
    -                           GVariant *options,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GVariant *options, + GCancellable *cancellable, + GError **error);

    A combined function handling the equivalent of ostree_repo_remote_add(), ostree_repo_remote_delete(), with more options.

    @@ -2587,9 +2587,9 @@ options.

    ostree_repo_remote_list ()

    char **
     ostree_repo_remote_list (OstreeRepo *self,
    -                         guint *out_n_remotes);
    + guint *out_n_remotes);

    List available remote names in an OstreeRepo. Remote names are sorted -alphabetically. If no remotes are available the function returns NULL.

    +alphabetically. If no remotes are available the function returns NULL.

    Parameters

    @@ -2614,7 +2614,7 @@ alphabetically. If no remotes are available the function returns

    Returns

    -

    a NULL-terminated +

    a NULL-terminated array of remote names.

    [array length=out_n_remotes][transfer full]

    @@ -2622,19 +2622,19 @@ array of remote names.


    ostree_repo_remote_list_collection_refs ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_list_collection_refs
                                    (OstreeRepo *self,
                                     const char *remote_name,
    -                                GHashTable **out_all_refs,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GHashTable **out_all_refs, + GCancellable *cancellable, + GError **error);

    List refs advertised by remote_name , including refs which are part of collections. If the repository at remote_name has a collection ID set, its refs will be returned with that collection ID; otherwise, they will be returned -with a NULL collection ID in each OstreeCollectionRef key in out_all_refs +with a NULL collection ID in each OstreeCollectionRef key in out_all_refs . Any refs for other collections stored in the repository will also be returned. No filtering is performed.

    @@ -2680,11 +2680,11 @@ No filtering is performed.


    ostree_repo_remote_get_url ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_get_url (OstreeRepo *self,
                                 const char *name,
                                 char **out_url,
    -                            GError **error);
    + GError **error);

    Return the URL of the remote named name through out_url . It is an @@ -2723,17 +2723,17 @@ error if the provided remote does not exist.

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure


    ostree_repo_remote_get_gpg_verify ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_get_gpg_verify (OstreeRepo *self,
                                        const char *name,
    -                                   gboolean *out_gpg_verify,
    -                                   GError **error);
    + gboolean *out_gpg_verify, + GError **error);

    Return whether GPG verification is enabled for the remote named name through out_gpg_verify @@ -2773,18 +2773,18 @@ not exist.

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure


    ostree_repo_remote_get_gpg_verify_summary ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_get_gpg_verify_summary
                                    (OstreeRepo *self,
                                     const char *name,
    -                                gboolean *out_gpg_verify_summary,
    -                                GError **error);
    + gboolean *out_gpg_verify_summary, + GError **error);

    Return whether GPG verification of the summary is enabled for the remote named name through out_gpg_verify_summary @@ -2824,30 +2824,30 @@ remote does not exist.

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure


    ostree_repo_remote_get_gpg_keys ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_get_gpg_keys (OstreeRepo *self,
                                      const char *name,
                                      const char * const *key_ids,
    -                                 GPtrArray **out_keys,
    -                                 GCancellable *cancellable,
    -                                 GError **error);
    + GPtrArray **out_keys, + GCancellable *cancellable, + GError **error);

    Enumerate the trusted GPG keys for the remote name . If name is -NULL, the global GPG keys will be returned. The keys will be +NULL, the global GPG keys will be returned. The keys will be returned in the out_keys - GPtrArray. Each element in the array is a -GVariant of format OSTREE_GPG_KEY_GVARIANT_FORMAT. The key_ids + GPtrArray. Each element in the array is a +GVariant of format OSTREE_GPG_KEY_GVARIANT_FORMAT. The key_ids array can be used to limit which keys are included. If key_ids is -NULL, then all keys are included.

    +NULL, then all keys are included.

    Parameters

    @@ -2864,28 +2864,28 @@ array can be used to limit which keys are included. If - + - + - + - + - + @@ -2893,28 +2893,28 @@ array can be used to limit which keys are included. If

    Returns

    -

    TRUE if the GPG keys could be enumerated, FALSE otherwise

    +

    TRUE if the GPG keys could be enumerated, FALSE otherwise

    Since: 2021.4


    ostree_repo_remote_gpg_import ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_gpg_import (OstreeRepo *self,
                                    const char *name,
    -                               GInputStream *source_stream,
    +                               GInputStream *source_stream,
                                    const char * const *key_ids,
    -                               guint *out_imported,
    -                               GCancellable *cancellable,
    -                               GError **error);
    + guint *out_imported, + GCancellable *cancellable, + GError **error);

    Imports one or more GPG keys from the open source_stream , or from the user's personal keyring if source_stream - is NULL. The key_ids + is NULL. The key_ids array can optionally restrict which keys are imported. If key_ids - is NULL, + is NULL, then all keys are imported.

    The imported keys will be used to conduct GPG verification when pulling from the remote named name @@ -2940,28 +2940,28 @@ from the remote named name

    - + - + +keys, or NULL.

    - + - + @@ -2969,19 +2969,19 @@ keys, or NULL.

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure


    ostree_repo_remote_fetch_summary ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_fetch_summary (OstreeRepo *self,
                                       const char *name,
    -                                  GBytes **out_summary,
    -                                  GBytes **out_signatures,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + GBytes **out_summary, + GBytes **out_signatures, + GCancellable *cancellable, + GError **error);

    Tries to fetch the summary file and any GPG signatures on the summary file over HTTP, and returns the binary data in out_summary and out_signatures @@ -2993,10 +2993,10 @@ respectively.

    . Likewise if the summary file is not signed, out_signatures is set to NULL -. In either case the function still returns TRUE.

    +. In either case the function still returns TRUE.

    This method does not verify the signature of the downloaded summary file. Use ostree_repo_verify_summary() for that.

    -

    Parse the summary data into a GVariant using g_variant_new_from_bytes() +

    Parse the summary data into a GVariant using g_variant_new_from_bytes() with OSTREE_SUMMARY_GVARIANT_FORMAT as the format string.

    Parameters

    @@ -3020,23 +3020,23 @@ with

    out_summary

    +NULL.

    +signature data, or NULL.

    - + - + @@ -3044,21 +3044,21 @@ signature data, or NULL.

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure


    ostree_repo_remote_fetch_summary_with_options ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_fetch_summary_with_options
                                    (OstreeRepo *self,
                                     const char *name,
    -                                GVariant *options,
    -                                GBytes **out_summary,
    -                                GBytes **out_signatures,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GVariant *options, + GBytes **out_summary, + GBytes **out_signatures, + GCancellable *cancellable, + GError **error);

    Like ostree_repo_remote_fetch_summary(), but supports an extensible set of flags. The following are currently defined:

      @@ -3096,23 +3096,23 @@ means return errors without retrying

    +NULL.

    +signature data, or NULL.

    - + - + @@ -3120,17 +3120,17 @@ signature data, or NULL.

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure

    Since: 2016.6


    ostree_repo_reload_config ()

    -
    gboolean
    +
    gboolean
     ostree_repo_reload_config (OstreeRepo *self,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    By default, an OstreeRepo will cache the remote configuration and its own repo/config data. This API can be used to reload it.

    @@ -3165,13 +3165,13 @@ own repo/config data. This API can be used to reload it.


    ostree_repo_get_remote_boolean_option ()

    -
    gboolean
    +
    gboolean
     ostree_repo_get_remote_boolean_option (OstreeRepo *self,
                                            const char *remote_name,
                                            const char *option_name,
    -                                       gboolean default_value,
    -                                       gboolean *out_value,
    -                                       GError **error);
    + gboolean default_value, + gboolean *out_value, + GError **error);

    OSTree remotes are represented by keyfile groups, formatted like: [remote "remotename"]. This function returns a value named option_name @@ -3180,7 +3180,7 @@ If the option is not set, out_value will be set to default_value . If an error is returned, out_value - will be set to FALSE.

    + will be set to FALSE.

    Parameters

    name

    name of the remote or NULL.

    name of the remote or NULL.

    [nullable]

    key_ids

    a NULL-terminated array of GPG key IDs to include, or NULL.

    a NULL-terminated array of GPG key IDs to include, or NULL.

    [array zero-terminated=1][element-type utf8][nullable]

    out_keys

    return location for a GPtrArray of the remote's trusted GPG keys, or -NULL.

    return location for a GPtrArray of the remote's trusted GPG keys, or +NULL.

    [out][optional][element-type GVariant][transfer container]

    cancellable

    a GCancellable, or NULL.

    a GCancellable, or NULL.

    [nullable]

    error

    return location for a GError, or NULL

    return location for a GError, or NULL

     

    source_stream

    a GInputStream, or NULL.

    a GInputStream, or NULL.

    [nullable]

    key_ids

    a NULL-terminated array of GPG key IDs, or NULL.

    a NULL-terminated array of GPG key IDs, or NULL.

    [array zero-terminated=1][element-type utf8][nullable]

    out_imported

    return location for the number of imported -keys, or NULL.

    [out][optional]

    cancellable

    a GCancellable

    a GCancellable

     

    error

    a GError

    a GError

     

    return location for raw summary data, or -NULL.

    [out][optional]

    out_signatures

    return location for raw summary -signature data, or NULL.

    [out][optional]

    cancellable

    a GCancellable

    a GCancellable

     

    error

    a GError

    a GError

     

    out_summary

    return location for raw summary data, or -NULL.

    [out][optional]

    out_signatures

    return location for raw summary -signature data, or NULL.

    [out][optional]

    cancellable

    a GCancellable

    a GCancellable

     

    error

    a GError

    a GError

     
    @@ -3226,7 +3226,7 @@ is not present

    Returns

    -

    TRUE on success, otherwise FALSE with error +

    TRUE on success, otherwise FALSE with error set

    Since: 2016.5

    @@ -3234,19 +3234,19 @@ set


    ostree_repo_get_remote_list_option ()

    -
    gboolean
    +
    gboolean
     ostree_repo_get_remote_list_option (OstreeRepo *self,
                                         const char *remote_name,
                                         const char *option_name,
                                         char ***out_value,
    -                                    GError **error);
    + GError **error);

    OSTree remotes are represented by keyfile groups, formatted like: [remote "remotename"]. This function returns a value named option_name underneath that group, and returns it as a zero terminated array of strings. If the option is not set, or if an error is returned, out_value will be set -to NULL.

    +to NULL.

    Parameters

    @@ -3275,7 +3275,7 @@ to NULL.

    +g_strfreev().

    @@ -3288,7 +3288,7 @@ of strings. The list should be freed with

    Returns

    -

    TRUE on success, otherwise FALSE with error +

    TRUE on success, otherwise FALSE with error set

    Since: 2016.5

    @@ -3296,20 +3296,20 @@ set


    ostree_repo_get_remote_option ()

    -
    gboolean
    +
    gboolean
     ostree_repo_get_remote_option (OstreeRepo *self,
                                    const char *remote_name,
                                    const char *option_name,
                                    const char *default_value,
                                    char **out_value,
    -                               GError **error);
    + GError **error);

    OSTree remotes are represented by keyfile groups, formatted like: [remote "remotename"]. This function returns a value named option_name underneath that group, or default_value if the remote exists but not the option name. If an error is returned, out_value - will be set to NULL.

    + will be set to NULL.

    Parameters

    out_value

    location to store the list of strings. The list should be freed with -g_strfreev().

    [out][array zero-terminated=1]
    @@ -3355,7 +3355,7 @@ is not present.

    Returns

    -

    TRUE on success, otherwise FALSE with error +

    TRUE on success, otherwise FALSE with error set

    Since: 2016.5

    @@ -3384,17 +3384,17 @@ called.

    Returns

    -

    Parent repository, or NULL if none.

    +

    Parent repository, or NULL if none.

    [transfer none]


    ostree_repo_write_config ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_config (OstreeRepo *self,
    -                          GKeyFile *new_config,
    -                          GError **error);
    + GKeyFile *new_config, + GError **error);

    Save new_config in place of this repository's config file.

    @@ -3418,7 +3418,7 @@ ostree_repo_write_config (

    error

    -
    + @@ -3428,10 +3428,10 @@ ostree_repo_write_config (

    ostree_repo_scan_hardlinks ()

    -
    gboolean
    +
    gboolean
     ostree_repo_scan_hardlinks (OstreeRepo *self,
    -                            GCancellable *cancellable,
    -                            GError **error);
    + GCancellable *cancellable, + GError **error);

    This function is deprecated in favor of using ostree_repo_devino_cache_new(), which allows a precise mapping to be built up between hardlink checkout files and their checksums between ostree_repo_checkout_at() and @@ -3477,11 +3477,11 @@ before you call

    ostree_repo_prepare_transaction ()

    -
    gboolean
    +
    gboolean
     ostree_repo_prepare_transaction (OstreeRepo *self,
    -                                 gboolean *out_transaction_resume,
    -                                 GCancellable *cancellable,
    -                                 GError **error);
    + gboolean *out_transaction_resume, + GCancellable *cancellable, + GError **error);

    Starts or resumes a transaction. In order to write to a repo, you need to start a transaction. You can complete the transaction with ostree_repo_commit_transaction(), or abort the transaction with @@ -3534,11 +3534,11 @@ pulls use per-commit state/.commitpartial files.

    ostree_repo_commit_transaction ()

    -
    gboolean
    +
    gboolean
     ostree_repo_commit_transaction (OstreeRepo *self,
                                     OstreeRepoTransactionStats *out_stats,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Complete the transaction. Any refs set with ostree_repo_transaction_set_ref() or ostree_repo_transaction_set_refspec() will be written out.

    @@ -3584,10 +3584,10 @@ that happened during this transaction.


    ostree_repo_abort_transaction ()

    -
    gboolean
    +
    gboolean
     ostree_repo_abort_transaction (OstreeRepo *self,
    -                               GCancellable *cancellable,
    -                               GError **error);
    + GCancellable *cancellable, + GError **error);

    Abort the active transaction; any staged objects and ref changes will be discarded. You *must* invoke this if you have chosen not to invoke ostree_repo_commit_transaction(). Calling this function when not in a @@ -3669,11 +3669,11 @@ ostree_repo_transaction_set_collection_ref const OstreeCollectionRef *ref, const char *checksum);

    If checksum - is not NULL, then record it as the target of local ref named + is not NULL, then record it as the target of local ref named ref .

    Otherwise, if checksum - is NULL, then record that the ref should + is NULL, then record that the ref should be deleted.

    The change will not be written out immediately, but when the transaction is completed with ostree_repo_commit_transaction(). If the transaction @@ -3718,13 +3718,13 @@ ostree_repo_transaction_set_ref (const char *ref, const char *checksum);

    If checksum - is not NULL, then record it as the target of ref named + is not NULL, then record it as the target of ref named ref ; if remote is provided, the ref will appear to originate from that remote.

    Otherwise, if checksum - is NULL, then record that the ref should + is NULL, then record that the ref should be deleted.

    The change will be written when the transaction is completed with ostree_repo_commit_transaction(); that function takes care of writing all of @@ -3775,13 +3775,13 @@ case.


    ostree_repo_set_ref_immediate ()

    -
    gboolean
    +
    gboolean
     ostree_repo_set_ref_immediate (OstreeRepo *self,
                                    const char *remote,
                                    const char *ref,
                                    const char *checksum,
    -                               GCancellable *cancellable,
    -                               GError **error);
    + GCancellable *cancellable, + GError **error);

    This is like ostree_repo_transaction_set_ref(), except it may be invoked outside of a transaction. This is presently safe for the case where we're creating or overwriting an existing ref.

    @@ -3812,7 +3812,7 @@ case where we're creating or overwriting an existing ref.

    - + @@ -3832,13 +3832,13 @@ case where we're creating or overwriting an existing ref.


    ostree_repo_set_alias_ref_immediate ()

    -
    gboolean
    +
    gboolean
     ostree_repo_set_alias_ref_immediate (OstreeRepo *self,
                                          const char *remote,
                                          const char *ref,
                                          const char *target,
    -                                     GCancellable *cancellable,
    -                                     GError **error);
    + GCancellable *cancellable, + GError **error);

    Like ostree_repo_set_ref_immediate(), but creates an alias.

    Parameters

    @@ -3866,7 +3866,7 @@ ostree_repo_set_alias_ref_immediate (
    - + @@ -3887,12 +3887,12 @@ ostree_repo_set_alias_ref_immediate (

    ostree_repo_set_cache_dir ()

    -
    gboolean
    +
    gboolean
     ostree_repo_set_cache_dir (OstreeRepo *self,
                                int dfd,
                                const char *path,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    Set a custom location for the cache directory used for e.g. per-remote summary caches. Setting this manually is useful when doing operations on a system repo as a user because you don't have @@ -3924,12 +3924,12 @@ write permissions in the repo, where the cache is normally stored.

    - + - + @@ -3940,10 +3940,10 @@ write permissions in the repo, where the cache is normally stored.


    ostree_repo_set_collection_id ()

    -
    gboolean
    +
    gboolean
     ostree_repo_set_collection_id (OstreeRepo *self,
    -                               const gchar *collection_id,
    -                               GError **error);
    + const gchar *collection_id, + GError **error);

    Set or clear the collection ID of this repository. See collection IDs. The update will be made in memory, but must be written out to the repository configuration on disk using ostree_repo_write_config().

    @@ -3963,12 +3963,12 @@ configuration on disk using

    collection_id

    -
    + - + @@ -3976,20 +3976,20 @@ configuration on disk using

    Returns

    -

    TRUE on success, FALSE otherwise

    +

    TRUE on success, FALSE otherwise

    Since: 2018.6


    ostree_repo_set_collection_ref_immediate ()

    -
    gboolean
    +
    gboolean
     ostree_repo_set_collection_ref_immediate
                                    (OstreeRepo *self,
                                     const OstreeCollectionRef *ref,
                                     const char *checksum,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    This is like ostree_repo_transaction_set_collection_ref(), except it may be invoked outside of a transaction. This is presently safe for the case where we're creating or overwriting an existing ref.

    @@ -4014,7 +4014,7 @@ case where we're creating or overwriting an existing ref.

    - + @@ -4032,21 +4032,21 @@ case where we're creating or overwriting an existing ref.

    Returns

    -

    TRUE on success, FALSE otherwise

    +

    TRUE on success, FALSE otherwise

    Since: 2018.6


    ostree_repo_sign_delta ()

    -
    gboolean
    +
    gboolean
     ostree_repo_sign_delta (OstreeRepo *self,
    -                        const gchar *from_commit,
    -                        const gchar *to_commit,
    -                        const gchar *key_id,
    -                        const gchar *homedir,
    -                        GCancellable *cancellable,
    -                        GError **error);
    + const gchar *from_commit, + const gchar *to_commit, + const gchar *key_id, + const gchar *homedir, + GCancellable *cancellable, + GError **error);

    This function is deprecated, sign the summary file instead. Add a GPG signature to a static delta.

    @@ -4100,17 +4100,17 @@ Add a GPG signature to a static delta.


    ostree_repo_has_object ()

    -
    gboolean
    +
    gboolean
     ostree_repo_has_object (OstreeRepo *self,
                             OstreeObjectType objtype,
                             const char *checksum,
    -                        gboolean *out_have_object,
    -                        GCancellable *cancellable,
    -                        GError **error);
    + gboolean *out_have_object, + GCancellable *cancellable, + GError **error);

    Set out_have_object - to TRUE if self + to TRUE if self contains the given object; -FALSE otherwise.

    +FALSE otherwise.

    Parameters

    a GError

    a GError

     

    checksum

    The checksum to point it to, or NULL to unset.

    The checksum to point it to, or NULL to unset.

    [allow-none]

    target

    The ref target to point it to, or NULL to unset.

    The ref target to point it to, or NULL to unset.

    [allow-none]

    cancellable

    a GCancellable

    a GCancellable

     

    error

    a GError

    a GError

     

    new collection ID, or NULL to unset it.

    new collection ID, or NULL to unset it.

    [nullable]

    error

    return location for a GError, or NULL

    return location for a GError, or NULL

     

    checksum

    The checksum to point it to, or NULL to unset.

    The checksum to point it to, or NULL to unset.

    [nullable]
    @@ -4137,7 +4137,7 @@ ostree_repo_has_object (

    out_have_object

    -
    + @@ -4155,17 +4155,17 @@ ostree_repo_has_object (

    Returns

    -

    FALSE if an unexpected error occurred, TRUE otherwise

    +

    FALSE if an unexpected error occurred, TRUE otherwise


    ostree_repo_mark_commit_partial ()

    -
    gboolean
    +
    gboolean
     ostree_repo_mark_commit_partial (OstreeRepo *self,
                                      const char *checksum,
    -                                 gboolean is_partial,
    -                                 GError **error);
    + gboolean is_partial, + GError **error);

    Commits in the "partial" state do not have all their child objects written. This occurs in various situations, such as during a pull, but also if a "subpath" pull is used, as well as "commit only" @@ -4209,13 +4209,13 @@ should use this if you are implementing a different type of transport.


    ostree_repo_mark_commit_partial_reason ()

    -
    gboolean
    +
    gboolean
     ostree_repo_mark_commit_partial_reason
                                    (OstreeRepo *self,
                                     const char *checksum,
    -                                gboolean is_partial,
    +                                gboolean is_partial,
                                     OstreeRepoCommitState in_state,
    -                                GError **error);
    + GError **error);

    Allows the setting of a reason code for a partial commit. Presently it only supports setting reason bitmask to OSTREE_REPO_COMMIT_STATE_FSCK_PARTIAL, or @@ -4265,20 +4265,20 @@ it.


    ostree_repo_write_metadata ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_metadata (OstreeRepo *self,
                                 OstreeObjectType objtype,
                                 const char *expected_checksum,
    -                            GVariant *object,
    -                            guchar **out_csum,
    -                            GCancellable *cancellable,
    -                            GError **error);
    + GVariant *object, + guchar **out_csum, + GCancellable *cancellable, + GError **error);

    Store the metadata object object . Return the checksum as out_csum .

    If expected_checksum - is not NULL, verify it against the + is not NULL, verify it against the computed checksum.

    Parameters

    @@ -4335,10 +4335,10 @@ computed checksum.

    ostree_repo_write_metadata_async (OstreeRepo *self, OstreeObjectType objtype, const char *expected_checksum, - GVariant *object, - GCancellable *cancellable, - GAsyncReadyCallback callback, - gpointer user_data); + GVariant *object, + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data);

    Asynchronously store the metadata object variant . If provided, the checksum expected_checksum @@ -4395,11 +4395,11 @@ the checksum expected_checksum


    ostree_repo_write_metadata_finish ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_metadata_finish (OstreeRepo *self,
    -                                   GAsyncResult *result,
    -                                   guchar **out_csum,
    -                                   GError **error);
    + GAsyncResult *result, + guchar **out_csum, + GError **error);

    Complete a call to ostree_repo_write_metadata_async().

    Parameters

    @@ -4437,14 +4437,14 @@ ostree_repo_write_metadata_finish (

    ostree_repo_write_content ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_content (OstreeRepo *self,
                                const char *expected_checksum,
    -                           GInputStream *object_input,
    -                           guint64 length,
    -                           guchar **out_csum,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GInputStream *object_input, + guint64 length, + guchar **out_csum, + GCancellable *cancellable, + GError **error);

    Store the content object streamed as object_input , with total length length @@ -4506,12 +4506,12 @@ be returned as out_csum

    OstreeContentWriter *
     ostree_repo_write_regfile (OstreeRepo *self,
                                const char *expected_checksum,
    -                           guint32 uid,
    -                           guint32 gid,
    -                           guint32 mode,
    -                           guint64 content_len,
    -                           GVariant *xattrs,
    -                           GError **error);
    + guint32 uid, + guint32 gid, + guint32 mode, + guint64 content_len, + GVariant *xattrs, + GError **error);

    Create an OstreeContentWriter that allows streaming output into the repository.

    @@ -4568,7 +4568,7 @@ the repository.

    Returns

    -

    A new writer, or NULL on error.

    +

    A new writer, or NULL on error.

    [transfer full]

    Since: 2021.2

    @@ -4579,14 +4579,14 @@ the repository.

    char *
     ostree_repo_write_regfile_inline (OstreeRepo *self,
                                       const char *expected_checksum,
    -                                  guint32 uid,
    -                                  guint32 gid,
    -                                  guint32 mode,
    -                                  GVariant *xattrs,
    -                                  const guint8 *buf,
    -                                  gsize len,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + guint32 uid, + guint32 gid, + guint32 mode, + GVariant *xattrs, + const guint8 *buf, + gsize len, + GCancellable *cancellable, + GError **error);

    Synchronously create a file object from the provided content. This API is intended for small files where it is reasonable to buffer the entire content in memory.

    @@ -4663,12 +4663,12 @@ this function will not check for the presence of the object beforehand.

    char *
     ostree_repo_write_symlink (OstreeRepo *self,
                                const char *expected_checksum,
    -                           guint32 uid,
    -                           guint32 gid,
    -                           GVariant *xattrs,
    +                           guint32 uid,
    +                           guint32 gid,
    +                           GVariant *xattrs,
                                const char *symlink_target,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    Synchronously create a symlink object.

    Unlike ostree_repo_write_content(), if expected_checksum is provided, @@ -4735,13 +4735,13 @@ this function will not check for the presence of the object beforehand.


    ostree_repo_write_metadata_trusted ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_metadata_trusted (OstreeRepo *self,
                                         OstreeObjectType objtype,
                                         const char *checksum,
    -                                    GVariant *variant,
    -                                    GCancellable *cancellable,
    -                                    GError **error);
    + GVariant *variant, + GCancellable *cancellable, + GError **error);

    Store the metadata object variant ; the provided checksum is @@ -4792,15 +4792,15 @@ trusted.


    ostree_repo_write_metadata_stream_trusted ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_metadata_stream_trusted
                                    (OstreeRepo *self,
                                     OstreeObjectType objtype,
                                     const char *checksum,
    -                                GInputStream *object_input,
    -                                guint64 length,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GInputStream *object_input, + guint64 length, + GCancellable *cancellable, + GError **error);

    Store the metadata object variant ; the provided checksum is @@ -4856,13 +4856,13 @@ trusted.


    ostree_repo_write_content_trusted ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_content_trusted (OstreeRepo *self,
                                        const char *checksum,
    -                                   GInputStream *object_input,
    -                                   guint64 length,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    + GInputStream *object_input, + guint64 length, + GCancellable *cancellable, + GError **error);

    Store the content object streamed as object_input , with total length length @@ -4921,11 +4921,11 @@ disk, for example.

    void
     ostree_repo_write_content_async (OstreeRepo *self,
                                      const char *expected_checksum,
    -                                 GInputStream *object,
    -                                 guint64 length,
    -                                 GCancellable *cancellable,
    -                                 GAsyncReadyCallback callback,
    -                                 gpointer user_data);
    + GInputStream *object, + guint64 length, + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data);

    Asynchronously store the content object object . If provided, the checksum expected_checksum @@ -4983,11 +4983,11 @@ checksum expected_checksum


    ostree_repo_write_content_finish ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_content_finish (OstreeRepo *self,
    -                                  GAsyncResult *result,
    -                                  guchar **out_csum,
    -                                  GError **error);
    + GAsyncResult *result, + guchar **out_csum, + GError **error);

    Completes an invocation of ostree_repo_write_content_async().

    Parameters

    @@ -5005,7 +5005,7 @@ ostree_repo_write_content_finish (
    - + @@ -5015,7 +5015,7 @@ ostree_repo_write_content_finish ( - + @@ -5025,12 +5025,12 @@ ostree_repo_write_content_finish (

    ostree_repo_resolve_rev ()

    -
    gboolean
    +
    gboolean
     ostree_repo_resolve_rev (OstreeRepo *self,
                              const char *refspec,
    -                         gboolean allow_noent,
    +                         gboolean allow_noent,
                              char **out_rev,
    -                         GError **error);
    + GError **error);

    Look up the given refspec, returning the checksum it references in the parameter out_rev . Will fall back on remote directory if cannot @@ -5061,7 +5061,7 @@ find the given refspec in local.

    - @@ -5077,13 +5077,13 @@ is true and it does not exist.


    ostree_repo_resolve_rev_ext ()

    -
    gboolean
    +
    gboolean
     ostree_repo_resolve_rev_ext (OstreeRepo *self,
                                  const char *refspec,
    -                             gboolean allow_noent,
    +                             gboolean allow_noent,
                                  OstreeRepoResolveRevExtFlags flags,
                                  char **out_rev,
    -                             GError **error);
    + GError **error);

    Look up the given refspec, returning the checksum it references in the parameter out_rev . Differently from ostree_repo_resolve_rev(), @@ -5122,7 +5122,7 @@ using it has no effect.

    - @@ -5139,14 +5139,14 @@ is true and it does not exist.


    ostree_repo_list_refs ()

    -
    gboolean
    +
    gboolean
     ostree_repo_list_refs (OstreeRepo *self,
                            const char *refspec_prefix,
    -                       GHashTable **out_all_refs,
    -                       GCancellable *cancellable,
    -                       GError **error);
    + GHashTable **out_all_refs, + GCancellable *cancellable, + GError **error);

    If refspec_prefix - is NULL, list all local and remote refspecs, + is NULL, list all local and remote refspecs, with their current values in out_all_refs . Otherwise, only list refspecs which have refspec_prefix @@ -5154,7 +5154,7 @@ refspecs which have refspec_prefix

    out_all_refs will be returned as a mapping from refspecs (including the remote name) to checksums. If refspec_prefix - is non-NULL, it will be + is non-NULL, it will be removed as a prefix from the hash table keys.

    Parameters

    @@ -5197,15 +5197,15 @@ removed as a prefix from the hash table keys.


    ostree_repo_list_refs_ext ()

    -
    gboolean
    +
    gboolean
     ostree_repo_list_refs_ext (OstreeRepo *self,
                                const char *refspec_prefix,
    -                           GHashTable **out_all_refs,
    +                           GHashTable **out_all_refs,
                                OstreeRepoListRefsExtFlags flags,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    If refspec_prefix - is NULL, list all local and remote refspecs, + is NULL, list all local and remote refspecs, with their current values in out_all_refs . Otherwise, only list refspecs which have refspec_prefix @@ -5262,13 +5262,13 @@ remote name) to checksums. Differently from

    ostree_repo_list_collection_refs ()

    -
    gboolean
    +
    gboolean
     ostree_repo_list_collection_refs (OstreeRepo *self,
                                       const char *match_collection_id,
    -                                  GHashTable **out_all_refs,
    +                                  GHashTable **out_all_refs,
                                       OstreeRepoListRefsExtFlags flags,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + GCancellable *cancellable, + GError **error);

    List all local, mirrored, and remote refs, mapping them to the commit checksums they currently point to in out_all_refs . If match_collection_id @@ -5276,7 +5276,7 @@ checksums they currently point to in out_all_refs

    OstreeCollectionRefs are guaranteed to be returned with their collection ID -set to a non-NULL value; so no refs from refs/heads will be listed if no +set to a non-NULL value; so no refs from refs/heads will be listed if no collection ID is configured for the repository (ostree_repo_get_collection_id()).

    If you want to exclude refs from refs/remotes, use @@ -5300,7 +5300,7 @@ collection ID is configured for the repository

    - + @@ -5328,19 +5328,19 @@ collection ID is configured for the repository

    Returns

    -

    TRUE on success, FALSE otherwise

    +

    TRUE on success, FALSE otherwise

    Since: 2018.6


    ostree_repo_remote_list_refs ()

    -
    gboolean
    +
    gboolean
     ostree_repo_remote_list_refs (OstreeRepo *self,
                                   const char *remote_name,
    -                              GHashTable **out_all_refs,
    -                              GCancellable *cancellable,
    -                              GError **error);
    + GHashTable **out_all_refs, + GCancellable *cancellable, + GError **error);

    Parameters

    TRUE if repository contains object.

    TRUE if repository contains object.

    [out]

    result

    a GAsyncResult

    a GAsyncResult

     

    error

    a GError

    a GError

     

    out_rev

    A checksum,or NULL if allow_noent +

    A checksum,or NULL if allow_noent is true and it does not exist.

    [out][nullable][transfer full]

    out_rev

    A checksum,or NULL if allow_noent +

    A checksum,or NULL if allow_noent is true and it does not exist.

    [out][nullable][transfer full]

    match_collection_id

    If non-NULL, only list refs from this collection.

    If non-NULL, only list refs from this collection.

    [nullable]
    @@ -5382,25 +5382,25 @@ ostree_repo_remote_list_refs (

    ostree_repo_resolve_collection_ref ()

    -
    gboolean
    +
    gboolean
     ostree_repo_resolve_collection_ref (OstreeRepo *self,
                                         const OstreeCollectionRef *ref,
    -                                    gboolean allow_noent,
    +                                    gboolean allow_noent,
                                         OstreeRepoResolveRevExtFlags flags,
                                         char **out_rev,
    -                                    GCancellable *cancellable,
    -                                    GError **error);
    + GCancellable *cancellable, + GError **error);

    Look up the checksum for the given collection–ref, returning it in out_rev . This will search through the mirrors and remote refs.

    If allow_noent - is TRUE and the given ref - cannot be found, TRUE will be + is TRUE and the given ref + cannot be found, TRUE will be returned and out_rev - will be set to NULL. If allow_noent - is FALSE and + will be set to NULL. If allow_noent + is FALSE and the given ref - cannot be found, a G_IO_ERROR_NOT_FOUND error will be + cannot be found, a G_IO_ERROR_NOT_FOUND error will be returned.

    If you want to check only local refs, not remote or mirrored ones, use the flag OSTREE_REPO_RESOLVE_REV_EXT_LOCAL_ONLY. This is analogous to using @@ -5426,7 +5426,7 @@ flag

    allow_noent

    -
    @@ -5439,20 +5439,20 @@ doesn’t exist

    - + - + @@ -5460,19 +5460,19 @@ could not be found.

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure

    Since: 2018.6


    ostree_repo_load_variant ()

    -
    gboolean
    +
    gboolean
     ostree_repo_load_variant (OstreeRepo *self,
                               OstreeObjectType objtype,
                               const char *sha256,
    -                          GVariant **out_variant,
    -                          GError **error);
    + GVariant **out_variant, + GError **error);

    Load the metadata object sha256 of type objtype , storing the @@ -5519,12 +5519,12 @@ result in out_variant


    ostree_repo_load_commit ()

    -
    gboolean
    +
    gboolean
     ostree_repo_load_commit (OstreeRepo *self,
                              const char *checksum,
    -                         GVariant **out_commit,
    +                         GVariant **out_commit,
                              OstreeRepoCommitState *out_state,
    -                         GError **error);
    + GError **error);

    A version of ostree_repo_load_variant() specialized to commits, capable of returning extended state information. Currently the only extended state is OSTREE_REPO_COMMIT_STATE_PARTIAL, which @@ -5570,19 +5570,19 @@ means that only a sub-path of the commit is available.


    ostree_repo_load_variant_if_exists ()

    -
    gboolean
    +
    gboolean
     ostree_repo_load_variant_if_exists (OstreeRepo *self,
                                         OstreeObjectType objtype,
                                         const char *sha256,
    -                                    GVariant **out_variant,
    -                                    GError **error);
    + GVariant **out_variant, + GError **error);

    Attempt to load the metadata object sha256 of type objtype if it exists, storing the result in out_variant . If it doesn't exist, out_variant - will be set to NULL and the function will still + will be set to NULL and the function will still return TRUE.

    Parameters

    @@ -5625,14 +5625,14 @@ return TRUE.


    ostree_repo_load_file ()

    -
    gboolean
    +
    gboolean
     ostree_repo_load_file (OstreeRepo *self,
                            const char *checksum,
    -                       GInputStream **out_input,
    -                       GFileInfo **out_file_info,
    -                       GVariant **out_xattrs,
    -                       GCancellable *cancellable,
    -                       GError **error);
    + GInputStream **out_input, + GFileInfo **out_file_info, + GVariant **out_xattrs, + GCancellable *cancellable, + GError **error);

    Load content object, decomposing it into three parts: the actual content (for regular files), the metadata, and extended attributes.

    @@ -5686,14 +5686,14 @@ content (for regular files), the metadata, and extended attributes.


    ostree_repo_load_object_stream ()

    -
    gboolean
    +
    gboolean
     ostree_repo_load_object_stream (OstreeRepo *self,
                                     OstreeObjectType objtype,
                                     const char *checksum,
    -                                GInputStream **out_input,
    -                                guint64 *out_size,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GInputStream **out_input, + guint64 *out_size, + GCancellable *cancellable, + GError **error);

    Load object as a stream; useful when copying objects between repositories.

    @@ -5748,13 +5748,13 @@ repositories.


    ostree_repo_query_object_storage_size ()

    -
    gboolean
    +
    gboolean
     ostree_repo_query_object_storage_size (OstreeRepo *self,
                                            OstreeObjectType objtype,
                                            const char *sha256,
    -                                       guint64 *out_size,
    -                                       GCancellable *cancellable,
    -                                       GError **error);
    + guint64 *out_size, + GCancellable *cancellable, + GError **error);

    Return the size in bytes of object with checksum sha256 , after any compression has been applied.

    @@ -5804,13 +5804,13 @@ compression has been applied.


    ostree_repo_import_object_from ()

    -
    gboolean
    +
    gboolean
     ostree_repo_import_object_from (OstreeRepo *self,
                                     OstreeRepo *source,
                                     OstreeObjectType objtype,
                                     const char *checksum,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Copy object named by objtype and checksum into self @@ -5866,22 +5866,22 @@ hard link operation.


    ostree_repo_import_object_from_with_trust ()

    -
    gboolean
    +
    gboolean
     ostree_repo_import_object_from_with_trust
                                    (OstreeRepo *self,
                                     OstreeRepo *source,
                                     OstreeObjectType objtype,
                                     const char *checksum,
    -                                gboolean trusted,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + gboolean trusted, + GCancellable *cancellable, + GError **error);

    Copy object named by objtype and checksum into self from the source repository source . If trusted - is TRUE and both + is TRUE and both repositories are of the same type and on the same filesystem, this will simply be a fast Unix hard link operation.

    Otherwise, a copy will be performed.

    @@ -5916,7 +5916,7 @@ this will simply be a fast Unix hard link operation.

    - + @@ -5937,14 +5937,14 @@ this will simply be a fast Unix hard link operation.


    ostree_repo_import_archive_to_mtree ()

    -
    gboolean
    +
    gboolean
     ostree_repo_import_archive_to_mtree (OstreeRepo *self,
                                          OstreeRepoImportArchiveOptions *opts,
                                          void *archive,
                                          OstreeMutableTree *mtree,
                                          OstreeRepoCommitModifier *modifier,
    -                                     GCancellable *cancellable,
    -                                     GError **error);
    + GCancellable *cancellable, + GError **error);

    Import an archive file archive into the repository, and write its file structure to mtree @@ -6001,13 +6001,13 @@ file structure to mtree


    ostree_repo_export_tree_to_archive ()

    -
    gboolean
    +
    gboolean
     ostree_repo_export_tree_to_archive (OstreeRepo *self,
                                         OstreeRepoExportArchiveOptions *opts,
                                         OstreeRepoFile *root,
                                         void *archive,
    -                                    GCancellable *cancellable,
    -                                    GError **error);
    + GCancellable *cancellable, + GError **error);

    Import an archive file archive into the repository, and write its file structure to mtree @@ -6059,16 +6059,16 @@ file structure to mtree


    ostree_repo_delete_object ()

    -
    gboolean
    +
    gboolean
     ostree_repo_delete_object (OstreeRepo *self,
                                OstreeObjectType objtype,
                                const char *sha256,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    Remove the object of type objtype with checksum sha256 -from the repository. An error of type G_IO_ERROR_NOT_FOUND +from the repository. An error of type G_IO_ERROR_NOT_FOUND is thrown if the object does not exist.

    Parameters

    @@ -6111,12 +6111,12 @@ is thrown if the object does not exist.


    ostree_repo_fsck_object ()

    -
    gboolean
    +
    gboolean
     ostree_repo_fsck_object (OstreeRepo *self,
                              OstreeObjectType objtype,
                              const char *sha256,
    -                         GCancellable *cancellable,
    -                         GError **error);
    + GCancellable *cancellable, + GError **error);

    Verify consistency of the object; this performs checks only relevant to the immediate object itself, such as checksumming. This API call will not itself traverse metadata objects for example.

    @@ -6165,8 +6165,8 @@ traverse metadata objects for example.

    OstreeRepoCommitFilterResult
     (*OstreeRepoCommitFilter) (OstreeRepo *repo,
                                const char *path,
    -                           GFileInfo *file_info,
    -                           gpointer user_data);
    + GFileInfo *file_info, + gpointer user_data);

    Parameters

    TRUE to not throw an error if ref +

    TRUE to not throw an error if ref doesn’t exist

     

    out_rev

    return location for the checksum corresponding to ref -, or NULL if allow_noent -is TRUE and +, or NULL if allow_noent +is TRUE and the ref could not be found.

    [out][transfer full][optional][nullable]

    cancellable

    a GCancellable, or NULL.

    a GCancellable, or NULL.

    [nullable]

    error

    return location for a GError, or NULL

    return location for a GError, or NULL

     

    trusted

    If TRUE, assume the source repo is valid and trusted

    If TRUE, assume the source repo is valid and trusted

     
    @@ -6210,8 +6210,8 @@ traverse metadata objects for example.

    OstreeRepoCommitModifier *
     ostree_repo_commit_modifier_new (OstreeRepoCommitModifierFlags flags,
                                      OstreeRepoCommitFilter commit_filter,
    -                                 gpointer user_data,
    -                                 GDestroyNotify destroy_notify);
    + gpointer user_data, + GDestroyNotify destroy_notify);

    Parameters

    @@ -6238,7 +6238,7 @@ ostree_repo_commit_modifier_new ( - + @@ -6253,12 +6253,12 @@ ostree_repo_commit_modifier_new (

    OstreeRepoCommitModifierXattrCallback ()

    -
    GVariant *
    +
    GVariant *
     (*OstreeRepoCommitModifierXattrCallback)
                                    (OstreeRepo *repo,
                                     const char *path,
    -                                GFileInfo *file_info,
    -                                gpointer user_data);
    + GFileInfo *file_info, + gpointer user_data);

    @@ -6267,8 +6267,8 @@ ostree_repo_commit_modifier_new (OstreeRepoCommitModifier *modifier, OstreeRepoCommitModifierXattrCallback callback, - GDestroyNotify destroy, - gpointer user_data); + GDestroyNotify destroy, + gpointer user_data);

    If set, this function should return extended attributes to use for the given path. This is useful for things like ACLs and SELinux, where a build system can label the files as it's committing to the @@ -6315,7 +6315,7 @@ ostree_repo_commit_modifier_set_sepolicy (OstreeRepoCommitModifier *modifier, OstreeSePolicy *sepolicy);

    If policy - is non-NULL, use it to look up labels to use for + is non-NULL, use it to look up labels to use for "security.selinux" extended attributes.

    Note that any policy specified this way operates in addition to any extended attributes provided via @@ -6348,13 +6348,13 @@ policy wins.


    ostree_repo_commit_modifier_set_sepolicy_from_commit ()

    -
    gboolean
    +
    gboolean
     ostree_repo_commit_modifier_set_sepolicy_from_commit
                                    (OstreeRepoCommitModifier *modifier,
                                     OstreeRepo *repo,
                                     const char *rev,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    In many cases, one wants to create a "derived" commit from base commit. SELinux policy labels are part of that base commit. This API allows one to easily set up SELinux labeling from a base commit.

    @@ -6473,19 +6473,19 @@ ostree_repo_devino_cache_unref (O

    ostree_repo_devino_cache_get_type ()

    -
    GType
    +
    GType
     ostree_repo_devino_cache_get_type (void);

    ostree_repo_write_directory_to_mtree ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_directory_to_mtree (OstreeRepo *self,
    -                                      GFile *dir,
    +                                      GFile *dir,
                                           OstreeMutableTree *mtree,
                                           OstreeRepoCommitModifier *modifier,
    -                                      GCancellable *cancellable,
    -                                      GError **error);
    + GCancellable *cancellable, + GError **error);

    Store objects for dir and all children into the repository self , @@ -6537,14 +6537,14 @@ overlaying the resulting filesystem hierarchy into m


    ostree_repo_write_dfd_to_mtree ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_dfd_to_mtree (OstreeRepo *self,
                                     int dfd,
                                     const char *path,
                                     OstreeMutableTree *mtree,
                                     OstreeRepoCommitModifier *modifier,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Store as objects all contents of the directory referred to by dfd and path @@ -6603,14 +6603,14 @@ resulting filesystem hierarchy into mtree

    ostree_repo_write_archive_to_mtree ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_archive_to_mtree (OstreeRepo *self,
    -                                    GFile *archive,
    +                                    GFile *archive,
                                         OstreeMutableTree *mtree,
                                         OstreeRepoCommitModifier *modifier,
    -                                    gboolean autocreate_parents,
    -                                    GCancellable *cancellable,
    -                                    GError **error);
    + gboolean autocreate_parents, + GCancellable *cancellable, + GError **error);

    Import an archive file archive into the repository, and write its file structure to mtree @@ -6666,15 +6666,15 @@ file structure to mtree


    ostree_repo_write_archive_to_mtree_from_fd ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_archive_to_mtree_from_fd
                                    (OstreeRepo *self,
                                     int fd,
                                     OstreeMutableTree *mtree,
                                     OstreeRepoCommitModifier *modifier,
    -                                gboolean autocreate_parents,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + gboolean autocreate_parents, + GCancellable *cancellable, + GError **error);

    Read an archive from fd and import it into the repository, writing its file structure to mtree @@ -6730,12 +6730,12 @@ its file structure to mtree


    ostree_repo_write_mtree ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_mtree (OstreeRepo *self,
                              OstreeMutableTree *mtree,
    -                         GFile **out_file,
    -                         GCancellable *cancellable,
    -                         GError **error);
    + GFile **out_file, + GCancellable *cancellable, + GError **error);

    Write all metadata objects for mtree to repo; the resulting out_file @@ -6784,16 +6784,16 @@ the mtree


    ostree_repo_write_commit ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_commit (OstreeRepo *self,
                               const char *parent,
                               const char *subject,
                               const char *body,
    -                          GVariant *metadata,
    +                          GVariant *metadata,
                               OstreeRepoFile *root,
                               char **out_commit,
    -                          GCancellable *cancellable,
    -                          GError **error);
    + GCancellable *cancellable, + GError **error);

    Write a commit metadata object, referencing root_contents_checksum and root_metadata_checksum @@ -6818,7 +6818,7 @@ overridden with an explicit timestamp via the

    - + @@ -6833,7 +6833,7 @@ overridden with an explicit timestamp via the - + @@ -6863,17 +6863,17 @@ overridden with an explicit timestamp via the

    ostree_repo_write_commit_with_time ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_commit_with_time (OstreeRepo *self,
                                         const char *parent,
                                         const char *subject,
                                         const char *body,
    -                                    GVariant *metadata,
    +                                    GVariant *metadata,
                                         OstreeRepoFile *root,
    -                                    guint64 time,
    +                                    guint64 time,
                                         char **out_commit,
    -                                    GCancellable *cancellable,
    -                                    GError **error);
    + GCancellable *cancellable, + GError **error);

    Write a commit metadata object, referencing root_contents_checksum and root_metadata_checksum @@ -6894,7 +6894,7 @@ and root_metadata_checksum

    - + @@ -6909,7 +6909,7 @@ and root_metadata_checksum - + @@ -6944,17 +6944,17 @@ and root_metadata_checksum

    ostree_repo_read_commit_detached_metadata ()

    -
    gboolean
    +
    gboolean
     ostree_repo_read_commit_detached_metadata
                                    (OstreeRepo *self,
                                     const char *checksum,
    -                                GVariant **out_metadata,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GVariant **out_metadata, + GCancellable *cancellable, + GError **error);

    OSTree commits can have arbitrary metadata associated; this function retrieves them. If none exists, out_metadata will be set -to NULL.

    +to NULL.

    Parameters

    destroy_notify

    A GDestroyNotify

    A GDestroyNotify

     

    parent

    ASCII SHA256 checksum for parent, or NULL for none.

    ASCII SHA256 checksum for parent, or NULL for none.

    [allow-none]

    metadata

    GVariant of type a{sv}, or NULL for none.

    GVariant of type a{sv}, or NULL for none.

    [allow-none]

    parent

    ASCII SHA256 checksum for parent, or NULL for none.

    ASCII SHA256 checksum for parent, or NULL for none.

    [allow-none]

    metadata

    GVariant of type a{sv}, or NULL for none.

    GVariant of type a{sv}, or NULL for none.

    [allow-none]
    @@ -6976,7 +6976,7 @@ to NULL.

    - + @@ -6996,18 +6996,18 @@ to NULL.


    ostree_repo_write_commit_detached_metadata ()

    -
    gboolean
    +
    gboolean
     ostree_repo_write_commit_detached_metadata
                                    (OstreeRepo *self,
                                     const char *checksum,
    -                                GVariant *metadata,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GVariant *metadata, + GCancellable *cancellable, + GError **error);

    Replace any existing metadata associated with commit referred to by checksum with metadata . If metadata - is NULL, then existing + is NULL, then existing data will be deleted.

    Parameters

    @@ -7030,7 +7030,7 @@ data will be deleted.

    - + @@ -7089,15 +7089,15 @@ ostree_repo_checkout_at_options_set_devino

    ostree_repo_checkout_tree ()

    -
    gboolean
    +
    gboolean
     ostree_repo_checkout_tree (OstreeRepo *self,
                                OstreeRepoCheckoutMode mode,
                                OstreeRepoCheckoutOverwriteMode overwrite_mode,
    -                           GFile *destination,
    +                           GFile *destination,
                                OstreeRepoFile *source,
    -                           GFileInfo *source_info,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GFileInfo *source_info, + GCancellable *cancellable, + GError **error);

    Check out source into destination , which must live on the @@ -7163,14 +7163,14 @@ files are checked out.


    ostree_repo_checkout_tree_at ()

    -
    gboolean
    +
    gboolean
     ostree_repo_checkout_tree_at (OstreeRepo *self,
                                   OstreeRepoCheckoutOptions *options,
                                   int destination_dfd,
                                   const char *destination_path,
                                   const char *commit,
    -                              GCancellable *cancellable,
    -                              GError **error);
    + GCancellable *cancellable, + GError **error);

    ostree_repo_checkout_tree_at is deprecated and should not be used in newly-written code.

    Similar to ostree_repo_checkout_tree(), but uses directory-relative paths for the destination, uses a new OstreeRepoCheckoutAtOptions, @@ -7232,14 +7232,14 @@ cache.


    ostree_repo_checkout_at ()

    -
    gboolean
    +
    gboolean
     ostree_repo_checkout_at (OstreeRepo *self,
                              OstreeRepoCheckoutAtOptions *options,
                              int destination_dfd,
                              const char *destination_path,
                              const char *commit,
    -                         GCancellable *cancellable,
    -                         GError **error);
    + GCancellable *cancellable, + GError **error);

    Similar to ostree_repo_checkout_tree(), but uses directory-relative paths for the destination, uses a new OstreeRepoCheckoutAtOptions, and takes a commit checksum and optional subpath pair, rather than @@ -7301,10 +7301,10 @@ cache.


    ostree_repo_checkout_gc ()

    -
    gboolean
    +
    gboolean
     ostree_repo_checkout_gc (OstreeRepo *self,
    -                         GCancellable *cancellable,
    -                         GError **error);
    + GCancellable *cancellable, + GError **error);

    Call this after finishing a succession of checkout operations; it will delete any currently-unused uncompressed objects from the cache.

    @@ -7339,13 +7339,13 @@ cache.


    ostree_repo_read_commit ()

    -
    gboolean
    +
    gboolean
     ostree_repo_read_commit (OstreeRepo *self,
                              const char *ref,
    -                         GFile **out_root,
    +                         GFile **out_root,
                              char **out_commit,
    -                         GCancellable *cancellable,
    -                         GError **error);
    + GCancellable *cancellable, + GError **error);

    Load the content for rev into out_root .

    @@ -7395,18 +7395,18 @@ ostree_repo_read_commit (

    ostree_repo_list_objects ()

    -
    gboolean
    +
    gboolean
     ostree_repo_list_objects (OstreeRepo *self,
                               OstreeRepoListObjectsFlags flags,
    -                          GHashTable **out_objects,
    -                          GCancellable *cancellable,
    -                          GError **error);
    + GHashTable **out_objects, + GCancellable *cancellable, + GError **error);

    This function synchronously enumerates all objects in the repository, returning data in out_objects . out_objects maps from keys returned by ostree_object_name_serialize() -to GVariant values of type OSTREE_REPO_LIST_OBJECTS_VARIANT_TYPE.

    +to GVariant values of type OSTREE_REPO_LIST_OBJECTS_VARIANT_TYPE.

    Parameters

    out_metadata

    Metadata associated with commit in with format "a{sv}", or NULL if none exists.

    Metadata associated with commit in with format "a{sv}", or NULL if none exists.

    [out][nullable][transfer full]

    metadata

    Metadata to associate with commit in with format "a{sv}", or NULL to delete.

    Metadata to associate with commit in with format "a{sv}", or NULL to delete.

    [allow-none]
    @@ -7446,20 +7446,20 @@ to GVariant values of type

    Returns

    -

    TRUE on success, FALSE on error, and error +

    TRUE on success, FALSE on error, and error will be set


    ostree_repo_list_commit_objects_starting_with ()

    -
    gboolean
    +
    gboolean
     ostree_repo_list_commit_objects_starting_with
                                    (OstreeRepo *self,
                                     const char *start,
    -                                GHashTable **out_commits,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GHashTable **out_commits, + GCancellable *cancellable, + GError **error);

    This function synchronously enumerates all commit objects starting with start , returning data in out_commits @@ -7505,18 +7505,18 @@ with start

    Returns

    -

    TRUE on success, FALSE on error, and error +

    TRUE on success, FALSE on error, and error will be set


    ostree_repo_list_static_delta_names ()

    -
    gboolean
    +
    gboolean
     ostree_repo_list_static_delta_names (OstreeRepo *self,
    -                                     GPtrArray **out_deltas,
    -                                     GCancellable *cancellable,
    -                                     GError **error);
    + GPtrArray **out_deltas, + GCancellable *cancellable, + GError **error);

    This function synchronously enumerates all static deltas in the repository, returning its result in out_deltas .

    @@ -7556,11 +7556,11 @@ repository, returning its result in out_deltas

    ostree_repo_list_static_delta_indexes ()

    -
    gboolean
    +
    gboolean
     ostree_repo_list_static_delta_indexes (OstreeRepo *self,
    -                                       GPtrArray **out_indexes,
    -                                       GCancellable *cancellable,
    -                                       GError **error);
    + GPtrArray **out_indexes, + GCancellable *cancellable, + GError **error);

    This function synchronously enumerates all static delta indexes in the repository, returning its result in out_indexes .

    @@ -7601,18 +7601,18 @@ repository, returning its result in out_indexes

    ostree_repo_static_delta_reindex ()

    -
    gboolean
    +
    gboolean
     ostree_repo_static_delta_reindex (OstreeRepo *repo,
                                       OstreeStaticDeltaIndexFlags flags,
                                       const char *opt_to_commit,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + GCancellable *cancellable, + GError **error);

    The delta index for a particular commit lists all the existing deltas that can be used when downloading that commit. This operation regenerates these indexes, either for a particular commit (if opt_to_commit - is non-NULL), or for all commits that + is non-NULL), or for all commits that are reachable by an existing delta (if opt_to_commit - is NULL).

    + is NULL).

    This is normally called automatically when the summary is updated in ostree_repo_regenerate_summary().

    Locking: shared

    @@ -7636,7 +7636,7 @@ are reachable by an existing delta (if opt_to_commit
    - + @@ -7657,17 +7657,17 @@ are reachable by an existing delta (if opt_to_commit

    ostree_repo_static_delta_generate ()

    -
    gboolean
    +
    gboolean
     ostree_repo_static_delta_generate (OstreeRepo *self,
                                        OstreeStaticDeltaGenerateOpt opt,
                                        const char *from,
                                        const char *to,
    -                                   GVariant *metadata,
    -                                   GVariant *params,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    + GVariant *metadata, + GVariant *params, + GCancellable *cancellable, + GError **error);

    Generate a lookaside "static delta" from from - (NULL means + (NULL means from-empty) which can generate the objects in to . This delta is an optimization over fetching individual objects, and can be @@ -7710,7 +7710,7 @@ for input files

    - + @@ -7745,14 +7745,14 @@ for input files


    ostree_repo_static_delta_execute_offline_with_signature ()

    -
    gboolean
    +
    gboolean
     ostree_repo_static_delta_execute_offline_with_signature
                                    (OstreeRepo *self,
    -                                GFile *dir_or_file,
    +                                GFile *dir_or_file,
                                     OstreeSign *sign,
    -                                gboolean skip_validation,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + gboolean skip_validation, + GCancellable *cancellable, + GError **error);

    Given a directory representing an already-downloaded static delta on disk, apply it, generating a new commit. If sign is passed, the static delta signature is verified. @@ -7787,7 +7787,7 @@ one part.

    - + @@ -7808,13 +7808,13 @@ one part.


    ostree_repo_static_delta_execute_offline ()

    -
    gboolean
    +
    gboolean
     ostree_repo_static_delta_execute_offline
                                    (OstreeRepo *self,
    -                                GFile *dir_or_file,
    -                                gboolean skip_validation,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GFile *dir_or_file, + gboolean skip_validation, + GCancellable *cancellable, + GError **error);

    Given a directory representing an already-downloaded static delta on disk, apply it, generating a new commit. The directory must be named with the form "FROM-TO", where both are checksums, and it @@ -7840,7 +7840,7 @@ must contain a file named "superblock", along with at least one part.

    - + @@ -7860,13 +7860,13 @@ must contain a file named "superblock", along with at least one part.


    ostree_repo_static_delta_verify_signature ()

    -
    gboolean
    +
    gboolean
     ostree_repo_static_delta_verify_signature
                                    (OstreeRepo *self,
                                     const char *delta_id,
                                     OstreeSign *sign,
                                     char **out_success_message,
    -                                GError **error);
    + GError **error);

    Verify static delta file signature.

    Parameters

    @@ -7915,9 +7915,9 @@ signature engine provided, FALSE otherwise.


    ostree_repo_traverse_new_reachable ()

    -
    GHashTable *
    +
    GHashTable *
     ostree_repo_traverse_new_reachable (void);
    -

    This hash table is a set of GVariant which can be accessed via +

    This hash table is a set of GVariant which can be accessed via ostree_object_name_deserialize().

    Returns

    @@ -7928,11 +7928,11 @@ ostree_repo_traverse_new_reachable (

    ostree_repo_traverse_new_parents ()

    -
    GHashTable *
    +
    GHashTable *
     ostree_repo_traverse_new_parents (void);
    -

    This hash table is a mapping from GVariant which can be accessed -via ostree_object_name_deserialize() to a GVariant containing either -a similar GVariant or and array of them, listing the parents of the key.

    +

    This hash table is a mapping from GVariant which can be accessed +via ostree_object_name_deserialize() to a GVariant containing either +a similar GVariant or and array of them, listing the parents of the key.

    Returns

    A new hash table.

    @@ -7945,8 +7945,8 @@ a similar GVariant or and array of them, listing the p

    ostree_repo_traverse_parents_get_commits ()

    char **
     ostree_repo_traverse_parents_get_commits
    -                               (GHashTable *parents,
    -                                GVariant *object);
    + (GHashTable *parents, + GVariant *object);

    Gets all the commits that a certain object belongs to, as recorded by a parents table gotten from ostree_repo_traverse_commit_union_with_parents.

    @@ -7960,13 +7960,13 @@ the commits the key belongs to.


    ostree_repo_traverse_commit ()

    -
    gboolean
    +
    gboolean
     ostree_repo_traverse_commit (OstreeRepo *repo,
                                  const char *commit_checksum,
                                  int maxdepth,
    -                             GHashTable **out_reachable,
    -                             GCancellable *cancellable,
    -                             GError **error);
    + GHashTable **out_reachable, + GCancellable *cancellable, + GError **error);

    Create a new set out_reachable containing all objects reachable from commit_checksum @@ -8018,13 +8018,13 @@ from commit_checksum


    ostree_repo_traverse_commit_union ()

    -
    gboolean
    +
    gboolean
     ostree_repo_traverse_commit_union (OstreeRepo *repo,
                                        const char *commit_checksum,
                                        int maxdepth,
    -                                   GHashTable *inout_reachable,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    + GHashTable *inout_reachable, + GCancellable *cancellable, + GError **error);

    Update the set inout_reachable containing all objects reachable from commit_checksum @@ -8077,15 +8077,15 @@ from commit_checksum


    ostree_repo_traverse_commit_union_with_parents ()

    -
    gboolean
    +
    gboolean
     ostree_repo_traverse_commit_union_with_parents
                                    (OstreeRepo *repo,
                                     const char *commit_checksum,
                                     int maxdepth,
    -                                GHashTable *inout_reachable,
    -                                GHashTable *inout_parents,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GHashTable *inout_reachable, + GHashTable *inout_parents, + GCancellable *cancellable, + GError **error);

    Update the set inout_reachable containing all objects reachable from commit_checksum @@ -8147,16 +8147,16 @@ belongs to.


    ostree_repo_traverse_commit_with_flags ()

    -
    gboolean
    +
    gboolean
     ostree_repo_traverse_commit_with_flags
                                    (OstreeRepo *repo,
                                     OstreeRepoCommitTraverseFlags flags,
                                     const char *commit_checksum,
                                     int maxdepth,
    -                                GHashTable *inout_reachable,
    -                                GHashTable *inout_parents,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GHashTable *inout_reachable, + GHashTable *inout_parents, + GCancellable *cancellable, + GError **error);

    Update the set inout_reachable containing all objects reachable from commit_checksum @@ -8321,13 +8321,13 @@ called if

    ostree_repo_commit_traverse_iter_init_commit ()

    -
    gboolean
    +
    gboolean
     ostree_repo_commit_traverse_iter_init_commit
                                    (OstreeRepoCommitTraverseIter *iter,
                                     OstreeRepo *repo,
    -                                GVariant *commit,
    +                                GVariant *commit,
                                     OstreeRepoCommitTraverseFlags flags,
    -                                GError **error);
    + GError **error);

    Initialize (in place) an iterator over the root of a commit object.

    Parameters

    @@ -8370,13 +8370,13 @@ ostree_repo_commit_traverse_iter_init_commit

    ostree_repo_commit_traverse_iter_init_dirtree ()

    -
    gboolean
    +
    gboolean
     ostree_repo_commit_traverse_iter_init_dirtree
                                    (OstreeRepoCommitTraverseIter *iter,
                                     OstreeRepo *repo,
    -                                GVariant *dirtree,
    +                                GVariant *dirtree,
                                     OstreeRepoCommitTraverseFlags flags,
    -                                GError **error);
    + GError **error);

    Initialize (in place) an iterator over a directory tree.

    Parameters

    @@ -8421,8 +8421,8 @@ ostree_repo_commit_traverse_iter_init_dirtree

    ostree_repo_commit_traverse_iter_next ()

    OstreeRepoCommitIterResult
     ostree_repo_commit_traverse_iter_next (OstreeRepoCommitTraverseIter *iter,
    -                                       GCancellable *cancellable,
    -                                       GError **error);
    + GCancellable *cancellable, + GError **error);

    Step the interator to the next item. Files will be returned first, then subdirectories. Call this in a loop; upon encountering OSTREE_REPO_COMMIT_ITER_RESULT_END, there will be no more files or @@ -8466,15 +8466,15 @@ program error to call any further API on iter


    ostree_repo_prune ()

    -
    gboolean
    +
    gboolean
     ostree_repo_prune (OstreeRepo *self,
                        OstreeRepoPruneFlags flags,
    -                   gint depth,
    -                   gint *out_objects_total,
    -                   gint *out_objects_pruned,
    -                   guint64 *out_pruned_object_size_total,
    -                   GCancellable *cancellable,
    -                   GError **error);
    + gint depth, + gint *out_objects_total, + gint *out_objects_pruned, + guint64 *out_pruned_object_size_total, + GCancellable *cancellable, + GError **error);

    Delete content from the repository. By default, this function will only delete "orphaned" objects not referred to by any commit. This can happen during a local commit operation, when we have written @@ -8544,11 +8544,11 @@ deleting them.


    ostree_repo_prune_static_deltas ()

    -
    gboolean
    +
    gboolean
     ostree_repo_prune_static_deltas (OstreeRepo *self,
                                      const char *commit,
    -                                 GCancellable *cancellable,
    -                                 GError **error);
    + GCancellable *cancellable, + GError **error);

    Prune static deltas, if COMMIT is specified then delete static delta files only targeting that commit; otherwise any static delta of non existing commits are deleted.

    @@ -8569,7 +8569,7 @@ deleted.

    - @@ -8590,12 +8590,12 @@ non existing commit.


    ostree_repo_traverse_reachable_refs ()

    -
    gboolean
    +
    gboolean
     ostree_repo_traverse_reachable_refs (OstreeRepo *self,
    -                                     guint depth,
    -                                     GHashTable *reachable,
    -                                     GCancellable *cancellable,
    -                                     GError **error);
    + guint depth, + GHashTable *reachable, + GCancellable *cancellable, + GError **error);

    Add all commit objects directly reachable via a ref to reachable .

    Locking: shared

    @@ -8641,14 +8641,14 @@ ostree_repo_traverse_reachable_refs (

    ostree_repo_prune_from_reachable ()

    -
    gboolean
    +
    gboolean
     ostree_repo_prune_from_reachable (OstreeRepo *self,
                                       OstreeRepoPruneOptions *options,
    -                                  gint *out_objects_total,
    -                                  gint *out_objects_pruned,
    -                                  guint64 *out_pruned_object_size_total,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + gint *out_objects_total, + gint *out_objects_pruned, + guint64 *out_pruned_object_size_total, + GCancellable *cancellable, + GError **error);

    Delete content from the repository. This function is the "backend" half of the higher level ostree_repo_prune(). To use this function, you determine the root set yourself, and this function finds all other @@ -8711,14 +8711,14 @@ statistics on objects that would be deleted, without actually deleting them.


    ostree_repo_pull ()

    -
    gboolean
    +
    gboolean
     ostree_repo_pull (OstreeRepo *self,
                       const char *remote_name,
                       char **refs_to_fetch,
                       OstreeRepoPullFlags flags,
                       OstreeAsyncProgress *progress,
    -                  GCancellable *cancellable,
    -                  GError **error);
    + GCancellable *cancellable, + GError **error);

    Connect to the remote repository, fetching the specified set of refs refs_to_fetch . For each ref that is changed, download the @@ -8728,7 +8728,7 @@ on disk in self

    If flags contains OSTREE_REPO_PULL_FLAGS_MIRROR, and the refs_to_fetch - is NULL, and the remote repository contains a + is NULL, and the remote repository contains a summary file, then all refs will be fetched.

    If flags contains OSTREE_REPO_PULL_FLAGS_COMMIT_ONLY, then only the @@ -8736,7 +8736,7 @@ metadata for the commits in refs_to_fetch

    Warning: This API will iterate the thread default main context, which is a bug, but kept for compatibility reasons. If you want to -avoid this, use g_main_context_push_thread_default() to push a new +avoid this, use g_main_context_push_thread_default() to push a new one around this call.

    Parameters

    @@ -8759,7 +8759,7 @@ one around this call.

    - + @@ -8789,15 +8789,15 @@ one around this call.


    ostree_repo_pull_one_dir ()

    -
    gboolean
    +
    gboolean
     ostree_repo_pull_one_dir (OstreeRepo *self,
                               const char *remote_name,
                               const char *dir_to_pull,
                               char **refs_to_fetch,
                               OstreeRepoPullFlags flags,
                               OstreeAsyncProgress *progress,
    -                          GCancellable *cancellable,
    -                          GError **error);
    + GCancellable *cancellable, + GError **error);

    This is similar to ostree_repo_pull(), but only fetches a single subpath.

    @@ -8826,7 +8826,7 @@ subpath.

    - + @@ -8856,13 +8856,13 @@ subpath.


    ostree_repo_pull_with_options ()

    -
    gboolean
    +
    gboolean
     ostree_repo_pull_with_options (OstreeRepo *self,
                                    const char *remote_name_or_baseurl,
    -                               GVariant *options,
    +                               GVariant *options,
                                    OstreeAsyncProgress *progress,
    -                               GCancellable *cancellable,
    -                               GError **error);
    + GCancellable *cancellable, + GError **error);

    Like ostree_repo_pull(), but supports an extensible set of flags. The following are currently defined:

      @@ -8885,7 +8885,7 @@ string to pull the latest commit for that ref

    • override-commit-ids (as): Array of specific commit IDs to fetch for refs

    • timestamp-check (b): Verify commit timestamps are newer than current (when pulling via ref); Since: 2017.11

    • timestamp-check-from-rev (s): Verify that all fetched commit timestamps are newer than timestamp of given rev; Since: 2020.4

    • -
    • metadata-size-restriction (t): Restrict metadata objects to a maximum number of bytes; 0 to disable. Since: 2018.9

    • +
    • max-metadata-size (t): Restrict metadata objects to a maximum number of bytes; 0 to disable. Since: 2018.9

    • dry-run (b): Only print information on what will be downloaded (requires static deltas)

    • override-url (s): Fetch objects from this URL if remote specifies no metalink in options

    • inherit-transaction (b): Don't initiate, finish or abort a transaction, useful to do multiple pulls in one transaction.

    • @@ -8954,7 +8954,7 @@ will be verified with the keyring of the remote being pulled from.

      void
       ostree_repo_pull_default_console_progress_changed
                                      (OstreeAsyncProgress *progress,
      -                                gpointer user_data);
      + gpointer user_data);

      Convenient "changed" callback for use with ostree_async_progress_new_and_connect() when pulling from a remote repository.

      @@ -8993,13 +8993,13 @@ and user_data

      ostree_repo_sign_commit ()

      -
      gboolean
      +
      gboolean
       ostree_repo_sign_commit (OstreeRepo *self,
      -                         const gchar *commit_checksum,
      -                         const gchar *key_id,
      -                         const gchar *homedir,
      -                         GCancellable *cancellable,
      -                         GError **error);
      + const gchar *commit_checksum, + const gchar *key_id, + const gchar *homedir, + GCancellable *cancellable, + GError **error);

      Add a GPG signature to a commit.

      Parameters

      @@ -9027,17 +9027,17 @@ ostree_repo_sign_commit (

      homedir

      -
    + - + - + @@ -9047,12 +9047,12 @@ ostree_repo_sign_commit (

    ostree_repo_append_gpg_signature ()

    -
    gboolean
    +
    gboolean
     ostree_repo_append_gpg_signature (OstreeRepo *self,
    -                                  const gchar *commit_checksum,
    -                                  GBytes *signature_bytes,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + const gchar *commit_checksum, + GBytes *signature_bytes, + GCancellable *cancellable, + GError **error);

    Append a GPG signature to a commit.

    Parameters

    @@ -9080,12 +9080,12 @@ ostree_repo_append_gpg_signature (
    - + - + @@ -9095,12 +9095,12 @@ ostree_repo_append_gpg_signature (

    ostree_repo_add_gpg_signature_summary ()

    -
    gboolean
    +
    gboolean
     ostree_repo_add_gpg_signature_summary (OstreeRepo *self,
    -                                       const gchar **key_id,
    -                                       const gchar *homedir,
    -                                       GCancellable *cancellable,
    -                                       GError **error);
    + const gchar **key_id, + const gchar *homedir, + GCancellable *cancellable, + GError **error);

    Add a GPG signature to a summary file.

    Parameters

    @@ -9123,17 +9123,17 @@ ostree_repo_add_gpg_signature_summary (

    homedir

    -
    + - + - + @@ -9143,15 +9143,15 @@ ostree_repo_add_gpg_signature_summary (

    ostree_repo_gpg_sign_data ()

    -
    gboolean
    +
    gboolean
     ostree_repo_gpg_sign_data (OstreeRepo *self,
    -                           GBytes *data,
    -                           GBytes *old_signatures,
    -                           const gchar **key_id,
    -                           const gchar *homedir,
    -                           GBytes **out_signatures,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GBytes *data, + GBytes *old_signatures, + const gchar **key_id, + const gchar *homedir, + GBytes **out_signatures, + GCancellable *cancellable, + GError **error);

    Sign the given data with the specified keys in key_id . Similar to @@ -9174,12 +9174,12 @@ data.

    - + - + @@ -9189,7 +9189,7 @@ data.

    - + @@ -9199,12 +9199,12 @@ data.

    - + - + @@ -9226,20 +9226,20 @@ will contain the reason).

    ostree_repo_gpg_verify_data ()

    OstreeGpgVerifyResult *
     ostree_repo_gpg_verify_data (OstreeRepo *self,
    -                             const gchar *remote_name,
    -                             GBytes *data,
    -                             GBytes *signatures,
    -                             GFile *keyringdir,
    -                             GFile *extra_keyring,
    -                             GCancellable *cancellable,
    -                             GError **error);
    + const gchar *remote_name, + GBytes *data, + GBytes *signatures, + GFile *keyringdir, + GFile *extra_keyring, + GCancellable *cancellable, + GError **error);

    Verify signatures for data using GPG keys in the keyring for remote_name , and return an OstreeGpgVerifyResult.

    The remote_name - parameter can be NULL. In that case it will do + parameter can be NULL. In that case it will do the verifications using GPG keys in the keyrings of all remotes.

    Parameters

    @@ -9262,12 +9262,12 @@ the verifications using GPG keys in the keyrings of all remotes.

    - + - + @@ -9295,7 +9295,7 @@ the verifications using GPG keys in the keyrings of all remotes.

    Returns

    -

    an OstreeGpgVerifyResult, or NULL on error.

    +

    an OstreeGpgVerifyResult, or NULL on error.

    [transfer full]

    Since: 2016.6

    @@ -9303,15 +9303,15 @@ the verifications using GPG keys in the keyrings of all remotes.


    ostree_repo_signature_verify_commit_data ()

    -
    gboolean
    +
    gboolean
     ostree_repo_signature_verify_commit_data
                                    (OstreeRepo *self,
                                     const char *remote_name,
    -                                GBytes *commit_data,
    -                                GBytes *commit_metadata,
    +                                GBytes *commit_data,
    +                                GBytes *commit_metadata,
                                     OstreeRepoVerifyFlags flags,
                                     char **out_results,
    -                                GError **error);
    + GError **error);

    Validate the commit data using the commit metadata which must contain at least one valid signature. If GPG and signapi are both enabled, then both must find at least one valid signature.

    @@ -9366,13 +9366,13 @@ both enabled, then both must find at least one valid signature.


    ostree_repo_verify_commit ()

    -
    gboolean
    +
    gboolean
     ostree_repo_verify_commit (OstreeRepo *self,
    -                           const gchar *commit_checksum,
    -                           GFile *keyringdir,
    -                           GFile *extra_keyring,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + const gchar *commit_checksum, + GFile *keyringdir, + GFile *extra_keyring, + GCancellable *cancellable, + GError **error);

    Check for a valid GPG signature on commit named by the ASCII checksum commit_checksum .

    @@ -9420,7 +9420,7 @@ checksum commit_checksum

    Returns

    -

    TRUE if there was a GPG signature from a trusted keyring, otherwise FALSE

    +

    TRUE if there was a GPG signature from a trusted keyring, otherwise FALSE


    @@ -9428,11 +9428,11 @@ checksum commit_checksum

    ostree_repo_verify_commit_ext ()

    OstreeGpgVerifyResult *
     ostree_repo_verify_commit_ext (OstreeRepo *self,
    -                               const gchar *commit_checksum,
    -                               GFile *keyringdir,
    -                               GFile *extra_keyring,
    -                               GCancellable *cancellable,
    -                               GError **error);
    + const gchar *commit_checksum, + GFile *keyringdir, + GFile *extra_keyring, + GCancellable *cancellable, + GError **error);

    Read GPG signature(s) on the commit named by the ASCII checksum commit_checksum and return detailed results.

    @@ -9480,7 +9480,7 @@ ostree_repo_verify_commit_ext (

    Returns

    -

    an OstreeGpgVerifyResult, or NULL on error.

    +

    an OstreeGpgVerifyResult, or NULL on error.

    [transfer full]

    @@ -9489,10 +9489,10 @@ ostree_repo_verify_commit_ext (

    ostree_repo_verify_commit_for_remote ()

    OstreeGpgVerifyResult *
     ostree_repo_verify_commit_for_remote (OstreeRepo *self,
    -                                      const gchar *commit_checksum,
    -                                      const gchar *remote_name,
    -                                      GCancellable *cancellable,
    -                                      GError **error);
    + const gchar *commit_checksum, + const gchar *remote_name, + GCancellable *cancellable, + GError **error);

    Read GPG signature(s) on the commit named by the ASCII checksum commit_checksum and return detailed results, based on the keyring @@ -9537,7 +9537,7 @@ configured for remote

    Returns

    -

    an OstreeGpgVerifyResult, or NULL on error.

    +

    an OstreeGpgVerifyResult, or NULL on error.

    [transfer full]

    Since: 2016.14

    @@ -9548,10 +9548,10 @@ configured for remote
    OstreeGpgVerifyResult *
     ostree_repo_verify_summary (OstreeRepo *self,
                                 const char *remote_name,
    -                            GBytes *summary,
    -                            GBytes *signatures,
    -                            GCancellable *cancellable,
    -                            GError **error);
    + GBytes *summary, + GBytes *signatures, + GCancellable *cancellable, + GError **error);

    Verify signatures for summary data using GPG keys in the keyring for @@ -9578,12 +9578,12 @@ ostree_repo_verify_summary (

    summary

    -
    + - + @@ -9601,18 +9601,18 @@ ostree_repo_verify_summary (

    Returns

    -

    an OstreeGpgVerifyResult, or NULL on error.

    +

    an OstreeGpgVerifyResult, or NULL on error.

    [transfer full]


    ostree_repo_regenerate_summary ()

    -
    gboolean
    +
    gboolean
     ostree_repo_regenerate_summary (OstreeRepo *self,
    -                                GVariant *additional_metadata,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GVariant *additional_metadata, + GCancellable *cancellable, + GError **error);

    An OSTree repository can contain a high level "summary" file that describes the available branches and other metadata.

    If the timetable for making commits and updating the summary file is fairly @@ -9644,7 +9644,7 @@ lexicographic order.

    - + @@ -9850,57 +9850,57 @@ interesting for reporting purposes.

    - + - + - + - + - + - + - + - + - + - + @@ -10145,8 +10145,9 @@ and OSTREE_REPO_COMMIT_MODIFIER_FLAGS_SKIP_XATTRS

    OSTREE_REPO_LIST_OBJECTS_VARIANT_TYPE

    #define OSTREE_REPO_LIST_OBJECTS_VARIANT_TYPE (G_VARIANT_TYPE ("(bas)")
     
    -

    b - TRUE if object is available "loose" +

    b - TRUE if object is available "loose" as - List of pack file checksums in which this object appears


    diff --git a/apidoc/html/ostree-Progress-notification-system-for-asynchronous-operations.html b/apidoc/html/ostree-Progress-notification-system-for-asynchronous-operations.html index 6dce7209..9681f100 100644 --- a/apidoc/html/ostree-Progress-notification-system-for-asynchronous-operations.html +++ b/apidoc/html/ostree-Progress-notification-system-for-asynchronous-operations.html @@ -81,7 +81,7 @@

    opt_to_commit

    ASCII SHA256 checksum of target commit, or NULL to index all targets

    ASCII SHA256 checksum of target commit, or NULL to index all targets

     

    from

    ASCII SHA256 checksum of origin, or NULL.

    ASCII SHA256 checksum of origin, or NULL.

    [nullable]

    skip_validation

    If TRUE, assume data integrity

    If TRUE, assume data integrity

     

    skip_validation

    If TRUE, assume data integrity

    If TRUE, assume data integrity

     

    commit

    ASCII SHA256 checksum for commit, or NULL for each +

    ASCII SHA256 checksum for commit, or NULL for each non existing commit.

    [allow-none]

    refs_to_fetch

    Optional list of refs; if NULL, fetch all configured refs.

    Optional list of refs; if NULL, fetch all configured refs.

    [array zero-terminated=1][element-type utf8][allow-none]

    refs_to_fetch

    Optional list of refs; if NULL, fetch all configured refs.

    Optional list of refs; if NULL, fetch all configured refs.

    [array zero-terminated=1][element-type utf8][allow-none]

    GPG home directory, or NULL.

    GPG home directory, or NULL.

    [allow-none]

    cancellable

    A GCancellable

    A GCancellable

     

    error

    a GError

    a GError

     

    cancellable

    A GCancellable

    A GCancellable

     

    error

    a GError

    a GError

     

    GPG home directory, or NULL.

    GPG home directory, or NULL.

    [allow-none]

    cancellable

    A GCancellable

    A GCancellable

     

    error

    a GError

    a GError

     

    data

    Data as a GBytes

    Data as a GBytes

     

    old_signatures

    Existing signatures to append to (or NULL)

    Existing signatures to append to (or NULL)

     

    homedir

    GPG home directory, or NULL.

    GPG home directory, or NULL.

    [allow-none]

    cancellable

    A GCancellable

    A GCancellable

     

    error

    a GError

    a GError

     

    data

    Data as a GBytes

    Data as a GBytes

     

    signatures

    Signatures as a GBytes

    Signatures as a GBytes

     

    Summary data as a GBytes

    Summary data as a GBytes

     

    signatures

    Summary signatures as a GBytes

    Summary signatures as a GBytes

     

    additional_metadata

    A GVariant of type a{sv}, or NULL.

    A GVariant of type a{sv}, or NULL.

    [allow-none]

    guint metadata_objects_total;

    guint metadata_objects_total;

    The total number of metadata objects in the repository after this transaction has completed.

     

    guint metadata_objects_written;

    guint metadata_objects_written;

    The number of metadata objects that were written to the repository in this transaction.

     

    guint content_objects_total;

    guint content_objects_total;

    The total number of content objects in the repository after this transaction has completed.

     

    guint content_objects_written;

    guint content_objects_written;

    The number of content objects that were written to the repository in this transaction.

     

    guint64 content_bytes_written;

    guint64 content_bytes_written;

    The amount of data added to the repository, in bytes, counting only content objects.

     

    guint devino_cache_hits;

    guint devino_cache_hits;

       

    guint padding1;

    guint padding1;

    reserved

     

    guint64 padding2;

    guint64 padding2;

    reserved

     

    guint64 padding3;

    guint64 padding3;

    reserved

     

    guint64 padding4;

    guint64 padding4;

    reserved

     
    -GVariant * +GVariant * ostree_async_progress_get_variant () @@ -89,7 +89,7 @@
    -guint +guint ostree_async_progress_get_uint () @@ -97,7 +97,7 @@
    -guint64 +guint64 ostree_async_progress_get_uint64 () @@ -179,7 +179,7 @@ handles thread safety, ensuring that the progress change notification occurs in the thread-default context of the calling operation.

    The ostree_async_progress_get_status() and ostree_async_progress_set_status() -methods get and set a well-known status key of type G_VARIANT_TYPE_STRING. +methods get and set a well-known status key of type G_VARIANT_TYPE_STRING. This key may be accessed using the other OstreeAsyncProgress methods, but it must always have the correct type.

    @@ -200,7 +200,7 @@ ostree_async_progress_new (void

    ostree_async_progress_new_and_connect ()

    OstreeAsyncProgress *
     ostree_async_progress_new_and_connect (void (*changed) (OstreeAsyncProgress *self, gpointer user_data),
    -                                       gpointer user_data);
    + gpointer user_data);
    @@ -212,7 +212,7 @@ ostree_async_progress_copy_state (dest , without invoking the callback. -This is used for proxying progress objects across different GMainContexts.

    +This is used for proxying progress objects across different
    GMainContexts.

    Parameters

    @@ -243,7 +243,7 @@ This is used for proxying progress objects across different G
    char *
     ostree_async_progress_get_status (OstreeAsyncProgress *self);

    Get the human-readable status string from the OstreeAsyncProgress. This -operation is thread-safe. The retuned value may be NULL if no status is +operation is thread-safe. The retuned value may be NULL if no status is set.

    This is a convenience function to get the well-known status key.

    @@ -263,7 +263,7 @@ set.

    Returns

    -

    the current status, or NULL if none is set.

    +

    the current status, or NULL if none is set.

    [transfer full][nullable]

    Since: 2017.6

    @@ -276,9 +276,9 @@ ostree_async_progress_get (...);

    Get the values corresponding to zero or more keys from the OstreeAsyncProgress. Each key is specified in @... as the key name, followed -by a GVariant format string, followed by the necessary arguments for that -format string, just as for g_variant_get(). After those arguments is the -next key name. The varargs list must be NULL-terminated.

    +by a GVariant format string, followed by the necessary arguments for that +format string, just as for g_variant_get(). After those arguments is the +next key name. The varargs list must be NULL-terminated.

    Each format string must make deep copies of its value, as the values stored in the OstreeAsyncProgress may be freed from another thread after this function returns.

    @@ -331,7 +331,7 @@ function returns.

    - + @@ -342,10 +342,10 @@ function returns.


    ostree_async_progress_get_variant ()

    -
    GVariant *
    +
    GVariant *
     ostree_async_progress_get_variant (OstreeAsyncProgress *self,
                                        const char *key);
    -

    Look up a key in the OstreeAsyncProgress and return the GVariant associated +

    Look up a key in the OstreeAsyncProgress and return the GVariant associated with it. The lookup is thread-safe.

    Parameters

    @@ -372,7 +372,7 @@ with it. The lookup is thread-safe.

    Returns

    value for the given key -, or NULL if +, or NULL if it was not set.

    [transfer full][nullable]

    @@ -381,14 +381,14 @@ it was not set.


    ostree_async_progress_get_uint ()

    -
    guint
    +
    guint
     ostree_async_progress_get_uint (OstreeAsyncProgress *self,
                                     const char *key);

    ostree_async_progress_get_uint64 ()

    -
    guint64
    +
    guint64
     ostree_async_progress_get_uint64 (OstreeAsyncProgress *self,
                                       const char *key);
    @@ -399,7 +399,7 @@ ostree_async_progress_get_uint64 (OstreeAsyncProgress *self, const char *status);

    Set the human-readable status string for the OstreeAsyncProgress. This -operation is thread-safe. NULL may be passed to clear the status.

    +operation is thread-safe. NULL may be passed to clear the status.

    This is a convenience function to set the well-known status key.

    Parameters

    @@ -417,7 +417,7 @@ operation is thread-safe. NULL may be passed to cle
    - + @@ -432,11 +432,11 @@ operation is thread-safe. NULL may be passed to cle ostree_async_progress_set (OstreeAsyncProgress *self, ...);

    Set the values for zero or more keys in the OstreeAsyncProgress. Each key is -specified in @... as the key name, followed by a GVariant format string, +specified in @... as the key name, followed by a GVariant format string, followed by the necessary arguments for that format string, just as for -g_variant_new(). After those arguments is the next key name. The varargs list -must be NULL-terminated.

    -

    g_variant_ref_sink() will be called as appropriate on the GVariant +g_variant_new(). After those arguments is the next key name. The varargs list +must be NULL-terminated.

    +

    g_variant_ref_sink() will be called as appropriate on the GVariant parameters, so they may be floating.

    This operation is thread-safe, and all the keys are set atomically.

    @@ -483,7 +483,7 @@ parameters, so they may be floating.

    - + @@ -497,13 +497,13 @@ parameters, so they may be floating.

    void
     ostree_async_progress_set_variant (OstreeAsyncProgress *self,
                                        const char *key,
    -                                   GVariant *value);
    + GVariant *value);

    Assign a new value to the given key , replacing any existing value. The operation is thread-safe. value may be a floating reference; -g_variant_ref_sink() will be called on it.

    +g_variant_ref_sink() will be called on it.

    Any watchers of the OstreeAsyncProgress will be notified of the change if value differs from the existing value for key @@ -544,7 +544,7 @@ operation is thread-safe. value

    void
     ostree_async_progress_set_uint (OstreeAsyncProgress *self,
                                     const char *key,
    -                                guint value);
    + guint value);
    @@ -552,7 +552,7 @@ ostree_async_progress_set_uint (void ostree_async_progress_set_uint64 (OstreeAsyncProgress *self, const char *key, - guint64 value); + guint64 value);

    diff --git a/apidoc/html/ostree-Root-partition-mount-point.html b/apidoc/html/ostree-Root-partition-mount-point.html index 360f8f6e..d5383f05 100644 --- a/apidoc/html/ostree-Root-partition-mount-point.html +++ b/apidoc/html/ostree-Root-partition-mount-point.html @@ -57,7 +57,7 @@
    - @@ -503,9 +503,9 @@ ostree_sysroot_new_default (void<

    ostree_sysroot_initialize ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_initialize (OstreeSysroot *self,
    -                           GError **error);
    + GError **error);

    Subset of ostree_sysroot_load(); performs basic initialization. Notably, one can invoke ostree_sysroot_get_fd() after calling this function.

    It is not necessary to call this function if ostree_sysroot_load() is @@ -530,7 +530,7 @@ invoked.


    ostree_sysroot_get_path ()

    -
    GFile *
    +
    GFile *
     ostree_sysroot_get_path (OstreeSysroot *self);

    Parameters

    @@ -556,10 +556,10 @@ ostree_sysroot_get_path (

    ostree_sysroot_load ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_load (OstreeSysroot *self,
    -                     GCancellable *cancellable,
    -                     GError **error);
    + GCancellable *cancellable, + GError **error);

    Load deployment list, bootversion, and subbootversion from the rootfs self .

    @@ -594,11 +594,11 @@ rootfs self

    ostree_sysroot_load_if_changed ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_load_if_changed (OstreeSysroot *self,
    -                                gboolean *out_changed,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + gboolean *out_changed, + GCancellable *cancellable, + GError **error);

    Parameters

    ...

    key name, format string, GVariant return locations, …, followed by NULL

    key name, format string, GVariant return locations, …, followed by NULL

     

    status

    new status string, or NULL to clear the status.

    new status string, or NULL to clear the status.

    [nullable]

    ...

    key name, format string, GVariant parameters, …, followed by NULL

    key name, format string, GVariant parameters, …, followed by NULL

     
    -gboolean +gboolean ostree_sysroot_initialize () @@ -65,7 +65,7 @@
    -GFile * +GFile * ostree_sysroot_get_path () @@ -73,7 +73,7 @@
    -gboolean +gboolean ostree_sysroot_load () @@ -81,7 +81,7 @@
    -gboolean +gboolean ostree_sysroot_load_if_changed () @@ -89,7 +89,7 @@
    -gboolean +gboolean ostree_sysroot_lock () @@ -97,7 +97,7 @@
    -gboolean +gboolean ostree_sysroot_try_lock () @@ -113,7 +113,7 @@
    -gboolean +gboolean ostree_sysroot_lock_finish () @@ -145,7 +145,7 @@
    -gboolean +gboolean ostree_sysroot_is_booted () @@ -161,7 +161,7 @@
    -gboolean +gboolean ostree_sysroot_ensure_initialized () @@ -185,7 +185,7 @@
    -GPtrArray * +GPtrArray * ostree_sysroot_get_deployments () @@ -209,7 +209,7 @@
    -GFile * +GFile * ostree_sysroot_get_deployment_directory () @@ -225,7 +225,7 @@
    -GFile * +GFile * ostree_sysroot_get_deployment_origin_path () @@ -233,7 +233,7 @@
    -gboolean +gboolean ostree_sysroot_cleanup () @@ -241,7 +241,7 @@
    -gboolean +gboolean ostree_sysroot_prepare_cleanup () @@ -249,7 +249,7 @@
    -gboolean +gboolean ostree_sysroot_cleanup_prune_repo () @@ -265,7 +265,7 @@
    -gboolean +gboolean ostree_sysroot_get_repo () @@ -281,7 +281,7 @@
    -gboolean +gboolean ostree_sysroot_init_osname () @@ -289,7 +289,7 @@
    -gboolean +gboolean ostree_sysroot_deployment_set_kargs () @@ -297,7 +297,7 @@
    -gboolean +gboolean ostree_sysroot_deployment_set_kargs_in_place () @@ -305,7 +305,7 @@
    -gboolean +gboolean ostree_sysroot_deployment_set_mutable () @@ -313,7 +313,7 @@
    -gboolean +gboolean ostree_sysroot_deployment_unlock () @@ -321,7 +321,7 @@
    -gboolean +gboolean ostree_sysroot_deployment_set_pinned () @@ -329,7 +329,7 @@
    -gboolean +gboolean ostree_sysroot_write_deployments () @@ -337,7 +337,7 @@
    -gboolean +gboolean ostree_sysroot_write_deployments_with_options () @@ -345,7 +345,7 @@
    -gboolean +gboolean ostree_sysroot_write_origin_file () @@ -353,7 +353,7 @@
    -gboolean +gboolean ostree_sysroot_stage_tree () @@ -361,7 +361,7 @@
    -gboolean +gboolean ostree_sysroot_stage_tree_with_options () @@ -369,7 +369,7 @@
    -gboolean +gboolean ostree_sysroot_stage_overlay_initrd () @@ -377,7 +377,7 @@
    -gboolean +gboolean ostree_sysroot_deploy_tree () @@ -385,7 +385,7 @@
    -gboolean +gboolean ostree_sysroot_deploy_tree_with_options () @@ -409,7 +409,7 @@
    -GKeyFile * +GKeyFile * ostree_sysroot_origin_new_from_refspec () @@ -417,7 +417,7 @@
    -gboolean +gboolean ostree_sysroot_simple_write_deployment () @@ -460,10 +460,10 @@ perform locking externally.

    ostree_sysroot_new ()

    OstreeSysroot *
    -ostree_sysroot_new (GFile *path);
    +ostree_sysroot_new (GFile *path);

    Create a new OstreeSysroot object for the sysroot at path . If path - is NULL, + is NULL, the current visible root file system is used, equivalent to ostree_sysroot_new_default().

    @@ -476,7 +476,7 @@ the current visible root file system is used, equivalent to

    path

    Path to a system root directory, or NULL to use the +

    Path to a system root directory, or NULL to use the current visible root file system.

    [allow-none]
    @@ -636,9 +636,9 @@ ostree_sysroot_load_if_changed (

    ostree_sysroot_lock ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_lock (OstreeSysroot *self,
    -                     GError **error);
    + GError **error);

    Acquire an exclusive multi-process write lock for self . This call blocks until the lock has been acquired. The lock is not @@ -672,15 +672,15 @@ be released if self


    ostree_sysroot_try_lock ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_try_lock (OstreeSysroot *self,
    -                         gboolean *out_acquired,
    -                         GError **error);
    + gboolean *out_acquired, + GError **error);

    Try to acquire an exclusive multi-process write lock for self . If another process holds the lock, this function will return immediately, setting out_acquired - to FALSE, and returning TRUE + to FALSE, and returning TRUE (and no error).

    Release the lock with ostree_sysroot_unlock(). The lock will also be released if self @@ -718,9 +718,9 @@ be released if self

    ostree_sysroot_lock_async ()

    void
     ostree_sysroot_lock_async (OstreeSysroot *self,
    -                           GCancellable *cancellable,
    -                           GAsyncReadyCallback callback,
    -                           gpointer user_data);
    + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data);

    An asynchronous version of ostree_sysroot_lock().

    Parameters

    @@ -758,10 +758,10 @@ ostree_sysroot_lock_async (

    ostree_sysroot_lock_finish ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_lock_finish (OstreeSysroot *self,
    -                            GAsyncResult *result,
    -                            GError **error);
    + GAsyncResult *result, + GError **error);

    Call when ostree_sysroot_lock_async() is ready.

    Parameters

    @@ -862,7 +862,7 @@ be invoked before or after

    ostree_sysroot_is_booted ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_is_booted (OstreeSysroot *self);

    Can only be invoked after ostree_sysroot_initialize().

    @@ -882,7 +882,7 @@ ostree_sysroot_is_booted (

    Returns

    -

    TRUE iff the sysroot points to a booted deployment

    +

    TRUE iff the sysroot points to a booted deployment

    Since: 2020.1

    @@ -918,10 +918,10 @@ prior to calling this function.


    ostree_sysroot_ensure_initialized ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_ensure_initialized (OstreeSysroot *self,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    + GCancellable *cancellable, + GError **error);

    Ensure that self is set up as a valid rootfs, by creating /ostree/repo, among other things.

    @@ -968,7 +968,7 @@ ostree_sysroot_get_subbootversion (

    ostree_sysroot_get_deployments ()

    -
    GPtrArray *
    +
    GPtrArray *
     ostree_sysroot_get_deployments (OstreeSysroot *self);

    Parameters

    @@ -1014,7 +1014,7 @@ ostree_sysroot_get_booted_deployment (

    Returns

    -

    The currently booted deployment, or NULL if none.

    +

    The currently booted deployment, or NULL if none.

    [transfer none][nullable]

    @@ -1024,7 +1024,7 @@ ostree_sysroot_get_booted_deployment (OstreeDeployment * ostree_sysroot_require_booted_deployment (OstreeSysroot *self, - GError **error); + GError **error);

    Find the booted deployment, or return an error if not booted via OSTree.

    Parameters

    @@ -1051,7 +1051,7 @@ ostree_sysroot_require_booted_deployment

    ostree_sysroot_get_deployment_directory ()

    -
    GFile *
    +
    GFile *
     ostree_sysroot_get_deployment_directory
                                    (OstreeSysroot *self,
                                     OstreeDeployment *deployment);
    @@ -1123,9 +1123,9 @@ or concatenate it with the full

    ostree_sysroot_get_deployment_origin_path ()

    -
    GFile *
    +
    GFile *
     ostree_sysroot_get_deployment_origin_path
    -                               (GFile *deployment_path);
    + (GFile *deployment_path);

    Parameters

    @@ -1150,10 +1150,10 @@ ostree_sysroot_get_deployment_origin_path

    ostree_sysroot_cleanup ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_cleanup (OstreeSysroot *self,
    -                        GCancellable *cancellable,
    -                        GError **error);
    + GCancellable *cancellable, + GError **error);

    Delete any state that resulted from a partially completed transaction, such as incomplete deployments.

    @@ -1187,10 +1187,10 @@ transaction, such as incomplete deployments.


    ostree_sysroot_prepare_cleanup ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_prepare_cleanup (OstreeSysroot *self,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Like ostree_sysroot_cleanup() in that it cleans up incomplete deployments and old boot versions, but does NOT prune the repository.

    @@ -1224,14 +1224,14 @@ and old boot versions, but does NOT prune the repository.


    ostree_sysroot_cleanup_prune_repo ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_cleanup_prune_repo (OstreeSysroot *sysroot,
                                        OstreeRepoPruneOptions *options,
    -                                   gint *out_objects_total,
    -                                   gint *out_objects_pruned,
    -                                   guint64 *out_pruned_object_size_total,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    + gint *out_objects_total, + gint *out_objects_pruned, + guint64 *out_pruned_object_size_total, + GCancellable *cancellable, + GError **error);

    Prune the system repository. This is a thin wrapper around ostree_repo_prune_from_reachable(); the primary addition is that this function automatically gathers @@ -1323,11 +1323,11 @@ or

    ostree_sysroot_get_repo ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_get_repo (OstreeSysroot *self,
                              OstreeRepo **out_repo,
    -                         GCancellable *cancellable,
    -                         GError **error);
    + GCancellable *cancellable, + GError **error);

    Retrieve the OSTree repository in sysroot self . The repo is guaranteed to be open (see ostree_repo_open()).

    @@ -1366,7 +1366,7 @@ ostree_sysroot_get_repo (

    Returns

    -

    TRUE on success, FALSE otherwise

    +

    TRUE on success, FALSE otherwise


    @@ -1391,7 +1391,7 @@ ostree_sysroot_get_staged_deployment (

    Returns

    -

    The currently staged deployment, or NULL if none.

    +

    The currently staged deployment, or NULL if none.

    [transfer none][nullable]

    Since: 2018.5

    @@ -1399,11 +1399,11 @@ ostree_sysroot_get_staged_deployment (

    ostree_sysroot_init_osname ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_init_osname (OstreeSysroot *self,
                                 const char *osname,
    -                            GCancellable *cancellable,
    -                            GError **error);
    + GCancellable *cancellable, + GError **error);

    Initialize the directory structure for an "osname", which is a group of operating system deployments, with a shared /var. One is required for generating a deployment.

    @@ -1444,12 +1444,12 @@ is required for generating a deployment.


    ostree_sysroot_deployment_set_kargs ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_deployment_set_kargs (OstreeSysroot *self,
                                          OstreeDeployment *deployment,
                                          char **new_kargs,
    -                                     GCancellable *cancellable,
    -                                     GError **error);
    + GCancellable *cancellable, + GError **error);

    Entirely replace the kernel arguments of deployment with the values in new_kargs @@ -1495,13 +1495,13 @@ values in new_kargs


    ostree_sysroot_deployment_set_kargs_in_place ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_deployment_set_kargs_in_place
                                    (OstreeSysroot *self,
                                     OstreeDeployment *deployment,
                                     char *kargs_str,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Replace the kernel arguments of deployment with the values in kargs_str .

    @@ -1528,7 +1528,7 @@ ostree_sysroot_deployment_set_kargs_in_place
    - + @@ -1547,12 +1547,12 @@ ostree_sysroot_deployment_set_kargs_in_place

    ostree_sysroot_deployment_set_mutable ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_deployment_set_mutable (OstreeSysroot *self,
                                            OstreeDeployment *deployment,
    -                                       gboolean is_mutable,
    -                                       GCancellable *cancellable,
    -                                       GError **error);
    + gboolean is_mutable, + GCancellable *cancellable, + GError **error);

    By default, deployment directories are not mutable. This function will allow making them temporarily mutable, for example to allow layering additional non-OSTree content.

    @@ -1597,12 +1597,12 @@ layering additional non-OSTree content.


    ostree_sysroot_deployment_unlock ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_deployment_unlock (OstreeSysroot *self,
                                       OstreeDeployment *deployment,
                                       OstreeDeploymentUnlockedState unlocked_state,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + GCancellable *cancellable, + GError **error);

    Configure the target deployment deployment such that it is writable. There are multiple modes, essentially differing @@ -1651,11 +1651,11 @@ across reboots.


    ostree_sysroot_deployment_set_pinned ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_deployment_set_pinned (OstreeSysroot *self,
                                           OstreeDeployment *deployment,
    -                                      gboolean is_pinned,
    -                                      GError **error);
    + gboolean is_pinned, + GError **error);

    By default, deployments may be subject to garbage collection. Typical uses of libostree only retain at most 2 deployments. If is_pinned is TRUE, a @@ -1702,11 +1702,11 @@ the staged deployment (as it's not in the bootloader entries).


    ostree_sysroot_write_deployments ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_write_deployments (OstreeSysroot *self,
    -                                  GPtrArray *new_deployments,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + GPtrArray *new_deployments, + GCancellable *cancellable, + GError **error);

    Older version of ostree_sysroot_write_deployments_with_options(). This version will perform post-deployment cleanup by default.

    @@ -1745,13 +1745,13 @@ version will perform post-deployment cleanup by default.


    ostree_sysroot_write_deployments_with_options ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_write_deployments_with_options
                                    (OstreeSysroot *self,
    -                                GPtrArray *new_deployments,
    +                                GPtrArray *new_deployments,
                                     OstreeSysrootWriteDeploymentsOpts *opts,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Assuming new_deployments have already been deployed in place on disk via ostree_sysroot_deploy_tree(), atomically update bootloader configuration. By @@ -1802,17 +1802,17 @@ if for example you want to control pruning of the repository.


    ostree_sysroot_write_origin_file ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_write_origin_file (OstreeSysroot *sysroot,
                                       OstreeDeployment *deployment,
    -                                  GKeyFile *new_origin,
    -                                  GCancellable *cancellable,
    -                                  GError **error);
    + GKeyFile *new_origin, + GCancellable *cancellable, + GError **error);

    Immediately replace the origin file of the referenced deployment with the contents of new_origin . If new_origin - is NULL, + is NULL, this function will write the current origin of deployment .

    @@ -1856,16 +1856,16 @@ this function will write the current origin of deplo

    ostree_sysroot_stage_tree ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_stage_tree (OstreeSysroot *self,
                                const char *osname,
                                const char *revision,
    -                           GKeyFile *origin,
    +                           GKeyFile *origin,
                                OstreeDeployment *merge_deployment,
                                char **override_kernel_argv,
                                OstreeDeployment **out_new_deployment,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    Older version of ostree_sysroot_stage_tree_with_options().

    Parameters

    @@ -1903,7 +1903,7 @@ ostree_sysroot_stage_tree (

    override_kernel_argv

    -
    + @@ -1929,17 +1929,17 @@ ostree_sysroot_stage_tree (

    ostree_sysroot_stage_tree_with_options ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_stage_tree_with_options
                                    (OstreeSysroot *self,
                                     const char *osname,
                                     const char *revision,
    -                                GKeyFile *origin,
    +                                GKeyFile *origin,
                                     OstreeDeployment *merge_deployment,
                                     OstreeSysrootDeployTreeOpts *opts,
                                     OstreeDeployment **out_new_deployment,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Like ostree_sysroot_deploy_tree(), but "finalization" only occurs at OS shutdown time.

    @@ -2004,12 +2004,12 @@ shutdown time.


    ostree_sysroot_stage_overlay_initrd ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_stage_overlay_initrd (OstreeSysroot *self,
                                          int fd,
                                          char **out_checksum,
    -                                     GCancellable *cancellable,
    -                                     GError **error);
    + GCancellable *cancellable, + GError **error);

    Stage an overlay initrd to be used in an upcoming deployment. Returns a checksum which can be passed to ostree_sysroot_deploy_tree_with_options() or ostree_sysroot_stage_tree_with_options() via the overlay_initrds array option.

    @@ -2055,16 +2055,16 @@ can be passed to

    ostree_sysroot_deploy_tree ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_deploy_tree (OstreeSysroot *self,
                                 const char *osname,
                                 const char *revision,
    -                            GKeyFile *origin,
    +                            GKeyFile *origin,
                                 OstreeDeployment *provided_merge_deployment,
                                 char **override_kernel_argv,
                                 OstreeDeployment **out_new_deployment,
    -                            GCancellable *cancellable,
    -                            GError **error);
    + GCancellable *cancellable, + GError **error);

    Older version of ostree_sysroot_stage_tree_with_options().

    Parameters

    @@ -2102,7 +2102,7 @@ ostree_sysroot_deploy_tree (

    override_kernel_argv

    -
    + @@ -2128,17 +2128,17 @@ ostree_sysroot_deploy_tree (

    ostree_sysroot_deploy_tree_with_options ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_deploy_tree_with_options
                                    (OstreeSysroot *self,
                                     const char *osname,
                                     const char *revision,
    -                                GKeyFile *origin,
    +                                GKeyFile *origin,
                                     OstreeDeployment *provided_merge_deployment,
                                     OstreeSysrootDeployTreeOpts *opts,
                                     OstreeDeployment **out_new_deployment,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Check out deployment tree with revision revision , performing a 3 way merge with provided_merge_deployment @@ -2249,7 +2249,7 @@ ostree_sysroot_query_deployments_for (OstreeDeployment **out_pending, OstreeDeployment **out_rollback);

    Find the pending and rollback deployments for osname -. Pass NULL for osname +. Pass NULL for osname to use the booted deployment's osname. By default, pending deployment is the first deployment in the order that matches osname @@ -2294,7 +2294,7 @@ we're not looking at the booted deployment.


    ostree_sysroot_origin_new_from_refspec ()

    -
    GKeyFile *
    +
    GKeyFile *
     ostree_sysroot_origin_new_from_refspec
                                    (OstreeSysroot *self,
                                     const char *refspec);
    @@ -2330,15 +2330,15 @@ as an origin.


    ostree_sysroot_simple_write_deployment ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_simple_write_deployment
                                    (OstreeSysroot *sysroot,
                                     const char *osname,
                                     OstreeDeployment *new_deployment,
                                     OstreeDeployment *merge_deployment,
                                     OstreeSysrootSimpleWriteDeploymentFlags flags,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Prepend new_deployment to the list of deployments, commit, and cleanup. By default, all other deployments for the given osname diff --git a/apidoc/html/ostree-SELinux-policy-management.html b/apidoc/html/ostree-SELinux-policy-management.html index d3cd48b4..7eda284e 100644 --- a/apidoc/html/ostree-SELinux-policy-management.html +++ b/apidoc/html/ostree-SELinux-policy-management.html @@ -65,7 +65,7 @@

    kargs_str

    Replace deployment 's kernel arguments.

    [allow none][allow-none]

    cancellable

    Use these as kernel arguments; if NULL, inherit options from provided_merge_deployment.

    Use these as kernel arguments; if NULL, inherit options from provided_merge_deployment.

    [allow-none][array zero-terminated=1][element-type utf8]

    Use these as kernel arguments; if NULL, inherit options from provided_merge_deployment.

    Use these as kernel arguments; if NULL, inherit options from provided_merge_deployment.

    [allow-none][array zero-terminated=1][element-type utf8]
    -GFile * +GFile * ostree_sepolicy_get_path () @@ -80,7 +80,7 @@
    -gboolean +gboolean ostree_sepolicy_get_label () @@ -95,7 +95,7 @@
    -gboolean +gboolean ostree_sepolicy_restorecon () @@ -103,7 +103,7 @@
    -gboolean +gboolean ostree_sepolicy_setfscreatecon () @@ -149,9 +149,9 @@ root and perform labeling.

    ostree_sepolicy_new ()

    OstreeSePolicy *
    -ostree_sepolicy_new (GFile *path,
    -                     GCancellable *cancellable,
    -                     GError **error);
    +ostree_sepolicy_new (GFile *path, + GCancellable *cancellable, + GError **error);

    Parameters

    @@ -191,8 +191,8 @@ ostree_sepolicy_new (GFile

    ostree_sepolicy_new_at ()

    OstreeSePolicy *
     ostree_sepolicy_new_at (int rootfs_dfd,
    -                        GCancellable *cancellable,
    -                        GError **error);
    + GCancellable *cancellable, + GError **error);

    Parameters

    @@ -234,8 +234,8 @@ ostree_sepolicy_new_at (intOstreeSePolicy * ostree_sepolicy_new_from_commit (OstreeRepo *repo, const char *rev, - GCancellable *cancellable, - GError **error); + GCancellable *cancellable, + GError **error);

    Extract the SELinux policy from a commit object via a partial checkout. This is useful for labeling derived content as separate commits.

    This function is the backend of ostree_repo_commit_modifier_set_sepolicy_from_commit().

    @@ -280,7 +280,7 @@ for labeling derived content as separate commits.


    ostree_sepolicy_get_path ()

    -
    GFile *
    +
    GFile *
     ostree_sepolicy_get_path (OstreeSePolicy *self);

    This API should be considered deprecated, because it's supported for policy objects to be created from file-descriptor relative paths, which @@ -320,18 +320,18 @@ ostree_sepolicy_get_name (

    ostree_sepolicy_get_label ()

    -
    gboolean
    +
    gboolean
     ostree_sepolicy_get_label (OstreeSePolicy *self,
                                const char *relpath,
    -                           guint32 unix_mode,
    +                           guint32 unix_mode,
                                char **out_label,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    Store in out_label the security context for the given relpath and mode unix_mode -. If the policy does not specify a label, NULL +. If the policy does not specify a label, NULL will be returned.

    Parameters

    @@ -391,15 +391,15 @@ ostree_sepolicy_get_csum (

    ostree_sepolicy_restorecon ()

    -
    gboolean
    +
    gboolean
     ostree_sepolicy_restorecon (OstreeSePolicy *self,
                                 const char *path,
    -                            GFileInfo *info,
    -                            GFile *target,
    +                            GFileInfo *info,
    +                            GFile *target,
                                 OstreeSePolicyRestoreconFlags flags,
                                 char **out_new_label,
    -                            GCancellable *cancellable,
    -                            GError **error);
    + GCancellable *cancellable, + GError **error);

    Reset the security context of target based on the SELinux policy.

    @@ -438,7 +438,7 @@ ostree_sepolicy_restorecon (

    out_new_label

    -
    + @@ -458,11 +458,11 @@ ostree_sepolicy_restorecon (

    ostree_sepolicy_setfscreatecon ()

    -
    gboolean
    +
    gboolean
     ostree_sepolicy_setfscreatecon (OstreeSePolicy *self,
                                     const char *path,
    -                                guint32 mode,
    -                                GError **error);
    + guint32 mode, + GError **error);

    Parameters

    New label, or NULL if unchanged.

    New label, or NULL if unchanged.

    [allow-none][out]
    diff --git a/apidoc/html/ostree-Signature-management.html b/apidoc/html/ostree-Signature-management.html index 39be5e72..d5038edb 100644 --- a/apidoc/html/ostree-Signature-management.html +++ b/apidoc/html/ostree-Signature-management.html @@ -41,7 +41,7 @@ - - - - + - + @@ -254,13 +254,13 @@ will contain the reason).


    ostree_sign_commit_verify ()

    -
    gboolean
    +
    gboolean
     ostree_sign_commit_verify (OstreeSign *self,
                                OstreeRepo *repo,
    -                           const gchar *commit_checksum,
    +                           const gchar *commit_checksum,
                                char **out_success_message,
    -                           GCancellable *cancellable,
    -                           GError **error);
    + GCancellable *cancellable, + GError **error);

    Verify if commit is signed with known key.

    Depending of the signing engine used you will need to load the public key(s) for verification with ostree_sign_set_pk, @@ -296,12 +296,12 @@ the public key(s) for verification with

    cancellable

    -
    + - + @@ -320,12 +320,12 @@ will contain the reason).


    ostree_sign_data ()

    -
    gboolean
    +
    gboolean
     ostree_sign_data (OstreeSign *self,
    -                  GBytes *data,
    -                  GBytes **signature,
    -                  GCancellable *cancellable,
    -                  GError **error);
    + GBytes *data, + GBytes **signature, + GCancellable *cancellable, + GError **error);

    Sign the given data with pre-loaded secret key.

    Depending of the signing engine used you will need to load @@ -356,12 +356,12 @@ the secret key with

    cancellable

    -
    + - + @@ -381,12 +381,12 @@ will contain the reason).


    ostree_sign_data_verify ()

    -
    gboolean
    +
    gboolean
     ostree_sign_data_verify (OstreeSign *self,
    -                         GBytes *data,
    -                         GVariant *signatures,
    +                         GBytes *data,
    +                         GVariant *signatures,
                              char **out_success_message,
    -                         GError **error);
    + GError **error);

    Verify given data against signatures with pre-loaded public keys.

    Depending of the signing engine used you will need to load the public key(s) with ostree_sign_set_pk, ostree_sign_add_pk @@ -422,7 +422,7 @@ or

    - + @@ -443,8 +443,8 @@ will contain the reason).

    ostree_sign_get_by_name ()

    OstreeSign *
    -ostree_sign_get_by_name (const gchar *name,
    -                         GError **error);
    +ostree_sign_get_by_name (const gchar *name, + GError **error);

    Create a new instance of a signing engine.

    Parameters

    @@ -462,7 +462,7 @@ ostree_sign_get_by_name (const gc
    - + @@ -470,7 +470,7 @@ ostree_sign_get_by_name (const gc

    Returns

    -

    New signing engine, or NULL if the engine is not known.

    +

    New signing engine, or NULL if the engine is not known.

    [transfer full]

    Since: 2020.2

    @@ -478,7 +478,7 @@ ostree_sign_get_by_name (const gc

    ostree_sign_get_name ()

    -
    const gchar *
    +
    const gchar *
     ostree_sign_get_name (OstreeSign *self);

    Return the pointer to the name of currently used/selected signing engine.

    @@ -508,10 +508,10 @@ in case of error (unlikely).


    ostree_sign_add_pk ()

    -
    gboolean
    +
    gboolean
     ostree_sign_add_pk (OstreeSign *self,
    -                    GVariant *public_key,
    -                    GError **error);
    + GVariant *public_key, + GError **error);

    Add the public key for verification. Could be called multiple times for adding all needed keys to be used for verification.

    The public_key @@ -537,7 +537,7 @@ adding all needed keys to be used for verification.

    - + @@ -556,9 +556,9 @@ will contain the reason).


    ostree_sign_clear_keys ()

    -
    gboolean
    +
    gboolean
     ostree_sign_clear_keys (OstreeSign *self,
    -                        GError **error);
    + GError **error);

    Clear all previously preloaded secret and public keys.

    Parameters

    @@ -576,7 +576,7 @@ ostree_sign_clear_keys (

    error

    -
    + @@ -593,10 +593,10 @@ in case of error


    ostree_sign_load_pk ()

    -
    gboolean
    +
    gboolean
     ostree_sign_load_pk (OstreeSign *self,
    -                     GVariant *options,
    -                     GError **error);
    + GVariant *options, + GError **error);

    Load public keys for verification from anywhere. It is expected that all keys would be added to already pre-loaded keys.

    The options @@ -633,7 +633,7 @@ directories if defaults are not suitable for any reason.

    - + @@ -652,7 +652,7 @@ will contain the reason).


    ostree_sign_metadata_format ()

    -
    const gchar *
    +
    const gchar *
     ostree_sign_metadata_format (OstreeSign *self);

    Return the pointer to the string with format used in (detached) metadata for current signing engine.

    @@ -683,7 +683,7 @@ in case of error (unlikely).


    ostree_sign_metadata_key ()

    -
    const gchar *
    +
    const gchar *
     ostree_sign_metadata_key (OstreeSign *self);

    Return the pointer to the name of the key used in (detached) metadata for current signing engine.

    @@ -714,10 +714,10 @@ in case of error (unlikely).


    ostree_sign_set_pk ()

    -
    gboolean
    +
    gboolean
     ostree_sign_set_pk (OstreeSign *self,
    -                    GVariant *public_key,
    -                    GError **error);
    + GVariant *public_key, + GError **error);

    Set the public key for verification. It is expected what all previously pre-loaded public keys will be dropped.

    The public_key @@ -743,7 +743,7 @@ previously pre-loaded public keys will be dropped.

    - + @@ -762,10 +762,10 @@ will contain the reason).


    ostree_sign_set_sk ()

    -
    gboolean
    +
    gboolean
     ostree_sign_set_sk (OstreeSign *self,
    -                    GVariant *secret_key,
    -                    GError **error);
    + GVariant *secret_key, + GError **error);

    Set the secret key to be used for signing data, commits and summary.

    The secret_key argument depends of the particular engine implementation.

    @@ -790,7 +790,7 @@ ostree_sign_set_sk (

    error

    -
    + @@ -809,12 +809,12 @@ will contain the reason).


    ostree_sign_summary ()

    -
    gboolean
    +
    gboolean
     ostree_sign_summary (OstreeSign *self,
                          OstreeRepo *repo,
    -                     GVariant *keys,
    -                     GCancellable *cancellable,
    -                     GError **error);
    + GVariant *keys, + GCancellable *cancellable, + GError **error);

    Add a signature to a summary file. Based on ostree_repo_add_gpg_signature_summary implementation.

    @@ -843,12 +843,12 @@ Based on ostree_repo_add_gpg_signature_summary implementation.

    - + - + diff --git a/apidoc/html/ostree-Simple-upgrade-class.html b/apidoc/html/ostree-Simple-upgrade-class.html index da3eee99..15cf4c20 100644 --- a/apidoc/html/ostree-Simple-upgrade-class.html +++ b/apidoc/html/ostree-Simple-upgrade-class.html @@ -65,7 +65,7 @@
    -GPtrArray * +GPtrArray * ostree_sign_get_all () @@ -49,7 +49,7 @@
    -gboolean +gboolean ostree_sign_commit () @@ -57,7 +57,7 @@
    -gboolean +gboolean ostree_sign_commit_verify () @@ -65,7 +65,7 @@
    -gboolean +gboolean ostree_sign_data () @@ -73,7 +73,7 @@
    -gboolean +gboolean ostree_sign_data_verify () @@ -88,7 +88,7 @@
    const gchar * +const gchar * ostree_sign_get_name () @@ -96,7 +96,7 @@
    -gboolean +gboolean ostree_sign_add_pk () @@ -104,7 +104,7 @@
    -gboolean +gboolean ostree_sign_clear_keys () @@ -112,21 +112,21 @@
    -gboolean +gboolean ostree_sign_load_pk ()
    const gchar * +const gchar * ostree_sign_metadata_format ()
    const gchar * +const gchar * ostree_sign_metadata_key () @@ -134,7 +134,7 @@
    -gboolean +gboolean ostree_sign_set_pk () @@ -142,7 +142,7 @@
    -gboolean +gboolean ostree_sign_set_sk () @@ -150,7 +150,7 @@
    -gboolean +gboolean ostree_sign_summary () @@ -181,7 +181,7 @@ for signing or verifying the commit object or summary file.

    Functions

    ostree_sign_get_all ()

    -
    GPtrArray *
    +
    GPtrArray *
     ostree_sign_get_all (void);

    Return an array with newly allocated instances of all available signing engines; they will not be initialized.

    @@ -195,12 +195,12 @@ signing engines; they will not be initialized.


    ostree_sign_commit ()

    -
    gboolean
    +
    gboolean
     ostree_sign_commit (OstreeSign *self,
                         OstreeRepo *repo,
    -                    const gchar *commit_checksum,
    -                    GCancellable *cancellable,
    -                    GError **error);
    + const gchar *commit_checksum, + GCancellable *cancellable, + GError **error);

    Add a signature to a commit.

    Depending of the signing engine used you will need to load the secret key with ostree_sign_set_sk.

    @@ -230,12 +230,12 @@ the secret key with

    cancellable

    A GCancellable

    A GCancellable

     

    error

    a GError

    a GError

     

    A GCancellable

    A GCancellable

     

    error

    a GError

    a GError

     

    A GCancellable

    A GCancellable

     

    error

    a GError

    a GError

     

    error

    a GError

    a GError

     

    error

    return location for a GError

    return location for a GError

     

    error

    a GError

    a GError

     

    a GError

    a GError

     

    error

    a GError

    a GError

     

    error

    a GError

    a GError

     

    a GError

    a GError

     

    cancellable

    A GCancellable

    A GCancellable

     

    error

    a GError

    a GError

     
    -GKeyFile * +GKeyFile * ostree_sysroot_upgrader_get_origin () @@ -73,7 +73,7 @@
    -GKeyFile * +GKeyFile * ostree_sysroot_upgrader_dup_origin () @@ -81,7 +81,7 @@
    -gboolean +gboolean ostree_sysroot_upgrader_set_origin () @@ -97,7 +97,7 @@
    -gboolean +gboolean ostree_sysroot_upgrader_check_timestamps () @@ -105,7 +105,7 @@
    -gboolean +gboolean ostree_sysroot_upgrader_pull () @@ -113,7 +113,7 @@
    -gboolean +gboolean ostree_sysroot_upgrader_pull_one_dir () @@ -121,7 +121,7 @@
    -gboolean +gboolean ostree_sysroot_upgrader_deploy () @@ -164,8 +164,8 @@ operations.

    ostree_sysroot_upgrader_new ()

    OstreeSysrootUpgrader *
     ostree_sysroot_upgrader_new (OstreeSysroot *sysroot,
    -                             GCancellable *cancellable,
    -                             GError **error);
    + GCancellable *cancellable, + GError **error);

    Parameters

    @@ -205,8 +205,8 @@ ostree_sysroot_upgrader_new (OstreeSysrootUpgrader * ostree_sysroot_upgrader_new_for_os (OstreeSysroot *sysroot, const char *osname, - GCancellable *cancellable, - GError **error); + GCancellable *cancellable, + GError **error);

    Parameters

    @@ -253,8 +253,8 @@ ostree_sysroot_upgrader_new_for_os_with_flags (OstreeSysroot *sysroot, const char *osname, OstreeSysrootUpgraderFlags flags, - GCancellable *cancellable, - GError **error); + GCancellable *cancellable, + GError **error);

    Parameters

    @@ -301,7 +301,7 @@ ostree_sysroot_upgrader_new_for_os_with_flags

    ostree_sysroot_upgrader_get_origin ()

    -
    GKeyFile *
    +
    GKeyFile *
     ostree_sysroot_upgrader_get_origin (OstreeSysrootUpgrader *self);

    Parameters

    @@ -320,14 +320,14 @@ ostree_sysroot_upgrader_get_origin (

    Returns

    -

    The origin file, or NULL if unknown.

    +

    The origin file, or NULL if unknown.

    [transfer none]


    ostree_sysroot_upgrader_dup_origin ()

    -
    GKeyFile *
    +
    GKeyFile *
     ostree_sysroot_upgrader_dup_origin (OstreeSysrootUpgrader *self);

    Parameters

    @@ -346,18 +346,18 @@ ostree_sysroot_upgrader_dup_origin (

    Returns

    -

    A copy of the origin file, or NULL if unknown.

    +

    A copy of the origin file, or NULL if unknown.

    [transfer full]


    ostree_sysroot_upgrader_set_origin ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_upgrader_set_origin (OstreeSysrootUpgrader *self,
    -                                    GKeyFile *origin,
    -                                    GCancellable *cancellable,
    -                                    GError **error);
    + GKeyFile *origin, + GCancellable *cancellable, + GError **error);

    Replace the origin with origin .

    @@ -416,18 +416,18 @@ ostree_sysroot_upgrader_get_origin_description

    Returns

    -

    A one-line descriptive summary of the origin, or NULL if unknown

    +

    A one-line descriptive summary of the origin, or NULL if unknown


    ostree_sysroot_upgrader_check_timestamps ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_upgrader_check_timestamps
                                    (OstreeRepo *repo,
                                     const char *from_rev,
                                     const char *to_rev,
    -                                GError **error);
    + GError **error);

    Check that the timestamp on to_rev is equal to or newer than from_rev @@ -469,21 +469,21 @@ attackers which provide a client with an older commit.


    ostree_sysroot_upgrader_pull ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_upgrader_pull (OstreeSysrootUpgrader *self,
                                   OstreeRepoPullFlags flags,
                                   OstreeSysrootUpgraderPullFlags upgrader_flags,
                                   OstreeAsyncProgress *progress,
    -                              gboolean *out_changed,
    -                              GCancellable *cancellable,
    -                              GError **error);
    + gboolean *out_changed, + GCancellable *cancellable, + GError **error);

    Perform a pull from the origin. First check if the ref has changed, if so download the linked objects, and store the updated ref locally. Then out_changed - will be TRUE.

    + will be TRUE.

    If the origin remote is unchanged, out_changed will be set to -FALSE.

    +FALSE.

    Parameters

    @@ -535,15 +535,15 @@ ref locally. Then out_changed

    ostree_sysroot_upgrader_pull_one_dir ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_upgrader_pull_one_dir (OstreeSysrootUpgrader *self,
                                           const char *dir_to_pull,
                                           OstreeRepoPullFlags flags,
                                           OstreeSysrootUpgraderPullFlags upgrader_flags,
                                           OstreeAsyncProgress *progress,
    -                                      gboolean *out_changed,
    -                                      GCancellable *cancellable,
    -                                      GError **error);
    + gboolean *out_changed, + GCancellable *cancellable, + GError **error);

    Like ostree_sysroot_upgrader_pull(), but allows retrieving just a subpath of the tree. This can be used to download metadata files from inside the tree such as package databases.

    @@ -603,10 +603,10 @@ from inside the tree such as package databases.


    ostree_sysroot_upgrader_deploy ()

    -
    gboolean
    +
    gboolean
     ostree_sysroot_upgrader_deploy (OstreeSysrootUpgrader *self,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Write the new deployment to disk, perform a configuration merge with /etc, and update the bootloader configuration.

    diff --git a/apidoc/html/ostree-ostree-bootconfig-parser.html b/apidoc/html/ostree-ostree-bootconfig-parser.html index d6c2e2b6..39ccebf7 100644 --- a/apidoc/html/ostree-ostree-bootconfig-parser.html +++ b/apidoc/html/ostree-ostree-bootconfig-parser.html @@ -57,7 +57,7 @@
    +initrds or NULL to unset.

    @@ -319,7 +319,7 @@ ostree_bootconfig_parser_get_overlay_initrds

    Returns

    -

    Array of initrds or NULL +

    Array of initrds or NULL if none are set.

    [array zero-terminated=1][transfer none][nullable]

    diff --git a/apidoc/html/ostree-ostree-chain-input-stream.html b/apidoc/html/ostree-ostree-chain-input-stream.html index 8f5262a3..c4dcdc15 100644 --- a/apidoc/html/ostree-ostree-chain-input-stream.html +++ b/apidoc/html/ostree-ostree-chain-input-stream.html @@ -69,7 +69,7 @@

    ostree_chain_input_stream_new ()

    OstreeChainInputStream *
    -ostree_chain_input_stream_new (GPtrArray *streams);
    +ostree_chain_input_stream_new (GPtrArray *streams);
    diff --git a/apidoc/html/ostree-ostree-checksum-input-stream.html b/apidoc/html/ostree-ostree-checksum-input-stream.html index 72e2a30d..65d115c4 100644 --- a/apidoc/html/ostree-ostree-checksum-input-stream.html +++ b/apidoc/html/ostree-ostree-checksum-input-stream.html @@ -69,8 +69,8 @@

    ostree_checksum_input_stream_new ()

    OstreeChecksumInputStream *
    -ostree_checksum_input_stream_new (GInputStream *stream,
    -                                  GChecksum *checksum);
    +ostree_checksum_input_stream_new (GInputStream *stream, + GChecksum *checksum);
    diff --git a/apidoc/html/ostree-ostree-content-writer.html b/apidoc/html/ostree-ostree-content-writer.html index 406f81dc..c1752da1 100644 --- a/apidoc/html/ostree-ostree-content-writer.html +++ b/apidoc/html/ostree-ostree-content-writer.html @@ -57,8 +57,8 @@

    ostree_content_writer_finish ()

    char *
     ostree_content_writer_finish (OstreeContentWriter *self,
    -                              GCancellable *cancellable,
    -                              GError **error);
    + GCancellable *cancellable, + GError **error);

    Complete the object write and return the checksum.

    Parameters

    @@ -89,7 +89,7 @@ ostree_content_writer_finish (Ost

    Returns

    -

    Checksum, or NULL on error.

    +

    Checksum, or NULL on error.

    [transfer full]

    diff --git a/apidoc/html/ostree-ostree-deployment.html b/apidoc/html/ostree-ostree-deployment.html index 41cc9be5..85f6f086 100644 --- a/apidoc/html/ostree-ostree-deployment.html +++ b/apidoc/html/ostree-ostree-deployment.html @@ -41,7 +41,7 @@
    -gboolean +gboolean ostree_bootconfig_parser_parse () @@ -65,7 +65,7 @@
    -gboolean +gboolean ostree_bootconfig_parser_parse_at () @@ -73,7 +73,7 @@
    -gboolean +gboolean ostree_bootconfig_parser_write () @@ -81,7 +81,7 @@
    -gboolean +gboolean ostree_bootconfig_parser_write_at () @@ -174,21 +174,21 @@ ostree_bootconfig_parser_clone (

    ostree_bootconfig_parser_parse ()

    -
    gboolean
    +
    gboolean
     ostree_bootconfig_parser_parse (OstreeBootconfigParser *self,
    -                                GFile *path,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GFile *path, + GCancellable *cancellable, + GError **error);

    ostree_bootconfig_parser_parse_at ()

    -
    gboolean
    +
    gboolean
     ostree_bootconfig_parser_parse_at (OstreeBootconfigParser *self,
                                        int dfd,
                                        const char *path,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    + GCancellable *cancellable, + GError **error);

    Initialize a bootconfig from the given file.

    Parameters

    @@ -231,21 +231,21 @@ ostree_bootconfig_parser_parse_at (

    ostree_bootconfig_parser_write ()

    -
    gboolean
    +
    gboolean
     ostree_bootconfig_parser_write (OstreeBootconfigParser *self,
    -                                GFile *output,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GFile *output, + GCancellable *cancellable, + GError **error);

    ostree_bootconfig_parser_write_at ()

    -
    gboolean
    +
    gboolean
     ostree_bootconfig_parser_write_at (OstreeBootconfigParser *self,
                                        int dfd,
                                        const char *path,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    + GCancellable *cancellable, + GError **error);

    @@ -288,7 +288,7 @@ base initrd is part of the primary keys.

    initrds

    Array of overlay -initrds or NULL to unset.

    [array zero-terminated=1][transfer none][allow-none]
    -guint +guint ostree_deployment_hash () @@ -49,7 +49,7 @@
    -gboolean +gboolean ostree_deployment_equal () @@ -118,7 +118,7 @@
    -GKeyFile * +GKeyFile * ostree_deployment_get_origin () @@ -142,7 +142,7 @@
    -gboolean +gboolean ostree_deployment_is_pinned () @@ -150,7 +150,7 @@
    -gboolean +gboolean ostree_deployment_is_staged () @@ -234,8 +234,8 @@

    Functions

    ostree_deployment_hash ()

    -
    guint
    -ostree_deployment_hash (gconstpointer v);
    +
    guint
    +ostree_deployment_hash (gconstpointer v);

    Parameters

    @@ -259,9 +259,9 @@ ostree_deployment_hash (gconstpoi

    ostree_deployment_equal ()

    -
    gboolean
    -ostree_deployment_equal (gconstpointer ap,
    -                         gconstpointer bp);
    +
    gboolean
    +ostree_deployment_equal (gconstpointer ap,
    +                         gconstpointer bp);

    Parameters

    @@ -286,7 +286,7 @@ ostree_deployment_equal (gconstpo

    Returns

    -

    TRUE if deployments have the same osname, csum, and deployserial

    +

    TRUE if deployments have the same osname, csum, and deployserial


    @@ -431,7 +431,7 @@ ostree_deployment_get_bootconfig (

    ostree_deployment_get_origin ()

    -
    GKeyFile *
    +
    GKeyFile *
     ostree_deployment_get_origin (OstreeDeployment *self);

    Parameters

    @@ -493,7 +493,7 @@ ostree_deployment_get_unlocked (

    ostree_deployment_is_pinned ()

    -
    gboolean
    +
    gboolean
     ostree_deployment_is_pinned (OstreeDeployment *self);

    See ostree_sysroot_deployment_set_pinned().

    @@ -520,7 +520,7 @@ ostree_deployment_is_pinned (

    ostree_deployment_is_staged ()

    -
    gboolean
    +
    gboolean
     ostree_deployment_is_staged (OstreeDeployment *self);

    Parameters

    @@ -638,7 +638,7 @@ ostree_deployment_set_bootconfig (

    ostree_deployment_set_origin ()

    void
     ostree_deployment_set_origin (OstreeDeployment *self,
    -                              GKeyFile *origin);
    + GKeyFile *origin);

    Replace the "origin", which is a description of the source of the deployment and how to update to the next version.

    @@ -669,7 +669,7 @@ of the deployment and how to update to the next version.

    ostree_deployment_origin_remove_transient_state ()

    void
     ostree_deployment_origin_remove_transient_state
    -                               (GKeyFile *origin);
    + (GKeyFile *origin);

    The intention of an origin file is primarily describe the "inputs" that resulted in a deployment, and it's commonly used to derive the new state. For example, a key value (in pure libostree mode) is the "refspec". However, @@ -806,7 +806,7 @@ ostree_deployment_unlocked_state_to_string

    - + @@ -816,7 +816,7 @@ ostree_deployment_unlocked_state_to_string - + diff --git a/apidoc/html/ostree-ostree-diff.html b/apidoc/html/ostree-ostree-diff.html index 627dff28..48c739fc 100644 --- a/apidoc/html/ostree-ostree-diff.html +++ b/apidoc/html/ostree-ostree-diff.html @@ -57,7 +57,7 @@ - + @@ -192,16 +192,16 @@ sets of

    ostree_diff_dirs_with_options ()

    -
    gboolean
    +
    gboolean
     ostree_diff_dirs_with_options (OstreeDiffFlags flags,
    -                               GFile *a,
    -                               GFile *b,
    -                               GPtrArray *modified,
    -                               GPtrArray *removed,
    -                               GPtrArray *added,
    +                               GFile *a,
    +                               GFile *b,
    +                               GPtrArray *modified,
    +                               GPtrArray *removed,
    +                               GPtrArray *added,
                                    OstreeDiffDirsOptions *options,
    -                               GCancellable *cancellable,
    -                               GError **error);
    + GCancellable *cancellable, + GError **error);

    Compute the difference between directory a and b as 3 separate @@ -225,7 +225,7 @@ sets of

    a

    -
    + @@ -272,11 +272,11 @@ sets of

    ostree_diff_print ()

    void
    -ostree_diff_print (GFile *a,
    -                   GFile *b,
    -                   GPtrArray *modified,
    -                   GPtrArray *removed,
    -                   GPtrArray *added);
    +ostree_diff_print (GFile *a, + GFile *b, + GPtrArray *modified, + GPtrArray *removed, + GPtrArray *added);

    Print the contents of a diff to stdout.

    Parameters

    diff --git a/apidoc/html/ostree-ostree-kernel-args.html b/apidoc/html/ostree-ostree-kernel-args.html index af9dcdbf..919125c7 100644 --- a/apidoc/html/ostree-ostree-kernel-args.html +++ b/apidoc/html/ostree-ostree-kernel-args.html @@ -121,7 +121,7 @@
    - + @@ -214,12 +214,12 @@ ostree_collection_ref_free (Ostre

    ostree_collection_ref_hash ()

    -
    guint
    -ostree_collection_ref_hash (gconstpointer ref);
    +
    guint
    +ostree_collection_ref_hash (gconstpointer ref);

    Hash the given ref -. This function is suitable for use with GHashTable. +. This function is suitable for use with GHashTable. ref - must be non-NULL.

    + must be non-NULL.

    Parameters

     

    GKeyFile *origin;

    GKeyFile *origin;

    How to construct an upgraded version of this tree

     
     

    gboolean staged;

    gboolean staged;

    TRUE iff this deployment is staged

     
    -gboolean +gboolean ostree_diff_dirs () @@ -65,7 +65,7 @@
    -gboolean +gboolean ostree_diff_dirs_with_options () @@ -120,15 +120,15 @@ ostree_diff_item_unref (

    ostree_diff_dirs ()

    -
    gboolean
    +
    gboolean
     ostree_diff_dirs (OstreeDiffFlags flags,
    -                  GFile *a,
    -                  GFile *b,
    -                  GPtrArray *modified,
    -                  GPtrArray *removed,
    -                  GPtrArray *added,
    -                  GCancellable *cancellable,
    -                  GError **error);
    + GFile *a, + GFile *b, + GPtrArray *modified, + GPtrArray *removed, + GPtrArray *added, + GCancellable *cancellable, + GError **error);

    Compute the difference between directory a and b as 3 separate @@ -152,7 +152,7 @@ sets of

    a

    First directory path, or NULL

    First directory path, or NULL

     

    First directory path, or NULL

    First directory path, or NULL

     
    -gboolean +gboolean ostree_kernel_args_new_replace () @@ -129,7 +129,7 @@
    -gboolean +gboolean ostree_kernel_args_delete () @@ -137,7 +137,7 @@
    -gboolean +gboolean ostree_kernel_args_delete_key_entry () @@ -145,7 +145,7 @@
    -gboolean +gboolean ostree_kernel_args_append_proc_cmdline () @@ -518,10 +518,10 @@ and appends key to kargs->order if it is not in the hash table.


    ostree_kernel_args_new_replace ()

    -
    gboolean
    +
    gboolean
     ostree_kernel_args_new_replace (OstreeKernelArgs *kargs,
                                     const char *arg,
    -                                GError **error);
    + GError **error);

    This function implements the basic logic behind key/value pair replacement. Do note that the arg need to be properly formatted

    When replacing key with exact one value, the arg can be in @@ -564,7 +564,7 @@ val will be swapped with the new_val in that case

    Returns

    -

    TRUE on success, FALSE on failure (and in some other instances such as:

    +

    TRUE on success, FALSE on failure (and in some other instances such as:

    1. key not found in kargs

    2. @@ -579,10 +579,10 @@ is in the form of key=old_val)


      ostree_kernel_args_delete ()

      -
      gboolean
      +
      gboolean
       ostree_kernel_args_delete (OstreeKernelArgs *kargs,
                                  const char *arg,
      -                           GError **error);
      + GError **error);

      There are few scenarios being handled for deletion:

      1: for input arg with a single key(i.e without = for split), the key/value pair will be deleted if there is only @@ -622,17 +622,17 @@ ostree_kernel_args_delete (

      Returns

      -

      TRUE on success, FALSE on failure

      +

      TRUE on success, FALSE on failure

      Since: 2019.3


    ostree_kernel_args_delete_key_entry ()

    -
    gboolean
    +
    gboolean
     ostree_kernel_args_delete_key_entry (OstreeKernelArgs *kargs,
                                          const char *key,
    -                                     GError **error);
    + GError **error);

    This function removes the key entry from the hashtable as well from the order pointer array inside kargs

    Note: since both table and order inside kernel args @@ -667,18 +667,18 @@ being called as they are done automatically by GLib

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure

    Since: 2019.3


    ostree_kernel_args_append_proc_cmdline ()

    -
    gboolean
    +
    gboolean
     ostree_kernel_args_append_proc_cmdline
                                    (OstreeKernelArgs *kargs,
    -                                GCancellable *cancellable,
    -                                GError **error);
    + GCancellable *cancellable, + GError **error);

    Appends the command line arguments in the file "/proc/cmdline" that does not have "BOOT_IMAGE=" and "initrd=" as prefixes to the kargs

    @@ -711,7 +711,7 @@ that does not have "BOOT_IMAGE=" and "initrd=" as prefixes to the

    Returns

    -

    TRUE on success, FALSE on failure

    +

    TRUE on success, FALSE on failure

    Since: 2019.3

    diff --git a/apidoc/html/ostree-ostree-ref.html b/apidoc/html/ostree-ostree-ref.html index 4c15cdf4..6ef49e33 100644 --- a/apidoc/html/ostree-ostree-ref.html +++ b/apidoc/html/ostree-ostree-ref.html @@ -65,7 +65,7 @@
    -guint +guint ostree_collection_ref_hash () @@ -73,7 +73,7 @@
    -gboolean +gboolean ostree_collection_ref_equal () @@ -119,13 +119,13 @@

    ostree_collection_ref_new ()

    OstreeCollectionRef *
    -ostree_collection_ref_new (const gchar *collection_id,
    -                           const gchar *ref_name);
    +ostree_collection_ref_new (const gchar *collection_id, + const gchar *ref_name);

    Create a new OstreeCollectionRef containing (collection_id , ref_name ). If collection_id - is NULL, this is equivalent to a plain ref name string (not a + is NULL, this is equivalent to a plain ref name string (not a refspec; no remote name is included), which can be used for non-P2P operations.

    @@ -139,7 +139,7 @@ operations.

    collection_id

    a collection ID, or NULL for a plain ref.

    a collection ID, or NULL for a plain ref.

    [nullable]
    @@ -245,15 +245,15 @@ ostree_collection_ref_hash (gcons

    ostree_collection_ref_equal ()

    -
    gboolean
    -ostree_collection_ref_equal (gconstpointer ref1,
    -                             gconstpointer ref2);
    +
    gboolean
    +ostree_collection_ref_equal (gconstpointer ref1,
    +                             gconstpointer ref2);

    Compare ref1 and ref2 - and return TRUE if they have the same collection ID and -ref name, and FALSE otherwise. Both ref1 + and return TRUE if they have the same collection ID and +ref name, and FALSE otherwise. Both ref1 and ref2 - must be non-NULL.

    + must be non-NULL.

    Parameters

    @@ -278,9 +278,9 @@ ref name, and FALSE otherwise. Both

    Returns

    -

    TRUE if ref1 +

    TRUE if ref1 and ref2 -are equal, FALSE otherwise

    +are equal, FALSE otherwise

    Since: 2018.6

    @@ -291,8 +291,8 @@ are equal, FALSE otherwise

    ostree_collection_ref_dupv (const OstreeCollectionRef * const *refs);

    Copy an array of OstreeCollectionRefs, including deep copies of all its elements. refs - must be NULL-terminated; it may be empty, but must not be -NULL.

    + must be NULL-terminated; it may be empty, but must not be +NULL.

    Parameters

    @@ -303,7 +303,7 @@ elements. refs - +

    refs

    NULL-terminated array of OstreeCollectionRefs.

    NULL-terminated array of OstreeCollectionRefs.

    [array zero-terminated=1]
    @@ -324,7 +324,7 @@ ostree_collection_ref_freev (Ostr

    Free the given array of refs , including freeing all its elements. refs -must be NULL-terminated; it may be empty, but must not be NULL.

    +must be NULL-terminated; it may be empty, but must not be NULL.

    Parameters

    @@ -349,8 +349,8 @@ must be NULL-terminated; it may be empty, but must

    OstreeCollectionRefv

    typedef OstreeCollectionRef** OstreeCollectionRefv;
     
    -

    A NULL-terminated array of OstreeCollectionRef instances, designed to -be used with g_auto():

    +

    A NULL-terminated array of OstreeCollectionRef instances, designed to +be used with g_auto():

    diff --git a/apidoc/html/ostree-ostree-remote.html b/apidoc/html/ostree-ostree-remote.html index 01e83fb7..91f43ade 100644 --- a/apidoc/html/ostree-ostree-remote.html +++ b/apidoc/html/ostree-ostree-remote.html @@ -56,7 +56,7 @@ -
    const gchar * +const gchar * ostree_remote_get_name () @@ -64,7 +64,7 @@
    -gchar * +gchar * ostree_remote_get_url () @@ -148,7 +148,7 @@ reference count reaches 0.


    ostree_remote_get_name ()

    -
    const gchar *
    +
    const gchar *
     ostree_remote_get_name (OstreeRemote *remote);

    Get the human-readable name of the remote. This is what the user configured, if the remote was explicitly configured; and will otherwise be a stable, @@ -177,7 +177,7 @@ arbitrary, string.


    ostree_remote_get_url ()

    -
    gchar *
    +
    gchar *
     ostree_remote_get_url (OstreeRemote *remote);

    Get the URL from the remote.

    diff --git a/apidoc/html/ostree-ostree-repo-file.html b/apidoc/html/ostree-ostree-repo-file.html index ff2bcf3b..87689d0e 100644 --- a/apidoc/html/ostree-ostree-repo-file.html +++ b/apidoc/html/ostree-ostree-repo-file.html @@ -41,7 +41,7 @@
    -gboolean +gboolean ostree_repo_file_ensure_resolved () @@ -49,7 +49,7 @@
    -gboolean +gboolean ostree_repo_file_get_xattrs () @@ -95,7 +95,7 @@
    -GVariant * +GVariant * ostree_repo_file_tree_get_contents () @@ -103,7 +103,7 @@
    -GVariant * +GVariant * ostree_repo_file_tree_get_metadata () @@ -126,7 +126,7 @@
    -gboolean +gboolean ostree_repo_file_tree_query_child () @@ -155,18 +155,18 @@

    Functions

    ostree_repo_file_ensure_resolved ()

    -
    gboolean
    +
    gboolean
     ostree_repo_file_ensure_resolved (OstreeRepoFile *self,
    -                                  GError **error);
    + GError **error);

    ostree_repo_file_get_xattrs ()

    -
    gboolean
    +
    gboolean
     ostree_repo_file_get_xattrs (OstreeRepoFile *self,
    -                             GVariant **out_xattrs,
    -                             GCancellable *cancellable,
    -                             GError **error);
    + GVariant **out_xattrs, + GCancellable *cancellable, + GError **error);

    Parameters

    @@ -228,7 +228,7 @@ ostree_repo_file_get_root (void ostree_repo_file_tree_set_metadata (OstreeRepoFile *self, const char *checksum, - GVariant *metadata); + GVariant *metadata);
    @@ -247,13 +247,13 @@ ostree_repo_file_tree_get_metadata_checksum

    ostree_repo_file_tree_get_contents ()

    -
    GVariant *
    +
    GVariant *
     ostree_repo_file_tree_get_contents (OstreeRepoFile *self);

    ostree_repo_file_tree_get_metadata ()

    -
    GVariant *
    +
    GVariant *
     ostree_repo_file_tree_get_metadata (OstreeRepoFile *self);

    @@ -268,8 +268,8 @@ ostree_repo_file_get_checksum (int ostree_repo_file_tree_find_child (OstreeRepoFile *self, const char *name, - gboolean *is_dir, - GVariant **out_container); + gboolean *is_dir, + GVariant **out_container);

    Parameters

    @@ -306,14 +306,14 @@ ostree_repo_file_tree_find_child (

    ostree_repo_file_tree_query_child ()

    -
    gboolean
    +
    gboolean
     ostree_repo_file_tree_query_child (OstreeRepoFile *self,
                                        int n,
                                        const char *attributes,
    -                                   GFileQueryInfoFlags flags,
    -                                   GFileInfo **out_info,
    -                                   GCancellable *cancellable,
    -                                   GError **error);
    + GFileQueryInfoFlags flags, + GFileInfo **out_info, + GCancellable *cancellable, + GError **error);

    Parameters

    diff --git a/apidoc/html/ostree-ostree-repo-finder.html b/apidoc/html/ostree-ostree-repo-finder.html index 53c12d63..c9b7f204 100644 --- a/apidoc/html/ostree-ostree-repo-finder.html +++ b/apidoc/html/ostree-ostree-repo-finder.html @@ -49,7 +49,7 @@ - + @@ -220,10 +220,10 @@ which provides configuration information and GPG keys.


    ostree_repo_finder_resolve_finish ()

    -
    GPtrArray *
    +
    GPtrArray *
     ostree_repo_finder_resolve_finish (OstreeRepoFinder *self,
    -                                   GAsyncResult *result,
    -                                   GError **error);
    + GAsyncResult *result, + GError **error);

    Get the results from a ostree_repo_finder_resolve_async() operation.

    Parameters

    @@ -241,12 +241,12 @@ ostree_repo_finder_resolve_finish (
    - + - + @@ -267,9 +267,9 @@ or more results.

    ostree_repo_finder_resolve_all_async (
    OstreeRepoFinder * const *finders, const OstreeCollectionRef * const *refs, OstreeRepo *parent_repo, - GCancellable *cancellable, - GAsyncReadyCallback callback, - gpointer user_data); + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data);

    A version of ostree_repo_finder_resolve_async() which queries one or more finders in parallel and combines the results.

    @@ -300,7 +300,7 @@ which provides configuration information and GPG keys.

    - + @@ -322,9 +322,9 @@ which provides configuration information and GPG keys.


    ostree_repo_finder_resolve_all_finish ()

    -
    GPtrArray *
    -ostree_repo_finder_resolve_all_finish (GAsyncResult *result,
    -                                       GError **error);
    +
    GPtrArray *
    +ostree_repo_finder_resolve_all_finish (GAsyncResult *result,
    +                                       GError **error);

    Get the results from a ostree_repo_finder_resolve_all_async() operation.

    Parameters

    @@ -337,12 +337,12 @@ ostree_repo_finder_resolve_all_finish (

    result

    -
    + - + @@ -362,10 +362,10 @@ or more results.

    OstreeRepoFinderResult *
     ostree_repo_finder_result_new (OstreeRemote *remote,
                                    OstreeRepoFinder *finder,
    -                               gint priority,
    -                               GHashTable *ref_to_checksum,
    -                               GHashTable *ref_to_timestamp,
    -                               guint64 summary_last_modified);
    + gint priority, + GHashTable *ref_to_checksum, + GHashTable *ref_to_timestamp, + guint64 summary_last_modified);

    Create a new OstreeRepoFinderResult instance. The semantics for the arguments are as described in the OstreeRepoFinderResult documentation.

    @@ -479,7 +479,7 @@ ostree_repo_finder_result_free (O

    ostree_repo_finder_result_compare ()

    -
    gint
    +
    gint
     ostree_repo_finder_result_compare (const OstreeRepoFinderResult *a,
                                        const OstreeRepoFinderResult *b);

    Compare two OstreeRepoFinderResult instances to work out which one is better @@ -553,8 +553,8 @@ ostree_repo_finder_result_freev (

    OstreeRepoFinderResultv

    typedef OstreeRepoFinderResult** OstreeRepoFinderResultv;
     
    -

    A NULL-terminated array of OstreeRepoFinderResult instances, designed to -be used with g_auto():

    +

    A NULL-terminated array of OstreeRepoFinderResult instances, designed to +be used with g_auto():

    -GPtrArray * +GPtrArray * ostree_repo_finder_resolve_finish () @@ -65,7 +65,7 @@
    -GPtrArray * +GPtrArray * ostree_repo_finder_resolve_all_finish () @@ -97,7 +97,7 @@
    -gint +gint ostree_repo_finder_result_compare () @@ -144,9 +144,9 @@ ostree_repo_finder_resolve_async (OstreeRepoFinder *self, const OstreeCollectionRef * const *refs, OstreeRepo *parent_repo, - GCancellable *cancellable, - GAsyncReadyCallback callback, - gpointer user_data); + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data);

    Find reachable remote URIs which claim to provide any of the given refs . The specific method for finding the remotes depends on the OstreeRepoFinder @@ -198,7 +198,7 @@ which provides configuration information and GPG keys.

    cancellable

    a GCancellable, or NULL.

    a GCancellable, or NULL.

    [nullable]

    result

    GAsyncResult from the callback

    GAsyncResult from the callback

     

    error

    return location for a GError

    return location for a GError

     

    cancellable

    a GCancellable, or NULL.

    a GCancellable, or NULL.

    [nullable]

    GAsyncResult from the callback

    GAsyncResult from the callback

     

    error

    return location for a GError

    return location for a GError

     
    diff --git a/apidoc/html/ostree-ostree-repo-remote-finder.html b/apidoc/html/ostree-ostree-repo-remote-finder.html index 006ba4d9..24912233 100644 --- a/apidoc/html/ostree-ostree-repo-remote-finder.html +++ b/apidoc/html/ostree-ostree-repo-remote-finder.html @@ -65,7 +65,7 @@
    -gboolean +gboolean ostree_repo_pull_from_remotes_finish () @@ -111,12 +111,12 @@
    void
     ostree_repo_find_remotes_async (OstreeRepo *self,
                                     const OstreeCollectionRef * const *refs,
    -                                GVariant *options,
    +                                GVariant *options,
                                     OstreeRepoFinder **finders,
                                     OstreeAsyncProgress *progress,
    -                                GCancellable *cancellable,
    -                                GAsyncReadyCallback callback,
    -                                gpointer user_data);
    + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data);

    Find reachable remote URIs which claim to provide any of the given named refs . This will search for configured remotes (OstreeRepoFinderConfig), @@ -153,12 +153,12 @@ receiving a transient network error, such as a socket timeout; default is 5, 0 means return errors without retrying. Since: 2018.6

    finders - must be a non-empty NULL-terminated array of the OstreeRepoFinder -instances to use, or NULL to use the system default set of finders, which + must be a non-empty NULL-terminated array of the OstreeRepoFinder +instances to use, or NULL to use the system default set of finders, which will typically be all available finders using their default options (but this is not guaranteed).

    GPG verification of commits will be used unconditionally.

    -

    This will use the thread-default GMainContext, but will not iterate it.

    +

    This will use the thread-default GMainContext, but will not iterate it.

    Parameters

    @@ -186,18 +186,18 @@ this is not guaranteed).

    +OstreeRepoFinder instances to use, or NULL to use the system defaults.

    +progress, or NULL.

    - + @@ -221,8 +221,8 @@ progress, or NULL.

    ostree_repo_find_remotes_finish ()

    OstreeRepoFinderResult **
     ostree_repo_find_remotes_finish (OstreeRepo *self,
    -                                 GAsyncResult *result,
    -                                 GError **error);
    + GAsyncResult *result, + GError **error);

    Finish an asynchronous pull operation started with ostree_repo_find_remotes_async().

    @@ -246,7 +246,7 @@ ostree_repo_find_remotes_finish (
    - + @@ -255,8 +255,8 @@ ostree_repo_find_remotes_finish (

    Returns

    a potentially empty array -of OstreeRepoFinderResults, followed by a NULL terminator element; or -NULL on error.

    +of OstreeRepoFinderResults, followed by a NULL terminator element; or +NULL on error.

    [transfer full][array zero-terminated=1]

    Since: 2018.6

    @@ -267,11 +267,11 @@ of OstreeRepoFinderResults, followed by a void ostree_repo_pull_from_remotes_async (OstreeRepo *self, const OstreeRepoFinderResult * const *results, - GVariant *options, + GVariant *options, OstreeAsyncProgress *progress, - GCancellable *cancellable, - GAsyncReadyCallback callback, - gpointer user_data); + GCancellable *cancellable, + GAsyncReadyCallback callback, + gpointer user_data);

    Pull refs from multiple remotes which have been found using ostree_repo_find_remotes_async().

    results @@ -280,11 +280,11 @@ from listed first. G_IO_ERROR_FAILED +downloaded successfully after all remotes have been tried, G_IO_ERROR_FAILED will be returned. The results of any successful downloads will remain cached in the local repository.

    If cancellable - is cancelled, G_IO_ERROR_CANCELLED will be returned + is cancelled, G_IO_ERROR_CANCELLED will be returned immediately. The results of any successfully completed downloads at that point will remain cached in the local repository.

    GPG verification of commits will be used unconditionally.

    @@ -292,7 +292,7 @@ point will remain cached in the local repository.

    are currently defined:

    • flags (i): OstreeRepoPullFlags to apply to the pull operation

    • -
    • inherit-transaction (b): TRUE to inherit an ongoing transaction on +

    • inherit-transaction (b): TRUE to inherit an ongoing transaction on the OstreeRepo, rather than encapsulating the pull in a new one

    • depth (i): How far in the history to traverse; default is 0, -1 means infinite

    • disable-static-deltas (b): Do not use static deltas

    • @@ -328,7 +328,7 @@ will be verified with the keyring of the remote being pulled from.

    - @@ -340,12 +340,12 @@ pull from, including the refs to pull from each.

    +progress, or NULL.

    - + @@ -367,10 +367,10 @@ progress, or NULL.


    ostree_repo_pull_from_remotes_finish ()

    -
    gboolean
    +
    gboolean
     ostree_repo_pull_from_remotes_finish (OstreeRepo *self,
    -                                      GAsyncResult *result,
    -                                      GError **error);
    + GAsyncResult *result, + GError **error);

    Finish an asynchronous pull operation started with ostree_repo_pull_from_remotes_async().

    @@ -394,7 +394,7 @@ ostree_repo_pull_from_remotes_finish (

    error

    -
    + @@ -402,7 +402,7 @@ ostree_repo_pull_from_remotes_finish (

    Returns

    -

    TRUE on success, FALSE otherwise

    +

    TRUE on success, FALSE otherwise

    Since: 2018.6

    @@ -412,9 +412,9 @@ ostree_repo_pull_from_remotes_finish (OstreeRemote * ostree_repo_resolve_keyring_for_collection (OstreeRepo *self, - const gchar *collection_id, - GCancellable *cancellable, - GError **error); + const gchar *collection_id, + GCancellable *cancellable, + GError **error);

    Find the GPG keyring for the given collection_id , using the local configuration from the given OstreeRepo. This will search the configured @@ -424,7 +424,7 @@ return the first matching remote.

    If multiple remotes match and have different keyrings, a debug message will be emitted, and the first result will be returned. It is expected that the keyrings should match.

    -

    If no match can be found, a G_IO_ERROR_NOT_FOUND error will be returned.

    +

    If no match can be found, a G_IO_ERROR_NOT_FOUND error will be returned.

    Parameters

    finders

    non-empty array of -OstreeRepoFinder instances to use, or NULL to use the system defaults.

    [array zero-terminated=1][transfer none]

    progress

    an OstreeAsyncProgress to update with the operation’s -progress, or NULL.

    [nullable]

    cancellable

    a GCancellable, or NULL.

    a GCancellable, or NULL.

    [nullable]

    error

    return location for a GError, or NULL

    return location for a GError, or NULL

     

    results

    NULL-terminated array of remotes to +

    NULL-terminated array of remotes to pull from, including the refs to pull from each.

    [array zero-terminated=1]

    progress

    an OstreeAsyncProgress to update with the operation’s -progress, or NULL.

    [nullable]

    cancellable

    a GCancellable, or NULL.

    a GCancellable, or NULL.

    [nullable]

    return location for a GError, or NULL

    return location for a GError, or NULL

     
    @@ -446,12 +446,12 @@ keyrings should match.

    - + - + diff --git a/apidoc/html/ostree-ostree-version.html b/apidoc/html/ostree-ostree-version.html index 1ca36833..49bc9f9e 100644 --- a/apidoc/html/ostree-ostree-version.html +++ b/apidoc/html/ostree-ostree-version.html @@ -86,7 +86,7 @@ at compile-time

    OSTREE_CHECK_VERSION()

    #define             OSTREE_CHECK_VERSION(year,release)
    -

    Compile-time version checking. Evaluates to TRUE if the version +

    Compile-time version checking. Evaluates to TRUE if the version of ostree is equal or greater than the required one.

    Parameters

    @@ -125,7 +125,7 @@ of ostree is equal or greater than the required one.


    OSTREE_RELEASE_VERSION

    -
    #define OSTREE_RELEASE_VERSION (5)
    +
    #define OSTREE_RELEASE_VERSION (6)
     

    ostree release version component (e.g. 2 if OSTREE_VERSION is 2017.2)

    Since: 2017.4

    @@ -133,7 +133,7 @@ of ostree is equal or greater than the required one.


    OSTREE_VERSION

    -
    #define OSTREE_VERSION (2022.5)
    +
    #define OSTREE_VERSION (2022.6)
     

    ostree version.

    Since: 2017.4

    @@ -141,7 +141,7 @@ of ostree is equal or greater than the required one.


    OSTREE_VERSION_S

    -
    #define OSTREE_VERSION_S "2022.5"
    +
    #define OSTREE_VERSION_S "2022.6"
     

    ostree version, encoded as a string, useful for printing and concatenation.

    diff --git a/apidoc/html/right-insensitive.png b/apidoc/html/right-insensitive.png index 4c95785b..763208da 100644 Binary files a/apidoc/html/right-insensitive.png and b/apidoc/html/right-insensitive.png differ diff --git a/apidoc/html/right.png b/apidoc/html/right.png index 76260ec8..eb90dd44 100644 Binary files a/apidoc/html/right.png and b/apidoc/html/right.png differ diff --git a/apidoc/html/up-insensitive.png b/apidoc/html/up-insensitive.png index f4049860..478700c9 100644 Binary files a/apidoc/html/up-insensitive.png and b/apidoc/html/up-insensitive.png differ diff --git a/apidoc/html/up.png b/apidoc/html/up.png index 80b4b37e..636d50dd 100644 Binary files a/apidoc/html/up.png and b/apidoc/html/up.png differ diff --git a/apidoc/version.xml b/apidoc/version.xml index 99dace7b..cb2017a8 100644 --- a/apidoc/version.xml +++ b/apidoc/version.xml @@ -1 +1 @@ -2022.5 \ No newline at end of file +2022.6 \ No newline at end of file diff --git a/bash/ostree b/bash/ostree index 46363315..6f3b86ea 100644 --- a/bash/ostree +++ b/bash/ostree @@ -249,6 +249,7 @@ _ostree_checkout() { --union-identical --user-mode -U --whiteouts + --process-passthrough-whiteouts " local options_with_args=" diff --git a/build-aux/config.guess b/build-aux/config.guess index c7f17e8f..7f76b622 100755 --- a/build-aux/config.guess +++ b/build-aux/config.guess @@ -1,10 +1,10 @@ -#!/usr/bin/sh +#! /bin/sh # Attempt to guess a canonical system name. # Copyright 1992-2022 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2022-05-25' +timestamp='2022-01-09' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -1151,27 +1151,16 @@ EOF ;; x86_64:Linux:*:*) set_cc_for_build - CPU=$UNAME_MACHINE LIBCABI=$LIBC if test "$CC_FOR_BUILD" != no_compiler_found; then - ABI=64 - sed 's/^ //' << EOF > "$dummy.c" - #ifdef __i386__ - ABI=x86 - #else - #ifdef __ILP32__ - ABI=x32 - #endif - #endif -EOF - cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` - eval "$cc_set_abi" - case $ABI in - x86) CPU=i686 ;; - x32) LIBCABI=${LIBC}x32 ;; - esac + if (echo '#ifdef __ILP32__'; echo IS_X32; echo '#endif') | \ + (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ + grep IS_X32 >/dev/null + then + LIBCABI=${LIBC}x32 + fi fi - GUESS=$CPU-pc-linux-$LIBCABI + GUESS=$UNAME_MACHINE-pc-linux-$LIBCABI ;; xtensa*:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC @@ -1378,11 +1367,8 @@ EOF BePC:Haiku:*:*) # Haiku running on Intel PC compatible. GUESS=i586-pc-haiku ;; - ppc:Haiku:*:*) # Haiku running on Apple PowerPC - GUESS=powerpc-apple-haiku - ;; - *:Haiku:*:*) # Haiku modern gcc (not bound by BeOS compat) - GUESS=$UNAME_MACHINE-unknown-haiku + x86_64:Haiku:*:*) + GUESS=x86_64-unknown-haiku ;; SX-4:SUPER-UX:*:*) GUESS=sx4-nec-superux$UNAME_RELEASE diff --git a/build-aux/config.sub b/build-aux/config.sub index b41da55d..dba16e84 100755 --- a/build-aux/config.sub +++ b/build-aux/config.sub @@ -1,4 +1,4 @@ -#!/usr/bin/sh +#! /bin/sh # Configuration validation subroutine script. # Copyright 1992-2022 Free Software Foundation, Inc. diff --git a/build-aux/ltmain.sh b/build-aux/ltmain.sh old mode 100644 new mode 100755 index 49fcad13..8fb8700e --- a/build-aux/ltmain.sh +++ b/build-aux/ltmain.sh @@ -31,7 +31,7 @@ PROGRAM=libtool PACKAGE=libtool -VERSION=2.4.7 +VERSION="2.4.7 Debian-2.4.7-4" package_revision=2.4.7 @@ -430,7 +430,7 @@ EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. # putting '$debug_cmd' at the start of all your functions, you can get # bash to show function call trace with: # -# debug_cmd='eval echo "${FUNCNAME[0]} $*" >&2' bash your-script-name +# debug_cmd='echo "${FUNCNAME[0]} $*" >&2' bash your-script-name debug_cmd=${debug_cmd-":"} exit_cmd=: @@ -1706,6 +1706,8 @@ func_run_hooks () { $debug_cmd + _G_rc_run_hooks=false + case " $hookable_fns " in *" $1 "*) ;; *) func_fatal_error "'$1' does not support hook functions." ;; @@ -2306,12 +2308,12 @@ include the following information: compiler: $LTCC compiler flags: $LTCFLAGS linker: $LD (gnu? $with_gnu_ld) - version: $progname (GNU libtool) 2.4.7 + version: $progname $scriptversion Debian-2.4.7-4 automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q` autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q` Report bugs to . -GNU libtool home page: . +GNU libtool home page: . General help using GNU software: ." exit 0 } @@ -2510,6 +2512,8 @@ libtool_options_prep () _G_rc_lt_options_prep=: + _G_rc_lt_options_prep=: + # Shorthand for --mode=foo, only valid as the first argument case $1 in clean|clea|cle|cl) @@ -2668,10 +2672,17 @@ libtool_validate_options () # preserve --debug test : = "$debug_cmd" || func_append preserve_args " --debug" - # Keeping compiler generated duplicates in $postdeps and $predeps is not - # harmful, and is necessary in a majority of systems that use it to satisfy - # symbol dependencies. - opt_duplicate_compiler_generated_deps=: + case $host in + # Solaris2 added to fix http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16452 + # see also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59788 + *cygwin* | *mingw* | *pw32* | *cegcc* | *solaris2* | *os2*) + # don't eliminate duplications in $postdeps and $predeps + opt_duplicate_compiler_generated_deps=: + ;; + *) + opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps + ;; + esac $opt_help || { # Sanity checks first: @@ -7550,11 +7561,13 @@ func_mode_link () # -stdlib=* select c++ std lib with clang # -fsanitize=* Clang/GCC memory and address sanitizer # -fuse-ld=* Linker select flags for GCC + # -static-* direct GCC to link specific libraries statically + # -fcilkplus Cilk Plus language extension features for C/C++ # -Wa,* Pass flags directly to the assembler -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \ - -specs=*|-fsanitize=*|-fuse-ld=*|-Wa,*) + -specs=*|-fsanitize=*|-fuse-ld=*|-static-*|-fcilkplus|-Wa,*) func_quote_arg pretty "$arg" arg=$func_quote_arg_result func_append compile_command " $arg" @@ -7847,7 +7860,10 @@ func_mode_link () case $pass in dlopen) libs=$dlfiles ;; dlpreopen) libs=$dlprefiles ;; - link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; + link) + libs="$deplibs %DEPLIBS%" + test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" + ;; esac fi if test lib,dlpreopen = "$linkmode,$pass"; then @@ -8166,19 +8182,19 @@ func_mode_link () # It is a libtool convenience library, so add in its objects. func_append convenience " $ladir/$objdir/$old_library" func_append old_convenience " $ladir/$objdir/$old_library" + tmp_libs= + for deplib in $dependency_libs; do + deplibs="$deplib $deplibs" + if $opt_preserve_dup_deps; then + case "$tmp_libs " in + *" $deplib "*) func_append specialdeplibs " $deplib" ;; + esac + fi + func_append tmp_libs " $deplib" + done elif test prog != "$linkmode" && test lib != "$linkmode"; then func_fatal_error "'$lib' is not a convenience library" fi - tmp_libs= - for deplib in $dependency_libs; do - deplibs="$deplib $deplibs" - if $opt_preserve_dup_deps; then - case "$tmp_libs " in - *" $deplib "*) func_append specialdeplibs " $deplib" ;; - esac - fi - func_append tmp_libs " $deplib" - done continue fi # $pass = conv @@ -9102,6 +9118,9 @@ func_mode_link () revision=$number_minor lt_irix_increment=no ;; + *) + func_fatal_configuration "$modename: unknown library version type '$version_type'" + ;; esac ;; no) diff --git a/buildutil/glibtests.m4 b/buildutil/glibtests.m4 index 108c8478..34dfcf67 100644 --- a/buildutil/glibtests.m4 +++ b/buildutil/glibtests.m4 @@ -25,7 +25,7 @@ AC_DEFUN([GLIB_TESTS], *) AC_MSG_ERROR([bad value ${enableval} for --enable-always-build-tests]) ;; esac]) AM_CONDITIONAL([ENABLE_ALWAYS_BUILD_TESTS], test "$ENABLE_ALWAYS_BUILD_TESTS" = "1") - if test "$ENABLE_INSTALLED_TESTS" == "1"; then + if test "$ENABLE_INSTALLED_TESTS" = "1"; then AC_SUBST(installed_test_metadir, [${datadir}/installed-tests/]AC_PACKAGE_NAME) AC_SUBST(installed_testdir, [${libexecdir}/installed-tests/]AC_PACKAGE_NAME) fi diff --git a/buildutil/libtool.m4 b/buildutil/libtool.m4 index e3adedad..e7b68334 100644 --- a/buildutil/libtool.m4 +++ b/buildutil/libtool.m4 @@ -730,7 +730,6 @@ _LT_CONFIG_SAVE_COMMANDS([ cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. @@ -2887,9 +2886,6 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) # before this can be enabled. hardcode_into_libs=yes - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command @@ -2898,7 +2894,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on @@ -2910,6 +2906,18 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no @@ -3569,7 +3577,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; -netbsd*) +netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else @@ -4075,7 +4083,8 @@ _LT_EOF if AC_TRY_EVAL(ac_compile); then # Now try to grab the symbols. nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then + $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&AS_MESSAGE_LOG_FD + if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&AS_MESSAGE_LOG_FD && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" @@ -4447,7 +4456,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise @@ -4715,6 +4724,12 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; + # flang / f18. f95 an alias for gfortran or flang on Debian + flang* | f18* | f95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) @@ -4959,6 +4974,9 @@ m4_if([$1], [CXX], [ ;; esac ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; @@ -5021,6 +5039,9 @@ dnl Note also adjust exclude_expsyms for C++ above. openbsd* | bitrig*) with_gnu_ld=no ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes @@ -5256,6 +5277,7 @@ _LT_EOF case $cc_basename in tcc*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) @@ -5276,7 +5298,7 @@ _LT_EOF fi ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= @@ -5797,6 +5819,7 @@ _LT_EOF if test yes = "$lt_cv_irix_exported_symbol"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi + _LT_TAGVAR(link_all_deplibs, $1)=no else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' @@ -5814,11 +5837,12 @@ _LT_EOF # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(ld_shlibs, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else @@ -6445,7 +6469,7 @@ if test yes != "$_lt_caught_CXX_error"; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else GXX=no @@ -6821,7 +6845,7 @@ if test yes != "$_lt_caught_CXX_error"; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then @@ -6886,7 +6910,7 @@ if test yes != "$_lt_caught_CXX_error"; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then @@ -7225,7 +7249,7 @@ if test yes != "$_lt_caught_CXX_error"; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else # FIXME: insert proper C++ library support @@ -7309,7 +7333,7 @@ if test yes != "$_lt_caught_CXX_error"; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. @@ -7320,7 +7344,7 @@ if test yes != "$_lt_caught_CXX_error"; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' diff --git a/configure b/configure index fd6ffa7e..8e6334e5 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.71 for libostree 2022.5. +# Generated by GNU Autoconf 2.71 for libostree 2022.6. # # Report bugs to . # @@ -621,8 +621,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='libostree' PACKAGE_TARNAME='libostree' -PACKAGE_VERSION='2022.5' -PACKAGE_STRING='libostree 2022.5' +PACKAGE_VERSION='2022.6' +PACKAGE_STRING='libostree 2022.6' PACKAGE_BUGREPORT='walters@verbum.org' PACKAGE_URL='' @@ -1599,7 +1599,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures libostree 2022.5 to adapt to many kinds of systems. +\`configure' configures libostree 2022.6 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1670,7 +1670,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of libostree 2022.5:";; + short | recursive ) echo "Configuration of libostree 2022.6:";; esac cat <<\_ACEOF @@ -1934,7 +1934,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -libostree configure 2022.5 +libostree configure 2022.6 generated by GNU Autoconf 2.71 Copyright (C) 2021 Free Software Foundation, Inc. @@ -2307,7 +2307,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by libostree $as_me 2022.5, which was +It was created by libostree $as_me 2022.6, which was generated by GNU Autoconf 2.71. Invocation command line was $ $0$ac_configure_args_raw @@ -3584,7 +3584,7 @@ fi # Define the identity of the package. PACKAGE='libostree' - VERSION='2022.5' + VERSION='2022.6' # Some tools Automake needs. @@ -6462,9 +6462,9 @@ test -n "$YACC" || YACC="yacc" YEAR_VERSION=2022 -RELEASE_VERSION=5 +RELEASE_VERSION=6 -PACKAGE_VERSION=2022.5 +PACKAGE_VERSION=2022.6 pkglibexecdir=$libexecdir/$PACKAGE @@ -8065,7 +8065,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; -netbsd*) +netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else @@ -8988,11 +8988,8 @@ _LT_EOF test $ac_status = 0; }; then # Now try to grab the symbols. nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 - ac_status=$? - printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then + $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&5 + if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&5 && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" @@ -11147,6 +11144,12 @@ lt_prog_compiler_static= lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; + # flang / f18. f95 an alias for gfortran or flang on Debian + flang* | f18* | f95*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) @@ -11628,6 +11631,9 @@ printf %s "checking whether the $compiler linker ($LD) supports shared libraries openbsd* | bitrig*) with_gnu_ld=no ;; + linux* | k*bsd*-gnu | gnu*) + link_all_deplibs=no + ;; esac ld_shlibs=yes @@ -11863,6 +11869,7 @@ _LT_EOF case $cc_basename in tcc*) + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' export_dynamic_flag_spec='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) @@ -11883,7 +11890,7 @@ _LT_EOF fi ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= @@ -12560,6 +12567,7 @@ printf "%s\n" "$lt_cv_irix_exported_symbol" >&6; } if test yes = "$lt_cv_irix_exported_symbol"; then archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi + link_all_deplibs=no else archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' @@ -12577,11 +12585,12 @@ printf "%s\n" "$lt_cv_irix_exported_symbol" >&6; } # Fabrice Bellard et al's Tiny C Compiler ld_shlibs=yes archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' ;; esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else @@ -13681,9 +13690,6 @@ fi # before this can be enabled. hardcode_into_libs=yes - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command @@ -13692,7 +13698,7 @@ fi # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on @@ -13704,6 +13710,18 @@ fi dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no @@ -14777,7 +14795,7 @@ else ENABLE_ALWAYS_BUILD_TESTS_FALSE= fi - if test "$ENABLE_INSTALLED_TESTS" == "1"; then + if test "$ENABLE_INSTALLED_TESTS" = "1"; then installed_test_metadir=${datadir}/installed-tests/libostree installed_testdir=${libexecdir}/installed-tests/libostree @@ -15427,8 +15445,8 @@ fi pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GLIB" >&5 -printf %s "checking for GLIB... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $pkg_config_args" >&5 +printf %s "checking for $pkg_config_args... " >&6; } if test -n "$GLIB_CFLAGS"; then pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" @@ -15468,7 +15486,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -15486,7 +15504,7 @@ fi : elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } : else @@ -15782,8 +15800,8 @@ rm -f core conftest.err conftest.$ac_objext conftest.beam \ GIO_DEPENDENCY="gio-unix-2.0 >= 2.66.0" pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_GIO_UNIX" >&5 -printf %s "checking for OT_DEP_GIO_UNIX... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $GIO_DEPENDENCY" >&5 +printf %s "checking for $GIO_DEPENDENCY... " >&6; } if test -n "$OT_DEP_GIO_UNIX_CFLAGS"; then pkg_cv_OT_DEP_GIO_UNIX_CFLAGS="$OT_DEP_GIO_UNIX_CFLAGS" @@ -15823,7 +15841,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -15850,7 +15868,7 @@ Alternatively, you may set the environment variables OT_DEP_GIO_UNIX_CFLAGS and OT_DEP_GIO_UNIX_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -15874,8 +15892,8 @@ fi pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_LZMA" >&5 -printf %s "checking for OT_DEP_LZMA... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for liblzma >= 5.0.5" >&5 +printf %s "checking for liblzma >= 5.0.5... " >&6; } if test -n "$OT_DEP_LZMA_CFLAGS"; then pkg_cv_OT_DEP_LZMA_CFLAGS="$OT_DEP_LZMA_CFLAGS" @@ -15915,7 +15933,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -15942,7 +15960,7 @@ Alternatively, you may set the environment variables OT_DEP_LZMA_CFLAGS and OT_DEP_LZMA_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -15966,8 +15984,8 @@ fi pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_ZLIB" >&5 -printf %s "checking for OT_DEP_ZLIB... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zlib" >&5 +printf %s "checking for zlib... " >&6; } if test -n "$OT_DEP_ZLIB_CFLAGS"; then pkg_cv_OT_DEP_ZLIB_CFLAGS="$OT_DEP_ZLIB_CFLAGS" @@ -16007,7 +16025,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -16034,7 +16052,7 @@ Alternatively, you may set the environment variables OT_DEP_ZLIB_CFLAGS and OT_DEP_ZLIB_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -16058,8 +16076,8 @@ fi pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_E2P" >&5 -printf %s "checking for OT_DEP_E2P... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for e2p" >&5 +printf %s "checking for e2p... " >&6; } if test -n "$OT_DEP_E2P_CFLAGS"; then pkg_cv_OT_DEP_E2P_CFLAGS="$OT_DEP_E2P_CFLAGS" @@ -16099,7 +16117,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -16126,7 +16144,7 @@ Alternatively, you may set the environment variables OT_DEP_E2P_CFLAGS and OT_DEP_E2P_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -16163,8 +16181,8 @@ then : pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_CURL" >&5 -printf %s "checking for OT_DEP_CURL... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libcurl >= $CURL_DEPENDENCY" >&5 +printf %s "checking for libcurl >= $CURL_DEPENDENCY... " >&6; } if test -n "$OT_DEP_CURL_CFLAGS"; then pkg_cv_OT_DEP_CURL_CFLAGS="$OT_DEP_CURL_CFLAGS" @@ -16204,7 +16222,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -16231,7 +16249,7 @@ Alternatively, you may set the environment variables OT_DEP_CURL_CFLAGS and OT_DEP_CURL_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -16337,8 +16355,8 @@ then : pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_SOUP" >&5 -printf %s "checking for OT_DEP_SOUP... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $SOUP_DEPENDENCY" >&5 +printf %s "checking for $SOUP_DEPENDENCY... " >&6; } if test -n "$OT_DEP_SOUP_CFLAGS"; then pkg_cv_OT_DEP_SOUP_CFLAGS="$OT_DEP_SOUP_CFLAGS" @@ -16378,7 +16396,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -16405,7 +16423,7 @@ Alternatively, you may set the environment variables OT_DEP_SOUP_CFLAGS and OT_DEP_SOUP_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -16805,8 +16823,8 @@ then : pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_GPGME" >&5 -printf %s "checking for OT_DEP_GPGME... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gpgme-pthread >= $LIBGPGME_DEPENDENCY" >&5 +printf %s "checking for gpgme-pthread >= $LIBGPGME_DEPENDENCY... " >&6; } if test -n "$OT_DEP_GPGME_CFLAGS"; then pkg_cv_OT_DEP_GPGME_CFLAGS="$OT_DEP_GPGME_CFLAGS" @@ -16846,7 +16864,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -16960,7 +16978,7 @@ printf "%s\n" "no" >&6; } elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } @@ -17075,8 +17093,8 @@ fi OSTREE_FEATURES="$OSTREE_FEATURES gpgme" pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_GPG_ERROR" >&5 -printf %s "checking for OT_DEP_GPG_ERROR... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gpg-error" >&5 +printf %s "checking for gpg-error... " >&6; } if test -n "$OT_DEP_GPG_ERROR_CFLAGS"; then pkg_cv_OT_DEP_GPG_ERROR_CFLAGS="$OT_DEP_GPG_ERROR_CFLAGS" @@ -17116,7 +17134,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -17183,7 +17201,7 @@ fi OT_DEP_GPG_ERROR_LIBS="$( $GPG_ERROR_CONFIG --libs )" elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } # Extract the first word of "gpg-error-config", so it can be a program name with args. @@ -17282,8 +17300,8 @@ printf "%s\n" "#define HAVE_LIBSODIUM 1" >>confdefs.h pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_LIBSODIUM" >&5 -printf %s "checking for OT_DEP_LIBSODIUM... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libsodium >= $LIBSODIUM_DEPENDENCY" >&5 +printf %s "checking for libsodium >= $LIBSODIUM_DEPENDENCY... " >&6; } if test -n "$OT_DEP_LIBSODIUM_CFLAGS"; then pkg_cv_OT_DEP_LIBSODIUM_CFLAGS="$OT_DEP_LIBSODIUM_CFLAGS" @@ -17323,7 +17341,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -17341,7 +17359,7 @@ fi have_libsodium=no elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } have_libsodium=no else @@ -17638,8 +17656,8 @@ printf "%s\n" "$enable_gtk_doc" >&6; } if test "x$PACKAGE_NAME" != "xglib"; then pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GTKDOC_DEPS" >&5 -printf %s "checking for GTKDOC_DEPS... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0" >&5 +printf %s "checking for glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0... " >&6; } if test -n "$GTKDOC_DEPS_CFLAGS"; then pkg_cv_GTKDOC_DEPS_CFLAGS="$GTKDOC_DEPS_CFLAGS" @@ -17679,7 +17697,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -17697,7 +17715,7 @@ fi : elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } : else @@ -17935,8 +17953,8 @@ printf "%s\n" "#define HAVE_LIBARCHIVE 1" >>confdefs.h pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_LIBARCHIVE" >&5 -printf %s "checking for OT_DEP_LIBARCHIVE... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $LIBARCHIVE_DEPENDENCY" >&5 +printf %s "checking for $LIBARCHIVE_DEPENDENCY... " >&6; } if test -n "$OT_DEP_LIBARCHIVE_CFLAGS"; then pkg_cv_OT_DEP_LIBARCHIVE_CFLAGS="$OT_DEP_LIBARCHIVE_CFLAGS" @@ -17976,7 +17994,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -18003,7 +18021,7 @@ Alternatively, you may set the environment variables OT_DEP_LIBARCHIVE_CFLAGS and OT_DEP_LIBARCHIVE_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -18098,8 +18116,8 @@ printf "%s\n" "#define HAVE_SELINUX 1" >>confdefs.h pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_SELINUX" >&5 -printf %s "checking for OT_DEP_SELINUX... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $SELINUX_DEPENDENCY" >&5 +printf %s "checking for $SELINUX_DEPENDENCY... " >&6; } if test -n "$OT_DEP_SELINUX_CFLAGS"; then pkg_cv_OT_DEP_SELINUX_CFLAGS="$OT_DEP_SELINUX_CFLAGS" @@ -18139,7 +18157,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -18166,7 +18184,7 @@ Alternatively, you may set the environment variables OT_DEP_SELINUX_CFLAGS and OT_DEP_SELINUX_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -18273,8 +18291,8 @@ then : pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_CRYPTO" >&5 -printf %s "checking for OT_DEP_CRYPTO... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $OPENSSL_DEPENDENCY" >&5 +printf %s "checking for $OPENSSL_DEPENDENCY... " >&6; } if test -n "$OT_DEP_CRYPTO_CFLAGS"; then pkg_cv_OT_DEP_CRYPTO_CFLAGS="$OT_DEP_CRYPTO_CFLAGS" @@ -18314,7 +18332,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -18341,7 +18359,7 @@ Alternatively, you may set the environment variables OT_DEP_CRYPTO_CFLAGS and OT_DEP_CRYPTO_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -18389,8 +18407,8 @@ then : pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_CRYPTO" >&5 -printf %s "checking for OT_DEP_CRYPTO... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $GNUTLS_DEPENDENCY" >&5 +printf %s "checking for $GNUTLS_DEPENDENCY... " >&6; } if test -n "$OT_DEP_CRYPTO_CFLAGS"; then pkg_cv_OT_DEP_CRYPTO_CFLAGS="$OT_DEP_CRYPTO_CFLAGS" @@ -18430,7 +18448,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -18457,7 +18475,7 @@ Alternatively, you may set the environment variables OT_DEP_CRYPTO_CFLAGS and OT_DEP_CRYPTO_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -18536,8 +18554,8 @@ printf "%s\n" "#define HAVE_AVAHI 1" >>confdefs.h pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_AVAHI" >&5 -printf %s "checking for OT_DEP_AVAHI... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $AVAHI_DEPENDENCY" >&5 +printf %s "checking for $AVAHI_DEPENDENCY... " >&6; } if test -n "$OT_DEP_AVAHI_CFLAGS"; then pkg_cv_OT_DEP_AVAHI_CFLAGS="$OT_DEP_AVAHI_CFLAGS" @@ -18577,7 +18595,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -18604,7 +18622,7 @@ Alternatively, you may set the environment variables OT_DEP_AVAHI_CFLAGS and OT_DEP_AVAHI_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -18689,8 +18707,8 @@ printf "%s\n" "#define HAVE_LIBMOUNT 1" >>confdefs.h pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OT_DEP_LIBMOUNT" >&5 -printf %s "checking for OT_DEP_LIBMOUNT... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $LIBMOUNT_DEPENDENCY" >&5 +printf %s "checking for $LIBMOUNT_DEPENDENCY... " >&6; } if test -n "$OT_DEP_LIBMOUNT_CFLAGS"; then pkg_cv_OT_DEP_LIBMOUNT_CFLAGS="$OT_DEP_LIBMOUNT_CFLAGS" @@ -18730,7 +18748,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -18757,7 +18775,7 @@ Alternatively, you may set the environment variables OT_DEP_LIBMOUNT_CFLAGS and OT_DEP_LIBMOUNT_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -18823,8 +18841,8 @@ then : pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for FUSE3" >&5 -printf %s "checking for FUSE3... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $FUSE3_DEPENDENCY" >&5 +printf %s "checking for $FUSE3_DEPENDENCY... " >&6; } if test -n "$FUSE3_CFLAGS"; then pkg_cv_FUSE3_CFLAGS="$FUSE3_CFLAGS" @@ -18864,7 +18882,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -18882,8 +18900,8 @@ fi pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for FUSE" >&5 -printf %s "checking for FUSE... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $FUSE_DEPENDENCY" >&5 +printf %s "checking for $FUSE_DEPENDENCY... " >&6; } if test -n "$FUSE_CFLAGS"; then pkg_cv_FUSE_CFLAGS="$FUSE_CFLAGS" @@ -18923,7 +18941,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -18950,7 +18968,7 @@ Alternatively, you may set the environment variables FUSE_CFLAGS and FUSE_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -18976,12 +18994,12 @@ printf "%s\n" "yes" >&6; } fi elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for FUSE" >&5 -printf %s "checking for FUSE... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $FUSE_DEPENDENCY" >&5 +printf %s "checking for $FUSE_DEPENDENCY... " >&6; } if test -n "$FUSE_CFLAGS"; then pkg_cv_FUSE_CFLAGS="$FUSE_CFLAGS" @@ -19021,7 +19039,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -19048,7 +19066,7 @@ Alternatively, you may set the environment variables FUSE_CFLAGS and FUSE_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -19193,8 +19211,8 @@ printf "%s\n" "#define HAVE_LIBSYSTEMD 1" >>confdefs.h pkg_failed=no -{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for LIBSYSTEMD" >&5 -printf %s "checking for LIBSYSTEMD... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libsystemd" >&5 +printf %s "checking for libsystemd... " >&6; } if test -n "$LIBSYSTEMD_CFLAGS"; then pkg_cv_LIBSYSTEMD_CFLAGS="$LIBSYSTEMD_CFLAGS" @@ -19234,7 +19252,7 @@ fi if test $pkg_failed = yes; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then @@ -19261,7 +19279,7 @@ Alternatively, you may set the environment variables LIBSYSTEMD_CFLAGS and LIBSYSTEMD_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 printf "%s\n" "no" >&6; } { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} @@ -20258,7 +20276,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by libostree $as_me 2022.5, which was +This file was extended by libostree $as_me 2022.6, which was generated by GNU Autoconf 2.71. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -20326,7 +20344,7 @@ ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -libostree config.status 2022.5 +libostree config.status 2022.6 configured by $0, generated by GNU Autoconf 2.71, with options \\"\$ac_cs_config\\" @@ -21453,7 +21471,6 @@ See \`config.log' for more details" "$LINENO" 5; } cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. diff --git a/configure.ac b/configure.ac index 964df128..83ccbdbd 100644 --- a/configure.ac +++ b/configure.ac @@ -1,7 +1,7 @@ AC_PREREQ([2.63]) dnl To perform a release, follow the instructions in `docs/CONTRIBUTING.md`. m4_define([year_version], [2022]) -m4_define([release_version], [5]) +m4_define([release_version], [6]) m4_define([package_version], [year_version.release_version]) AC_INIT([libostree], [package_version], [walters@verbum.org]) is_release_build=yes diff --git a/libglnx/glnx-fdio.c b/libglnx/glnx-fdio.c index ee69aa12..b1af6793 100644 --- a/libglnx/glnx-fdio.c +++ b/libglnx/glnx-fdio.c @@ -794,10 +794,21 @@ glnx_regfile_copy_bytes (int fdf, int fdt, off_t max_bytes) /* If we've requested to copy the whole range, try a full-file clone first. */ - if (max_bytes == (off_t) -1) + if (max_bytes == (off_t) -1 && + lseek (fdf, 0, SEEK_CUR) == 0 && + lseek (fdt, 0, SEEK_CUR) == 0) { if (ioctl (fdt, FICLONE, fdf) == 0) - return 0; + { + /* All the other methods advance the fds. Do it here too for consistency. */ + if (lseek (fdf, 0, SEEK_END) < 0) + return -1; + if (lseek (fdt, 0, SEEK_END) < 0) + return -1; + + return 0; + } + /* Fall through */ struct stat stbuf; diff --git a/man/ostree-checkout.xml b/man/ostree-checkout.xml index 4ed53a91..8f7d4f9b 100644 --- a/man/ostree-checkout.xml +++ b/man/ostree-checkout.xml @@ -114,6 +114,17 @@ License along with this library. If not, see . + + + + + Enable overlayfs whiteout extraction into 0:0 character devices. + Overlayfs whiteouts are encoded inside ostree as .ostree-wh.filename + and extracted as 0:0 character devices. This is useful to carry + container storage embedded into ostree. + + + diff --git a/man/ostree-rev-parse.xml b/man/ostree-rev-parse.xml index 74c585fd..f39868a6 100644 --- a/man/ostree-rev-parse.xml +++ b/man/ostree-rev-parse.xml @@ -54,6 +54,19 @@ License along with this library. If not, see . + + Options + + + , + + + If the repository has exactly one commit, then print it; any other case will result in an error. + + + + + Description diff --git a/src/boot/ostree-finalize-staged-hold.service b/src/boot/ostree-finalize-staged-hold.service new file mode 100644 index 00000000..85b5d543 --- /dev/null +++ b/src/boot/ostree-finalize-staged-hold.service @@ -0,0 +1,35 @@ +# Copyright (C) 2018 Red Hat, Inc. +# Copyright (C) 2022 Endless OS Foundation LLC +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2 of the License, or (at your option) any later version. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library. If not, see . + +# See https://github.com/ostreedev/ostree/pull/2543 for background. +[Unit] +Description=Hold /boot Open for OSTree Finalize Staged Deployment +Documentation=man:ostree(1) +ConditionPathExists=/run/ostree-booted +DefaultDependencies=no + +RequiresMountsFor=/sysroot /boot +After=local-fs.target +Before=basic.target final.target + +[Service] +Type=exec + +# This is explicitly run in the root namespace to ensure an automounted +# /boot doesn't time out since autofs doesn't handle mount namespaces. +# +# https://bugzilla.redhat.com/show_bug.cgi?id=2056090 +ExecStart=+/usr/bin/ostree admin finalize-staged --hold diff --git a/src/boot/ostree-finalize-staged.service b/src/boot/ostree-finalize-staged.service index 2f28bbb7..63621ce1 100644 --- a/src/boot/ostree-finalize-staged.service +++ b/src/boot/ostree-finalize-staged.service @@ -29,6 +29,11 @@ Before=basic.target final.target After=systemd-journal-flush.service Conflicts=final.target +# Start the hold unit and ensure it stays active throughout this +# service. +Wants=ostree-finalize-staged-hold.service +After=ostree-finalize-staged-hold.service + [Service] Type=oneshot RemainAfterExit=yes diff --git a/src/libostree/ostree-bootconfig-parser.c b/src/libostree/ostree-bootconfig-parser.c index e005fab9..08259ebf 100644 --- a/src/libostree/ostree-bootconfig-parser.c +++ b/src/libostree/ostree-bootconfig-parser.c @@ -73,7 +73,7 @@ ostree_bootconfig_parser_parse_at (OstreeBootconfigParser *self, GCancellable *cancellable, GError **error) { - g_return_val_if_fail (!self->parsed, FALSE); + g_assert (!self->parsed); g_autofree char *contents = glnx_file_get_contents_utf8_at (dfd, path, NULL, cancellable, error); if (!contents) diff --git a/src/libostree/ostree-bootloader-zipl.c b/src/libostree/ostree-bootloader-zipl.c index 0ff350f9..05a3b2ac 100644 --- a/src/libostree/ostree-bootloader-zipl.c +++ b/src/libostree/ostree-bootloader-zipl.c @@ -20,6 +20,7 @@ #include "ostree-sysroot-private.h" #include "ostree-bootloader-zipl.h" #include "ostree-deployment-private.h" +#include "ostree-libarchive-private.h" #include "otutil.h" #include #include @@ -34,7 +35,10 @@ #define SECURE_EXECUTION_LUKS_ROOT_KEY "/etc/luks/root" #define SECURE_EXECUTION_LUKS_BOOT_KEY "/etc/luks/boot" #define SECURE_EXECUTION_LUKS_CONFIG "/etc/crypttab" -#define SECURE_EXECUTION_RAMDISK_TOOL PKGLIBEXECDIR "/s390x-se-luks-gencpio" + +#if !(defined HAVE_LIBARCHIVE) && defined(__s390x__) +#error libarchive is required for s390x +#endif /* This is specific to zipl today, but in the future we could also * use it for the grub2-mkconfig case. @@ -195,31 +199,86 @@ static gboolean _ostree_secure_execution_luks_key_exists (void) { return (access(SECURE_EXECUTION_LUKS_CONFIG, F_OK) == 0 && - (access(SECURE_EXECUTION_LUKS_ROOT_KEY, F_OK) == 0 || access(SECURE_EXECUTION_LUKS_BOOT_KEY, F_OK) == 0)); + access(SECURE_EXECUTION_LUKS_ROOT_KEY, F_OK) == 0 && + access(SECURE_EXECUTION_LUKS_BOOT_KEY, F_OK) == 0); } static gboolean -_ostree_secure_execution_enable_luks(const gchar *oldramfs, - const gchar *newramfs, - GError **error) +_ostree_secure_execution_append_luks_keys (int initrd_fd, + GCancellable *cancellable, + GError **error) { - const char *const argv[] = {SECURE_EXECUTION_RAMDISK_TOOL, oldramfs, newramfs, NULL}; - g_autofree gchar *out = NULL; - g_autofree gchar *err = NULL; - int status = 0; - if (!g_spawn_sync (NULL, (char**)argv, NULL, G_SPAWN_SEARCH_PATH, - NULL, NULL, &out, &err, &status, error)) - return glnx_prefix_error(error, "s390x SE: spawning %s", SECURE_EXECUTION_RAMDISK_TOOL); +#ifdef HAVE_LIBARCHIVE + // appending cpio gzip archive with LUKS keys + g_autoptr(OtAutoArchiveWrite) a = archive_write_new (); + g_assert (a != NULL); - if (!g_spawn_check_exit_status (status, error)) + if (archive_write_set_format_cpio_newc (a) != 0 || + archive_write_add_filter_gzip (a) != 0 || + archive_write_open_fd(a, initrd_fd) != 0) + return glnx_prefix_error (error, "s390x SE: initing cpio: %s", archive_error_string (a)); + + const char *files[] = {"/etc", "/etc/luks", SECURE_EXECUTION_LUKS_CONFIG, SECURE_EXECUTION_LUKS_BOOT_KEY, SECURE_EXECUTION_LUKS_ROOT_KEY}; + for (uint i = 0; i != G_N_ELEMENTS (files); ++i) { - g_printerr("s390x SE: `%s` stdout: %s\n", SECURE_EXECUTION_RAMDISK_TOOL, out); - g_printerr("s390x SE: `%s` stderr: %s\n", SECURE_EXECUTION_RAMDISK_TOOL, err); - return glnx_prefix_error(error, "s390x SE: `%s` failed", SECURE_EXECUTION_RAMDISK_TOOL); - } + const char *path = files[i]; + struct stat st; + if (stat(path, &st) != 0) + glnx_throw_errno_prefix (error, "s390x SE: stat(%s) failed", path); - ot_journal_print(LOG_INFO, "s390x SE: luks key added to initrd"); + g_autoptr(OtArchiveEntry) ae = archive_entry_new (); + g_assert (ae != NULL); + + archive_entry_copy_stat (ae, &st); + archive_entry_set_pathname (ae, path); + if (archive_write_header (a, ae) != 0) + glnx_prefix_error (error, "s390x SE: writing cpio header: %s", archive_error_string (a)); + + if (S_ISREG (st.st_mode)) + { + ot_journal_print(LOG_INFO, "s390x SE: appending %s to initrd", path); + glnx_autofd int fd = -1; + if (!glnx_openat_rdonly (AT_FDCWD, path, TRUE, &fd, error)) + return glnx_prefix_error (error, "s390x SE: opening %s", path); + g_autoptr(GBytes) data = glnx_fd_readall_bytes (fd, cancellable, error); + if (!data) + return glnx_prefix_error (error, "s390x SE: reading %s", path); + + gsize size = 0; + const char *ptr = (const char *) g_bytes_get_data (data, &size); + ssize_t written = archive_write_data (a, ptr, size); + if (written == -1) + return glnx_prefix_error (error, "s390x SE: writing cpio entry: %s", archive_error_string (a)); + if (written != size) + return glnx_prefix_error (error, "s390x SE: writing cpio entry %zd != %zu", written, size); + } + } + ot_journal_print(LOG_INFO, "s390x SE: luks keys added to initrd"); return TRUE; + #else + return glnx_throw (error, "'libarchive' is required for s390x"); + #endif +} + +static gboolean +_ostree_secure_execution_generate_initrd (const gchar *initrd, + GLnxTmpfile *out_initrd, + GCancellable *cancellable, + GError **error) +{ + if (!_ostree_secure_execution_luks_key_exists ()) + return glnx_throw (error, "s390x SE: missing luks keys and config"); + + if (!glnx_open_anonymous_tmpfile (O_RDWR | O_CLOEXEC, out_initrd, error)) + return glnx_prefix_error (error, "s390x SE: opening new ramdisk"); + { + glnx_autofd int fd = -1; + glnx_openat_rdonly (AT_FDCWD, initrd, TRUE, &fd, error); + if (glnx_regfile_copy_bytes (fd, out_initrd->fd, (off_t) -1) < 0) + return glnx_throw_errno_prefix (error, "s390x SE: copying ramdisk"); + } + + return _ostree_secure_execution_append_luks_keys (out_initrd->fd, cancellable, error); } static gboolean @@ -227,6 +286,7 @@ _ostree_secure_execution_generate_sdboot (gchar *vmlinuz, gchar *initramfs, gchar *options, GPtrArray *keys, + GCancellable *cancellable, GError **error) { g_assert (vmlinuz && initramfs && options && keys && keys->len); @@ -234,34 +294,28 @@ _ostree_secure_execution_generate_sdboot (gchar *vmlinuz, ot_journal_print(LOG_INFO, "s390x SE: initrd: %s", initramfs); ot_journal_print(LOG_INFO, "s390x SE: kargs: %s", options); - pid_t self = getpid(); + pid_t self = getpid (); // Store kernel options to temp file, so `genprotimg` can later embed it g_auto(GLnxTmpfile) cmdline = { 0, }; if (!glnx_open_anonymous_tmpfile (O_RDWR | O_CLOEXEC, &cmdline, error)) - return glnx_prefix_error(error, "s390x SE: opening cmdline file"); + return glnx_prefix_error (error, "s390x SE: opening cmdline file"); if (glnx_loop_write (cmdline.fd, options, strlen (options)) < 0) - return glnx_throw_errno_prefix (error, "s390x SE: writting cmdline file"); + return glnx_throw_errno_prefix (error, "s390x SE: writing cmdline file"); g_autofree gchar *cmdline_filename = g_strdup_printf ("/proc/%d/fd/%d", self, cmdline.fd); - // Copy initramfs to temp file and embed LUKS key and config into it + // Copy initramfs to temp file and embed LUKS keys & config into it g_auto(GLnxTmpfile) ramdisk = { 0, }; - g_autofree gchar *ramdisk_filename = NULL; - if (_ostree_secure_execution_luks_key_exists ()) - { - if (!glnx_open_anonymous_tmpfile (O_RDWR | O_CLOEXEC, &ramdisk, error)) - return glnx_prefix_error(error, "s390x SE: creating new ramdisk"); - ramdisk_filename = g_strdup_printf ("/proc/%d/fd/%d", self, ramdisk.fd); - if (!_ostree_secure_execution_enable_luks (initramfs, ramdisk_filename, error)) - return FALSE; - } + if (!_ostree_secure_execution_generate_initrd (initramfs, &ramdisk, cancellable, error)) + return FALSE; + g_autofree gchar *ramdisk_filename = g_strdup_printf ("/proc/%d/fd/%d", self, ramdisk.fd); g_autoptr(GPtrArray) argv = g_ptr_array_new (); g_ptr_array_add (argv, "genprotimg"); g_ptr_array_add (argv, "-i"); g_ptr_array_add (argv, vmlinuz); g_ptr_array_add (argv, "-r"); - g_ptr_array_add (argv, (ramdisk_filename == NULL) ? initramfs: ramdisk_filename); + g_ptr_array_add (argv, ramdisk_filename); g_ptr_array_add (argv, "-p"); g_ptr_array_add (argv, cmdline_filename); for (guint i = 0; i < keys->len; ++i) @@ -300,7 +354,7 @@ _ostree_secure_execution_call_zipl (GError **error) if (!g_spawn_check_exit_status (status, error)) return glnx_prefix_error(error, "s390x SE: `zipl` failed"); - ot_journal_print(LOG_INFO, "s390x SE: `sd-boot` zipled"); + ot_journal_print(LOG_INFO, "s390x SE: `sdboot` zipled"); return TRUE; } @@ -318,7 +372,7 @@ _ostree_secure_execution_enable (OstreeBootloaderZipl *self, gboolean rc = _ostree_secure_execution_mount (error) && _ostree_secure_execution_get_bls_config (self, bootversion, &vmlinuz, &initramfs, &options, cancellable, error) && - _ostree_secure_execution_generate_sdboot (vmlinuz, initramfs, options, keys, error) && + _ostree_secure_execution_generate_sdboot (vmlinuz, initramfs, options, keys, cancellable, error) && _ostree_secure_execution_call_zipl (error) && _ostree_secure_execution_umount (error); diff --git a/src/libostree/ostree-bootloader.c b/src/libostree/ostree-bootloader.c index 785fd233..790bf502 100644 --- a/src/libostree/ostree-bootloader.c +++ b/src/libostree/ostree-bootloader.c @@ -31,7 +31,7 @@ _ostree_bootloader_query (OstreeBootloader *self, GCancellable *cancellable, GError **error) { - g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), FALSE); + g_assert (OSTREE_IS_BOOTLOADER (self)); return OSTREE_BOOTLOADER_GET_IFACE (self)->query (self, out_is_active, cancellable, error); } @@ -44,7 +44,7 @@ _ostree_bootloader_query (OstreeBootloader *self, const char * _ostree_bootloader_get_name (OstreeBootloader *self) { - g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), NULL); + g_assert (OSTREE_IS_BOOTLOADER (self)); return OSTREE_BOOTLOADER_GET_IFACE (self)->get_name (self); } @@ -56,7 +56,7 @@ _ostree_bootloader_write_config (OstreeBootloader *self, GCancellable *cancellable, GError **error) { - g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), FALSE); + g_assert (OSTREE_IS_BOOTLOADER (self)); return OSTREE_BOOTLOADER_GET_IFACE (self)->write_config (self, bootversion, new_deployments, @@ -69,7 +69,7 @@ _ostree_bootloader_post_bls_sync (OstreeBootloader *self, GCancellable *cancellable, GError **error) { - g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), FALSE); + g_assert (OSTREE_IS_BOOTLOADER (self)); if (OSTREE_BOOTLOADER_GET_IFACE (self)->post_bls_sync) return OSTREE_BOOTLOADER_GET_IFACE (self)->post_bls_sync (self, bootversion, cancellable, error); @@ -80,7 +80,7 @@ _ostree_bootloader_post_bls_sync (OstreeBootloader *self, gboolean _ostree_bootloader_is_atomic (OstreeBootloader *self) { - g_return_val_if_fail (OSTREE_IS_BOOTLOADER (self), FALSE); + g_assert (OSTREE_IS_BOOTLOADER (self)); if (OSTREE_BOOTLOADER_GET_IFACE (self)->is_atomic) return OSTREE_BOOTLOADER_GET_IFACE (self)->is_atomic (self); diff --git a/src/libostree/ostree-fetcher-curl.c b/src/libostree/ostree-fetcher-curl.c index 75038ecc..522eacfb 100644 --- a/src/libostree/ostree-fetcher-curl.c +++ b/src/libostree/ostree-fetcher-curl.c @@ -882,8 +882,10 @@ initiate_next_curl_request (FetcherRequest *req, if (!(self->config_flags & OSTREE_FETCHER_FLAGS_DISABLE_HTTP2)) { #if CURL_AT_LEAST_VERSION(7, 51, 0) - rc = curl_easy_setopt (req->easy, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_2_0); - g_assert_cmpint (rc, ==, CURLM_OK); + if ((curl_version_info (CURLVERSION_NOW))->features & CURL_VERSION_HTTP2) { + rc = curl_easy_setopt (req->easy, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_2_0); + g_assert_cmpint (rc, ==, CURLM_OK); + } #endif /* https://github.com/curl/curl/blob/curl-7_53_0/docs/examples/http2-download.c */ #if (CURLPIPE_MULTIPLEX > 0) diff --git a/src/libostree/ostree-libarchive-private.h b/src/libostree/ostree-libarchive-private.h index 6e6daddb..4eaeaedb 100644 --- a/src/libostree/ostree-libarchive-private.h +++ b/src/libostree/ostree-libarchive-private.h @@ -38,6 +38,8 @@ G_BEGIN_DECLS #ifdef HAVE_LIBARCHIVE typedef struct archive OtAutoArchiveWrite; G_DEFINE_AUTOPTR_CLEANUP_FUNC(OtAutoArchiveWrite, archive_write_free) +typedef struct archive_entry OtArchiveEntry; +G_DEFINE_AUTOPTR_CLEANUP_FUNC(OtArchiveEntry, archive_entry_free) typedef struct archive OtAutoArchiveRead; G_DEFINE_AUTOPTR_CLEANUP_FUNC(OtAutoArchiveRead, archive_read_free) diff --git a/src/libostree/ostree-linuxfsutil.c b/src/libostree/ostree-linuxfsutil.c index 97f93604..aa389aaa 100644 --- a/src/libostree/ostree-linuxfsutil.c +++ b/src/libostree/ostree-linuxfsutil.c @@ -24,10 +24,12 @@ #include #include +// This should be the only file including linux/fs.h; see +// https://sourceware.org/glibc/wiki/Release/2.36#Usage_of_.3Clinux.2Fmount.h.3E_and_.3Csys.2Fmount.h.3E +// https://github.com/ostreedev/ostree/issues/2685 +#include #include -#include "otutil.h" - /** * _ostree_linuxfs_fd_alter_immutable_flag: * @fd: A file descriptor @@ -88,3 +90,21 @@ _ostree_linuxfs_fd_alter_immutable_flag (int fd, return TRUE; } + +/* Wrapper for FIFREEZE ioctl. + * This is split into a separate wrapped API for + * reasons around conflicts between glibc and linux/fs.h + * includes; see above. + */ +int +_ostree_linuxfs_filesystem_freeze (int fd) +{ + return TEMP_FAILURE_RETRY (ioctl (fd, FIFREEZE, 0)); +} + +/* Wrapper for FITHAW ioctl. See above. */ +int +_ostree_linuxfs_filesystem_thaw (int fd) +{ + return TEMP_FAILURE_RETRY (ioctl (fd, FITHAW, 0)); +} diff --git a/src/libostree/ostree-linuxfsutil.h b/src/libostree/ostree-linuxfsutil.h index 0654b6fc..9011c9d8 100644 --- a/src/libostree/ostree-linuxfsutil.h +++ b/src/libostree/ostree-linuxfsutil.h @@ -29,4 +29,7 @@ _ostree_linuxfs_fd_alter_immutable_flag (int fd, GCancellable *cancellable, GError **error); +int _ostree_linuxfs_filesystem_freeze (int fd); +int _ostree_linuxfs_filesystem_thaw (int fd); + G_END_DECLS diff --git a/src/libostree/ostree-mutable-tree.c b/src/libostree/ostree-mutable-tree.c index 58dd3c4c..60e3be2f 100644 --- a/src/libostree/ostree-mutable-tree.c +++ b/src/libostree/ostree-mutable-tree.c @@ -303,8 +303,6 @@ ostree_mutable_tree_replace_file (OstreeMutableTree *self, const char *checksum, GError **error) { - g_return_val_if_fail (name != NULL, FALSE); - if (!ot_util_filename_validate (name, error)) return FALSE; @@ -338,8 +336,6 @@ ostree_mutable_tree_remove (OstreeMutableTree *self, gboolean allow_noent, GError **error) { - g_return_val_if_fail (name != NULL, FALSE); - if (!ot_util_filename_validate (name, error)) return FALSE; @@ -374,8 +370,6 @@ ostree_mutable_tree_ensure_dir (OstreeMutableTree *self, OstreeMutableTree **out_subdir, GError **error) { - g_return_val_if_fail (name != NULL, FALSE); - if (!ot_util_filename_validate (name, error)) return FALSE; diff --git a/src/libostree/ostree-repo-checkout.c b/src/libostree/ostree-repo-checkout.c index 663292a9..7c7d0cc7 100644 --- a/src/libostree/ostree-repo-checkout.c +++ b/src/libostree/ostree-repo-checkout.c @@ -35,6 +35,8 @@ #define WHITEOUT_PREFIX ".wh." #define OPAQUE_WHITEOUT_NAME ".wh..wh..opq" +#define OVERLAYFS_WHITEOUT_PREFIX ".ostree-wh." + /* Per-checkout call state/caching */ typedef struct { GString *path_buf; /* buffer for real path if filtering enabled */ @@ -582,6 +584,117 @@ checkout_file_hardlink (OstreeRepo *self, return TRUE; } +static gboolean +_checkout_overlayfs_whiteout_at_no_overwrite (OstreeRepoCheckoutAtOptions *options, + int destination_dfd, + const char *destination_name, + GFileInfo *file_info, + GVariant *xattrs, + gboolean *found_exant_file, + GCancellable *cancellable, + GError **error) +{ + if (found_exant_file != NULL) + *found_exant_file = FALSE; + guint32 file_mode = g_file_info_get_attribute_uint32 (file_info, "unix::mode"); + if (mknodat(destination_dfd, destination_name, (file_mode & ~S_IFMT) | S_IFCHR, (dev_t)0) < 0) + { + if (errno == EEXIST && found_exant_file != NULL) + { + *found_exant_file = TRUE; + return TRUE; + } + return glnx_throw_errno_prefix (error, "Creating whiteout char device"); + } + if (options->mode != OSTREE_REPO_CHECKOUT_MODE_USER) + { + if (xattrs != NULL && + !glnx_dfd_name_set_all_xattrs(destination_dfd, destination_name, xattrs, + cancellable, error)) + return glnx_throw_errno_prefix (error, "Setting xattrs for whiteout char device"); + + if (TEMP_FAILURE_RETRY(fchownat(destination_dfd, destination_name, + g_file_info_get_attribute_uint32 (file_info, "unix::uid"), + g_file_info_get_attribute_uint32 (file_info, "unix::gid"), + AT_SYMLINK_NOFOLLOW) < 0)) + return glnx_throw_errno_prefix (error, "fchownat"); + if (TEMP_FAILURE_RETRY (fchmodat (destination_dfd, destination_name, file_mode & ~S_IFMT, 0)) < 0) + return glnx_throw_errno_prefix (error, "fchmodat %s to 0%o", destination_name, file_mode & ~S_IFMT); + } + + return TRUE; +} + +static gboolean +_checkout_overlayfs_whiteout_at (OstreeRepo *repo, + OstreeRepoCheckoutAtOptions *options, + int destination_dfd, + const char *destination_name, + GFileInfo *file_info, + GVariant *xattrs, + GCancellable *cancellable, + GError **error) +{ + gboolean found_exant_file = FALSE; + if (!_checkout_overlayfs_whiteout_at_no_overwrite(options, destination_dfd, destination_name, + file_info, xattrs,&found_exant_file, + cancellable, error)) + return FALSE; + + if (!found_exant_file) + return TRUE; + + guint32 uid = g_file_info_get_attribute_uint32 (file_info, "unix::uid"); + guint32 gid = g_file_info_get_attribute_uint32 (file_info, "unix::gid"); + guint32 file_mode = g_file_info_get_attribute_uint32 (file_info, "unix::mode"); + + struct stat dest_stbuf; + + switch(options->overwrite_mode) + { + case OSTREE_REPO_CHECKOUT_OVERWRITE_NONE: + return FALSE; + case OSTREE_REPO_CHECKOUT_OVERWRITE_UNION_FILES: + if (!ot_ensure_unlinked_at (destination_dfd, destination_name, error)) + return FALSE; + return _checkout_overlayfs_whiteout_at_no_overwrite(options, destination_dfd, destination_name, + file_info, xattrs, NULL, cancellable, error); + case OSTREE_REPO_CHECKOUT_OVERWRITE_ADD_FILES: + return TRUE; + + case OSTREE_REPO_CHECKOUT_OVERWRITE_UNION_IDENTICAL: + if (!glnx_fstatat(destination_dfd, destination_name, &dest_stbuf, AT_SYMLINK_NOFOLLOW, + error)) + return FALSE; + if (!(repo->disable_xattrs || repo->mode == OSTREE_REPO_MODE_BARE_USER_ONLY)) + { + g_autoptr(GVariant) fs_xattrs; + if (!glnx_dfd_name_get_all_xattrs (destination_dfd, destination_name, + &fs_xattrs, cancellable, error)) + return FALSE; + if (!g_variant_equal(fs_xattrs, xattrs)) + return glnx_throw(error, "existing destination file %s xattrs don't match", + destination_name); + } + if (options->mode != OSTREE_REPO_CHECKOUT_MODE_USER) + { + if (gid != dest_stbuf.st_gid) + return glnx_throw(error, "existing destination file %s does not match gid %d", + destination_name, gid); + + if (uid != dest_stbuf.st_uid) + return glnx_throw(error, "existing destination file %s does not match uid %d", + destination_name, gid); + + if ((file_mode & ALLPERMS) != (dest_stbuf.st_mode & ALLPERMS)) + return glnx_throw(error, "existing destination file %s does not match mode %o", + destination_name, file_mode); + } + break; + } + return TRUE; +} + static gboolean checkout_one_file_at (OstreeRepo *repo, OstreeRepoCheckoutAtOptions *options, @@ -603,7 +716,8 @@ checkout_one_file_at (OstreeRepo *repo, /* FIXME - avoid the GFileInfo here */ g_autoptr(GFileInfo) source_info = NULL; - if (!ostree_repo_load_file (repo, checksum, NULL, &source_info, NULL, + g_autoptr(GVariant) source_xattrs = NULL; + if (!ostree_repo_load_file (repo, checksum, NULL, &source_info, &source_xattrs, cancellable, error)) return FALSE; @@ -623,6 +737,7 @@ checkout_one_file_at (OstreeRepo *repo, const gboolean is_unreadable = (!is_symlink && (source_mode & S_IRUSR) == 0); const gboolean is_whiteout = (!is_symlink && options->process_whiteouts && g_str_has_prefix (destination_name, WHITEOUT_PREFIX)); + const gboolean is_overlayfs_whiteout = (!is_symlink && g_str_has_prefix (destination_name, OVERLAYFS_WHITEOUT_PREFIX)); const gboolean is_reg_zerosized = (!is_symlink && g_file_info_get_size (source_info) == 0); const gboolean override_user_unreadable = (options->mode == OSTREE_REPO_CHECKOUT_MODE_USER && is_unreadable); @@ -643,6 +758,18 @@ checkout_one_file_at (OstreeRepo *repo, need_copy = FALSE; } + else if (is_overlayfs_whiteout && options->process_passthrough_whiteouts) + { + const char *name = destination_name + (sizeof (OVERLAYFS_WHITEOUT_PREFIX) - 1); + + if (!name[0]) + return glnx_throw (error, "Invalid empty overlayfs whiteout '%s'", name); + + g_assert (name[0] != '/'); /* Sanity */ + + return _checkout_overlayfs_whiteout_at(repo, options, destination_dfd, name, + source_info, source_xattrs, cancellable, error); + } else if (is_reg_zerosized || override_user_unreadable) { /* In https://github.com/ostreedev/ostree/commit/673cacd633f9d6b653cdea530657d3e780a41bbd we diff --git a/src/libostree/ostree-repo-commit.c b/src/libostree/ostree-repo-commit.c index afab3fdf..c22864cd 100644 --- a/src/libostree/ostree-repo-commit.c +++ b/src/libostree/ostree-repo-commit.c @@ -30,7 +30,6 @@ #include #include #include -#include #include #include "otutil.h" @@ -882,11 +881,8 @@ _try_clone_from_payload_link (OstreeRepo *self, else { /* This undoes all of the previous writes; we want to generate reflinked data. */ - if (ftruncate (tmpf->fd, 0) < 0) - return glnx_throw_errno_prefix (error, "ftruncate"); - - if (glnx_regfile_copy_bytes (fdf, tmpf->fd, -1) < 0) - return glnx_throw_errno_prefix (error, "regfile copy"); + if (ioctl (tmpf->fd, FICLONE, fdf) < 0) + return glnx_throw_errno_prefix (error, "FICLONE"); return TRUE; } @@ -1749,7 +1745,7 @@ ostree_repo_prepare_transaction (OstreeRepo *self, return FALSE; /* Success: do not abort the transaction when returning. */ - txn->repo = NULL; (void) txn; + g_clear_object (&txn->repo); (void) txn; if (out_transaction_resume) *out_transaction_resume = ret_transaction_resume; diff --git a/src/libostree/ostree-repo-pull.c b/src/libostree/ostree-repo-pull.c index 4819a40a..86b4358a 100644 --- a/src/libostree/ostree-repo-pull.c +++ b/src/libostree/ostree-repo-pull.c @@ -3680,7 +3680,7 @@ all_requested_refs_have_commit (GHashTable *requested_refs /* (element-type Ostr * * `override-commit-ids` (`as`): Array of specific commit IDs to fetch for refs * * `timestamp-check` (`b`): Verify commit timestamps are newer than current (when pulling via ref); Since: 2017.11 * * `timestamp-check-from-rev` (`s`): Verify that all fetched commit timestamps are newer than timestamp of given rev; Since: 2020.4 - * * `metadata-size-restriction` (`t`): Restrict metadata objects to a maximum number of bytes; 0 to disable. Since: 2018.9 + * * `max-metadata-size` (`t`): Restrict metadata objects to a maximum number of bytes; 0 to disable. Since: 2018.9 * * `dry-run` (`b`): Only print information on what will be downloaded (requires static deltas) * * `override-url` (`s`): Fetch objects from this URL if remote specifies no metalink in options * * `inherit-transaction` (`b`): Don't initiate, finish or abort a transaction, useful to do multiple pulls in one transaction. diff --git a/src/libostree/ostree-repo-static-delta-compilation.c b/src/libostree/ostree-repo-static-delta-compilation.c index cf232c11..28b42139 100644 --- a/src/libostree/ostree-repo-static-delta-compilation.c +++ b/src/libostree/ostree-repo-static-delta-compilation.c @@ -1369,7 +1369,6 @@ ostree_repo_static_delta_generate (OstreeRepo *self, g_autoptr(GPtrArray) builder_parts = g_ptr_array_new_with_free_func ((GDestroyNotify)ostree_static_delta_part_builder_unref); g_autoptr(GPtrArray) builder_fallback_objects = g_ptr_array_new_with_free_func ((GDestroyNotify)g_variant_unref); g_auto(GLnxTmpfile) descriptor_tmpf = { 0, }; - g_autoptr(OtVariantBuilder) descriptor_builder = NULL; const char *opt_sign_name; const char **opt_key_ids; @@ -1456,7 +1455,10 @@ ostree_repo_static_delta_generate (OstreeRepo *self, &descriptor_tmpf, error)) return FALSE; - descriptor_builder = ot_variant_builder_new (G_VARIANT_TYPE (OSTREE_STATIC_DELTA_SUPERBLOCK_FORMAT), descriptor_tmpf.fd); + g_autoptr(OtVariantBuilder) descriptor_builder = + ot_variant_builder_new (G_VARIANT_TYPE (OSTREE_STATIC_DELTA_SUPERBLOCK_FORMAT), + descriptor_tmpf.fd); + g_assert (descriptor_builder != NULL); /* Open the metadata dict */ if (!ot_variant_builder_open (descriptor_builder, G_VARIANT_TYPE ("a{sv}"), error)) @@ -1603,7 +1605,6 @@ ostree_repo_static_delta_generate (OstreeRepo *self, const gchar *signature_key = NULL; g_autoptr(GVariantBuilder) signature_builder = NULL; g_auto(GLnxTmpfile) descriptor_sign_tmpf = { 0, }; - g_autoptr(OtVariantBuilder) descriptor_sign_builder = NULL; lseek (descriptor_tmpf.fd, 0, SEEK_SET); tmpdata = glnx_fd_readall_bytes (descriptor_tmpf.fd, cancellable, error); @@ -1640,8 +1641,10 @@ ostree_repo_static_delta_generate (OstreeRepo *self, &descriptor_sign_tmpf, error)) return FALSE; - descriptor_sign_builder = ot_variant_builder_new (G_VARIANT_TYPE (OSTREE_STATIC_DELTA_SIGNED_FORMAT), - descriptor_sign_tmpf.fd); + g_autoptr(OtVariantBuilder) descriptor_sign_builder = + ot_variant_builder_new (G_VARIANT_TYPE (OSTREE_STATIC_DELTA_SIGNED_FORMAT), + descriptor_sign_tmpf.fd); + g_assert (descriptor_sign_builder != NULL); if (!ot_variant_builder_add (descriptor_sign_builder, error, "t", GUINT64_TO_BE (OSTREE_STATIC_DELTA_SIGNED_MAGIC))) diff --git a/src/libostree/ostree-repo.c b/src/libostree/ostree-repo.c index 90cde651..7bdb3c4e 100644 --- a/src/libostree/ostree-repo.c +++ b/src/libostree/ostree-repo.c @@ -3514,7 +3514,7 @@ reload_sysroot_config (OstreeRepo *self, * https://github.com/ostreedev/ostree/issues/1719 * https://github.com/ostreedev/ostree/issues/1801 */ - gboolean valid_bootloader; + gboolean valid_bootloader = FALSE; for (int i = 0; CFG_SYSROOT_BOOTLOADER_OPTS_STR[i]; i++) { if (g_str_equal (bootloader, CFG_SYSROOT_BOOTLOADER_OPTS_STR[i])) diff --git a/src/libostree/ostree-repo.h b/src/libostree/ostree-repo.h index b7ed3600..ce9b2507 100644 --- a/src/libostree/ostree-repo.h +++ b/src/libostree/ostree-repo.h @@ -989,8 +989,9 @@ typedef struct { gboolean force_copy; /* Since: 2017.6 */ gboolean bareuseronly_dirs; /* Since: 2017.7 */ gboolean force_copy_zerosized; /* Since: 2018.9 */ - gboolean unused_bools[4]; - /* 4 byte hole on 64 bit */ + gboolean process_passthrough_whiteouts; + gboolean unused_bools[3]; + /* 3 byte hole on 64 bit */ const char *subpath; diff --git a/src/libostree/ostree-sign.c b/src/libostree/ostree-sign.c index 16e5d0f1..587d7164 100644 --- a/src/libostree/ostree-sign.c +++ b/src/libostree/ostree-sign.c @@ -96,8 +96,11 @@ ostree_sign_default_init (OstreeSignInterface *iface) const gchar * ostree_sign_metadata_key (OstreeSign *self) { + g_assert (OSTREE_IS_SIGN (self)); + + if (OSTREE_SIGN_GET_IFACE (self)->metadata_key == NULL) + return NULL; - g_return_val_if_fail (OSTREE_SIGN_GET_IFACE (self)->metadata_key != NULL, NULL); return OSTREE_SIGN_GET_IFACE (self)->metadata_key (self); } @@ -116,8 +119,11 @@ ostree_sign_metadata_key (OstreeSign *self) const gchar * ostree_sign_metadata_format (OstreeSign *self) { + g_assert (OSTREE_IS_SIGN (self)); + + if (OSTREE_SIGN_GET_IFACE (self)->metadata_format == NULL) + return NULL; - g_return_val_if_fail (OSTREE_SIGN_GET_IFACE (self)->metadata_format != NULL, NULL); return OSTREE_SIGN_GET_IFACE (self)->metadata_format (self); } @@ -136,7 +142,8 @@ gboolean ostree_sign_clear_keys (OstreeSign *self, GError **error) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); + g_assert (OSTREE_IS_SIGN (self)); + if (OSTREE_SIGN_GET_IFACE (self)->clear_keys == NULL) return glnx_throw (error, "not implemented"); @@ -163,7 +170,8 @@ ostree_sign_set_sk (OstreeSign *self, GVariant *secret_key, GError **error) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); + g_assert (OSTREE_IS_SIGN (self)); + if (OSTREE_SIGN_GET_IFACE (self)->set_sk == NULL) return glnx_throw (error, "not implemented"); @@ -191,7 +199,8 @@ ostree_sign_set_pk (OstreeSign *self, GVariant *public_key, GError **error) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); + g_assert (OSTREE_IS_SIGN (self)); + if (OSTREE_SIGN_GET_IFACE (self)->set_pk == NULL) return glnx_throw (error, "not implemented"); @@ -219,7 +228,8 @@ ostree_sign_add_pk (OstreeSign *self, GVariant *public_key, GError **error) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); + g_assert (OSTREE_IS_SIGN (self)); + if (OSTREE_SIGN_GET_IFACE (self)->add_pk == NULL) return glnx_throw (error, "not implemented"); @@ -258,7 +268,8 @@ ostree_sign_load_pk (OstreeSign *self, GVariant *options, GError **error) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); + g_assert (OSTREE_IS_SIGN (self)); + if (OSTREE_SIGN_GET_IFACE (self)->load_pk == NULL) return glnx_throw (error, "not implemented"); @@ -290,8 +301,8 @@ ostree_sign_data (OstreeSign *self, GCancellable *cancellable, GError **error) { + g_assert (OSTREE_IS_SIGN (self)); - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); if (OSTREE_SIGN_GET_IFACE (self)->data == NULL) return glnx_throw (error, "not implemented"); @@ -324,7 +335,8 @@ ostree_sign_data_verify (OstreeSign *self, char **out_success_message, GError **error) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); + g_assert (OSTREE_IS_SIGN (self)); + if (OSTREE_SIGN_GET_IFACE (self)->data_verify == NULL) return glnx_throw (error, "not implemented"); @@ -337,9 +349,13 @@ ostree_sign_data_verify (OstreeSign *self, static GVariant * _sign_detached_metadata_append (OstreeSign *self, GVariant *existing_metadata, - GBytes *signature_bytes) + GBytes *signature_bytes, + GError **error) { - g_return_val_if_fail (signature_bytes != NULL, FALSE); + g_assert (OSTREE_IS_SIGN (self)); + + if (signature_bytes == NULL) + return glnx_null_throw (error, "Invalid NULL signature bytes"); GVariantDict metadata_dict; g_autoptr(GVariant) signature_data = NULL; @@ -395,7 +411,7 @@ ostree_sign_commit_verify (OstreeSign *self, GError **error) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); + g_assert (OSTREE_IS_SIGN (self)); g_autoptr(GVariant) commit_variant = NULL; /* Load the commit */ @@ -447,10 +463,12 @@ ostree_sign_commit_verify (OstreeSign *self, const gchar * ostree_sign_get_name (OstreeSign *self) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), NULL); - g_return_val_if_fail (OSTREE_SIGN_GET_IFACE (self)->get_name != NULL, NULL); + g_assert (OSTREE_IS_SIGN (self)); - return OSTREE_SIGN_GET_IFACE (self)->get_name (self); + if (OSTREE_SIGN_GET_IFACE (self)->get_name == NULL) + return NULL; + + return OSTREE_SIGN_GET_IFACE (self)->get_name (self); } /** @@ -503,7 +521,9 @@ ostree_sign_commit (OstreeSign *self, return glnx_prefix_error (error, "Not able to sign the cobject"); new_metadata = - _sign_detached_metadata_append (self, old_metadata, signature); + _sign_detached_metadata_append (self, old_metadata, signature, error); + if (new_metadata == NULL) + return FALSE; if (!ostree_repo_write_commit_detached_metadata (repo, commit_checksum, @@ -603,8 +623,8 @@ ostree_sign_summary (OstreeSign *self, GCancellable *cancellable, GError **error) { - g_return_val_if_fail (OSTREE_IS_SIGN (self), FALSE); - g_return_val_if_fail (OSTREE_IS_REPO (repo), FALSE); + g_assert (OSTREE_IS_SIGN (self)); + g_assert (OSTREE_IS_REPO (repo)); g_autoptr(GVariant) normalized = NULL; g_autoptr(GBytes) summary_data = NULL; @@ -653,7 +673,9 @@ ostree_sign_summary (OstreeSign *self, g_autoptr(GVariant) old_metadata = g_steal_pointer (&metadata); metadata = - _sign_detached_metadata_append (self, old_metadata, signature); + _sign_detached_metadata_append (self, old_metadata, signature, error); + if (metadata == NULL) + return FALSE; } g_variant_iter_free (iter); diff --git a/src/libostree/ostree-sysroot-deploy.c b/src/libostree/ostree-sysroot-deploy.c index 2dc9f58b..f27ae0e1 100644 --- a/src/libostree/ostree-sysroot-deploy.c +++ b/src/libostree/ostree-sysroot-deploy.c @@ -29,7 +29,6 @@ #include #include #include -#include #include #ifdef HAVE_LIBMOUNT @@ -642,7 +641,7 @@ checkout_deployment_tree (OstreeSysroot *sysroot, return FALSE; /* Generate hardlink farm, then opendir it */ - OstreeRepoCheckoutAtOptions checkout_opts = { 0, }; + OstreeRepoCheckoutAtOptions checkout_opts = { .process_passthrough_whiteouts = TRUE }; if (!ostree_repo_checkout_at (repo, &checkout_opts, osdeploy_dfd, checkout_target_name, csum, cancellable, error)) @@ -1476,7 +1475,7 @@ fsfreeze_thaw_cycle (OstreeSysroot *self, * EOPNOTSUPP: If the filesystem doesn't support it */ int saved_errno = errno; - (void) TEMP_FAILURE_RETRY (ioctl (rootfs_dfd, FITHAW, 0)); + _ostree_linuxfs_filesystem_thaw (rootfs_dfd); errno = saved_errno; /* But if we got an error from poll, let's log it */ if (r < 0) @@ -1517,7 +1516,7 @@ fsfreeze_thaw_cycle (OstreeSysroot *self, return glnx_throw (error, "aborting due to test-fifreeze"); } /* Do a freeze/thaw cycle; TODO add a FIFREEZETHAW ioctl */ - if (ioctl (rootfs_dfd, FIFREEZE, 0) != 0) + if (_ostree_linuxfs_filesystem_freeze (rootfs_dfd) != 0) { /* Not supported, we're running in the unit tests (as non-root), or * the filesystem is already frozen (EBUSY). @@ -1539,7 +1538,7 @@ fsfreeze_thaw_cycle (OstreeSysroot *self, return glnx_throw_errno_prefix (error, "ioctl(FIFREEZE)"); } /* And finally thaw, then signal our completion to the watchdog */ - if (TEMP_FAILURE_RETRY (ioctl (rootfs_dfd, FITHAW, 0)) != 0) + if (_ostree_linuxfs_filesystem_thaw (rootfs_dfd) != 0) { /* Warn but don't error if the filesystem was already thawed */ if (errno == EINVAL) @@ -2006,7 +2005,7 @@ install_deployment_kernel (OstreeSysroot *sysroot, &variant, NULL)) { metadata = g_variant_get_child_value (variant, 0); - g_variant_lookup (metadata, OSTREE_COMMIT_META_KEY_VERSION, "s", &deployment_version); + (void) g_variant_lookup (metadata, OSTREE_COMMIT_META_KEY_VERSION, "s", &deployment_version); } } @@ -2233,7 +2232,7 @@ get_deployment_ostree_version (OstreeRepo *repo, if (ostree_repo_load_variant (repo, OSTREE_OBJECT_TYPE_COMMIT, csum, &variant, NULL)) { g_autoptr(GVariant) metadata = g_variant_get_child_value (variant, 0); - g_variant_lookup (metadata, OSTREE_COMMIT_META_KEY_VERSION, "s", &version); + (void) g_variant_lookup (metadata, OSTREE_COMMIT_META_KEY_VERSION, "s", &version); } return g_steal_pointer (&version); @@ -3595,7 +3594,7 @@ ostree_sysroot_deployment_set_kargs (OstreeSysroot *self, * ostree_sysroot_deployment_set_kargs_in_place: * @self: Sysroot * @deployment: A deployment - * @kargs_str: (allow none): Replace @deployment's kernel arguments + * @kargs_str: (allow-none): Replace @deployment's kernel arguments * @cancellable: Cancellable * @error: Error * @@ -3615,25 +3614,55 @@ ostree_sysroot_deployment_set_kargs_in_place (OstreeSysroot *self, if (!_ostree_sysroot_ensure_writable (self, error)) return FALSE; - g_assert (!ostree_deployment_is_staged (deployment)); + // handle staged deployment + if (ostree_deployment_is_staged (deployment)) + { + /* Read the staged state from disk */ + glnx_autofd int fd = -1; + if (!glnx_openat_rdonly (AT_FDCWD, _OSTREE_SYSROOT_RUNSTATE_STAGED, TRUE, &fd, error)) + return FALSE; - OstreeBootconfigParser *new_bootconfig = ostree_deployment_get_bootconfig (deployment); - ostree_bootconfig_parser_set (new_bootconfig, "options", kargs_str); - - g_autofree char *bootconf_name = - g_strdup_printf ("ostree-%d-%s.conf", - self->deployments->len - ostree_deployment_get_index (deployment), - ostree_deployment_get_osname (deployment)); - - g_autofree char *bootconfdir = g_strdup_printf ("loader.%d/entries", self->bootversion); - glnx_autofd int bootconf_dfd = -1; - if (!glnx_opendirat (self->boot_fd, bootconfdir, TRUE, &bootconf_dfd, error)) - return FALSE; - - if (!ostree_bootconfig_parser_write_at (new_bootconfig, - bootconf_dfd, bootconf_name, + g_autoptr(GBytes) contents = ot_fd_readall_or_mmap (fd, 0, error); + if (!contents) + return FALSE; + g_autoptr(GVariant) staged_deployment_data = + g_variant_new_from_bytes ((GVariantType*)"a{sv}", contents, TRUE); + g_autoptr(GVariantDict) staged_deployment_dict = + g_variant_dict_new (staged_deployment_data); + + g_autoptr(OstreeKernelArgs) kargs = ostree_kernel_args_from_string (kargs_str); + g_auto(GStrv) kargs_strv = ostree_kernel_args_to_strv (kargs); + + g_variant_dict_insert (staged_deployment_dict, "kargs", "^a&s", kargs_strv); + g_autoptr(GVariant) new_staged_deployment_data = g_variant_dict_end (staged_deployment_dict); + + if (!glnx_file_replace_contents_at (fd, _OSTREE_SYSROOT_RUNSTATE_STAGED, + g_variant_get_data (new_staged_deployment_data), + g_variant_get_size (new_staged_deployment_data), + GLNX_FILE_REPLACE_NODATASYNC, cancellable, error)) - return FALSE; + return FALSE; + } + else + { + OstreeBootconfigParser *new_bootconfig = ostree_deployment_get_bootconfig (deployment); + ostree_bootconfig_parser_set (new_bootconfig, "options", kargs_str); + + g_autofree char *bootconf_name = + g_strdup_printf ("ostree-%d-%s.conf", + self->deployments->len - ostree_deployment_get_index (deployment), + ostree_deployment_get_osname (deployment)); + + g_autofree char *bootconfdir = g_strdup_printf ("loader.%d/entries", self->bootversion); + glnx_autofd int bootconf_dfd = -1; + if (!glnx_opendirat (self->boot_fd, bootconfdir, TRUE, &bootconf_dfd, error)) + return FALSE; + + if (!ostree_bootconfig_parser_write_at (new_bootconfig, + bootconf_dfd, bootconf_name, + cancellable, error)) + return FALSE; + } return TRUE; } diff --git a/src/libostree/ostree-version.h b/src/libostree/ostree-version.h index 227252a4..11ce1594 100644 --- a/src/libostree/ostree-version.h +++ b/src/libostree/ostree-version.h @@ -41,7 +41,7 @@ * * Since: 2017.4 */ -#define OSTREE_RELEASE_VERSION (5) +#define OSTREE_RELEASE_VERSION (6) /** * OSTREE_VERSION @@ -50,7 +50,7 @@ * * Since: 2017.4 */ -#define OSTREE_VERSION (2022.5) +#define OSTREE_VERSION (2022.6) /** * OSTREE_VERSION_S: @@ -60,7 +60,7 @@ * * Since: 2017.4 */ -#define OSTREE_VERSION_S "2022.5" +#define OSTREE_VERSION_S "2022.6" #define OSTREE_ENCODE_VERSION(year,release) \ ((year) << 16 | (release)) @@ -99,5 +99,5 @@ * Since: 2019.3 */ #ifndef __GI_SCANNER__ -#define OSTREE_BUILT_FEATURES "libsoup gpgme ex-fsverity libarchive selinux libmount systemd release p2p" +#define OSTREE_BUILT_FEATURES "libsoup gpgme ex-fsverity libarchive selinux avahi libmount systemd release p2p" #endif diff --git a/src/libostree/s390x-se-luks-gencpio b/src/libostree/s390x-se-luks-gencpio deleted file mode 100755 index e821e2fe..00000000 --- a/src/libostree/s390x-se-luks-gencpio +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/bash -# This script creates new initramdisk with LUKS config within -set -euo pipefail - -old_initrd=$1 -new_initrd=$2 -currdir=$PWD - -# Copying existing initramdisk -cp ${old_initrd} ${new_initrd} - -# Appending LUKS root keys and crypttab config to the end of initrd -workdir=$(mktemp -d -p /tmp se-initramfs-XXXXXX) -cd ${workdir} -mkdir -p etc/luks -cp -f /etc/luks/* etc/luks/ -cp -f /etc/crypttab etc/ -find . -mindepth 1 | cpio --quiet -H newc -o | gzip -9 -n >> ${new_initrd} - -# Cleanup -cd ${currdir} -rm -rf ${workdir} diff --git a/src/libotutil/ot-variant-builder.c b/src/libotutil/ot-variant-builder.c index 4d3dcbe5..955bf2ee 100644 --- a/src/libotutil/ot-variant-builder.c +++ b/src/libotutil/ot-variant-builder.c @@ -758,11 +758,9 @@ struct _OtVariantBuilder { static OtVariantBuilderInfo * ot_variant_builder_info_new (OtVariantBuilder *builder, const GVariantType *type) { - OtVariantBuilderInfo *info; + g_assert (g_variant_type_is_container (type)); - g_return_val_if_fail (g_variant_type_is_container (type), NULL); - - info = (OtVariantBuilderInfo *) g_slice_new0 (OtVariantBuilderInfo); + OtVariantBuilderInfo *info = (OtVariantBuilderInfo *) g_slice_new0 (OtVariantBuilderInfo); info->builder = builder; info->type = g_variant_type_copy (type); @@ -843,11 +841,9 @@ OtVariantBuilder * ot_variant_builder_new (const GVariantType *type, int fd) { - OtVariantBuilder *builder; + g_assert (g_variant_type_is_container (type)); - g_return_val_if_fail (g_variant_type_is_container (type), NULL); - - builder = (OtVariantBuilder *) g_slice_new0 (OtVariantBuilder); + OtVariantBuilder *builder = (OtVariantBuilder *) g_slice_new0 (OtVariantBuilder); builder->head = ot_variant_builder_info_new (builder, type); builder->ref_count = 1; @@ -1083,7 +1079,6 @@ ot_variant_builder_open (OtVariantBuilder *builder, GError **error) { OtVariantBuilderInfo *info = builder->head; - OtVariantBuilderInfo *new_info; g_assert (info->n_children < info->max_items); g_assert (!info->expected_type || @@ -1096,7 +1091,9 @@ ot_variant_builder_open (OtVariantBuilder *builder, if (!ot_variant_builder_pre_add (info, type, error)) return FALSE; - new_info = ot_variant_builder_info_new (builder, type); + OtVariantBuilderInfo *new_info = ot_variant_builder_info_new (builder, type); + g_assert (new_info != NULL); + new_info->parent = info; /* push the prev_item_type down into the subcontainer */ diff --git a/src/ostree/ot-admin-builtin-finalize-staged.c b/src/ostree/ot-admin-builtin-finalize-staged.c index eedffdde..e408f447 100644 --- a/src/ostree/ot-admin-builtin-finalize-staged.c +++ b/src/ostree/ot-admin-builtin-finalize-staged.c @@ -1,5 +1,6 @@ /* * Copyright (C) 2018 Red Hat, Inc. + * Copyright (C) 2022 Endless OS Foundation LLC * * SPDX-License-Identifier: LGPL-2.0+ * @@ -19,8 +20,9 @@ #include "config.h" -#include "config.h" - +#include +#include +#include #include #include "ot-main.h" @@ -32,7 +34,10 @@ #include "ostree-cmd-private.h" #include "ostree.h" +static gboolean opt_hold; + static GOptionEntry options[] = { + { "hold", 0, 0, G_OPTION_ARG_NONE, &opt_hold, "Hold /boot open during finalization", NULL }, { NULL } }; @@ -50,13 +55,52 @@ ot_admin_builtin_finalize_staged (int argc, char **argv, OstreeCommandInvocation g_autoptr(GOptionContext) context = g_option_context_new (""); g_autoptr(OstreeSysroot) sysroot = NULL; + + /* First parse the args without loading the sysroot to see what options are + * set. */ if (!ostree_admin_option_context_parse (context, options, &argc, &argv, - OSTREE_ADMIN_BUILTIN_FLAG_SUPERUSER, + OSTREE_ADMIN_BUILTIN_FLAG_NO_LOAD, invocation, &sysroot, cancellable, error)) return FALSE; - if (!ostree_cmd__private__()->ostree_finalize_staged (sysroot, cancellable, error)) - return FALSE; + if (opt_hold) + { + /* Load the sysroot unlocked so that a separate namespace isn't + * created. */ + if (!ostree_admin_sysroot_load (sysroot, + OSTREE_ADMIN_BUILTIN_FLAG_SUPERUSER | OSTREE_ADMIN_BUILTIN_FLAG_UNLOCKED, + cancellable, error)) + return FALSE; + + /* In case it's an automount, open /boot so that the automount doesn't + * expire until before this process exits. If it did expire and got + * unmounted, the service would be stopped and the deployment would be + * finalized earlier than expected. + */ + int sysroot_fd = ostree_sysroot_get_fd (sysroot); + glnx_autofd int boot_fd = -1; + g_debug ("Opening /boot directory"); + if (!glnx_opendirat (sysroot_fd, "boot", TRUE, &boot_fd, error)) + return FALSE; + + /* We want to keep /boot open until the deployment is finalized during + * system shutdown, so block until we get SIGTERM which systemd will send + * when the unit is stopped. + */ + pause (); + } + else + { + /* Load the sysroot with the normal flags and actually finalize the + * deployment. */ + if (!ostree_admin_sysroot_load (sysroot, + OSTREE_ADMIN_BUILTIN_FLAG_SUPERUSER, + cancellable, error)) + return FALSE; + + if (!ostree_cmd__private__()->ostree_finalize_staged (sysroot, cancellable, error)) + return FALSE; + } return TRUE; } diff --git a/src/ostree/ot-builtin-checkout.c b/src/ostree/ot-builtin-checkout.c index d69c8b0b..bfa43885 100644 --- a/src/ostree/ot-builtin-checkout.c +++ b/src/ostree/ot-builtin-checkout.c @@ -37,6 +37,7 @@ static gboolean opt_union; static gboolean opt_union_add; static gboolean opt_union_identical; static gboolean opt_whiteouts; +static gboolean opt_process_passthrough_whiteouts; static gboolean opt_from_stdin; static char *opt_from_file; static gboolean opt_disable_fsync; @@ -77,6 +78,7 @@ static GOptionEntry options[] = { { "union-add", 0, 0, G_OPTION_ARG_NONE, &opt_union_add, "Keep existing files/directories, only add new", NULL }, { "union-identical", 0, 0, G_OPTION_ARG_NONE, &opt_union_identical, "When layering checkouts, error out if a file would be replaced with a different version, but add new files and directories", NULL }, { "whiteouts", 0, 0, G_OPTION_ARG_NONE, &opt_whiteouts, "Process 'whiteout' (Docker style) entries", NULL }, + { "process-passthrough-whiteouts", 0, 0, G_OPTION_ARG_NONE, &opt_process_passthrough_whiteouts, "Enable overlayfs whiteout extraction into char 0:0 devices", NULL }, { "allow-noent", 0, 0, G_OPTION_ARG_NONE, &opt_allow_noent, "Do nothing if specified path does not exist", NULL }, { "from-stdin", 0, 0, G_OPTION_ARG_NONE, &opt_from_stdin, "Process many checkouts from standard input", NULL }, { "from-file", 0, 0, G_OPTION_ARG_STRING, &opt_from_file, "Process many checkouts from input file", "FILE" }, @@ -129,7 +131,8 @@ process_one_checkout (OstreeRepo *repo, if (opt_disable_cache || opt_whiteouts || opt_require_hardlinks || opt_union_add || opt_force_copy || opt_force_copy_zerosized || opt_bareuseronly_dirs || opt_union_identical || - opt_skiplist_file || opt_selinux_policy || opt_selinux_prefix) + opt_skiplist_file || opt_selinux_policy || opt_selinux_prefix || + opt_process_passthrough_whiteouts) { OstreeRepoCheckoutAtOptions checkout_options = { 0, }; @@ -162,6 +165,8 @@ process_one_checkout (OstreeRepo *repo, } if (opt_whiteouts) checkout_options.process_whiteouts = TRUE; + if (opt_process_passthrough_whiteouts) + checkout_options.process_passthrough_whiteouts = TRUE; if (subpath) checkout_options.subpath = subpath; diff --git a/src/ostree/ot-builtin-rev-parse.c b/src/ostree/ot-builtin-rev-parse.c index c4a7ec94..95cb45ab 100644 --- a/src/ostree/ot-builtin-rev-parse.c +++ b/src/ostree/ot-builtin-rev-parse.c @@ -25,47 +25,73 @@ #include "ot-builtins.h" #include "ostree.h" #include "otutil.h" +#include /* ATTENTION: * Please remember to update the bash-completion script (bash/ostree) and * man page (man/ostree-rev-parse.xml) when changing the option list. */ +static gboolean opt_single; + static GOptionEntry options[] = { + { "single", 'S', 0, G_OPTION_ARG_NONE, &opt_single, "If the repository has exactly one commit, then print it; any other case will result in an error", NULL }, { NULL } }; gboolean ostree_builtin_rev_parse (int argc, char **argv, OstreeCommandInvocation *invocation, GCancellable *cancellable, GError **error) { - g_autoptr(GOptionContext) context = NULL; + g_autoptr(GOptionContext) context = g_option_context_new ("REV"); g_autoptr(OstreeRepo) repo = NULL; - gboolean ret = FALSE; - const char *rev = "master"; - int i; - g_autofree char *resolved_rev = NULL; - - context = g_option_context_new ("REV"); - if (!ostree_option_context_parse (context, options, &argc, &argv, invocation, &repo, cancellable, error)) - goto out; + return FALSE; + + if (opt_single) + { + if (argc >= 2) + { + ot_util_usage_error (context, "Cannot specify arguments with --single", error); + return FALSE; + } + + g_autoptr(GHashTable) objects = NULL; + if (!ostree_repo_list_commit_objects_starting_with (repo, "", &objects, cancellable, error)) + return FALSE; + + GVariant *found = NULL; + GLNX_HASH_TABLE_FOREACH (objects, GVariant*, key) + { + if (found) + return glnx_throw (error, "Multiple commit objects found"); + found = key; + } + if (!found) + return glnx_throw (error, "No commit objects found"); + const char *checksum; + OstreeObjectType objtype; + ostree_object_name_deserialize (found, &checksum, &objtype); + g_assert (objtype == OSTREE_OBJECT_TYPE_COMMIT); + + g_print ("%s\n", checksum); + + return TRUE; /* Note early return */ + } if (argc < 2) { ot_util_usage_error (context, "REV must be specified", error); - goto out; + return FALSE; } - for (i = 1; i < argc; i++) + + for (gint i = 1; i < argc; i++) { - rev = argv[i]; - g_free (resolved_rev); - resolved_rev = NULL; + const char *rev = argv[i]; + g_autofree char *resolved_rev = NULL; if (!ostree_repo_resolve_rev (repo, rev, FALSE, &resolved_rev, error)) - goto out; + return FALSE; g_print ("%s\n", resolved_rev); } - ret = TRUE; - out: - return ret; + return TRUE; } diff --git a/src/ostree/ot-main.c b/src/ostree/ot-main.c index b7b50d67..770962a4 100644 --- a/src/ostree/ot-main.c +++ b/src/ostree/ot-main.c @@ -28,7 +28,6 @@ #include #include #include -#include #include "ot-main.h" #include "ostree.h" @@ -580,41 +579,11 @@ on_sysroot_journal_msg (OstreeSysroot *sysroot, } gboolean -ostree_admin_option_context_parse (GOptionContext *context, - const GOptionEntry *main_entries, - int *argc, - char ***argv, - OstreeAdminBuiltinFlags flags, - OstreeCommandInvocation *invocation, - OstreeSysroot **out_sysroot, - GCancellable *cancellable, - GError **error) +ostree_admin_sysroot_load (OstreeSysroot *sysroot, + OstreeAdminBuiltinFlags flags, + GCancellable *cancellable, + GError **error) { - /* Entries are listed in --help output in the order added. We add the - * main entries ourselves so that we can add the --sysroot entry first. */ - - g_option_context_add_main_entries (context, global_admin_entries, NULL); - - if (!ostree_option_context_parse (context, main_entries, argc, argv, - invocation, NULL, cancellable, error)) - return FALSE; - - if (!opt_print_current_dir && (flags & OSTREE_ADMIN_BUILTIN_FLAG_NO_SYSROOT)) - { - g_assert_null (out_sysroot); - /* Early return if no sysroot is requested */ - return TRUE; - } - - g_autoptr(GFile) sysroot_path = NULL; - if (opt_sysroot != NULL) - sysroot_path = g_file_new_for_path (opt_sysroot); - - g_autoptr(OstreeSysroot) sysroot = ostree_sysroot_new (sysroot_path); - if (!ostree_sysroot_initialize (sysroot, error)) - return FALSE; - g_signal_connect (sysroot, "journal-msg", G_CALLBACK (on_sysroot_journal_msg), NULL); - if ((flags & OSTREE_ADMIN_BUILTIN_FLAG_UNLOCKED) == 0) { /* If we're requested to lock the sysroot, first check if we're operating @@ -658,6 +627,51 @@ ostree_admin_option_context_parse (GOptionContext *context, } } + return TRUE; +} + +gboolean +ostree_admin_option_context_parse (GOptionContext *context, + const GOptionEntry *main_entries, + int *argc, + char ***argv, + OstreeAdminBuiltinFlags flags, + OstreeCommandInvocation *invocation, + OstreeSysroot **out_sysroot, + GCancellable *cancellable, + GError **error) +{ + /* Entries are listed in --help output in the order added. We add the + * main entries ourselves so that we can add the --sysroot entry first. */ + + g_option_context_add_main_entries (context, global_admin_entries, NULL); + + if (!ostree_option_context_parse (context, main_entries, argc, argv, + invocation, NULL, cancellable, error)) + return FALSE; + + if (!opt_print_current_dir && (flags & OSTREE_ADMIN_BUILTIN_FLAG_NO_SYSROOT)) + { + g_assert_null (out_sysroot); + /* Early return if no sysroot is requested */ + return TRUE; + } + + g_autoptr(GFile) sysroot_path = NULL; + if (opt_sysroot != NULL) + sysroot_path = g_file_new_for_path (opt_sysroot); + + g_autoptr(OstreeSysroot) sysroot = ostree_sysroot_new (sysroot_path); + if (!ostree_sysroot_initialize (sysroot, error)) + return FALSE; + g_signal_connect (sysroot, "journal-msg", G_CALLBACK (on_sysroot_journal_msg), NULL); + + if (opt_print_current_dir || (flags & OSTREE_ADMIN_BUILTIN_FLAG_NO_LOAD) == 0) + { + if (!ostree_admin_sysroot_load (sysroot, flags, cancellable, error)) + return FALSE; + } + if (opt_print_current_dir) { g_autoptr(GPtrArray) deployments = NULL; diff --git a/src/ostree/ot-main.h b/src/ostree/ot-main.h index b369deb8..e296501a 100644 --- a/src/ostree/ot-main.h +++ b/src/ostree/ot-main.h @@ -36,6 +36,7 @@ typedef enum { OSTREE_ADMIN_BUILTIN_FLAG_SUPERUSER = (1 << 0), OSTREE_ADMIN_BUILTIN_FLAG_UNLOCKED = (1 << 1), OSTREE_ADMIN_BUILTIN_FLAG_NO_SYSROOT = (1 << 2), + OSTREE_ADMIN_BUILTIN_FLAG_NO_LOAD = (1 << 3), } OstreeAdminBuiltinFlags; @@ -91,6 +92,11 @@ gboolean ostree_admin_option_context_parse (GOptionContext *context, OstreeSysroot **out_sysroot, GCancellable *cancellable, GError **error); +gboolean ostree_admin_sysroot_load (OstreeSysroot *sysroot, + OstreeAdminBuiltinFlags flags, + GCancellable *cancellable, + GError **error); + gboolean ostree_ensure_repo_writable (OstreeRepo *repo, GError **error); void ostree_print_gpg_verify_result (OstreeGpgVerifyResult *result); diff --git a/tests/archive-test.sh b/tests/archive-test.sh index b6d84979..6b45790e 100644 --- a/tests/archive-test.sh +++ b/tests/archive-test.sh @@ -71,6 +71,11 @@ mkdir -p test-overlays date > test-overlays/overlaid-file $OSTREE commit ${COMMIT_ARGS} -b test-base --base test2 --owner-uid 42 --owner-gid 42 test-overlays/ $OSTREE ls -R test-base > ls.txt -assert_streq "$(wc -l < ls.txt)" 14 +if can_create_whiteout_devices; then + assert_streq "$(wc -l < ls.txt)" 17 +else + assert_streq "$(wc -l < ls.txt)" 14 +fi + assert_streq "$(grep '42.*42' ls.txt | wc -l)" 2 echo "ok commit overlay base" diff --git a/tests/basic-test.sh b/tests/basic-test.sh index 04506c3d..f97f6fc3 100644 --- a/tests/basic-test.sh +++ b/tests/basic-test.sh @@ -19,7 +19,7 @@ set -euo pipefail -echo "1..$((87 + ${extra_basic_tests:-0}))" +echo "1..$((90 + ${extra_basic_tests:-0}))" CHECKOUT_U_ARG="" CHECKOUT_H_ARGS="-H" @@ -97,6 +97,22 @@ $OSTREE rev-parse 'test2^' $OSTREE rev-parse 'test2^^' 2>/dev/null && fatal "rev-parse test2^^ unexpectedly succeeded!" echo "ok rev-parse" +if $OSTREE rev-parse -S 2>err.txt; then + fatal "rev parse multiple" +fi +assert_file_has_content_literal err.txt 'Multiple commit objects found' +$CMD_PREFIX ostree --repo=repo-copy init --mode=archive +if $CMD_PREFIX ostree --repo=repo-copy rev-parse -S 2>err.txt; then + fatal "rev parse none" +fi +assert_file_has_content_literal err.txt 'No commit objects found' +rev=$($OSTREE rev-parse test2) +$CMD_PREFIX ostree --repo=repo-copy pull-local repo test2 +rev2=$($CMD_PREFIX ostree --repo=repo-copy rev-parse -S) +assert_streq "${rev}" "${rev2}" +echo "ok rev-parse -S" + + checksum=$($OSTREE rev-parse test2) partial=${checksum:0:6} echo "partial:" $partial @@ -1187,3 +1203,30 @@ if test "$(id -u)" != "0"; then else echo "ok # SKIP not run when root" fi + +if ! skip_one_without_whiteouts_devices; then + cd ${test_tmpdir} + rm checkout-test2 -rf + $OSTREE checkout test2 checkout-test2 + + assert_not_has_file checkout-test2/whiteouts/whiteout + assert_not_has_file checkout-test2/whiteouts/whiteout2 + assert_has_file checkout-test2/whiteouts/.ostree-wh.whiteout + assert_has_file checkout-test2/whiteouts/.ostree-wh.whiteout2 + + echo "ok checkout: no whiteout passthrough by default" +fi + +if ! skip_one_without_whiteouts_devices; then + cd ${test_tmpdir} + rm checkout-test2 -rf + $OSTREE checkout --process-passthrough-whiteouts test2 checkout-test2 + + assert_not_has_file checkout-test2/whiteouts/.ostree-wh.whiteout + assert_not_has_file checkout-test2/whiteouts/.ostree-wh.whiteout2 + + assert_is_whiteout_device checkout-test2/whiteouts/whiteout + assert_is_whiteout_device checkout-test2/whiteouts/whiteout2 + + echo "ok checkout: whiteout with overlayfs passthrough processing" +fi diff --git a/tests/libtest-core.sh b/tests/libtest-core.sh index d10aac1c..3465fb9b 100644 --- a/tests/libtest-core.sh +++ b/tests/libtest-core.sh @@ -163,6 +163,13 @@ assert_file_has_mode () { fi } +assert_is_whiteout_device () { + device_details="$(stat -c '%F %t:%T' $1)" + if [ "$device_details" != "character special file 0:0" ]; then + fatal "File '$1' is not a whiteout character device 0:0" + fi +} + assert_symlink_has_content () { if ! test -L "$1"; then fatal "File '$1' is not a symbolic link" diff --git a/tests/libtest.sh b/tests/libtest.sh index 686f08dc..5830f210 100755 --- a/tests/libtest.sh +++ b/tests/libtest.sh @@ -148,6 +148,20 @@ if ! have_selinux_relabel; then fi echo done +# whiteout char 0:0 devices can be created as regular users, but +# cannot be created inside containers mounted via overlayfs +can_create_whiteout_devices() { + mknod -m 000 ${test_tmpdir}/.test-whiteout c 0 0 || return 1 + rm -f ${test_tmpdir}/.test-whiteout + return 0 +} + +echo -n checking for overlayfs whiteouts... +if ! can_create_whiteout_devices; then + export OSTREE_NO_WHITEOUTS=1 +fi +echo done + if test -n "${OT_TESTS_DEBUG:-}"; then set -x fi @@ -245,6 +259,15 @@ setup_test_repository () { ln -s nonexistent baz/alink mkdir baz/another/ echo x > baz/another/y + + # if we are running inside a container we cannot test + # the overlayfs whiteout marker passthrough + if ! test -n "${OSTREE_NO_WHITEOUTS:-}"; then + mkdir whiteouts + touch whiteouts/.ostree-wh.whiteout + touch whiteouts/.ostree-wh.whiteout2 + chmod 755 whiteouts/.ostree-wh.whiteout2 + fi umask "${oldumask}" cd ${test_tmpdir}/files @@ -406,7 +429,7 @@ setup_os_repository () { mkdir osdata cd osdata kver=3.6.0 - mkdir -p usr/bin ${bootdir} usr/lib/modules/${kver} usr/share usr/etc + mkdir -p usr/bin ${bootdir} usr/lib/modules/${kver} usr/share usr/etc usr/container/layers/abcd kernel_path=${bootdir}/vmlinuz initramfs_path=${bootdir}/initramfs.img # the HMAC file is only in /usr/lib/modules @@ -449,6 +472,17 @@ EOF mkdir -p usr/etc/testdirectory echo "a default daemon file" > usr/etc/testdirectory/test + # if we are running inside a container we cannot test + # the overlayfs whiteout marker passthrough + if ! test -n "${OSTREE_NO_WHITEOUTS:-}"; then + # overlayfs whiteout passhthrough marker files + touch usr/container/layers/abcd/.ostree-wh.whiteout + chmod 400 usr/container/layers/abcd/.ostree-wh.whiteout + + touch usr/container/layers/abcd/.ostree-wh.whiteout2 + chmod 777 usr/container/layers/abcd/.ostree-wh.whiteout2 + fi + ${CMD_PREFIX} ostree --repo=${test_tmpdir}/testos-repo commit ${bootable_flag} --add-metadata-string version=1.0.9 -b testos/buildmain/x86_64-runtime -s "Build" # Ensure these commits have distinct second timestamps @@ -588,6 +622,22 @@ skip_without_user_xattrs () { fi } +# Usage: if ! skip_one_without_whiteouts_devices; then ... more tests ...; fi +skip_one_without_whiteouts_devices() { + if ! can_create_whiteout_devices; then + echo "ok # SKIP - this test requires whiteout device support (test outside containers)" + return 0 + else + return 1 + fi +} + +skip_without_whiteouts_devices () { + if ! can_create_whiteout_devices; then + skip "this test requires whiteout device support (test outside containers)" + fi +} + _have_systemd_and_libmount='' have_systemd_and_libmount() { if test "${_have_systemd_and_libmount}" = ''; then diff --git a/tests/test-admin-deploy-whiteouts.sh b/tests/test-admin-deploy-whiteouts.sh new file mode 100755 index 00000000..66421949 --- /dev/null +++ b/tests/test-admin-deploy-whiteouts.sh @@ -0,0 +1,42 @@ +#!/bin/bash +# +# Copyright (C) 2022 Red Hat, Inc. +# +# SPDX-License-Identifier: LGPL-2.0+ +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2 of the License, or (at your option) any later version. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library. If not, see . + +set -euox pipefail + +. $(dirname $0)/libtest.sh + +skip_without_whiteouts_devices + +# Exports OSTREE_SYSROOT so --sysroot not needed. +setup_os_repository "archive" "syslinux" +${CMD_PREFIX} ostree --repo=sysroot/ostree/repo pull-local --remote=testos testos-repo testos/buildmain/x86_64-runtime + +echo "1..3" +${CMD_PREFIX} ostree admin deploy --os=testos --karg=root=LABEL=foo --karg=testkarg=1 testos:testos/buildmain/x86_64-runtime +origdeployment=$(${CMD_PREFIX} ostree admin --sysroot=sysroot --print-current-dir) + +assert_is_whiteout_device "${origdeployment}"/usr/container/layers/abcd/whiteout +echo "ok whiteout deployment" + +assert_not_has_file "${origdeployment}"/usr/container/layers/abcd/.ostree-wh.whiteout +echo "ok .ostree-wh.whiteout not created" + +assert_file_has_mode "${origdeployment}"/usr/container/layers/abcd/whiteout 400 +assert_file_has_mode "${origdeployment}"/usr/container/layers/abcd/whiteout2 777 +echo "ok whiteout permissions are preserved"

    cancellable

    a GCancellable, or NULL.

    a GCancellable, or NULL.

    [nullable]

    error

    return location for a GError, or NULL

    return location for a GError, or NULL