From patchwork Tue Nov 19 07:32:17 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Divya Ranjan X-Patchwork-Id: 70573 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id AED8627BBE9; Tue, 19 Nov 2024 07:36:03 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-6.4 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id D891227BBE2 for ; Tue, 19 Nov 2024 07:36:02 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tDIlt-00033T-0f; Tue, 19 Nov 2024 02:35:37 -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 1tDIlN-0002mk-PF for guix-patches@gnu.org; Tue, 19 Nov 2024 02:35:06 -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 1tDIlN-0001Bg-EP for guix-patches@gnu.org; Tue, 19 Nov 2024 02:35:05 -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=iQ0sqGB/VuQy61YMB6swJv6RLphMHJP3GaZzeBt6E5g=; b=iofIkEUXVm4ZWx14AAocy8TLbTqYlFmdkeTmdEI1OwlXNnFcKEz/bf+4NOTrzGoIBQGkwlumT87emcgp4VHdk87YXRPvJBbHiJpTabZFu6gAK+UUDG08d2ZU9qjzrLazmCv9xM8Ly4vE2U4XuAY4320cn0Y6w4kMNi1N2aLEsPnbpB/27AYJvJ+ogQHtu5aK5TcGxBGi4Tz9GYF3cIif4eDp+7fyk2xlZfNJ/q0G6yMBEsdseP6ffxIE5ER8i00AB0WYQm6NwyX0eWukoL+6OjIlmu7ApMepsLaj7ryosAunDmf8gmU2a33fZHmPb8MKiQyNlg9BN7sBJv0bxCEKAw==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tDIlN-0006zr-8p for guix-patches@gnu.org; Tue, 19 Nov 2024 02:35:05 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#74432] [rust-team 9/9] gnu: rust-apps: Add blue-recorder Resent-From: Divya Ranjan Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 19 Nov 2024 07:35:05 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74432 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: To: 74432@debbugs.gnu.org Cc: Divya Ranjan Received: via spool by 74432-submit@debbugs.gnu.org id=B74432.173200167226796 (code B ref 74432); Tue, 19 Nov 2024 07:35:05 +0000 Received: (at 74432) by debbugs.gnu.org; 19 Nov 2024 07:34:32 +0000 Received: from localhost ([127.0.0.1]:40802 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tDIkq-0006y2-AI for submit@debbugs.gnu.org; Tue, 19 Nov 2024 02:34:32 -0500 Received: from devianza.investici.org ([198.167.222.108]:58159) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tDIkn-0006xk-3h for 74432@debbugs.gnu.org; Tue, 19 Nov 2024 02:34:29 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=subvertising.org; s=stigmate; t=1732001661; bh=iQ0sqGB/VuQy61YMB6swJv6RLphMHJP3GaZzeBt6E5g=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ln3Wt6HjelZT1tw63vJw4+vbSj0jeRRUXgj6UANgZm9xOcqF9aFq/xONqVeM88Xo6 Zi418ifRgkNDlZRYZLT1D+dgl0Q66ZC4vCpgzdrynRC7t3JqFnh3Eg3R1+T7CHVs7Y mv0w/e3K4j6fbEGGSmm5JM/yhu2VyiAUW9tXEcrM= Received: from mx2.investici.org (unknown [127.0.0.1]) by devianza.investici.org (Postfix) with ESMTP id 4Xsx8F3KJTz6vTS; Tue, 19 Nov 2024 07:34:21 +0000 (UTC) Received: from [198.167.222.108] (mx2.investici.org [198.167.222.108]) (Authenticated sender: divya@subvertising.org) by localhost (Postfix) with ESMTPSA id 4Xsx8D5NrDz70Q9; Tue, 19 Nov 2024 07:34:20 +0000 (UTC) Date: Tue, 19 Nov 2024 07:32:17 +0000 Message-ID: <20241119073222.22383-11-divya@subvertising.org> X-Mailer: git-send-email 2.46.0 In-Reply-To: <20241119073222.22383-2-divya@subvertising.org> References: <20241119073222.22383-2-divya@subvertising.org> MIME-Version: 1.0 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: Divya Ranjan X-ACL-Warn: , Divya Ranjan via Guix-patches X-Patchwork-Original-From: Divya Ranjan via Guix-patches via From: Divya Ranjan Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/rust-apps.scm (blue-recorder): New variable Change-Id: Ic282f69fa2b5b4ffce938d106961c4df5e491cd3 --- gnu/packages/rust-apps.scm | 90 +++++++++++++++++++++++++++++++++++++- 1 file changed, 89 insertions(+), 1 deletion(-) diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm index 303fe44995..3f4e78a59c 100644 --- a/gnu/packages/rust-apps.scm +++ b/gnu/packages/rust-apps.scm @@ -106,7 +106,10 @@ (define-module (gnu packages rust-apps) #:use-module (gnu packages tls) #:use-module (gnu packages version-control) #:use-module (gnu packages webkit) - #:use-module (gnu packages xorg)) + #:use-module (gnu packages xorg) + #:use-module (gnu packages gstreamer) + #:use-module (gnu packages gettext) + #:use-module (gnu packages video)) (define-public aardvark-dns (package @@ -3889,3 +3892,88 @@ (define-public htmlq (synopsis "Like jq, but for HTML") (description "Extract content from HTML files using CSS selectors.") (license license:expat))) + +(define-public blue-recorder + (package + (name "blue-recorder") + (version "0.2.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/xlmnxp/blue-recorder") + (commit "1cfa3bbb1b5ea845b3e4c51eba269745f0c3e271"))) + ;; The original Cargo.toml tries to pull gdk from git, which is impossible + ;; during guix build. + (snippet #~(begin + (use-modules (guix build utils)) + (substitute* "Cargo.toml" + (("gdk = \\{ git =.+") + "gdk = { version = \"0.7.3\", package = \"gdk4\" } +")))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0fz5l1z5rq8gx2vhrpfnf5l5karlqa7m8fdwx7ixlvy5klywwa5y")))) + (build-system cargo-build-system) + (arguments + `(#:cargo-build-flags '("--release") + #:phases ,#~(modify-phases %standard-phases + ;; As per the application’s build instructions the binary + ;; needs to be wrapped with po and data paths as environment + ;; variables. + (add-after 'install 'wrap-paths + (lambda _ + (let* ((bin (string-append #$output "/bin")) + (name-version (string-append #$name "-" + #$version)) + (blue-recorder (string-append bin + "/blue-recorder")) + (src (string-append #$output + "/share/cargo/src/")) + (po (string-append src name-version "/po/")) + (data (string-append src name-version "/data/"))) + (wrap-program blue-recorder + `("PO_DIR" prefix + (,po)) + `("DATA_DIR" prefix + (,data))))))) + #:cargo-inputs (("rust-async-std" ,rust-async-std-1) + ("rust-chrono" ,rust-chrono-0.4) + ("rust-dark-light" ,rust-dark-light-1) + ("rust-dirs" ,rust-dirs-4) + ("rust-filename" ,rust-filename-0.1) + ("rust-gdk-pixbuf" ,rust-gdk-pixbuf-0.9) + ("rust-gdk4" ,rust-gdk4-0.7) + ("rust-gettext-rs" ,rust-gettext-rs-0.7) + ("rust-gio" ,rust-gio-0.15) + ("rust-glib" ,rust-glib-0.10) + ("rust-gstreamer" ,rust-gstreamer-0.21) + ("rust-gtk-sys" ,rust-gtk-sys-0.18) + ("rust-gtk4" ,rust-gtk4-0.8) + ("rust-regex" ,rust-regex-1) + ("rust-rust-ini" ,rust-rust-ini-0.18) + ("rust-secfmt" ,rust-secfmt-0.1) + ("rust-subprocess" ,rust-subprocess-0.2) + ("rust-tempfile" ,rust-tempfile-3) + ("rust-zbus" ,rust-zbus-3)))) + (native-inputs (list pkg-config + glib + graphene + gstreamer + gnu-gettext + libappindicator + xz)) + (inputs (list glib bash-minimal)) + (propagated-inputs (list ffmpeg + gtk + gtk+ + xwininfo + libappindicator + pulseaudio)) + (home-page "https://github.com/xlmnxp/blue-recorder/") + (synopsis "Simple Screen Recorder written in Rust based on Green Recorder") + (description + "A simple desktop recorder for Linux systems. +Built using GTK4 and ffmpeg. It supports recording audio and video on almost all Linux +interfaces with support for Wayland display server on GNOME session.") + (license license:gpl3)))