From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id sPE9Al8P42WHYAAAqHPOHw:P1 (envelope-from ) for ; Sat, 02 Mar 2024 12:37:03 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id sPE9Al8P42WHYAAAqHPOHw (envelope-from ) for ; Sat, 02 Mar 2024 12:37:03 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=zancanaro.id.au header.s=k1 header.b=hTbPw1X3; dmarc=fail reason="SPF not aligned (relaxed)" header.from=zancanaro.id.au (policy=none); 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" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1709379422; h=from:from:sender:sender: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=VpU9AM4NPA+drRBHpyYi++DOeVse+xyDZJKKmGD/68A=; b=sCikAy/nB4we3FByCHhT6+PdVduW1ASM3wwPqcEvpCWTbEdCphl+vLp7aVQxDsICABcGUs 7EUKe+fX5xPiODZsexIDYc0eFeMWRZrHICl9PfSDqhHG1pUGnIDMP+39sVeLFtn3MVKWWz CdT3wV46QfVVi2rtO0wKOZPWB5ZVIlc4IHaOOoDzVRG0Lv50HgRO87v67ZCsmwEBcyDccM MFyqsDZH4pApNjFWkG0rKEvw2usCuFy+NApd+RXNuSRtPABiSgP+jzUiNg/DB4ZwvCbyOb 0Tox+6CVospoIo3bgk1bcyldKoF5fW7fcLRuDBNFJLWv/N0X+YVAXlXzBdyuBA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=zancanaro.id.au header.s=k1 header.b=hTbPw1X3; dmarc=fail reason="SPF not aligned (relaxed)" header.from=zancanaro.id.au (policy=none); 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" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1709379422; a=rsa-sha256; cv=none; b=G8MSEnDdwVxZE7vUaa3ZTzPnU5PIwuoCJv/7oMmWS6jrnl3/rJ5OZ4ntvIH/b/tPj9ARRc lBFCLkLlB3V4DF5vmVClv8C2KCkErxKMNXlcVl5TVUY/Yj0/eBYMCkEjBrPVt8/ZUx9OhC TvAz9pmFyY0A1xRDyH+xd8TN++3xGMuUP+RUyHWo6+foH4sRYURoUZuTHkR7GDLHNy2zgK 7xvjeYXiD5jw4k46Rtm4TsHlDSKRwc7wkM+3flvhHQ0UeqlQcEgFfjxXQVQ8zzni3S/FH6 3qSAp/U9ji8RX3cpvb2r7z31avPwwPKLibIR0jsUOTfWebeCtBKNLwJAQsPbxg== 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 9953853847 for ; Sat, 2 Mar 2024 12:37:02 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rgNfP-0002Te-4K; Sat, 02 Mar 2024 06:36:35 -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 1rgNfO-0002TH-4u for guix-patches@gnu.org; Sat, 02 Mar 2024 06:36:34 -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 1rgNfN-0003nT-SV for guix-patches@gnu.org; Sat, 02 Mar 2024 06:36:33 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rgNfq-0002oS-5y for guix-patches@gnu.org; Sat, 02 Mar 2024 06:37:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#69272] [PATCH v3 1/4] gnu: Extract prosody-module from existing prosody modules. Resent-From: Carlo Zancanaro Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 02 Mar 2024 11:37:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 69272 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 69272@debbugs.gnu.org Cc: Liliana Marie Prikler Received: via spool by 69272-submit@debbugs.gnu.org id=B69272.170937937910717 (code B ref 69272); Sat, 02 Mar 2024 11:37:02 +0000 Received: (at 69272) by debbugs.gnu.org; 2 Mar 2024 11:36:19 +0000 Received: from localhost ([127.0.0.1]:38129 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rgNf8-0002mi-U8 for submit@debbugs.gnu.org; Sat, 02 Mar 2024 06:36:19 -0500 Received: from voltorb.zancanaro.id.au ([45.77.50.64]:39162) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rgNf5-0002mR-Mi for 69272@debbugs.gnu.org; Sat, 02 Mar 2024 06:36:17 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; s=k1; bh=VpU9AM4NPA+drRB HpyYi++DOeVse+xyDZJKKmGD/68A=; h=references:in-reply-to:date:subject: cc:to:from; d=zancanaro.id.au; b=hTbPw1X33MKgUmD1wJyhSFDvIvscSW0B4UoxL BYFGvhgY6qiY+5XbrvztP6PxklD3ondIz1KSeX/xTwy7qSxd/VvIlhIGeoXvjt3kyifJg+ /s8VlCTn2tEZ14RWOrWQFRY0Jzl1XqKiT5WD+JeXqKWBry1cVzev7+DWYS8xigcQ= Received: by voltorb.zancanaro.id.au (OpenSMTPD) with ESMTPSA id 6af504b6 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Sat, 2 Mar 2024 11:35:36 +0000 (UTC) From: Carlo Zancanaro Date: Sat, 2 Mar 2024 22:35:12 +1100 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: <87v864j2kq.fsf@zancanaro.id.au> References: <87v864j2kq.fsf@zancanaro.id.au> 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: , 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-Spam-Score: 3.73 X-Spam-Score: 3.73 X-Migadu-Queue-Id: 9953853847 X-Migadu-Scanner: mx13.migadu.com X-TUID: ZRjAiVxTvhqv * gnu/packages/messaging.scm (prosody-module): New procedure. (prosody-http-upload, prosody-smacks): Use it. Change-Id: I55c69104460adbbd89c491b18f9f22681aefb92a --- gnu/packages/messaging.scm | 69 ++++++++++++++++---------------------- 1 file changed, 29 insertions(+), 40 deletions(-) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 98c1c9bf67..35e11fb5dc 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -40,6 +40,7 @@ ;;; Copyright © 2023 Giacomo Leidi ;;; Copyright © 2023 Yovan Naumovski ;;; Copyright © 2023 gemmaro +;;; Copyright © 2024 Carlo Zancanaro ;;; ;;; This file is part of GNU Guix. ;;; @@ -1577,11 +1578,18 @@ (define-public prosody protocols.") (license license:x11))) -(define-public prosody-http-upload +(define (prosody-module module-name) (let ((changeset "765735bb590b") - (revision "1")) + (revision "1") + (package-name (string-append + "prosody-" + (string-replace-substring + (if (string-prefix? "mod_" module-name) + (substring module-name 4) + module-name) + "_" "-")))) (package - (name "prosody-http-upload") + (name package-name) (version (string-append "0-" revision "." (string-take changeset 7))) (source (origin (method hg-fetch) @@ -1600,47 +1608,28 @@ (define-public prosody-http-upload (use-modules (guix build utils)) (let ((out (assoc-ref %outputs "out")) (source (assoc-ref %build-inputs "source"))) - (with-directory-excursion (in-vicinity source "mod_http_upload") - (install-file "mod_http_upload.lua" out)) + (with-directory-excursion (in-vicinity source module-name) + (install-file (string-append module-name ".lua") out)) #t)))) - (home-page "https://modules.prosody.im/mod_http_upload.html") - (synopsis "XEP-0363: Allow clients to upload files over HTTP") - (description "This module implements XEP-0363: it allows clients to -upload files over HTTP.") + (home-page #f) + (synopsis #f) + (description #f) (license (package-license prosody))))) -(define-public prosody-smacks - (let ((changeset "67f1d1f22625") - (revision "1")) - (package - (name "prosody-smacks") - (version (string-append "0-" revision "." (string-take changeset 7))) - (source (origin - (method hg-fetch) - (uri (hg-reference - (url "https://hg.prosody.im/prosody-modules/") - (changeset changeset))) - (file-name (string-append name "-" version "-checkout")) - (sha256 - (base32 - "020ngpax30fgarah98yvlj0ni8rcdwq60if03a9hqdw8mic0nxxs")))) - (build-system trivial-build-system) - (arguments - '(#:modules ((guix build utils)) - #:builder - (begin - (use-modules (guix build utils)) - (let ((out (assoc-ref %outputs "out")) - (source (assoc-ref %build-inputs "source"))) - (with-directory-excursion (in-vicinity source "mod_smacks") - (install-file "mod_smacks.lua" out)) - #t)))) - (home-page "https://modules.prosody.im/mod_smacks.html") - (synopsis "XEP-0198: Reliability and fast reconnects for XMPP") - (description "This module implements XEP-0198: when supported by both +(define-public prosody-http-upload + (package + (inherit (prosody-module "mod_http_upload")) + (synopsis "XEP-0363: Allow clients to upload files over HTTP") + (description "This module implements XEP-0363: it allows clients to +upload files over HTTP."))) + +(define-public prosody-smack + (package + (inherit (prosody-module "mod_smacks")) + (synopsis "XEP-0198: Reliability and fast reconnects for XMPP") + (description "This module implements XEP-0198: when supported by both the client and server, it can allow clients to resume a disconnected session, -and prevent message loss.") - (license (package-license prosody))))) +and prevent message loss."))) (define-public libtoxcore (let ((revision "2") base-commit: 4a0549be52f3f46fbce61342d8de30f7b83130c5 -- 2.41.0