Description: Fix building kiwix-desktop with libkiwix-12.1.0 Bug: https://github.com/kiwix/kiwix-desktop/issues/964 Origin: https://github.com/kiwix/kiwix-desktop/commit/1b322d8f01c787846546a6473f153cf1daa41e65 Applied-Upstream: https://github.com/kiwix/kiwix-desktop/commit/1b322d8f01c787846546a6473f153cf1daa41e65 --- From 1b322d8f01c787846546a6473f153cf1daa41e65 Mon Sep 17 00:00:00 2001 From: Matthieu Gautier Date: Thu, 9 Feb 2023 09:47:47 +0100 Subject: [PATCH] With last version of libkiwix, Downloader now return shared_ptr. --- src/contentmanager.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/contentmanager.cpp b/src/contentmanager.cpp index c2f4ff9..d4db50a 100644 --- a/src/contentmanager.cpp +++ b/src/contentmanager.cpp @@ -173,7 +173,7 @@ QStringList ContentManager::updateDownloadInfos(QString id, const QStringList &k return values; } auto& b = mp_library->getBookById(id); - kiwix::Download* d; + std::shared_ptr d; try { d = mp_downloader->getDownload(b.getDownloadId()); } catch(...) { @@ -270,7 +270,7 @@ QString ContentManager::downloadBook(const QString &id) for (auto b : booksList) if (b.toStdString() == book.getId()) return ""; - kiwix::Download *download; + std::shared_ptr download; try { std::pair downloadDir("dir", downloadPath.toStdString()); const std::vector> options = { downloadDir }; -- 2.41.0 lass='right' method='get' action='/guix/log/build-aux/update-guix-package.scm'>
AgeCommit message (Expand)Author
2020-11-12maint: update-guix-package: Optionally add sources to store....Following discussions in <https://issues.guix.gnu.org/43893>, keeping a copy of the updated package source is desirable when generating a release. * build-aux/update-guix-package.scm (version-controlled?): Remove variable. (call-with-temporary-git-worktree): Renamed from 'with-temporary-git-worktree'. Update doc. Do not change directory implicitly. Define as a procedure, not a syntax. (keep-source-in-store): New procedure. (main): Adjust to use with call-with-temporary-git-worktree. Add the sources to the store when GUIX_ALLOW_ME_TO_USE_PRIVATE_COMMIT is set. Exit gracefully when FIND-ORIGIN-REMOTE returns #f. (%savannah-guix-git-repo-push-url-regexp): Adjust match for a potential colon separator. * Makefile.am (GUIX_ALLOW_ME_TO_USE_PRIVATE_COMMIT): Adjust. * .dir-locals.el (scheme-mode): Remove entry for with-temporary-git-worktree. * doc/contributing.texi (Updating the Guix Package): Update doc. Co-authored-by: Ludovic Courtès <ludo@gnu.org> Maxim Cournoyer
2020-10-25maint: update-guix-package: Include the git.sv.gnu.org alias....* build-aux/update-guix-package.scm (%savannah-guix-git-repo-push-url): Rename to... (%savannah-guix-git-repo-push-url-regexp): ...this. Add the 'sv' alternative to 'savannah' and the (push) suffix in the URL regexp. (find-origin-remote): Adjust accordingly. Reported-by: Ludovic Courtès <ludo@gnu.org> Maxim Cournoyer
2020-10-19maint: update-guix-package: Prevent accidentally breaking guix pull....Fixes <https://issues.guix.gnu.org/43893>. This changes the 'update-guix-package' tool so that it: 1. Always uses a clean checkout to compute the hash of the updated 'guix' package. 2. Ensures the commit used in the updated 'guix' package definition has already been pushed upstream. * build-aux/update-guix-package.scm (%savannah-guix-git-repo-push-url): New variable. (with-input-pipe-to-string, with-temporary-git-worktree): New syntaxes. (find-origin-remote, git-add-worktree): New procedures. (commit-already-pushed?): New predicate. (main): Check the commit used has already been pushed upstream and compute the hash from a clean checkout. * doc/contributing.texi (Updating the Guix Package): Document it. * .dir-locals.el (scheme-mode): Fix indentation of with-temporary-git-worktree. Maxim Cournoyer