From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id YF7JE3xnY2fFtQAAqHPOHw:P1 (envelope-from ) for ; Thu, 19 Dec 2024 00:23:24 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id YF7JE3xnY2fFtQAAqHPOHw (envelope-from ) for ; Thu, 19 Dec 2024 01:23:24 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=kAmdMIB3; dkim=fail ("headers rsa verify failed") header.d=xn--no-cja.eu header.s=ds202402 header.b="n oqeHke"; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gnu.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1734567803; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=7MpDuXpGYIEpbbqNG1QCrmCNBR+PKZUG5gD02OD9aLQ=; b=p3IVvVTgGFg4sZXlHkxfcN/f7uCtXpvPqrDcb0i8TMmyc26Y48UaRh+q7J8kFlpK38LPzt O8tKxBoysC3DaTQcCj7bW30oZ4suJWuXPilsvf4kmbxOqFyv9y/wkzVFQaXAtcoWt5wg48 RVbXBAb9Mgr8KJ0+xfANnY4kth7phGZLYm34qXH2ni7+1PxFCLifxi8pPea+jeUMipd1dz 1vVqScFpDVO1BLq90hcFB29NkVqr3jmSx4LyoJ79YNfRJNI9gD487dKCGX98sccEPFYRqZ Za4u17leVcqfnoPuodgNpF0WGK10pTFT6QZpjgl0TM8nJov0edXm7lQs1XhRBg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1734567803; a=rsa-sha256; cv=none; b=c2i7XEq/HVkNwGXTQ8mMl+5dnqJ1fVfZVRSXQ1D26ObGbxRY/sJ3uwZjw2A+i7wlq8MSb8 5fUP9W5R5dhFaQayHhZhyqDsoI4z2MHdH3cc8piBuC55vrp+9mO+Y/1lMIC8K+8vOmRVNM eHMqZqoW8Flo/gH5H/CFIDUTuWnt8aUzSf+DzyhpV6ycs4zXx+wf3L1Db6ewOpJEB2Nw1G 3SQ3aaVOHWklKxToBZXrsSjkaDnwY0dUNQjCIikZqMq1Rqz1iqAKCID/xlr5Ygk6Nr6AW8 bLQsPQ+QizdCo6RnZph1s9Wp1N4mj2Rr5YKHm7SakYZVKF+IR21EIxq8GqkVSg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=kAmdMIB3; dkim=fail ("headers rsa verify failed") header.d=xn--no-cja.eu header.s=ds202402 header.b="n oqeHke"; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gnu.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id D103980FA9 for ; Thu, 19 Dec 2024 01:23:23 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tO4Jl-0001Gz-Fq; Wed, 18 Dec 2024 19:23:05 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tO4Jj-0001G3-TD for guix-patches@gnu.org; Wed, 18 Dec 2024 19:23:03 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tO4Jj-0006MN-KD; Wed, 18 Dec 2024 19:23:03 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:Date:From:To:Subject; bh=7MpDuXpGYIEpbbqNG1QCrmCNBR+PKZUG5gD02OD9aLQ=; b=kAmdMIB3ZYISkmE/+MreWIOXr+o9cNYD8vFqm5IkIswP38J2ljOotyGtlIz1kWkbPLO2DheCtZTmAG24YOyJMMT4MIAsK9SCYonpfuOEyJp5lzgEJMXdWoy+y7RHRXWBxLyGcR2PkFo88+4X9B0tzIp6ZxuY3RpS4+HHtq2n0AMbl/7VgmfH9JFPZ5Zze1xwmniMq2TVdGYVz/0bS4WZ9u1w9WIR2FZuMkWXCPA+M9bDDcR6xRzXw5kVZ6B1vvt6EQjP+qcJbf4DvRK9ONr5ltfR36eRdU9y7khZtVmXc9Au7i5oz0xUnw6ekoWWnn8LwdsLEIuVMWMUGLeNQTd+Sg==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tO4Jj-0002EC-3f; Wed, 18 Dec 2024 19:23:03 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#74670] [PATCH v3 1/2] pack: Support localstatedir in AppImage format. Resent-From: =?UTF-8?Q?No=C3=A9?= Lopez Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Thu, 19 Dec 2024 00:23:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74670 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 74670@debbugs.gnu.org Cc: =?UTF-8?Q?No=C3=A9?= Lopez , Christopher Baines , Josselin Poiret , Ludovic =?UTF-8?Q?Court=C3=A8s?= , Mathieu Othacehe , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?UTF-8?Q?Court=C3=A8s?= , Mathieu Othacehe , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 74670-submit@debbugs.gnu.org id=B74670.17345677278440 (code B ref 74670); Thu, 19 Dec 2024 00:23:03 +0000 Received: (at 74670) by debbugs.gnu.org; 19 Dec 2024 00:22:07 +0000 Received: from localhost ([127.0.0.1]:36531 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tO4Ip-0002C2-2z for submit@debbugs.gnu.org; Wed, 18 Dec 2024 19:22:07 -0500 Received: from smtp.domeneshop.no ([194.63.252.55]:41233) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tO4In-0002BD-H3 for 74670@debbugs.gnu.org; Wed, 18 Dec 2024 19:22:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=xn--no-cja.eu; s=ds202402; h=Content-Transfer-Encoding:Content-Type: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From:From: Sender:Reply-To:Subject:Date:Message-ID:To:Cc:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post: List-Owner:List-Archive; bh=7MpDuXpGYIEpbbqNG1QCrmCNBR+PKZUG5gD02OD9aLQ=; b=n oqeHkeKAZySEYRHad22VYOJk6fR1il3xRWB2D7Iennd7mqx/lHqajOQJmLbiyY+/wSJW3+7tUSJpW KKhkpgUZWZbYZhGuw/EKOKUX0d7Hf3VAMI/QJNWewotVCAuh7ckgkk70VczRBqfjoBa3Ni3wvQJYT RGsCO6+xzJ79eS2NGxEU15ir5K7Cj4yYfL0DTYM1pF1QLR3mjQDimkb+mjerWu1FryuMWWm13zeQs ccfLUX1zfhXcs8dwpTZJ3vKxajgxU62icUjW861fQu14ldQKcxV7puM9FmBV7csshQdYp3o0ofoqE hGTWZCImwDjyRFWMkUtV351q6gZVjwhyg==; Received: from smtp by smtp.domeneshop.no with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) id 1tO4Ih-00CPhh-FZ; Thu, 19 Dec 2024 01:21:59 +0100 Date: Thu, 19 Dec 2024 01:23:02 +0100 Message-ID: <91137c795a6d4ac347893a7388fba240962225ef.1734566923.git.noelopez@free.fr> In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: =?UTF-8?Q?No=C3=A9?= Lopez X-ACL-Warn: , =?utf-8?q?No=C3=A9_Lopez_via_Guix-patches?= From: =?utf-8?q?No=C3=A9_Lopez_via_Guix-patches?= via Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Scanner: mx11.migadu.com X-Migadu-Spam-Score: -0.71 X-Spam-Score: -0.71 X-Migadu-Queue-Id: D103980FA9 X-TUID: b1tSU+AIdLTQ From: NoƩ Lopez * guix/scripts/pack.scm (self-contained-appimage): Support localstatedir option. Change-Id: I296b3d3e442aa90f36de62a9b23aba4a2c3de9a0 --- guix/scripts/pack.scm | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/guix/scripts/pack.scm b/guix/scripts/pack.scm index d0e66c3013..7f5a5f2aa7 100644 --- a/guix/scripts/pack.scm +++ b/guix/scripts/pack.scm @@ -1018,15 +1018,22 @@ (define* (self-contained-appimage name profile compressor-name %valid-compressors))) + (define database + (and localstatedir? + (file-append (store-database (list profile)) + "/db/db.sqlite"))) + (define builder (with-extensions (list guile-gcrypt) (with-imported-modules (source-module-closure '((guix build store-copy) - (guix build utils)) + (guix build utils) + (gnu build install)) #:select? not-config?) #~(begin (use-modules (guix build utils) (guix build store-copy) + (gnu build install) (rnrs io ports) (srfi srfi-1) (srfi srfi-26)) @@ -1060,6 +1067,10 @@ (define* (self-contained-appimage name profile (string-append appdir "/" #$name ".desktop") #:name #$name #:exec #$entry-point) + ;; Install database and gc roots. + (when #+database + ;; Initialize /var/guix. + (install-database-and-gc-roots appdir #+database profile)) ;; Compress the AppDir. (invoke #+(file-append squashfs-tools "/bin/mksquashfs") appdir squashfs "-root-owned" "-noappend" -- 2.46.0