...
 
Commits (37)
......@@ -109,6 +109,7 @@ _installed_or_uninstalled_test_scripts = \
tests/test-admin-pull-deploy-split.sh \
tests/test-admin-locking.sh \
tests/test-admin-deploy-clean.sh \
tests/test-admin-gpg.sh \
tests/test-reset-nonlinear.sh \
tests/test-oldstyle-partial.sh \
tests/test-delta.sh \
......
......@@ -155,4 +155,14 @@ release-tarball-embedded:
mv ostree-embeddeps-$${GITVERSION}.tar{.tmp,}; \
gzip -f ostree-embeddeps-$${GITVERSION}.tar
# `make dist` + `make`; explicitly not the other
# parts of distcheck like `make uninstall` since
# we don't care about that.
dist-then-build: dist
rm $(distdir) -rf && tar -xf $(distdir).tar.xz
cd $(distdir) && mkdir _build && cd _build && \
../configure --prefix=/usr --libdir=/usr/lib --sysconfdir=/etc && \
$(MAKE) && make install DESTDIR=$$(pwd)/_install && \
rm -rf $(distdir)
-include $(top_srcdir)/git.mk
This source diff could not be displayed because it is too large. You can view the blob instead.
This diff is collapsed.
# Makefile.in generated by automake 1.15.1 from Makefile.am.
# Makefile.in generated by automake 1.16.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2017 Free Software Foundation, Inc.
# Copyright (C) 1994-2018 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
......@@ -609,8 +609,8 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \
esac;
$(srcdir)/../Makefile-libostree-defines.am $(top_srcdir)/gtk-doc.make $(am__empty):
......@@ -635,7 +635,10 @@ ctags CTAGS:
cscope cscopelist:
distdir: $(DISTFILES)
distdir: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) distdir-am
distdir-am: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
......@@ -890,6 +893,7 @@ html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files) $(expand_con
for file in $(HTML_IMAGES) ; do \
test -f $(abs_srcdir)/$$file && cp $(abs_srcdir)/$$file $(abs_builddir)/html; \
test -f $(abs_builddir)/$$file && cp $(abs_builddir)/$$file $(abs_builddir)/html; \
test -f $$file && cp $$file $(abs_builddir)/html; \
done;
$(GTK_DOC_V_XREF)gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
$(AM_V_at)touch html-build.stamp
......
......@@ -6,7 +6,7 @@
<meta name="generator" content="DocBook XSL Stylesheets Vsnapshot">
<link rel="home" href="index.html" title="OSTree API references">
<link rel="next" href="reference.html" title="API Reference">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -14,7 +14,7 @@
<div class="titlepage">
<div>
<div><table class="navigation" id="top" width="100%" cellpadding="2" cellspacing="0"><tr><th valign="middle"><p class="title">OSTree API references</p></th></tr></table></div>
<div><p class="releaseinfo">for OSTree 2018.7</p></div>
<div><p class="releaseinfo">for OSTree 2019.1</p></div>
</div>
<hr>
</div>
......@@ -68,6 +68,6 @@
</dl></div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="reference.html" title="API Reference">
<link rel="next" href="ostree-OstreeRepo.html" title="OstreeRepo: Content-addressed object store">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -2618,6 +2618,6 @@ Unix epoch in UTC, big-endian) when the commit was committed</p></li></ul></div>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-Simple-upgrade-class.html" title="Simple upgrade class">
<link rel="next" href="ostree-ostree-bootconfig-parser.html" title="ostree-bootconfig-parser">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -707,6 +707,6 @@ for future variations.</p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-OstreeRepo.html" title="OstreeRepo: Content-addressed object store">
<link rel="next" href="ostree-Root-partition-mount-point.html" title="Root partition mount point">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -582,6 +582,6 @@ the contents will be loaded only when needed.</p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-Core-repository-independent-functions.html" title="Core repository-independent functions">
<link rel="next" href="ostree-In-memory-modifiable-filesystem-tree.html" title="In-memory modifiable filesystem tree">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -4579,9 +4579,10 @@ ostree_repo_import_object_from_with_trust
into <em class="parameter"><code>self</code></em>
from the
source repository <em class="parameter"><code>source</code></em>
. If both repositories are of the same
type and on the same filesystem, this will simply be a fast Unix
hard link operation.</p>
. If <em class="parameter"><code>trusted</code></em>
is <code class="literal">TRUE</code> and both
repositories are of the same type and on the same filesystem,
this will simply be a fast Unix hard link operation.</p>
<p>Otherwise, a copy will be performed.</p>
<div class="refsect3">
<a name="ostree-repo-import-object-from-with-trust.parameters"></a><h4>Parameters</h4>
......@@ -7902,8 +7903,9 @@ possible modes.</p>
guint content_objects_total;
guint content_objects_written;
guint64 content_bytes_written;
guint devino_cache_hits;
guint64 padding1;
guint padding1;
guint64 padding2;
guint64 padding3;
guint64 padding4;
......@@ -7951,7 +7953,12 @@ in bytes, counting only content objects.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><span class="type">guint64</span> <em class="structfield"><code><a name="OstreeRepoTransactionStats.padding1"></a>padding1</code></em>;</p></td>
<td class="struct_member_name"><p><span class="type">guint</span> <em class="structfield"><code><a name="OstreeRepoTransactionStats.devino-cache-hits"></a>devino_cache_hits</code></em>;</p></td>
<td> </td>
<td> </td>
</tr>
<tr>
<td class="struct_member_name"><p><span class="type">guint</span> <em class="structfield"><code><a name="OstreeRepoTransactionStats.padding1"></a>padding1</code></em>;</p></td>
<td class="struct_member_description"><p>reserved</p></td>
<td class="struct_member_annotations"> </td>
</tr>
......@@ -8514,6 +8521,6 @@ as - List of pack file checksums in which this object appears</p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-Root-partition-mount-point.html" title="Root partition mount point">
<link rel="next" href="ostree-SELinux-policy-management.html" title="SELinux policy management">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -546,6 +546,6 @@ events will be queued.</p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-In-memory-modifiable-filesystem-tree.html" title="In-memory modifiable filesystem tree">
<link rel="next" href="ostree-Progress-notification-system-for-asynchronous-operations.html" title="Progress notification system for asynchronous operations">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -1990,6 +1990,6 @@ later, instead.</p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-Progress-notification-system-for-asynchronous-operations.html" title="Progress notification system for asynchronous operations">
<link rel="next" href="ostree-Simple-upgrade-class.html" title="Simple upgrade class">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -484,6 +484,6 @@ ostree_sepolicy_fscreatecon_cleanup (<em class="parameter"><code><span class="ty
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-SELinux-policy-management.html" title="SELinux policy management">
<link rel="next" href="ostree-GPG-signature-verification-results.html" title="GPG signature verification results">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -710,6 +710,6 @@ with /etc, and update the bootloader configuration.</p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-GPG-signature-verification-results.html" title="GPG signature verification results">
<link rel="next" href="ostree-ostree-chain-input-stream.html" title="ostree-chain-input-stream">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -256,6 +256,6 @@ ostree_bootconfig_parser_get (<em class="parameter"><code><a class="link" href="
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-ostree-bootconfig-parser.html" title="ostree-bootconfig-parser">
<link rel="next" href="ostree-ostree-checksum-input-stream.html" title="ostree-checksum-input-stream">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -84,6 +84,6 @@ ostree_chain_input_stream_new (<em class="parameter"><code><span class="type">GP
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-ostree-chain-input-stream.html" title="ostree-chain-input-stream">
<link rel="next" href="ostree-ostree-deployment.html" title="ostree-deployment">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -85,6 +85,6 @@ ostree_checksum_input_stream_new (<em class="parameter"><code><span class="type"
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-ostree-checksum-input-stream.html" title="ostree-checksum-input-stream">
<link rel="next" href="ostree-ostree-diff.html" title="ostree-diff">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -640,6 +640,6 @@ ostree_deployment_unlocked_state_to_string
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -8,7 +8,7 @@
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-ostree-deployment.html" title="ostree-deployment">
<link rel="next" href="ostree-ostree-repo-file.html" title="ostree-repo-file">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -363,6 +363,6 @@ ostree_diff_print (<em class="parameter"><code><span class="type">GFile</span> *
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -7,7 +7,7 @@
<link rel="home" href="index.html" title="OSTree API references">
<link rel="up" href="reference.html" title="API Reference">
<link rel="prev" href="ostree-ostree-diff.html" title="ostree-diff">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -261,6 +261,6 @@ ostree_repo_file_tree_query_child (<em class="parameter"><code><a class="link" h
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
......@@ -501,6 +501,7 @@
<keyword type="member" name="OstreeRepoTransactionStats.content-objects-total" link="ostree-OstreeRepo.html#OstreeRepoTransactionStats.content-objects-total"/>
<keyword type="member" name="OstreeRepoTransactionStats.content-objects-written" link="ostree-OstreeRepo.html#OstreeRepoTransactionStats.content-objects-written"/>
<keyword type="member" name="OstreeRepoTransactionStats.content-bytes-written" link="ostree-OstreeRepo.html#OstreeRepoTransactionStats.content-bytes-written"/>
<keyword type="member" name="OstreeRepoTransactionStats.devino-cache-hits" link="ostree-OstreeRepo.html#OstreeRepoTransactionStats.devino-cache-hits"/>
<keyword type="member" name="OstreeRepoTransactionStats.padding1" link="ostree-OstreeRepo.html#OstreeRepoTransactionStats.padding1"/>
<keyword type="member" name="OstreeRepoTransactionStats.padding2" link="ostree-OstreeRepo.html#OstreeRepoTransactionStats.padding2"/>
<keyword type="member" name="OstreeRepoTransactionStats.padding3" link="ostree-OstreeRepo.html#OstreeRepoTransactionStats.padding3"/>
......
......@@ -8,7 +8,7 @@
<link rel="up" href="index.html" title="OSTree API references">
<link rel="prev" href="index.html" title="OSTree API references">
<link rel="next" href="ostree-Core-repository-independent-functions.html" title="Core repository-independent functions">
<meta name="generator" content="GTK-Doc V1.28 (XML mode)">
<meta name="generator" content="GTK-Doc V1.29 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
......@@ -1828,6 +1828,6 @@ OSTREE_YEAR_VERSION, macro in ostree-version
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.28</div>
<hr>Generated by GTK-Doc V1.29</div>
</body>
</html>
\ No newline at end of file
2018.7
\ No newline at end of file
2019.1
\ No newline at end of file
#!/bin/sh
#! /bin/sh
# Wrapper for compilers which do not understand '-c -o'.
scriptversion=2016-01-11.22; # UTC
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1999-2017 Free Software Foundation, Inc.
# Copyright (C) 1999-2018 Free Software Foundation, Inc.
# Written by Tom Tromey <tromey@cygnus.com>.
#
# This program is free software; you can redistribute it and/or modify
......@@ -17,7 +17,7 @@ scriptversion=2016-01-11.22; # UTC
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
......@@ -340,7 +340,7 @@ exit $ret
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC0"
......
This diff is collapsed.
This diff is collapsed.
#!/bin/sh
#! /bin/sh
# depcomp - compile a program generating dependencies as side-effects
scriptversion=2016-01-11.22; # UTC
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1999-2017 Free Software Foundation, Inc.
# Copyright (C) 1999-2018 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
......@@ -16,7 +16,7 @@ scriptversion=2016-01-11.22; # UTC
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
......@@ -783,7 +783,7 @@ exit 0
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC0"
......
#!/bin/sh
# install - install a program, script, or datafile
scriptversion=2016-01-11.22; # UTC
scriptversion=2018-03-11.20; # UTC
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
......@@ -271,15 +271,18 @@ do
fi
dst=$dst_arg
# If destination is a directory, append the input filename; won't work
# if double slashes aren't ignored.
# If destination is a directory, append the input filename.
if test -d "$dst"; then
if test "$is_target_a_directory" = never; then
echo "$0: $dst_arg: Is a directory" >&2
exit 1
fi
dstdir=$dst
dst=$dstdir/`basename "$src"`
dstbase=`basename "$src"`
case $dst in
*/) dst=$dst$dstbase;;
*) dst=$dst/$dstbase;;
esac
dstdir_status=0
else
dstdir=`dirname "$dst"`
......@@ -288,6 +291,11 @@ do
fi
fi
case $dstdir in
*/) dstdirslash=$dstdir;;
*) dstdirslash=$dstdir/;;
esac
obsolete_mkdir_used=false
if test $dstdir_status != 0; then
......@@ -324,34 +332,43 @@ do
# is incompatible with FreeBSD 'install' when (umask & 300) != 0.
;;
*)
# Note that $RANDOM variable is not portable (e.g. dash); Use it
# here however when possible just to lower collision chance.
tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0
trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0
# Because "mkdir -p" follows existing symlinks and we likely work
# directly in world-writeable /tmp, make sure that the '$tmpdir'
# directory is successfully created first before we actually test
# 'mkdir -p' feature.
if (umask $mkdir_umask &&
exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1
$mkdirprog $mkdir_mode "$tmpdir" &&
exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1
then
if test -z "$dir_arg" || {
# Check for POSIX incompatibilities with -m.
# HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
# other-writable bit of parent directory when it shouldn't.
# FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
ls_ld_tmpdir=`ls -ld "$tmpdir"`
test_tmpdir="$tmpdir/a"
ls_ld_tmpdir=`ls -ld "$test_tmpdir"`
case $ls_ld_tmpdir in
d????-?r-*) different_mode=700;;
d????-?--*) different_mode=755;;
*) false;;
esac &&
$mkdirprog -m$different_mode -p -- "$tmpdir" && {
ls_ld_tmpdir_1=`ls -ld "$tmpdir"`
$mkdirprog -m$different_mode -p -- "$test_tmpdir" && {
ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"`
test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
}
}
then posix_mkdir=:
fi
rmdir "$tmpdir/d" "$tmpdir"
rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir"
else
# Remove any dirs left behind by ancient mkdir implementations.
rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null
rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null
fi
trap '' 0;;
esac;;
......@@ -427,8 +444,8 @@ do
else
# Make a couple of temp file names in the proper directory.
dsttmp=$dstdir/_inst.$$_
rmtmp=$dstdir/_rm.$$_
dsttmp=${dstdirslash}_inst.$$_
rmtmp=${dstdirslash}_rm.$$_
# Trap to clean up those temp files at exit.
trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
......@@ -493,7 +510,7 @@ do
done
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC0"
......
......@@ -2124,7 +2124,7 @@ fi
# a configuration failure hint, and exit.
func_fatal_configuration ()
{
func__fatal_error ${1+"$@"} \
func_fatal_error ${1+"$@"} \
"See the $PACKAGE documentation for more information." \
"Fatal configuration error."
}
......
#!/bin/sh
#! /bin/sh
# Common wrapper for a few potentially missing GNU programs.
scriptversion=2016-01-11.22; # UTC
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 1996-2017 Free Software Foundation, Inc.
# Copyright (C) 1996-2018 Free Software Foundation, Inc.
# Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
# This program is free software; you can redistribute it and/or modify
......@@ -17,7 +17,7 @@ scriptversion=2016-01-11.22; # UTC
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
......@@ -101,9 +101,9 @@ else
exit $st
fi
perl_URL=http://www.perl.org/
flex_URL=http://flex.sourceforge.net/
gnu_software_URL=http://www.gnu.org/software
perl_URL=https://www.perl.org/
flex_URL=https://github.com/westes/flex
gnu_software_URL=https://www.gnu.org/software
program_details ()
{
......@@ -207,7 +207,7 @@ give_advice "$1" | sed -e '1s/^/WARNING: /' \
exit $st
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC0"
......
#!/bin/sh
#! /bin/sh
# test-driver - basic testsuite driver script.
scriptversion=2016-01-11.22; # UTC
scriptversion=2018-03-07.03; # UTC
# Copyright (C) 2011-2017 Free Software Foundation, Inc.
# Copyright (C) 2011-2018 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
......@@ -16,7 +16,7 @@ scriptversion=2016-01-11.22; # UTC
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
......@@ -140,7 +140,7 @@ echo ":copy-in-global-log: $gcopy" >> $trs_file
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# eval: (add-hook 'before-save-hook 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC0"
......
......@@ -6,7 +6,7 @@
/* Define if we are enabling ostree trivial-httpd entrypoint */
#undef BUILDOPT_ENABLE_TRIVIAL_HTTPD_CMDLINE
/* Define if we enable http2 */
/* Define if we enable http2 by default */
#undef BUILDOPT_HTTP2
/* Define if doing a development build */
......
This diff is collapsed.
......@@ -3,8 +3,8 @@ dnl If doing a final release, remember to follow the instructions to
dnl update libostree-released.sym from libostree-devel.sym, and update the checksum
dnl in test-symbols.sh, and also set is_release_build=yes below. Then make
dnl another post-release commit to bump the version, and set is_release_build=no.
m4_define([year_version], [2018])
m4_define([release_version], [9])
m4_define([year_version], [2019])
m4_define([release_version], [1])
m4_define([package_version], [year_version.release_version])
AC_INIT([libostree], [package_version], [walters@verbum.org])
is_release_build=yes
......@@ -141,7 +141,7 @@ AS_HELP_STRING([--disable-http2],
[Disable use of http2 (default: no)]),,
[enable_http2=yes])
AS_IF([test x$enable_http2 != xno ], [
AC_DEFINE([BUILDOPT_HTTP2], 1, [Define if we enable http2])
AC_DEFINE([BUILDOPT_HTTP2], 1, [Define if we enable http2 by default])
], [
OSTREE_FEATURES="$OSTREE_FEATURES no-http2"
])
......
ostree (2019.1-1~bpo9+1) stretch-backports; urgency=medium
* Rebuild for stretch-backports.
- debian/gbp.conf: Adjust for this branch
-- Simon McVittie <smcv@debian.org> Thu, 31 Jan 2019 08:50:45 +0000
ostree (2019.1-1) unstable; urgency=medium
* New upstream release
* d/copyright: Update
* Standards-Version: 4.3.0 (no changes required)
-- Simon McVittie <smcv@debian.org> Mon, 14 Jan 2019 08:23:44 +0000
ostree (2018.9.1-1~bpo9+1) stretch-backports; urgency=medium
* Rebuild for stretch-backports.
......
......@@ -46,7 +46,7 @@ Build-Depends:
Build-Depends-Indep:
libglib2.0-doc,
Rules-Requires-Root: no
Standards-Version: 4.2.1
Standards-Version: 4.3.0
Homepage: https://github.com/ostreedev/ostree/
Vcs-Git: https://salsa.debian.org/debian/ostree.git
Vcs-Browser: https://salsa.debian.org/debian/ostree
......
......@@ -24,6 +24,7 @@ Copyright:
© 2017-2018 Endless Mobile, Inc.
© 2018 Matthew Leeds
© 2018 Sinny Kumari
© 2019 Rafael Fonseca
License: LGPL-2+
Files:
......
......@@ -212,6 +212,7 @@ html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files) $(expand_con
for file in $(HTML_IMAGES) ; do \
test -f $(abs_srcdir)/$$file && cp $(abs_srcdir)/$$file $(abs_builddir)/html; \
test -f $(abs_builddir)/$$file && cp $(abs_builddir)/$$file $(abs_builddir)/html; \
test -f $$file && cp $$file $(abs_builddir)/html; \
done;
$(GTK_DOC_V_XREF)gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
$(AM_V_at)touch html-build.stamp
......
......@@ -44,9 +44,7 @@ APIs not defined in GLib yet, such as `glnx_autofd`.
Contributing
------------
Currently there is not a Bugzilla product - one may be created
in the future. You can submit PRs against the Github mirror:
Development happens in GNOME Gitlab: https://gitlab.gnome.org/GNOME/libglnx
https://github.com/GNOME/libglnx/pulls
Or alternatively, email one of the maintainers directly.
(If you're seeing this on the Github mirror, we used to do development
on Github but that was before GNOME deployed Gitlab.)
......@@ -1002,8 +1002,7 @@ glnx_file_copy_at (int src_dfd,
* contents. This and other behavior can be controlled via @flags.
*
* Note that no metadata from the existing file is preserved, such as
* uid/gid or extended attributes. The default mode will be `0666`,
* modified by umask.
* uid/gid or extended attributes. The default mode will be `0644`.
*/
gboolean
glnx_file_replace_contents_at (int dfd,
......@@ -1025,7 +1024,7 @@ glnx_file_replace_contents_at (int dfd,
* @subpath: Subpath
* @buf: (array len=len) (element-type guint8): File contents
* @len: Length (if `-1`, assume @buf is `NUL` terminated)
* @mode: File mode; if `-1`, use `0666 - umask`
* @mode: File mode; if `-1`, use `0644`
* @flags: Flags
* @cancellable: Cancellable
* @error: Error
......
......@@ -24,8 +24,23 @@
#include <glnx-shutil.h>
#include <glnx-errors.h>
#include <glnx-fdio.h>
#include <glnx-local-alloc.h>
static gboolean
unlinkat_allow_noent (int dfd,
const char *path,
int flags,
GError **error)
{
if (unlinkat (dfd, path, flags) == -1)
{
if (errno != ENOENT)
return glnx_throw_errno_prefix (error, "unlinkat(%s)", path);
}
return TRUE;
}
static gboolean
glnx_shutil_rm_rf_children (GLnxDirFdIterator *dfd_iter,
GCancellable *cancellable,
......@@ -51,16 +66,13 @@ glnx_shutil_rm_rf_children (GLnxDirFdIterator *dfd_iter,
if (!glnx_shutil_rm_rf_children (&child_dfd_iter, cancellable, error))
return FALSE;
if (unlinkat (dfd_iter->fd, dent->d_name, AT_REMOVEDIR) == -1)
return glnx_throw_errno_prefix (error, "unlinkat");
if (!glnx_unlinkat (dfd_iter->fd, dent->d_name, AT_REMOVEDIR, error))
return FALSE;
}
else
{
if (unlinkat (dfd_iter->fd, dent->d_name, 0) == -1)
{
if (errno != ENOENT)
return glnx_throw_errno_prefix (error, "unlinkat");
}
if (!unlinkat_allow_noent (dfd_iter->fd, dent->d_name, 0, error))
return FALSE;
}
}
......@@ -86,7 +98,6 @@ glnx_shutil_rm_rf_at (int dfd,
{
dfd = glnx_dirfd_canonicalize (dfd);
/* With O_NOFOLLOW first */
glnx_autofd int target_dfd =
openat (dfd, path, O_RDONLY | O_NONBLOCK | O_DIRECTORY | O_CLOEXEC | O_NOFOLLOW);
......@@ -100,8 +111,8 @@ glnx_shutil_rm_rf_at (int dfd,
}
else if (errsv == ENOTDIR || errsv == ELOOP)
{
if (unlinkat (dfd, path, 0) != 0)
return glnx_throw_errno_prefix (error, "unlinkat");
if (!glnx_unlinkat (dfd, path, 0, error))
return FALSE;
}
else
return glnx_throw_errno_prefix (error, "open(%s)", path);
......@@ -113,13 +124,10 @@ glnx_shutil_rm_rf_at (int dfd,
return FALSE;
if (!glnx_shutil_rm_rf_children (&dfd_iter, cancellable, error))
return FALSE;
return glnx_prefix_error (error, "Removing %s", path);
if (unlinkat (dfd, path, AT_REMOVEDIR) == -1)
{
if (errno != ENOENT)
return glnx_throw_errno_prefix (error, "unlinkat");
}
if (!unlinkat_allow_noent (dfd, path, AT_REMOVEDIR, error))
return FALSE;
}
return TRUE;
......
......@@ -138,7 +138,11 @@ Boston, MA 02111-1307, USA.
</para>
<para>
If <varname>min-free-space-size</varname> is set to a non-zero
value, <varname>min-free-space-percent</varname> is ignored.
value, <varname>min-free-space-percent</varname> is ignored. Note
that, <varname>min-free-space-percent</varname> is not enforced on
metadata objects. It is assumed that metadata objects are relatively
small in size compared to content objects and thus kept outside the
scope of this option.
</para>
</listitem>
</varlistentry>
......@@ -156,7 +160,10 @@ Boston, MA 02111-1307, USA.
<para>
If this option is set to a non-zero value, and
<varname>min-free-space-percent</varname> is also set, this option
takes priority.
takes priority. Note that, <varname>min-free-space-size</varname> is
not enforced on metadata objects. It is assumed that metadata objects
are relatively small in size compared to content objects and thus kept
outside the scope of this option.
</para>
</listitem>
</varlistentry>
......
......@@ -432,6 +432,7 @@ Boston, MA 02111-1307, USA.
<refsect1>
<title>Examples</title>
<para>
For specific examples, please see the man page regarding the specific ostree command. For example:
</para>
......@@ -445,28 +446,32 @@ Boston, MA 02111-1307, USA.
<para>
OSTree supports signing commits with GPG. Operations on the system
repository by default use keyring files in
repository by default use keyring files in
<filename>/usr/share/ostree/trusted.gpg.d</filename>. Any
public key in a keyring file in that directory will be
trusted by the client. No private keys should be present
in this directory.
</para>
<para>
In addition to the system repository, OSTree supports two
other paths. First, there is a
<literal>gpgkeypath</literal> option for remotes, which must
point to the filename of an ASCII-armored key.
</para>
<para>Second, there is support for a per-remote
<filename><replaceable>remotename</replaceable>.trustedkeys.gpg</filename>
file stored in the toplevel of the repository (alongside
<filename>objects/</filename> and such). This is
particularly useful when downloading content that may not
be fully trusted (e.g. you want to inspect it but not
deploy it as an OS), or use it for containers. This file
is written via <command>ostree remote add
--gpg-import</command>.
</para>
In addition to the system repository, OSTree supports two
other paths. First, there is a
<literal>gpgkeypath</literal> option for remotes, which must point
to the filename of an ASCII-armored GPG key, or a directory containing
ASCII-armored GPG keys to import. Multiple file and directory paths
to import from can be specified, as a comma-separated list of paths. This option
may be specified by using <command>--set</command> in <command>ostree remote add</command>.
</para>
<para>
Second, there is support for a per-remote
<filename><replaceable>remotename</replaceable>.trustedkeys.gpg</filename>
file stored in the toplevel of the repository (alongside
<filename>objects/</filename> and such). This is
particularly useful when downloading content that may not
be fully trusted (e.g. you want to inspect it but not
deploy it as an OS), or use it for containers. This file
is written via <command>ostree remote add
--gpg-import</command>.
</para>
</refsect1>
<refsect1>
......
#!/bin/sh
# The builtin grub.cfg generator.
# The builtin grub.cfg generator. This script is called by
# ostree/src/libostree/ostree-bootloader-grub2.c whenever boot loader
# configuration file needs to be updated on systems which do not use
# grub2-mkconfig (and thus, the `ostree admin instutil grub2-generate` path).
#
# This script is called by ostree/src/libostree/ostree-bootloader-grub2.c whenever
# boot loader configuration file needs to be updated. It can be used as a template
# for a custom grub.cfg generator. What to consider when writing a custom grub.cfg
# generator:
# It can be used as a template for a custom grub.cfg generator. What to consider
# when writing a custom grub.cfg generator:
#
# - The populate_menu() function converts boot loader entries as defined by
# https://www.freedesktop.org/wiki/Specifications/BootLoaderSpec/ into GRUB2
......@@ -32,6 +33,7 @@ read_config()
initrd=""
options=""
linux=""
devicetree=""
while read -r line
do
......@@ -47,6 +49,9 @@ read_config()
"linux")
linux=${value}
;;
"devicetree")
devicetree=${value}
;;
"options")
options=${value}
;;
......@@ -73,6 +78,9 @@ populate_menu()
if [ -n "${initrd}" ] ; then
menu="${menu}\t initrd ${boot_prefix}${initrd}\n"
fi
if [ -n "${devicetree}" ] ; then
menu="${menu}\t devicetree ${boot_prefix}${devicetree}\n"
fi
menu="${menu}}\n\n"
done
# The printf command seems to be more reliable across shells for special character (\n, \t) evaluation
......
......@@ -18,6 +18,8 @@
***/
/* Add new symbols here. Release commits should copy this section into -released.sym. */
LIBOSTREE_2018.10 {
} LIBOSTREE_2018.9;
/* Stub section for the stable release *after* this development one; don't
* edit this other than to update the last number. This is just a copy/paste
......
......@@ -191,6 +191,7 @@ _ostree_bootloader_grub2_generate_config (OstreeSysroot *sysroot
const char *options;
const char *kernel;
const char *initrd;
const char *devicetree;
char *quoted_title = NULL;
char *uuid = NULL;
char *quoted_uuid = NULL;
......@@ -246,6 +247,15 @@ _ostree_bootloader_grub2_generate_config (OstreeSysroot *sysroot
g_string_append_c (output, '\n');
}
devicetree = ostree_bootconfig_parser_get (config, "devicetree");
if (devicetree)
{
g_string_append (output, "devicetree");
g_string_append_c (output, ' ');
g_string_append (output, devicetree);
g_string_append_c (output, '\n');
}
g_string_append (output, "}\n");
}
......
......@@ -626,9 +626,9 @@ ostree_content_stream_parse (gboolean compressed,
cancellable, error))
return FALSE;
g_autoptr(GVariant) file_header =
g_variant_new_from_data (compressed ? _OSTREE_ZLIB_FILE_HEADER_GVARIANT_FORMAT : _OSTREE_FILE_HEADER_GVARIANT_FORMAT,
buf, archive_header_size, trusted,
g_free, buf);
g_variant_ref_sink(g_variant_new_from_data (compressed ? _OSTREE_ZLIB_FILE_HEADER_GVARIANT_FORMAT : _OSTREE_FILE_HEADER_GVARIANT_FORMAT,
buf, archive_header_size, trusted,
g_free, buf));
buf = NULL;
g_autoptr(GFileInfo) ret_file_info = NULL;
g_autoptr(GVariant) ret_xattrs = NULL;
......
......@@ -777,7 +777,6 @@ initiate_next_curl_request (FetcherRequest *req,
* there are numerous HTTP/2 fixes since the original version in
* libcurl 7.43.0.
*/
#ifdef BUILDOPT_HTTP2
if (!(self->config_flags & OSTREE_FETCHER_FLAGS_DISABLE_HTTP2))
{
#if CURL_AT_LEAST_VERSION(7, 51, 0)
......@@ -789,7 +788,7 @@ initiate_next_curl_request (FetcherRequest *req,
curl_easy_setopt (req->easy, CURLOPT_PIPEWAIT, 1L);
#endif
}
#endif
curl_easy_setopt (req->easy, CURLOPT_WRITEFUNCTION, write_cb);
if (g_getenv ("OSTREE_DEBUG_HTTP"))
curl_easy_setopt (req->easy, CURLOPT_VERBOSE, 1L);
......
......@@ -304,12 +304,82 @@ _ostree_gpg_verifier_add_key_ascii_file (OstreeGpgVerifier *self,
g_ptr_array_add (self->key_ascii_files, g_strdup (path));
}
gboolean
_ostree_gpg_verifier_add_keyfile_path (OstreeGpgVerifier *self,
const char *path,
GCancellable *cancellable,
GError **error)
{
g_autoptr(GError) temp_error = NULL;
if (!_ostree_gpg_verifier_add_keyfile_dir_at (self, AT_FDCWD, path,
cancellable, &temp_error))
{
g_assert (temp_error);
/* If failed due to not being a directory, add the file as an ascii key. */
if (g_error_matches (temp_error, G_IO_ERROR, G_IO_ERROR_NOT_DIRECTORY))
{
g_clear_error (&temp_error);
_ostree_gpg_verifier_add_key_ascii_file (self, path);
}
else
{
g_propagate_error (error, g_steal_pointer (&temp_error));
return FALSE;
}
}
return TRUE;
}
/* Add files that exist one level below the directory at @path as ascii
* key files. If @path cannot be opened as a directory,
* an error is returned.
*/
gboolean
_ostree_gpg_verifier_add_keyfile_dir_at (OstreeGpgVerifier *self,
int dfd,
const char *path,
GCancellable *cancellable,
GError **error)
{
g_auto(GLnxDirFdIterator) dfd_iter = { 0, };
if (!glnx_dirfd_iterator_init_at (dfd, path, FALSE,
&dfd_iter, error))
return FALSE;
g_debug ("Adding GPG keyfile dir %s to verifier", path);
while (TRUE)
{
struct dirent *dent;
if (!glnx_dirfd_iterator_next_dent_ensure_dtype (&dfd_iter, &dent,
cancellable, error))
return FALSE;
if (dent == NULL)
break;
if (dent->d_type != DT_REG)
continue;
/* TODO: Potentially open the files here and have the GPG verifier iterate
over the fds. See https://github.com/ostreedev/ostree/pull/1773#discussion_r235421900. */
g_autofree char *iter_path = g_build_filename (path, dent->d_name, NULL);
_ostree_gpg_verifier_add_key_ascii_file (self, iter_path);
}
return TRUE;
}
gboolean
_ostree_gpg_verifier_add_keyring_dir (OstreeGpgVerifier *self,
GFile *path,
GCancellable *cancellable,
GError **error)
{
return _ostree_gpg_verifier_add_keyring_dir_at (self, AT_FDCWD,
gs_file_get_path_cached (path),
......@@ -322,7 +392,6 @@ _ostree_gpg_verifier_add_keyring_dir_at (OstreeGpgVerifier *self,
const char *path,
GCancellable *cancellable,
GError **error)
{
g_auto(GLnxDirFdIterator) dfd_iter = { 0, };
if (!glnx_dirfd_iterator_init_at (dfd, path, FALSE,
......
......@@ -75,4 +75,17 @@ void _ostree_gpg_verifier_add_keyring_file (OstreeGpgVerifier *self,
void _ostree_gpg_verifier_add_key_ascii_file (OstreeGpgVerifier *self,
const char *path);
gboolean
_ostree_gpg_verifier_add_keyfile_path (OstreeGpgVerifier *self,
const char *path,
GCancellable *cancellable,
GError **error);
gboolean
_ostree_gpg_verifier_add_keyfile_dir_at (OstreeGpgVerifier *self,
int dfd,
const char *path,
GCancellable *cancellable,
GError **error);
G_END_DECLS
......@@ -33,23 +33,14 @@ static char *
split_keyeq (char *arg)
{
char *eq;
eq = strchr (arg, '=');
if (eq)
{
/* Note key/val are in one malloc block,
* so we don't free val...
*/
*eq = '\0';
return eq+1;
}
else
{
/* ...and this allows us to insert a constant
* string.
*/
return "";
}
if (eq == NULL)
return NULL;
// Note: key/val are in a single allocation block, so we don't free val.
*eq = '\0';
return eq+1;
}
static gboolean
......@@ -264,8 +255,10 @@ _ostree_kernel_args_to_strv (OstreeKernelArgs *kargs)
for (j = 0; j < values->len; j++)
{
const char *value = values->pdata[j];
g_ptr_array_add (strv, g_strconcat (key, "=", value, NULL));
if (value == NULL)
g_ptr_array_add (strv, g_strconcat (key, NULL));
else
g_ptr_array_add (strv, g_strconcat (key, "=", value, NULL));
}
}
g_ptr_array_add (strv, NULL);
......@@ -297,14 +290,12 @@ _ostree_kernel_args_to_string (OstreeKernelArgs *kargs)
else
g_string_append_c (buf, ' ');
if (value && *value)
g_string_append (buf, key);
if (value != NULL)
{
g_string_append (buf, key);
g_string_append_c (buf, '=');
g_string_append (buf, value);
}
else
g_string_append (buf, key);
}
}
......
......@@ -35,6 +35,7 @@
#include "ostree-repo-private.h"
#define WHITEOUT_PREFIX ".wh."
#define OPAQUE_WHITEOUT_NAME ".wh..wh..opq"
/* Per-checkout call state/caching */
typedef struct {
......@@ -879,6 +880,7 @@ checkout_tree_at_recurse (OstreeRepo *self,
GError **error)
{
gboolean did_exist = FALSE;
gboolean is_opaque_whiteout = FALSE;
const gboolean sepolicy_enabled = options->sepolicy && !self->disable_xattrs;
g_autoptr(GVariant) dirtree = NULL;
g_autoptr(GVariant) dirmeta = NULL;
......@@ -912,6 +914,22 @@ checkout_tree_at_recurse (OstreeRepo *self,
return TRUE; /* Note early return */
}
if (options->process_whiteouts)
{
g_autoptr(GVariant) dir_file_contents = g_variant_get_child_value (dirtree, 0);
GVariantIter viter;
const char *fname;
g_autoptr(GVariant) contents_csum_v = NULL;
g_variant_iter_init (&viter, dir_file_contents);
while (g_variant_iter_loop (&viter, "(&s@ay)", &fname, &contents_csum_v))
{
is_opaque_whiteout = (g_str_equal (fname, OPAQUE_WHITEOUT_NAME));
if (is_opaque_whiteout)
break;
}
contents_csum_v = NULL; /* iter_loop freed it */
}
/* First, make the directory. Push a new scope in case we end up using
* setfscreatecon().
*/
......@@ -931,6 +949,13 @@ checkout_tree_at_recurse (OstreeRepo *self,
return FALSE;
}
/* If it is an opaque whiteout, ensure the destination is empty first. */
if (is_opaque_whiteout)
{
if (!glnx_shutil_rm_rf_at (destination_parent_fd, destination_name, cancellable, error))
return FALSE;
}
/* Create initially with mode 0700, then chown/chmod only when we're
* done. This avoids anyone else being able to operate on partially
* constructed dirs.
......
......@@ -1624,9 +1624,18 @@ ostree_repo_prepare_transaction (OstreeRepo *self,
self->txn.max_blocks = bfree - self->reserved_blocks;
else
{
self->cleanup_stagedir = TRUE;
g_mutex_unlock (&self->txn_lock);
return throw_min_free_space_error (self, 0, error);
self->txn.max_blocks = 0;
/* Don't throw_min_free_space_error here; reason being that
* this transaction could be just committing metadata objects
* which are relatively small in size and we do not really
* want to block them via min-free-space-* value. Metadata
* objects helps in housekeeping and hence should be kept
* out of the strict min-free-space values.
*
* The main drivers for writing content objects will always honor
* the min-free-space value and throw_min_free_space_error in
* case of overstepping the number of reserved blocks.
*/
}
g_mutex_unlock (&self->txn_lock);
......@@ -3338,6 +3347,9 @@ write_content_to_mtree_internal (OstreeRepo *self,
if (!glnx_shutil_rm_rf_at (dfd_iter->fd, name, cancellable, error))
return FALSE;
}
g_mutex_lock (&self->txn_lock);
self->txn.stats.devino_cache_hits++;
g_mutex_unlock (&self->txn_lock);
return TRUE; /* Early return */
}
}
......@@ -3469,6 +3481,10 @@ write_content_to_mtree_internal (OstreeRepo *self,
if (!ostree_mutable_tree_replace_file (mtree, name, loose_checksum,
error))
return FALSE;
g_mutex_lock (&self->txn_lock);
self->txn.stats