guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

03/03: gnu: Add lcsync.


From: guix-commits
Subject: 03/03: gnu: Add lcsync.
Date: Wed, 10 Aug 2022 22:26:26 -0400 (EDT)

vagrantc pushed a commit to branch master
in repository guix.

commit 6bdcd2f3f08d054f8a605fc33935c4057528cdcc
Author: Vagrant Cascadian <vagrant@debian.org>
AuthorDate: Thu May 26 14:37:32 2022 -0700

    gnu: Add lcsync.
    
    * gnu/packages/networking.scm (lcsync): New variable.
---
 gnu/packages/networking.scm | 49 +++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 49 insertions(+)

diff --git a/gnu/packages/networking.scm b/gnu/packages/networking.scm
index 25c62cadb0..741cd74df8 100644
--- a/gnu/packages/networking.scm
+++ b/gnu/packages/networking.scm
@@ -275,6 +275,55 @@ strict standards compliance.  The code does, however, 
fairly closely follow
 the RFC.")
     (license (list license:gpl2 license:gpl3))))
 
+(define-public lcsync
+  (package
+    (name "lcsync")
+    (version "0.0.1")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://codeberg.org/librecast/lcsync";)
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0s038b4xg9nlzhrganzjyfvc6n6cgd6kilnpik4axp62j2n5q11q"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:parallel-tests? #f
+       #:make-flags (let ((target ,(%current-target-system)))
+                      (list ,(string-append "CC="
+                                            (cc-for-target))
+                            ;; avoid running setcap in the install process
+                            "SETCAP_PROGRAM=true"
+                            (string-append "prefix="
+                                           (assoc-ref %outputs "out"))))
+       #:phases (modify-phases %standard-phases
+                  (delete 'configure) ;no configure script
+                  (add-before 'check 'remove-network-tests
+                    (lambda _
+                      ;; these tests require networking
+                      (delete-file "./test/0000-0027.c")
+                      (delete-file "./test/0000-0049.c")
+                      (delete-file "./test/0000-0074.c")))
+                  (replace 'check
+                    (lambda _
+                      (invoke "make" "test" "CC=gcc")))
+                  (add-before 'build 'add-library-paths
+                    (lambda* (#:key inputs #:allow-other-keys)
+                      (let* ((librecast (assoc-ref inputs "librecast")))
+                        (substitute* (list "./src/Makefile" "./test/Makefile")
+                          (("-llibrecast")
+                           (string-append "-L" librecast "/lib 
-llibrecast")))))))))
+    (inputs (list librecast libsodium))
+    (home-page "https://librecast.net/lcsync.html";)
+    (synopsis "librecast file and data syncing tool")
+    (description
+     "lcsync is a tool to sync files over IPv6 multicast or the
+local filesystem.  It splits the file into blocks, hashes them, and compares
+them in order to efficiently transfer a minimal amount of data.")
+    (license (list license:gpl2 license:gpl3))))
+
 ;; This package does not have a release yet.
 ;; But this is required to provide a feature in PipeWire.
 (define-public libcamera



reply via email to

[Prev in Thread] Current Thread [Next in Thread]