Make sure we build against older ostree (without gpg import)

This means we work on the f22 ostree version at least.
This commit is contained in:
Alexander Larsson
2015-09-29 16:12:37 +02:00
parent 279558b6bf
commit 8cd95d2621
2 changed files with 11 additions and 0 deletions

View File

@@ -120,9 +120,14 @@ import_keys (XdgAppDir *dir,
if (!open_source_stream (&input_stream, cancellable, error))
return FALSE;
#ifdef HAVE_OSTREE_REPO_REMOTE_GPG_IMPORT
if (!ostree_repo_remote_gpg_import (xdg_app_dir_get_repo (dir), remote_name, input_stream,
NULL, &imported, cancellable, error))
return FALSE;
#else
if (FALSE)
return xdg_app_fail (error, "gpg key import not supported by libostree, use --no-gpg-verify");
#endif
/* XXX If we ever add internationalization, use ngettext() here. */
g_print ("Imported %u GPG key%s to remote \"%s\"\n",

View File

@@ -59,9 +59,15 @@ AC_SUBST(BASE_LIBS)
PKG_CHECK_MODULES(SOUP, [libsoup-2.4])
AC_SUBST(SOUP_CFLAGS)
AC_SUBST(SOUP_LIBS)
PKG_CHECK_MODULES(OSTREE, [libgsystem >= 2015.1 ostree-1 >= 2015.3])
AC_SUBST(OSTREE_CFLAGS)
AC_SUBST(OSTREE_LIBS)
save_LIBS=$LIBS
LIBS=$OSTREE_LIBS
AC_CHECK_FUNCS(ostree_repo_remote_gpg_import)
LIBS=$save_LIBS
PKG_CHECK_MODULES(FUSE, [fuse])
AC_SUBST(FUSE_CFLAGS)
AC_SUBST(FUSE_LIBS)