gnu: ruby-pandoc-ruby: Use pandoc instead of ghc-pandoc.
[jackhill/guix/guix.git] / gnu / packages / upnp.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014 Sree Harsha Totakura <sreeharsha@totakura.in>
3 ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
4 ;;; Copyright © 2016, 2017, 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
5 ;;; Copyright © 2018 Theodoros Foradis <theodoros@foradis.org>
6 ;;; Copyright © 2019 Jens Mølgaard <jens@zete.tk>
7 ;;; Copyright © 2020 Jan Wielkiewicz <tona_kosmicznego_smiecia@interia.pl>
8 ;;;
9 ;;; This file is part of GNU Guix.
10 ;;;
11 ;;; GNU Guix is free software; you can redistribute it and/or modify it
12 ;;; under the terms of the GNU General Public License as published by
13 ;;; the Free Software Foundation; either version 3 of the License, or (at
14 ;;; your option) any later version.
15 ;;;
16 ;;; GNU Guix is distributed in the hope that it will be useful, but
17 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
18 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 ;;; GNU General Public License for more details.
20 ;;;
21 ;;; You should have received a copy of the GNU General Public License
22 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
23
24 (define-module (gnu packages upnp)
25 #:use-module (gnu packages)
26 #:use-module (gnu packages gettext)
27 #:use-module (gnu packages autotools)
28 #:use-module (gnu packages video)
29 #:use-module (gnu packages photo)
30 #:use-module (gnu packages image)
31 #:use-module (gnu packages mp3)
32 #:use-module (gnu packages pkg-config)
33 #:use-module (gnu packages xiph)
34 #:use-module (gnu packages sqlite)
35 #:use-module (gnu packages python)
36 #:use-module (guix build-system gnu)
37 #:use-module (guix utils)
38 #:use-module (guix download)
39 #:use-module (guix git-download)
40 #:use-module (guix licenses)
41 #:use-module (guix packages)
42 #:use-module (ice-9 match))
43
44 (define-public miniupnpc
45 (package
46 (name "miniupnpc")
47 (version "2.1.20191224")
48 (source
49 (origin
50 (method url-fetch)
51 (uri (string-append "https://miniupnp.tuxfamily.org/files/"
52 "miniupnpc-" version ".tar.gz"))
53 (sha256
54 (base32 "1kv6dpj93gckvwvgzxl4vdqpwnicb0c8p0xw53m2gh5naiw44ys4"))))
55 (build-system gnu-build-system)
56 (native-inputs
57 `(("python" ,python-2)))
58 (arguments
59 ;; The build system does not use a configure script but depends on
60 ;; `make'. Hence we should pass parameters to `make' instead and remove
61 ;; the configure phase.
62 '(#:make-flags
63 (list
64 (string-append "SH=" (assoc-ref %build-inputs "bash") "/bin/sh")
65 (string-append "INSTALLPREFIX=" (assoc-ref %outputs "out"))
66 "CC=gcc"
67
68 ;; Allow executables to find libminiupnpc.so.
69 (string-append "LDFLAGS=-Wl,-rpath="
70 (assoc-ref %outputs "out") "/lib"))
71 #:phases
72 (modify-phases %standard-phases
73 (delete 'configure)
74 (add-before 'install 'qualify-paths
75 (lambda* (#:key outputs #:allow-other-keys)
76 (substitute* "external-ip.sh"
77 (("upnpc")
78 (string-append (assoc-ref outputs "out") "/bin/upnpc")))
79 #t)))))
80 (home-page "http://miniupnp.free.fr/")
81 (synopsis "UPnP protocol client library")
82 (description
83 "The MiniUPnPc client library facilitates access to the services provided
84 by any @dfn{Universal Plug and Play} (UPnP) @dfn{Internet Gateway Device} (IGD)
85 present on the network. In UPnP terminology, MiniUPnPc is a UPnP Control Point.
86
87 It is useful whenever an application needs to listen for incoming connections
88 while running behind a UPnP-enabled router or firewall. Such applications
89 include peer-to-peer applications, active-mode FTP clients, DCC file transfers
90 over IRC, instant messaging, network games, and most server software.")
91 (license
92 (x11-style "file://LICENSE" "See 'LICENSE' file in the distribution"))))
93
94 (define-public libupnp
95 (package
96 (name "libupnp")
97 (version "1.12.1")
98 (source
99 (origin
100 (method url-fetch)
101 (uri (string-append "https://github.com/pupnp/pupnp/releases/download"
102 "/release-" version "/libupnp-" version".tar.bz2"))
103 (sha256
104 (base32
105 "02a0dnbk1cla8xlb5l2zp09grv2hsf8n4jbd560mmzj830mn8dpw"))))
106 (native-inputs
107 `(("pkg-config" ,pkg-config)))
108 (build-system gnu-build-system)
109 (arguments
110 ;; The tests require a network device capable of multicasting which is
111 ;; not available in the build environment. See
112 ;; https://lists.gnu.org/archive/html/guix-devel/2015-01/msg00312.html.
113 `(#:tests? #f
114 #:configure-flags '("--disable-static")))
115 (home-page "http://pupnp.sourceforge.net")
116 (synopsis "Portable SDK for UPnP Devices")
117 (description
118 "The portable SDK for UPnP Devices (libupnp) provides developers with an
119 API and code for building control points, devices, and bridges that are
120 compliant with Version 1.0 of the Universal Plug and Play Device Architecture
121 Specification and support several operating systems like Linux, *BSD, Solaris
122 and others.")
123 (license bsd-3)))
124
125 (define-public readymedia
126 (package
127 (name "readymedia")
128 (version "1.2.1")
129 (source
130 (origin
131 (method git-fetch)
132 (uri (git-reference
133 (url "https://git.code.sf.net/p/minidlna/git")
134 (commit (string-append
135 "v"
136 (string-map (match-lambda
137 (#\. #\_)
138 (chr chr))
139 version)))))
140 (file-name (git-file-name name version))
141 (sha256
142 (base32
143 "160915yv38k0p5zmyncs12kkbbcd8m8fk9jq70fkfd5x6dz40xm4"))))
144 (build-system gnu-build-system)
145 (native-inputs
146 `(("automake" ,automake)
147 ("autoconf" ,autoconf)
148 ("gettext" ,gettext-minimal)))
149 (inputs
150 `(("libexif" ,libexif)
151 ("libjpeg" ,libjpeg-turbo)
152 ("libid3tag" ,libid3tag)
153 ("flac" ,flac)
154 ("libvorbis" ,libvorbis)
155 ("sqlite" ,sqlite)
156 ("ffmpeg" ,ffmpeg)))
157 (home-page "https://sourceforge.net/projects/minidlna/")
158 (synopsis "DLNA/UPnP-AV media server")
159 (description "ReadyMedia (formerly known as MiniDLNA) is a simple media
160 server, which serves multimedia content to compatible clients on the network.
161 It aims to be fully compliant with DLNA and UPnP-AV standards.")
162 (license gpl2)))