Commit | Line | Data |
---|---|---|
9478c9d8 | 1 | ;;; GNU Guix --- Functional package management for GNU |
8f1f2784 | 2 | ;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il> |
b5f57f60 | 3 | ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com> |
261f5691 | 4 | ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org> |
5c7d6224 | 5 | ;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net> |
9478c9d8 EF |
6 | ;;; |
7 | ;;; This file is part of GNU Guix. | |
8 | ;;; | |
9 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
10 | ;;; under the terms of the GNU General Public License as published by | |
11 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
12 | ;;; your option) any later version. | |
13 | ;;; | |
14 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
15 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
17 | ;;; GNU General Public License for more details. | |
18 | ;;; | |
19 | ;;; You should have received a copy of the GNU General Public License | |
20 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
21 | ||
22 | (define-module (gnu packages connman) | |
23 | #:use-module (guix packages) | |
24 | #:use-module (guix download) | |
25 | #:use-module (guix build-system gnu) | |
26 | #:use-module (guix licenses) | |
27 | #:use-module (guix utils) | |
28 | #:use-module (gnu packages) | |
29 | #:use-module (gnu packages admin) | |
8c158517 | 30 | #:use-module (gnu packages enlightenment) |
9478c9d8 EF |
31 | #:use-module (gnu packages glib) |
32 | #:use-module (gnu packages linux) | |
33 | #:use-module (gnu packages pkg-config) | |
125e3cde | 34 | #:use-module (gnu packages polkit) |
9478c9d8 | 35 | #:use-module (gnu packages python) |
5819431c | 36 | #:use-module (gnu packages qt) |
9478c9d8 EF |
37 | #:use-module (gnu packages readline) |
38 | #:use-module (gnu packages samba) | |
39 | #:use-module (gnu packages tls) | |
40 | #:use-module (gnu packages vpn)) | |
41 | ||
42 | (define-public connman | |
43 | (package | |
44 | (name "connman") | |
723f0ce7 | 45 | (version "1.34") |
9478c9d8 EF |
46 | (source |
47 | (origin | |
48 | (method url-fetch) | |
f2bca8db | 49 | (uri (string-append "mirror://kernel.org/linux/network/connman/" |
9478c9d8 EF |
50 | name "-" version ".tar.xz")) |
51 | (sha256 | |
52 | (base32 | |
723f0ce7 | 53 | "07n71wcy1c4cc01ca4dl9k1jpdqr5nsyr33dqf7k87wwfa681859")))) |
9478c9d8 EF |
54 | (build-system gnu-build-system) |
55 | (arguments | |
56 | `(#:configure-flags | |
57 | (list "--enable-nmcompat" | |
125e3cde | 58 | "--enable-polkit" |
9478c9d8 EF |
59 | "--enable-openconnect" |
60 | "--enable-openvpn" | |
61 | "--enable-vpnc" | |
62 | "--enable-pptp" | |
63 | "--enable-l2tp" | |
028bf3c0 TČ |
64 | ;; location for daemon state files and internal configuration |
65 | ;; needs to be writeable | |
66 | "--localstatedir=/var" | |
9478c9d8 EF |
67 | (string-append |
68 | "--with-dbusconfdir=" (assoc-ref %outputs "out") "/etc") | |
69 | (string-append | |
70 | "--with-dbusdatadir=" (assoc-ref %outputs "out") "/share")))) | |
71 | (native-inputs | |
72 | `(("pkg-config", pkg-config) | |
73 | ("python" ,python-2))) | |
74 | (inputs | |
75 | `(("dbus" ,dbus) | |
76 | ("glib" ,glib) | |
77 | ("gnutls" ,gnutls) | |
78 | ("iptables" ,iptables) | |
125e3cde | 79 | ("polkit" ,polkit) ;so connman can be used by unprivileged users |
9478c9d8 EF |
80 | ("readline" ,readline) |
81 | ;; These inputs are needed for connman to include the interface to | |
82 | ;; these technologies so IF they are installed they can be used. | |
83 | ;; TODO: add neard, ofono | |
84 | ("openconnect" ,openconnect) | |
85 | ("openvpn" ,openvpn) | |
86 | ("ppp", ppp) | |
87 | ("vpnc" ,vpnc) | |
88 | ("wpa-supplicant" ,wpa-supplicant))) | |
89 | (home-page "https://01.org/connman") | |
90 | (synopsis "Connection management daemon") | |
91 | (description "Connman provides a daemon for managing Internet connections. | |
92 | The Connection Manager is designed to be slim and to use as few resources as | |
93 | possible. It is fully modular system that can be extended through plug-ins. | |
94 | The plug-in approach allows for easy adaption and modification for various use | |
95 | cases. Connman implements DNS resolving and caching, DHCP clients for both | |
96 | IPv4 and IPv6, link-local IPv4 address handling and tethering (IP connection | |
97 | sharing) to clients via USB, ethernet, WiFi, cellular and Bluetooth.") | |
98 | (license gpl2))) | |
8c158517 EF |
99 | |
100 | (define-public econnman | |
101 | (package | |
102 | (name "econnman") | |
103 | (version "1.1") | |
104 | (source | |
105 | (origin | |
106 | (method url-fetch) | |
107 | (uri (string-append "https://download.enlightenment.org/rel/apps/" | |
108 | "econnman/econnman-" version ".tar.gz")) | |
109 | (sha256 | |
110 | (base32 | |
111 | "057pwwavlvrrq26bncqnfrf449zzaim0zq717xv86av4n940gwv0")))) | |
112 | (build-system gnu-build-system) | |
113 | (arguments | |
114 | `(#:configure-flags '("--localstatedir=/var") | |
115 | #:phases | |
116 | (modify-phases %standard-phases | |
8f1f2784 EF |
117 | (add-after 'unpack 'set-home-directory |
118 | ;; FATAL: Cannot create run dir '/homeless-shelter/.run' - errno=2 | |
119 | (lambda _ (setenv "HOME" "/tmp") #t)) | |
8c158517 EF |
120 | (add-after 'install 'wrap-binary |
121 | (lambda* (#:key outputs #:allow-other-keys) | |
122 | (let* ((out (assoc-ref outputs "out")) | |
123 | (bin (string-append out "/bin/econnman-bin"))) | |
124 | (wrap-program bin | |
125 | `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH")))) | |
126 | #t)))))) | |
127 | (native-inputs `(("pkg-config" ,pkg-config))) | |
128 | (inputs | |
129 | `(("efl" ,efl) | |
130 | ("python-2" ,python-2) | |
261f5691 | 131 | ("python2-dbus" ,python2-dbus) |
8c158517 EF |
132 | ("python2-efl" ,python2-efl))) |
133 | (home-page "https://www.enlightenment.org") | |
134 | (synopsis "Connman User Interface written using the EFL") | |
135 | (description | |
136 | "An EFL user interface for the @code{connman} connection manager.") | |
137 | (license lgpl3))) | |
5819431c MO |
138 | |
139 | (define-public cmst | |
140 | (package | |
141 | (name "cmst") | |
c2bae4a2 | 142 | (version "2017.03.18") |
5819431c MO |
143 | (source |
144 | (origin | |
145 | (method url-fetch) | |
146 | (uri (string-append | |
147 | "https://github.com/andrew-bibb/cmst/releases/download/cmst-" | |
148 | version "/cmst-" version ".tar.gz")) | |
149 | (sha256 | |
c2bae4a2 | 150 | (base32 "16g9byxr1rkmrnzi6sjplpmkr8h6pqj7418jz30czqviw5qlkqwl")))) |
5819431c | 151 | (inputs |
5c7d6224 | 152 | `(("qtbase" ,qtbase))) |
5819431c | 153 | (native-inputs |
5c7d6224 | 154 | `(("qttools" ,qttools))) |
5819431c MO |
155 | (build-system gnu-build-system) |
156 | (arguments | |
157 | '(#:phases | |
158 | (modify-phases %standard-phases | |
159 | (replace 'configure | |
160 | (lambda* (#:key outputs #:allow-other-keys) | |
161 | (zero? | |
162 | (system* "qmake" | |
163 | (string-append "PREFIX=" | |
164 | (assoc-ref outputs "out")))))) | |
165 | (add-before 'install 'fix-Makefiles | |
166 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
167 | (let ((out (assoc-ref outputs "out"))) | |
168 | (substitute* (find-files "." "Makefile") | |
169 | (("INSTALL_ROOT)") | |
170 | (string-append "INSTALL_ROOT)" out)) | |
171 | (("/usr/bin") "/bin")))))))) | |
172 | (home-page "https://github.com/andrew-bibb/cmst") | |
173 | (synopsis "Qt frontend for Connman") | |
174 | (description | |
175 | "Cmst is a Qt based frontend for the @code{connman} connection manager. | |
176 | This package also provides a systemtray icon.") | |
177 | (license x11))) |