summary refs log tree commit diff
path: root/gnu/packages/networking.scm
diff options
context:
space:
mode:
authorHartmut Goebel <h.goebel@crazy-compilers.com>2021-04-03 17:12:45 +0200
committerHartmut Goebel <h.goebel@crazy-compilers.com>2021-04-11 17:02:30 +0200
commit03e80cf42240f65346713ff414eb2ca628ef0884 (patch)
tree908e0bbe7ff37b190cf06c072971bbf87e3ff60c /gnu/packages/networking.scm
parent3281ba6eae1ead32b5146cfe6af4479dbb72593a (diff)
downloadguix-03e80cf42240f65346713ff414eb2ca628ef0884.tar.gz
gnu: Add python-pysctp.
* gnu/packages/networking.scm(python-pysctp): New variable.
Diffstat (limited to 'gnu/packages/networking.scm')
-rw-r--r--gnu/packages/networking.scm33
1 files changed, 33 insertions, 0 deletions
diff --git a/gnu/packages/networking.scm b/gnu/packages/networking.scm
index 5fe9ec26db..f7557fc331 100644
--- a/gnu/packages/networking.scm
+++ b/gnu/packages/networking.scm
@@ -42,6 +42,7 @@
 ;;; Copyright © 2020 Jesse Dowell <jessedowell@gmail.com>
 ;;; Copyright © 2020 Hamzeh Nasajpour <h.nasajpour@pantherx.org>
 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
+;;; Copyright © 2021 Hartmut Goebel <h.goebel@crazy-compilers.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -473,6 +474,38 @@ sockets, and also some helper utilities around SCTP.")
       ;; Others.
       license:gpl2+))))
 
+(define-public python-pysctp
+  (package
+    (name "python-pysctp")
+    (version "0.6.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "pysctp" version))
+       (sha256
+        (base32 "14h2qlmfi24bizhvvqkfqfa78pzm3911ibrzy9k94i97xy1978dy"))))
+    (build-system python-build-system)
+    (inputs
+     `(("lksctp-tools" ,lksctp-tools)))
+    (arguments
+     `(#:tests? #f  ;; tests require network
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-setup.py
+           (lambda _
+             (substitute* "setup.py"
+               (("include_dirs\\s*=.*")
+                (string-append "include_dirs = ['.'] + '"
+                               (getenv "C_INCLUDE_PATH") "'.split(':'),"))
+               (("library_dirs\\s*=.*")
+                (string-append "library_dirs = '"
+                               (getenv "LIBRARY_PATH") "'.split(':'),"))))))))
+    (home-page "https://github.com/p1sec/pysctp")
+    (synopsis "Python module for the SCTP protocol stack and library")
+    (description "@code{pysctp} implements the SCTP socket API.  You need a
+SCTP-aware kernel (most are).")
+    (license license:lgpl2.1+)))
+
 (define-public knockd
   (package
     (name "knockd")