From 0408934fc4d45e027ec723797e9ff6fccd15956d Mon Sep 17 00:00:00 2001 From: "Artyom V. Poptsov" Date: Sun, 11 Aug 2024 00:09:56 +0300 Subject: gnu: Add go-github-com-koron-go-ssdp. * gnu/packages/golang-web.scm (go-github-com-koron-go-ssdp): New variable. Change-Id: I870d5152d052af6976af44ce6c86d49f0f030e32 Signed-off-by: Sharlatan Hellseher --- gnu/packages/golang-web.scm | 48 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) (limited to 'gnu') diff --git a/gnu/packages/golang-web.scm b/gnu/packages/golang-web.scm index 4edbd6c18e..2257b9b399 100644 --- a/gnu/packages/golang-web.scm +++ b/gnu/packages/golang-web.scm @@ -2076,6 +2076,54 @@ jsoniter and variable type declarations (if any). jsoniter interfaces gives router.") (license license:bsd-3))) +(define-public go-github-com-koron-go-ssdp + (package + (name "go-github-com-koron-go-ssdp") + (version "0.0.4") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/koron/go-ssdp") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0agzxzlwvnhgwk6sxswjq7v1ghmf0l02gr7zpdih24i3g457af4f")))) + (build-system go-build-system) + (arguments + (list + #:import-path "github.com/koron/go-ssdp" + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-failing-tests + (lambda* (#:key tests? import-path #:allow-other-keys) + (with-directory-excursion (string-append "src/" import-path) + (substitute* (find-files "." "\\_test.go$") + ;; Test requiring network setup. + (("TestAdvertise_Alive") "OffTestAdvertise_Alive") + (("TestAdvertise_Bye") "OffTestAdvertise_Bye") + (("TestAnnounceAlive") "OffTestAnnounceAlive") + (("TestAnnounceBye") "OffTestAnnounceBye") + (("TestInterfaces") "OffTestInterfaces") + (("TestSearch_Request") "OffTestSearch_Request") + (("TestSearch_Response") "OffTestSearch_Response") + (("TestSearch_ServiceRawHeader") "OffTestSearch_ServiceRawHeader"))))) + ;; XXX: Run all tests, workaround for go-build-system's lack of Go + ;; modules support. + (replace 'check + (lambda* (#:key tests? import-path #:allow-other-keys) + (when tests? + (with-directory-excursion (string-append "src/" import-path) + (invoke "go" "test" "-v" "./...")))))))) + (propagated-inputs + (list go-golang-org-x-net)) + (home-page "https://github.com/koron/go-ssdp") + (synopsis "SSDP library for Golang") + (description + "@code{go-ssdp} is a @url{https://tools.ietf.org/html/draft-cai-ssdp-v1-03, +@acronym{Simple Service Discovery Protocol, SSDP}} library for Golang.") + (license license:expat))) + (define-public go-github-com-makeworld-the-better-one-go-gemini (package (name "go-github-com-makeworld-the-better-one-go-gemini") -- cgit v1.2.3