syncthing.scm 52 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251
  1. ;;; GNU Guix --- Functional package management for GNU
  2. ;;; Copyright © 2016 Petter <petter@mykolab.ch>
  3. ;;; Copyright © 2016, 2017, 2018 Leo Famulari <leo@famulari.name>
  4. ;;;
  5. ;;; This file is part of GNU Guix.
  6. ;;;
  7. ;;; GNU Guix is free software; you can redistribute it and/or modify it
  8. ;;; under the terms of the GNU General Public License as published by
  9. ;;; the Free Software Foundation; either version 3 of the License, or (at
  10. ;;; your option) any later version.
  11. ;;;
  12. ;;; GNU Guix is distributed in the hope that it will be useful, but
  13. ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
  14. ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. ;;; GNU General Public License for more details.
  16. ;;;
  17. ;;; You should have received a copy of the GNU General Public License
  18. ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
  19. (define-module (gnu packages syncthing)
  20. #:use-module (guix build-system go)
  21. #:use-module (guix build-system trivial)
  22. #:use-module (guix packages)
  23. #:use-module (guix download)
  24. #:use-module (guix git-download)
  25. #:use-module (guix licenses)
  26. #:use-module (gnu packages)
  27. #:use-module (gnu packages golang))
  28. (define-public syncthing
  29. (package
  30. (name "syncthing")
  31. (version "1.0.1")
  32. (source (origin
  33. (method url-fetch)
  34. (uri (string-append "https://github.com/syncthing/syncthing"
  35. "/releases/download/v" version
  36. "/syncthing-source-v" version ".tar.gz"))
  37. (sha256
  38. (base32
  39. "0gas07lxm5d2c21axgcs90r779rj9sk3jymnnffxz457rvpr2qn3"))
  40. ;; Since the update to Go 1.11, Go programs have been keeping
  41. ;; spurious references to all their dependencies:
  42. ;; <https://bugs.gnu.org/33620>.
  43. ;; For Syncthing, this increases the size of the 'out' closure
  44. ;; from 87.6 MiB to 253.5 MiB. So, we use the bundled
  45. ;; dependencies until the bug is resolved.
  46. ; (modules '((guix build utils)))
  47. ; ;; Delete bundled ("vendored") free software source code.
  48. ; (snippet '(begin
  49. ; (delete-file-recursively "vendor")
  50. ; #t))
  51. ))
  52. (build-system go-build-system)
  53. ;; The primary Syncthing executable goes to "out", while the auxiliary
  54. ;; server programs and utility tools go to "utils". This reduces the size
  55. ;; of "out" by ~80 MiB.
  56. (outputs '("out" "utils"))
  57. (arguments
  58. `(#:import-path "github.com/syncthing/syncthing"
  59. #:unpack-path "github.com/syncthing"
  60. ;; We don't need to install the source code for end-user applications.
  61. #:install-source? #f
  62. #:phases
  63. (modify-phases %standard-phases
  64. (add-before 'build 'increase-test-timeout
  65. (lambda _
  66. (substitute* "src/github.com/syncthing/syncthing/build.go"
  67. (("120s") "999s"))
  68. #t))
  69. (replace 'build
  70. (lambda _
  71. (with-directory-excursion "src/github.com/syncthing/syncthing"
  72. (invoke "go" "run" "build.go" "-no-upgrade"))))
  73. (replace 'check
  74. (lambda _
  75. (with-directory-excursion "src/github.com/syncthing/syncthing"
  76. (invoke "go" "run" "build.go" "test"))))
  77. (replace 'install
  78. (lambda* (#:key outputs #:allow-other-keys)
  79. (let ((out (assoc-ref outputs "out"))
  80. (utils (assoc-ref outputs "utils"))
  81. (src "src/github.com/syncthing/syncthing/bin/"))
  82. (install-file (string-append src "/syncthing")
  83. (string-append out "/bin"))
  84. (delete-file (string-append src "/syncthing"))
  85. (copy-recursively "src/github.com/syncthing/syncthing/bin/"
  86. (string-append utils "/bin"))
  87. #t)))
  88. (add-after 'install 'install-docs
  89. (lambda* (#:key outputs #:allow-other-keys)
  90. (let* ((out (assoc-ref outputs "out"))
  91. (utils (assoc-ref outputs "utils"))
  92. (man "/share/man")
  93. (man-section (string-append man "/man"))
  94. (src "src/github.com/syncthing/syncthing/man/"))
  95. ;; Install all the man pages to "out".
  96. (for-each
  97. (lambda (file)
  98. (install-file file
  99. (string-append out man-section
  100. (string-take-right file 1))))
  101. (find-files src "\\.[1-9]"))
  102. ;; Copy all the man pages to "utils"
  103. (copy-recursively (string-append out man)
  104. (string-append utils man))
  105. ;; Delete extraneous man pages from "out" and "utils",
  106. ;; respectively.
  107. (delete-file (string-append out man "/man1/stdiscosrv.1"))
  108. (delete-file (string-append out man "/man1/strelaysrv.1"))
  109. (delete-file (string-append utils man "/man1/syncthing.1"))
  110. #t))))))
  111. (synopsis "Decentralized continuous file system synchronization")
  112. (description "Syncthing is a peer-to-peer file synchronization tool that
  113. supports a wide variety of computing platforms. It uses the Block Exchange
  114. Protocol.")
  115. (home-page "https://github.com/syncthing/syncthing")
  116. (license mpl2.0)))
  117. (define-public go-github-com-audriusbutkevicius-go-nat-pmp
  118. (let ((commit "452c97607362b2ab5a7839b8d1704f0396b640ca")
  119. (revision "0"))
  120. (package
  121. (name "go-github-com-audriusbutkevicius-go-nat-pmp")
  122. (version (git-version "0.0.0" revision commit))
  123. (source (origin
  124. (method git-fetch)
  125. (uri (git-reference
  126. (url "https://github.com/AudriusButkevicius/go-nat-pmp")
  127. (commit commit)))
  128. (file-name (git-file-name name version))
  129. (sha256
  130. (base32 "1accmpl1llk16a19nlyy991fqrgfay6l53gb64hgmdfmqljdvbk7"))))
  131. (build-system go-build-system)
  132. (arguments
  133. `(#:import-path "github.com/AudriusButkevicius/go-nat-pmp"))
  134. (synopsis "Port mapping and discovery of external IP address")
  135. (description "This packages provides a Go client for the NAT-PMP internet
  136. protocol for port mapping and discovering the external IP address of a
  137. firewall.")
  138. (home-page "https://github.com/AudriusButkevicius/go-nat-pmp")
  139. (license asl2.0))))
  140. (define-public go-github-com-bkaradzic-go-lz4
  141. (let ((commit "7224d8d8f27ef618c0a95f1ae69dbb0488abc33a")
  142. (revision "0"))
  143. (package
  144. (name "go-github-com-bkaradzic-go-lz4")
  145. (version (git-version "0.0.0" revision commit))
  146. (source (origin
  147. (method git-fetch)
  148. (uri (git-reference
  149. (url "https://github.com/bkaradzic/go-lz4")
  150. (commit commit)))
  151. (file-name (git-file-name name version))
  152. (sha256
  153. (base32
  154. "10lmya17vdqg2pvqni0p73iahni48s1v11ya9a0hcz4jh5vw4dkb"))))
  155. (build-system go-build-system)
  156. (arguments
  157. `(#:import-path "github.com/bkaradzic/go-lz4"))
  158. (synopsis "LZ4 compression algorithm")
  159. (description "This package provides @code{go-lz4}, a Go implementation of
  160. the LZ4 compression algorithm.")
  161. (home-page "https://github.com/bkaradzic/go-lz4")
  162. (license bsd-2))))
  163. (define-public go-github-com-calmh-du
  164. (package
  165. (name "go-github-com-calmh-du")
  166. (version "1.0.1")
  167. (source (origin
  168. (method git-fetch)
  169. (uri (git-reference
  170. (url "https://github.com/calmh/du")
  171. (commit (string-append "v" version))))
  172. (file-name (git-file-name name version))
  173. (sha256
  174. (base32
  175. "0qb3a6y3p9nkyn3s66k6zcm16y8n8578qh23ddj14cxf2scrr2n2"))))
  176. (build-system go-build-system)
  177. (arguments
  178. `(#:import-path "github.com/calmh/du"))
  179. (synopsis "Get total and available disk space of a given volume")
  180. (description "This is a Go implementation of `du`. It provides disk usage
  181. information, such as how much storage space is available, free, and used.")
  182. (home-page "https://github.com/calmh/du")
  183. (license public-domain)))
  184. (define-public go-github-com-calmh-xdr
  185. (let ((commit "08e072f9cb164f943a92eb59f90f3abc64ac6e8f")
  186. (revision "0"))
  187. (package
  188. (name "go-github-com-calmh-xdr")
  189. (version (git-version "2.0.1" revision commit))
  190. (source (origin
  191. (method git-fetch)
  192. (uri (git-reference
  193. (url "https://github.com/calmh/xdr")
  194. (commit commit)))
  195. (file-name (git-file-name name version))
  196. (sha256
  197. (base32
  198. "072wqdncz3nd4a3zkhvzzx1y3in1lm29wfvl0d8wrnqs5pyqh0mh"))))
  199. (build-system go-build-system)
  200. (arguments
  201. `(#:import-path "github.com/calmh/xdr"))
  202. (synopsis "XDR marshalling and unmarshalling")
  203. (description "XDR is an External Data Representation (XDR)
  204. marshalling and unmarshalling library in Go. It uses code generation and not
  205. reflection.")
  206. (home-page "https://github.com/calmh/xdr")
  207. (license expat))))
  208. (define-public go-github-com-d4l3k-messagediff
  209. (let ((commit "29f32d820d112dbd66e58492a6ffb7cc3106312b")
  210. (revision "0"))
  211. (package
  212. (name "go-github-com-d4l3k-messagediff")
  213. (version (git-version "1.1.0" revision commit))
  214. (source (origin
  215. (method git-fetch)
  216. (uri (git-reference
  217. (url "https://github.com/d4l3k/messagediff")
  218. (commit commit)))
  219. (file-name (git-file-name name version))
  220. (sha256
  221. (base32
  222. "104hl8x57ciaz7mzafg1vp9qggxcyfm8hsv9bmlihbz9ml3nyr8v"))))
  223. (build-system go-build-system)
  224. (arguments
  225. `(#:import-path "github.com/d4l3k/messagediff"))
  226. (synopsis "Diff arbitrary Go structs")
  227. (description "Messagediff is a library for calculating diffs of arbitrary
  228. structs in the Go programming language.")
  229. (home-page "https://github.com/d4l3k/messagediff")
  230. (license expat))))
  231. (define-public go-github-com-gobwas-glob
  232. (let ((commit "51eb1ee00b6d931c66d229ceeb7c31b985563420")
  233. (revision "0"))
  234. (package
  235. (name "go-github-com-gobwas-glob")
  236. (version (git-version "0.0.0" revision commit))
  237. (source (origin
  238. (method git-fetch)
  239. (uri (git-reference
  240. (url "https://github.com/gobwas/glob")
  241. (commit commit)))
  242. (file-name (git-file-name name version))
  243. (sha256
  244. (base32
  245. "090wzpwsjana1qas8ipwh1pj959gvc4b7vwybzi01f3bmd79jwlp"))))
  246. (build-system go-build-system)
  247. (arguments
  248. `(#:import-path "github.com/gobwas/glob"))
  249. (synopsis "Go globbing library")
  250. (description "This packages provides a Go implementation of globs.")
  251. (home-page "https://github.com/gobwas/glob")
  252. (license expat))))
  253. (define-public go-github-com-golang-groupcache-lru
  254. (let ((commit "84a468cf14b4376def5d68c722b139b881c450a4")
  255. (revision "1"))
  256. (package
  257. (name "go-github-com-golang-groupcache-lru")
  258. (version (git-version "0.0.0" revision commit))
  259. (source (origin
  260. (method git-fetch)
  261. (uri (git-reference
  262. (url "https://github.com/golang/groupcache")
  263. (commit commit)))
  264. (file-name (git-file-name name version))
  265. (sha256
  266. (base32
  267. "1ky1r9qh54yi9zp2769qrjngzndgd8fn7mja2qfac285n06chmcn"))))
  268. (build-system go-build-system)
  269. (arguments
  270. `(#:import-path "github.com/golang/groupcache/lru"
  271. #:unpack-path "github.com/golang/groupcache"))
  272. (synopsis "Groupcache is a caching and cache-filling library")
  273. (description "Groupcache is a caching and cache-filling library, intended
  274. as a replacement for memcached in many cases. It provides a data loading
  275. mechanism with caching and de-duplication that works across a set of peer
  276. processes.")
  277. (home-page "https://github.com/golang/groupcache")
  278. (license asl2.0))))
  279. (define-public go-github-com-golang-snappy
  280. (let ((commit "553a641470496b2327abcac10b36396bd98e45c9")
  281. (revision "0"))
  282. (package
  283. (name "go-github-com-golang-snappy")
  284. (version (git-version "0.0.0" revision commit))
  285. (source (origin
  286. (method git-fetch)
  287. (uri (git-reference
  288. (url "https://github.com/golang/snappy")
  289. (commit commit)))
  290. (file-name (git-file-name name version))
  291. (sha256
  292. (base32
  293. "0kssxnih1l722hx9219c7javganjqkqhvl3i0hp0hif6xm6chvqk"))))
  294. (build-system go-build-system)
  295. (arguments
  296. `(#:import-path "github.com/golang/snappy"))
  297. (synopsis "Snappy compression format in the Go programming language")
  298. (description "This package provides a Go implementation of the Snappy
  299. compression format.")
  300. (home-page "https://github.com/golang/snappy")
  301. (license bsd-3))))
  302. (define-public go-github-com-jackpal-gateway
  303. (let ((commit "5795ac81146e01d3fab7bcf21c043c3d6a32b006")
  304. (revision "0"))
  305. (package
  306. (name "go-github-com-jackpal-gateway")
  307. (version (git-version "0.0.0" revision commit))
  308. (source (origin
  309. (method git-fetch)
  310. (uri (git-reference
  311. (url "https://github.com/jackpal/gateway")
  312. (commit commit)))
  313. (file-name (git-file-name name version))
  314. (sha256
  315. (base32
  316. "0fkwkwmhfadwk3cha8616bhqxfkr9gjjnynhhxyldlphixgs3f25"))))
  317. (build-system go-build-system)
  318. (arguments
  319. `(#:import-path "github.com/jackpal/gateway"))
  320. (synopsis "Discover the address of a LAN gateway")
  321. (description "@code{gateway} is a Go library for discovering the IP
  322. address of the default LAN gateway.")
  323. (home-page "https://github.com/jackpal/gateway")
  324. (license bsd-3))))
  325. (define-public go-github-com-lib-pq
  326. (let ((commit "83612a56d3dd153a94a629cd64925371c9adad78")
  327. (revision "1"))
  328. (package
  329. (name "go-github-com-lib-pq")
  330. (version (git-version "0.0.0" revision commit))
  331. (source (origin
  332. (method git-fetch)
  333. (uri (git-reference
  334. (url "https://github.com/lib/pq")
  335. (commit commit)))
  336. (file-name (git-file-name name version))
  337. (sha256
  338. (base32
  339. "12334yigh284k5cdvb9pgxaq6n78205jcbp75ajz44vvfd4wi6qc"))))
  340. (build-system go-build-system)
  341. (arguments
  342. `(#:import-path "github.com/lib/pq"
  343. ;; The tests seem to fail without access to the network or a running
  344. ;; Postgres instance.
  345. #:tests? #f))
  346. (synopsis "Golang Postgres driver for Go's database/sql")
  347. (description "This packages provides a pure Go Postgres driver for Go's
  348. database/sql package.")
  349. (home-page "https://github.com/lib/pq")
  350. (license expat))))
  351. (define-public go-github-com-oschwald-geoip2-golang
  352. (package
  353. (name "go-github-com-oschwald-geoip2-golang")
  354. (version "1.1.0")
  355. (source (origin
  356. (method git-fetch)
  357. (uri (git-reference
  358. (url "https://github.com/oschwald/geoip2-golang")
  359. (commit (string-append "v" version))))
  360. (file-name (git-file-name name version))
  361. (sha256
  362. (base32
  363. "0v698bzs8lb59cqpsa9cf4sl8rdsvnnmaravhbfn6g6i511ppclr"))))
  364. (build-system go-build-system)
  365. (propagated-inputs
  366. `(("go-github-com-oschwald-maxminddb-golang"
  367. ,go-github-com-oschwald-maxminddb-golang)
  368. ("go-golang-org-x-sys-unix" ,go-golang-org-x-sys-unix)))
  369. (arguments
  370. `(#:import-path "github.com/oschwald/geoip2-golang"
  371. #:tests? #f)) ; Requires some unpackaged software and test data
  372. (synopsis "MaxMind GeoIP2 reader")
  373. (description "This packages provides a library for reading MaxMind
  374. GeoLite2 and GeoIP2 databases in Go.")
  375. (home-page "https://github.com/oschwald/geoip2-golang")
  376. (license isc)))
  377. (define-public go-github-com-oschwald-maxminddb-golang
  378. (let ((commit "26fe5ace1c706491c2936119e1dc69c1a9c04d7f")
  379. (revision "0"))
  380. (package
  381. (name "go-github-com-oschwald-maxminddb-golang")
  382. (version (git-version "1.2.0" revision commit))
  383. (source (origin
  384. (method git-fetch)
  385. (uri (git-reference
  386. (url "https://github.com/oschwald/maxminddb-golang")
  387. (commit commit)))
  388. (file-name (git-file-name name version))
  389. (sha256
  390. (base32
  391. "1i6d935f3cv9djpjvc2ibh8aps8jqvg454b9pkwg2h98al759ggk"))))
  392. (build-system go-build-system)
  393. (propagated-inputs
  394. `(("go-golang-org-x-sys-unix" ,go-golang-org-x-sys-unix)))
  395. (arguments
  396. `(#:import-path "github.com/oschwald/maxminddb-golang"
  397. #:tests? #f)) ; Requires some unpackaged software and test data
  398. (synopsis "MaxMind DB Reader for Go")
  399. (description "This is a Go reader for the MaxMind DB format. Although
  400. this can be used to read GeoLite2 and GeoIP2 databases, @code{geoip2} provides a
  401. higher-level API for doing so.")
  402. (home-page "https://github.com/oschwald/maxminddb-golang")
  403. (license isc))))
  404. (define-public go-github-com-stathat-go
  405. (let ((commit "74669b9f388d9d788c97399a0824adbfee78400e")
  406. (revision "0"))
  407. (package
  408. (name "go-github-com-stathat-go")
  409. (version (git-version "0.0.0" revision commit))
  410. (source (origin
  411. (method git-fetch)
  412. (uri (git-reference
  413. (url "https://github.com/stathat/go")
  414. (commit commit)))
  415. (file-name (git-file-name name version))
  416. (sha256
  417. (base32
  418. "1zzlsl24dyr202qkr2pay22m6d0gb7ssms77wgdx0r0clgm7dihw"))))
  419. (build-system go-build-system)
  420. (arguments
  421. `(#:import-path "github.com/stathat/go"))
  422. (synopsis "Post statistics to StatHat")
  423. (description "This is a Go package for posting to a StatHat account.")
  424. (home-page "https://github.com/stathat/go")
  425. (license expat))))
  426. (define-public go-github-com-rcrowley-go-metrics
  427. (let ((commit "e181e095bae94582363434144c61a9653aff6e50")
  428. (revision "1"))
  429. (package
  430. (name "go-github-com-rcrowley-go-metrics")
  431. (version (git-version "0.0.0" revision commit))
  432. (source (origin
  433. (method git-fetch)
  434. (uri (git-reference
  435. (url "https://github.com/rcrowley/go-metrics")
  436. (commit commit)))
  437. (file-name (git-file-name name version))
  438. (sha256
  439. (base32
  440. "1pwkyw801hy7n94skzk6h177zqcil6ayrmb5gs3jdpsfayh8ia5w"))))
  441. (build-system go-build-system)
  442. (arguments
  443. `(#:import-path "github.com/rcrowley/go-metrics"))
  444. (propagated-inputs
  445. `(("go-github-com-stathat-go" ,go-github-com-stathat-go)))
  446. (synopsis "Go port of Coda Hale's Metrics library")
  447. (description "This package provides a Go implementation of Coda Hale's
  448. Metrics library.")
  449. (home-page "https://github.com/rcrowley/go-metrics")
  450. (license bsd-2))))
  451. (define-public go-github-com-sasha-s-go-deadlock
  452. (let ((commit "03d40e5dbd5488667a13b3c2600b2f7c2886f02f")
  453. (revision "1"))
  454. (package
  455. (name "go-github-com-sasha-s-go-deadlock")
  456. (version (git-version "0.1.0" revision commit))
  457. (source (origin
  458. (method git-fetch)
  459. (uri (git-reference
  460. (url "https://github.com/sasha-s/go-deadlock")
  461. (commit commit)))
  462. (file-name (git-file-name name version))
  463. (sha256
  464. (base32
  465. "13p7b7pakd9k1c2k0fs1hfim3c8mivz679977ai6zb01s4aw7gyg"))))
  466. (build-system go-build-system)
  467. (arguments
  468. `(#:import-path "github.com/sasha-s/go-deadlock"))
  469. (propagated-inputs
  470. `(("go-github-com-petermattis-goid" ,go-github-com-petermattis-goid)))
  471. (synopsis "Deadlock detection in go")
  472. (description "This package provides tools for detecting deadlocks at
  473. run-time in Go.")
  474. (home-page "https://github.com/sasha-s/go-deadlock")
  475. (license asl2.0))))
  476. (define-public go-github-com-syndtr-goleveldb
  477. (let ((commit "34011bf325bce385408353a30b101fe5e923eb6e")
  478. (revision "2"))
  479. (package
  480. (name "go-github-com-syndtr-goleveldb")
  481. (version (git-version "0.0.0" revision commit))
  482. (source (origin
  483. (method git-fetch)
  484. (uri (git-reference
  485. (url "https://github.com/syndtr/goleveldb")
  486. (commit commit)))
  487. (file-name (git-file-name name version))
  488. (sha256
  489. (base32
  490. "097ja0vyj6p27zrxha9nhk09fj977xsvhmd3bk2hbyvnbw4znnhd"))))
  491. (build-system go-build-system)
  492. (propagated-inputs
  493. `(("go-github-com-golang-snappy" ,go-github-com-golang-snappy)))
  494. (arguments
  495. `(#:import-path "github.com/syndtr/goleveldb/leveldb"
  496. #:unpack-path "github.com/syndtr/goleveldb"
  497. #:tests? #f)) ; XXX needs 'github.com/onsi/gomega' package
  498. (synopsis "LevelDB key/value database")
  499. (description "This is an implementation of the LevelDB key / value
  500. database in Go.")
  501. (home-page "https://github.com/syndtr/goleveldb")
  502. (license bsd-2))))
  503. (define-public go-github-com-thejerf-suture
  504. (let ((commit "bf6ee6a0b047ebbe9ae07d847f750dd18c6a9276")
  505. (revision "0"))
  506. (package
  507. (name "go-github-com-thejerf-suture")
  508. (version (git-version "3.0.0" revision commit))
  509. (source (origin
  510. (method git-fetch)
  511. (uri (git-reference
  512. (url "https://github.com/thejerf/suture")
  513. (commit commit)))
  514. (file-name (git-file-name name version))
  515. (sha256
  516. (base32
  517. "0rzx9k408vaglwnnpgpcs6y7ff7p65915nbg33rvbaz13hxwkz3y"))))
  518. (build-system go-build-system)
  519. (arguments
  520. `(#:import-path "github.com/thejerf/suture"))
  521. (synopsis "Supervisor trees for Go")
  522. (description "Suture provides Erlang-ish supervisor trees for Go.
  523. \"Supervisor trees\" -> \"sutree\" -> \"suture\" -> holds your code together
  524. when it's trying to die.
  525. It is intended to deal gracefully with the real failure cases that can occur
  526. with supervision trees (such as burning all your CPU time endlessly restarting
  527. dead services), while also making no unnecessary demands on the \"service\"
  528. code, and providing hooks to perform adequate logging with in a production
  529. environment")
  530. (home-page "https://github.com/thejerf/suture")
  531. (license expat))))
  532. (define* (go-github-com-vitrun-qart-union
  533. #:optional (packages (list go-github-com-vitrun-qart-coding
  534. go-github-com-vitrun-qart-gf256
  535. go-github-com-vitrun-qart-qr)))
  536. (package
  537. (name "go-github-com-vitrun-qart")
  538. (version (package-version go-github-com-vitrun-qart-qr))
  539. (source #f)
  540. (build-system trivial-build-system)
  541. (arguments
  542. '(#:modules ((guix build union))
  543. #:builder (begin
  544. (use-modules (ice-9 match)
  545. (guix build union))
  546. (match %build-inputs
  547. (((names . directories) ...)
  548. (union-build (assoc-ref %outputs "out")
  549. directories)
  550. #t)))))
  551. (inputs (map (lambda (package)
  552. (list (package-name package) package))
  553. packages))
  554. (synopsis "Union of qart libraries")
  555. (description "This is a union of qart libraries.")
  556. (home-page (package-home-page go-github-com-vitrun-qart-qr))
  557. (license (package-license go-github-com-vitrun-qart-qr))))
  558. (define-public go-github-com-vitrun-qart-coding
  559. (let ((commit "bf64b92db6b05651d6c25a3dabf2d543b360c0aa")
  560. (revision "0"))
  561. (package
  562. (name "go-github-com-vitrun-qart-coding")
  563. (version (git-version "0.0.0" revision commit))
  564. (source (origin
  565. (method git-fetch)
  566. (uri (git-reference
  567. (url "https://github.com/vitrun/qart")
  568. (commit commit)))
  569. (file-name (string-append "go-github-com-vitrun-qart-"
  570. version "-checkout"))
  571. (sha256
  572. (base32
  573. "1xk7qki703xmay9ghi3kq2bjf1iw9dz8wik55739d6i7sn77vvkc"))))
  574. (build-system go-build-system)
  575. (arguments
  576. `(#:import-path "github.com/vitrun/qart/coding"
  577. #:unpack-path "github.com/vitrun/qart"))
  578. (synopsis "Low-level QR coding library")
  579. (description "This package provides a library for embedding
  580. human-meaningful graphics in QR codes. However, instead of scribbling on
  581. redundant pieces and relying on error correction to preserve the meaning,
  582. @code{qart} engineers the encoded values to create the picture in a code with no
  583. inherent errors. This @code{qart} component, @code{coding}, implements
  584. low-level QR coding details.")
  585. (home-page "https://github.com/vitrun/qart/")
  586. (license bsd-3))))
  587. (define-public go-github-com-vitrun-qart-gf256
  588. (let ((commit "bf64b92db6b05651d6c25a3dabf2d543b360c0aa")
  589. (revision "0"))
  590. (package
  591. (name "go-github-com-vitrun-qart-gf256")
  592. (version (git-version "0.0.0" revision commit))
  593. (source (origin
  594. (method git-fetch)
  595. (uri (git-reference
  596. (url "https://github.com/vitrun/qart")
  597. (commit commit)))
  598. (file-name (string-append "go-github-com-vitrun-qart-"
  599. version "-checkout"))
  600. (sha256
  601. (base32
  602. "1xk7qki703xmay9ghi3kq2bjf1iw9dz8wik55739d6i7sn77vvkc"))))
  603. (build-system go-build-system)
  604. (arguments
  605. `(#:import-path "github.com/vitrun/qart/gf256"
  606. #:unpack-path "github.com/vitrun/qart"))
  607. (synopsis "Qart library for Galois Field GF(256) math")
  608. (description "This package, a component of @code{qart}, provides @code{gf256},
  609. implements arithmetic over the Galois Field GF(256).")
  610. (home-page "https://github.com/vitrun/qart")
  611. (license bsd-3))))
  612. (define-public go-github-com-vitrun-qart-qr
  613. (let ((commit "bf64b92db6b05651d6c25a3dabf2d543b360c0aa")
  614. (revision "0"))
  615. (package
  616. (name "go-github-com-vitrun-qart-qr")
  617. (version (git-version "0.0.0" revision commit))
  618. (source (origin
  619. (method git-fetch)
  620. (uri (git-reference
  621. (url "https://github.com/vitrun/qart")
  622. (commit commit)))
  623. (file-name (string-append "go-github-com-vitrun-qart-"
  624. version "-checkout"))
  625. (sha256
  626. (base32
  627. "1xk7qki703xmay9ghi3kq2bjf1iw9dz8wik55739d6i7sn77vvkc"))))
  628. (build-system go-build-system)
  629. (arguments
  630. `(#:import-path "github.com/vitrun/qart/qr"
  631. #:unpack-path "github.com/vitrun/qart"))
  632. (synopsis "Qart component for generating QR codes")
  633. (description "This package provides a library for embedding
  634. human-meaningful graphics in QR codes. However, instead of scribbling on
  635. redundant pieces and relying on error correction to preserve the meaning,
  636. @code{qart} engineers the encoded values to create the picture in a code with no
  637. inherent errors. This @code{qart} component, @code{qr}, provides QR code
  638. generation.")
  639. (home-page "https://github.com/vitrun/qart")
  640. (license bsd-3))))
  641. (define* (go-golang-org-x-net-union #:optional
  642. (packages (list go-golang-org-x-net-ipv4
  643. go-golang-org-x-net-bpf
  644. go-golang-org-x-net-ipv6
  645. go-golang-org-x-net-proxy
  646. go-golang-org-x-net-internal-iana)))
  647. (package
  648. (name "go-golang-org-x-net")
  649. (version (package-version go-golang-org-x-net-ipv4))
  650. (source #f)
  651. (build-system trivial-build-system)
  652. (arguments
  653. '(#:modules ((guix build union))
  654. #:builder (begin
  655. (use-modules (ice-9 match)
  656. (guix build union))
  657. (match %build-inputs
  658. (((names . directories) ...)
  659. (union-build (assoc-ref %outputs "out")
  660. directories)
  661. #t)))))
  662. (inputs (map (lambda (package)
  663. (list (package-name package) package))
  664. packages))
  665. (synopsis "Union of the Go net libraries")
  666. (description "A union of the Golang net libraries.")
  667. (home-page (package-home-page go-golang-org-x-net-ipv4))
  668. (license (package-license go-golang-org-x-net-ipv4))))
  669. (define* (go-golang-org-x-text-union #:optional
  670. (packages (list go-golang-org-x-text-transform
  671. go-golang-org-x-text-unicode-norm)))
  672. (package
  673. (name "go-golang-org-x-text")
  674. (version (package-version go-golang-org-x-text-transform))
  675. (source #f)
  676. (build-system trivial-build-system)
  677. (arguments
  678. '(#:modules ((guix build union))
  679. #:builder (begin
  680. (use-modules (ice-9 match)
  681. (guix build union))
  682. (match %build-inputs
  683. (((names . directories) ...)
  684. (union-build (assoc-ref %outputs "out")
  685. directories)
  686. #t)))))
  687. (inputs (map (lambda (package)
  688. (list (package-name package) package))
  689. packages))
  690. (synopsis "Union of the Go text libraries")
  691. (description "A union of the Golang text libraries.")
  692. (home-page (package-home-page go-golang-org-x-text-transform))
  693. (license (package-license go-golang-org-x-text-transform))))
  694. (define-public go-github-com-audriusbutkevicius-pfilter
  695. (let ((commit "9dca34a5b530bfc9843fa8aa2ff08ff9821032cb")
  696. (revision "2"))
  697. (package
  698. (name "go-github-com-audriusbutkevicius-pfilter")
  699. (version (git-version "0.0.0" revision commit))
  700. (source
  701. (origin
  702. (method git-fetch)
  703. (uri (git-reference
  704. (url "https://github.com/AudriusButkevicius/pfilter.git")
  705. (commit commit)))
  706. (file-name (git-file-name name version))
  707. (sha256
  708. (base32
  709. "0i4qbnwba49db27fb1y792gcvhb0m744i9q4zgwjbypqmy3bj2a5"))))
  710. (build-system go-build-system)
  711. (arguments
  712. '(#:import-path "github.com/AudriusButkevicius/pfilter"))
  713. (synopsis "Filter packets into mulitple virtual connections")
  714. (description "Pfilter is a Go package for filtering packets into multiple
  715. virtual connections from a single physical connection.")
  716. (home-page "https://github.com/AudriusButkevicius/pfilter")
  717. (license expat))))
  718. (define-public go-github-com-chmduquesne-rollinghash-adler32
  719. (let ((commit "abb8cbaf9915e48ee20cae94bcd94221b61707a2")
  720. (revision "2"))
  721. (package
  722. (name "go-github-com-chmduquesne-rollinghash-adler32")
  723. (version (git-version "0.0.0" revision commit))
  724. (source
  725. (origin
  726. (method git-fetch)
  727. (uri (git-reference
  728. (url "https://github.com/chmduquesne/rollinghash.git")
  729. (commit commit)))
  730. (file-name (git-file-name name version))
  731. (sha256
  732. (base32
  733. "0ylqb9r60q77qw0d6g9cg4yzadxzwcw74lfd25cw9yglyq0wgd3l"))))
  734. (build-system go-build-system)
  735. (arguments
  736. '(#:import-path "github.com/chmduquesne/rollinghash/adler32"
  737. #:unpack-path "github.com/chmduquesne/rollinghash"))
  738. (synopsis "Adler-32 rolling hash in Go")
  739. (description "This package provides a Go implementation of the Adler-32
  740. rolling hash.")
  741. (home-page "https://github.com/chmduquesne/rollinghash")
  742. (license expat))))
  743. (define-public go-github-com-pkg-errors
  744. (let ((commit "e881fd58d78e04cf6d0de1217f8707c8cc2249bc")
  745. (revision "1"))
  746. (package
  747. (name "go-github-com-pkg-errors")
  748. (version (git-version "0.0.0" revision commit))
  749. (source (origin
  750. (method git-fetch)
  751. (uri (git-reference
  752. (url "https://github.com/pkg/errors.git")
  753. (commit commit)))
  754. (file-name (git-file-name name version))
  755. (sha256
  756. (base32
  757. "0vfhj598jp6dzy4pbyjdrqxzb5kppw8ggvfh78g80nz11r34xnzs"))))
  758. (build-system go-build-system)
  759. (arguments
  760. `(#:import-path "github.com/pkg/errors"))
  761. (synopsis "Go error handling primitives")
  762. (description "This packages provides @code{error}, which offers simple
  763. error handling primitives in Go.")
  764. (home-page "https://github.com/pkg/errors")
  765. (license bsd-2))))
  766. (define-public go-github-com-petermattis-goid
  767. (let ((commit "3db12ebb2a599ba4a96bea1c17b61c2f78a40e02")
  768. (revision "0"))
  769. (package
  770. (name "go-github-com-petermattis-goid")
  771. (version (git-version "0.0.0" revision commit))
  772. (source (origin
  773. (method git-fetch)
  774. (uri (git-reference
  775. (url "https://github.com/petermattis/goid.git")
  776. (commit commit)))
  777. (file-name (git-file-name name version))
  778. (sha256
  779. (base32
  780. "0z18a3mr72c52g7g94n08gxw0ksnaafbfwdl5p5jav2sffirb0kd"))))
  781. (build-system go-build-system)
  782. (arguments
  783. '(#:import-path "github.com/petermattis/goid"))
  784. (synopsis "Identify the running goroutine")
  785. (description "This package offers a method of programatically retrieving
  786. the current goroutine's ID.")
  787. (home-page "https://github.com/petermattis/goid")
  788. (license asl2.0))))
  789. (define-public go-github-com-audriusbutkevicius-cli
  790. (let ((commit "7f561c78b5a4aad858d9fd550c92b5da6d55efbb")
  791. (revision "0"))
  792. (package
  793. (name "go-github-com-audriusbutkevicius-cli")
  794. (version (git-version "0.0.0" revision commit))
  795. (source (origin
  796. (method git-fetch)
  797. (uri (git-reference
  798. (url "https://github.com/AudriusButkevicius/cli.git")
  799. (commit commit)))
  800. (file-name (git-file-name name version))
  801. (sha256
  802. (base32
  803. "0bg26pfg25vr16jmczig2m493mja2nxjxyswz3hha7avxw20rpi5"))))
  804. (build-system go-build-system)
  805. (arguments
  806. '(#:import-path "github.com/AudriusButkevicius/cli"
  807. ;; Tests don't pass "vet" on go-1.11. See
  808. ;; https://github.com/AudriusButkevicius/cli/pull/1.
  809. #:phases
  810. (modify-phases %standard-phases
  811. (replace 'check
  812. (lambda* (#:key import-path #:allow-other-keys)
  813. (invoke "go" "test"
  814. "-vet=off"
  815. import-path))))))
  816. (synopsis "Library for building command-line interfaces in Go")
  817. (description "This package provides a library for building command-line
  818. interfaces in Go.")
  819. (home-page "https://github.com/AudriusButkevicius/cli")
  820. (license expat))))
  821. (define-public go-github-com-kballard-go-shellquote
  822. (let ((commit "cd60e84ee657ff3dc51de0b4f55dd299a3e136f2")
  823. (revision "0"))
  824. (package
  825. (name "go-github-com-kballard-go-shellquote")
  826. (version (git-version "0.0.0" revision commit))
  827. (source (origin
  828. (method git-fetch)
  829. (uri (git-reference
  830. (url "https://github.com/kballard/go-shellquote.git")
  831. (commit commit)))
  832. (file-name (git-file-name name version))
  833. (sha256
  834. (base32
  835. "1xjpin4jq1zl84dcn96xhjmn9bsfyszf6g9aqyj2dc0xfi6c88y0"))))
  836. (build-system go-build-system)
  837. (arguments
  838. '(#:import-path "github.com/kballard/go-shellquote"))
  839. (synopsis "Shell-style string joins and splits")
  840. (description "Shellquote provides utilities for joining/splitting strings
  841. using sh's word-splitting rules.")
  842. (home-page "https://github.com/kballard/go-shellquote")
  843. (license expat))))
  844. (define-public go-github-com-syncthing-notify
  845. (let ((commit "116c45bb5ad48777321e4984d1320d56889b6097")
  846. (revision "3"))
  847. (package
  848. (name "go-github-com-syncthing-notify")
  849. (version (git-version "0.0.0" revision commit))
  850. (source (origin
  851. (method git-fetch)
  852. (uri (git-reference
  853. (url "https://github.com/syncthing/notify")
  854. (commit commit)))
  855. (file-name (git-file-name name version))
  856. (sha256
  857. (base32
  858. "14bh95pkhwmnc65bnv08p3y4flj1j7f6xxr2cgmlwrphnlp9yhl9"))))
  859. (build-system go-build-system)
  860. (arguments
  861. '(#:import-path "github.com/syncthing/notify"))
  862. (propagated-inputs
  863. `(("go-golang-org-x-sys-unix" ,go-golang-org-x-sys-unix)))
  864. (synopsis "File system event notification library")
  865. (description "This package provides @code{notify}, a file system event
  866. notification library in Go.")
  867. (home-page "https://github.com/syncthing/notify")
  868. (license expat))))
  869. (define-public go-github-com-beorn7-perks-quantile
  870. (let ((commit "4c0e84591b9aa9e6dcfdf3e020114cd81f89d5f9")
  871. (revision "0"))
  872. (package
  873. (name "go-github-com-beorn7-perks-quantile")
  874. (version (git-version "0.0.0" revision commit))
  875. (source (origin
  876. (method git-fetch)
  877. (uri (git-reference
  878. (url "https://github.com/beorn7/perks.git")
  879. (commit commit)))
  880. (file-name (git-file-name name version))
  881. (sha256
  882. (base32
  883. "1hrybsql68xw57brzj805xx2mghydpdiysv3gbhr7f5wlxj2514y"))))
  884. (build-system go-build-system)
  885. (arguments
  886. '(#:import-path "github.com/beorn7/perks/quantile"
  887. #:unpack-path "github.com/beorn7/perks"))
  888. (synopsis "Compute approximate quantiles over an unbounded data stream")
  889. (description "Perks contains the Go package @code{quantile} that computes
  890. approximate quantiles over an unbounded data stream within low memory and CPU
  891. bounds.")
  892. (home-page "https://github.com/beorn7/perks")
  893. (license expat))))
  894. (define-public go-github-com-golang-protobuf-proto
  895. (let ((commit "1e59b77b52bf8e4b449a57e6f79f21226d571845")
  896. (revision "0"))
  897. (package
  898. (name "go-github-com-golang-protobuf-proto")
  899. (version (git-version "0.0.0" revision commit))
  900. (source (origin
  901. (method git-fetch)
  902. (uri (git-reference
  903. (url "https://github.com/golang/protobuf.git")
  904. (commit commit)))
  905. (file-name (git-file-name name version))
  906. (sha256
  907. (base32
  908. "19bkh81wnp6njg3931wky6hsnnl2d1ig20vfjxpv450sd3k6yys8"))))
  909. (build-system go-build-system)
  910. (arguments
  911. '(#:import-path "github.com/golang/protobuf/proto"
  912. #:unpack-path "github.com/golang/protobuf"
  913. #:tests? #f ; requires unpackaged golang.org/x/sync/errgroup
  914. ))
  915. (synopsis "Go support for Protocol Buffers")
  916. (description "This package provides Go support for the Protocol Buffers
  917. data serialization format.")
  918. (home-page "https://github.com/golang/protobuf")
  919. (license bsd-3))))
  920. (define-public go-github-com-prometheus-client-model-go
  921. (let ((commit "99fa1f4be8e564e8a6b613da7fa6f46c9edafc6c")
  922. (revision "0"))
  923. (package
  924. (name "go-github-com-prometheus-client-model-go")
  925. (version (git-version "0.0.2" revision commit))
  926. (source (origin
  927. (method git-fetch)
  928. (uri (git-reference
  929. (url "https://github.com/prometheus/client_model.git")
  930. (commit commit)))
  931. (file-name (git-file-name name version))
  932. (sha256
  933. (base32
  934. "19y4ywsivhpxj7ikf2j0gm9k3cmyw37qcbfi78n526jxcc7kw998"))))
  935. (build-system go-build-system)
  936. (arguments
  937. '(#:import-path "github.com/prometheus/client_model/go"
  938. #:unpack-path "github.com/prometheus/client_model"))
  939. (propagated-inputs
  940. `(("go-github-com-golang-protobuf-proto"
  941. ,go-github-com-golang-protobuf-proto)))
  942. (synopsis "Data model artifacts for Prometheus")
  943. (description "This package provides data model artifacts for Prometheus.")
  944. (home-page "https://github.com/prometheus/client_model")
  945. (license asl2.0))))
  946. (define-public go-github-com-matttproud-golang-protobuf-extensions-pbutil
  947. (let ((commit "c12348ce28de40eed0136aa2b644d0ee0650e56c")
  948. (revision "0"))
  949. (package
  950. (name "go-github-com-matttproud-golang-protobuf-extensions-pbutil")
  951. (version (git-version "1.0.0" revision commit))
  952. (source
  953. (origin
  954. (method git-fetch)
  955. (uri
  956. (git-reference
  957. (url "https://github.com/matttproud/golang_protobuf_extensions.git")
  958. (commit commit)))
  959. (file-name (git-file-name name version))
  960. (sha256
  961. (base32
  962. "1d0c1isd2lk9pnfq2nk0aih356j30k3h1gi2w0ixsivi5csl7jya"))))
  963. (build-system go-build-system)
  964. (arguments
  965. '(#:import-path "github.com/matttproud/golang_protobuf_extensions/pbutil"
  966. #:unpack-path "github.com/matttproud/golang_protobuf_extensions"))
  967. (propagated-inputs
  968. `(("go-github-com-golang-protobuf-proto"
  969. ,go-github-com-golang-protobuf-proto)))
  970. (synopsis "Streaming Protocol Buffers in Go")
  971. (description "This package provides various Protocol Buffer
  972. extensions for the Go language, namely support for record length-delimited
  973. message streaming.")
  974. (home-page "https://github.com/matttproud/golang_protobuf_extensions")
  975. (license asl2.0))))
  976. (define-public go-github-com-prometheus-common-expfmt
  977. (let ((commit "2e54d0b93cba2fd133edc32211dcc32c06ef72ca")
  978. (revision "0"))
  979. (package
  980. (name "go-github-com-prometheus-common-expfmt")
  981. (version (git-version "0.0.0" revision commit))
  982. (source (origin
  983. (method git-fetch)
  984. (uri (git-reference
  985. (url "https://github.com/prometheus/common.git")
  986. (commit commit)))
  987. (file-name (git-file-name name version))
  988. (sha256
  989. (base32
  990. "14kn5w7imcxxlfdqxl21fsnlf1ms7200g3ldy29hwamldv8qlm7j"))))
  991. (build-system go-build-system)
  992. (arguments
  993. '(#:import-path "github.com/prometheus/common/expfmt"
  994. #:unpack-path "github.com/prometheus/common"
  995. #:phases
  996. (modify-phases %standard-phases
  997. (add-before 'reset-gzip-timestamps 'make-gzip-archive-writable
  998. (lambda* (#:key outputs #:allow-other-keys)
  999. (map (lambda (file)
  1000. (make-file-writable file))
  1001. (find-files
  1002. (string-append (assoc-ref outputs "out")
  1003. "/src/github.com/prometheus/common/expfmt/testdata/")
  1004. ".*\\.gz$"))
  1005. #t))
  1006. (replace 'check
  1007. ;; Tests don't pass "vet" on go-1.11. See
  1008. ;; https://github.com/syncthing/syncthing/issues/5311.
  1009. (lambda* (#:key import-path #:allow-other-keys)
  1010. (invoke "go" "test"
  1011. "-vet=off"
  1012. import-path))))))
  1013. (propagated-inputs
  1014. `(("go-github-com-golang-protobuf-proto"
  1015. ,go-github-com-golang-protobuf-proto)
  1016. ("go-github-com-matttproud-golang-protobuf-extensions-pbutil"
  1017. ,go-github-com-matttproud-golang-protobuf-extensions-pbutil)
  1018. ("go-github-com-prometheus-client-model-go"
  1019. ,go-github-com-prometheus-client-model-go)))
  1020. (synopsis "Prometheus metrics")
  1021. (description "This package provides tools for reading and writing
  1022. Prometheus metrics.")
  1023. (home-page "https://github.com/prometheus/common")
  1024. (license asl2.0))))
  1025. (define-public go-github-com-prometheus-procfs
  1026. (let ((commit "b15cd069a83443be3154b719d0cc9fe8117f09fb")
  1027. (revision "0"))
  1028. (package
  1029. (name "go-github-com-prometheus-procfs")
  1030. (version (git-version "0.0.0" revision commit))
  1031. (source (origin
  1032. (method git-fetch)
  1033. (uri (git-reference
  1034. (url "https://github.com/prometheus/procfs.git")
  1035. (commit commit)))
  1036. (file-name (git-file-name name version))
  1037. (sha256
  1038. (base32
  1039. "1cr45wg2m40bj2za8f32mq09rjlcnk5kfam0h0hr8wcb015k4wxj"))))
  1040. (build-system go-build-system)
  1041. (arguments
  1042. '(#:import-path "github.com/prometheus/procfs"))
  1043. (synopsis "Go library for reading @file{/proc}")
  1044. (description "The @code{procfs} Go package provides functions to retrieve
  1045. system, kernel, and process metrics from the @file{/proc} pseudo file system.")
  1046. (home-page "https://github.com/prometheus/procfs")
  1047. (license asl2.0))))
  1048. (define-public go-github-com-client-golang-prometheus-promhttp
  1049. (let ((commit "180b8fdc22b4ea7750bcb43c925277654a1ea2f3")
  1050. (revision "0"))
  1051. (package
  1052. (name "go-github-com-client-golang-prometheus-promhttp")
  1053. (version (git-version "0.0.0" revision commit))
  1054. (source (origin
  1055. (method git-fetch)
  1056. (uri (git-reference
  1057. (url "https://github.com/prometheus/client_golang.git")
  1058. (commit commit)))
  1059. (file-name (git-file-name name version))
  1060. (sha256
  1061. (base32
  1062. "1kkfx1j9ka18ydsmdi2cdy3hs39c22b39mbc4laykmj2x93lmbdp"))))
  1063. (build-system go-build-system)
  1064. (arguments
  1065. '(#:tests? #f ; The tests require internet access
  1066. #:import-path "github.com/prometheus/client_golang/prometheus/promhttp"
  1067. #:unpack-path "github.com/prometheus/client_golang"))
  1068. (propagated-inputs
  1069. `(("go-github-com-beorn7-perks-quantile"
  1070. ,go-github-com-beorn7-perks-quantile)
  1071. ("go-github-com-golang-protobuf-proto"
  1072. ,go-github-com-golang-protobuf-proto)
  1073. ("go-github-com-prometheus-client-model-go"
  1074. ,go-github-com-prometheus-client-model-go)
  1075. ("go-github-com-prometheus-common-expfmt"
  1076. ,go-github-com-prometheus-common-expfmt)
  1077. ("go-github-com-prometheus-procfs" ,go-github-com-prometheus-procfs)))
  1078. (synopsis "HTTP server and client tools for Prometheus")
  1079. (description "This package @code{promhttp} provides HTTP client and
  1080. server tools for Prometheus metrics.")
  1081. (home-page "https://github.com/prometheus/client_golang")
  1082. (license asl2.0))))
  1083. (define-public go-github-com-client-golang-prometheus
  1084. (let ((commit "7e9098b20fb8e103a7a5691878272d7e3d703663")
  1085. (revision "0"))
  1086. (package
  1087. (name "go-github-com-prometheus-client-golang-prometheus")
  1088. (version (git-version "0.9.1" revision commit))
  1089. (source (origin
  1090. (method git-fetch)
  1091. (uri (git-reference
  1092. (url "https://github.com/prometheus/client_golang.git")
  1093. (commit commit)))
  1094. (file-name (git-file-name name version))
  1095. (sha256
  1096. (base32
  1097. "09q8hlvgyn58hn8fmmj535hrwhqc1215czwzf7fhaqpa9zamj4w1"))))
  1098. (build-system go-build-system)
  1099. (arguments
  1100. '(#:import-path "github.com/prometheus/client_golang/prometheus"
  1101. #:unpack-path "github.com/prometheus/client_golang"
  1102. #:tests? #f)) ; 'TestHandler' test fails in this non-critical dependency
  1103. (propagated-inputs
  1104. `(("go-github-com-beorn7-perks-quantile"
  1105. ,go-github-com-beorn7-perks-quantile)
  1106. ("go-github-com-golang-protobuf-proto"
  1107. ,go-github-com-golang-protobuf-proto)
  1108. ("go-github-com-prometheus-client-model-go"
  1109. ,go-github-com-prometheus-client-model-go)
  1110. ("go-github-com-prometheus-common-expfmt"
  1111. ,go-github-com-prometheus-common-expfmt)
  1112. ("go-github-com-prometheus-procfs" ,go-github-com-prometheus-procfs)
  1113. ("go-github-com-client-golang-prometheus-promhttp"
  1114. ,go-github-com-client-golang-prometheus-promhttp)))
  1115. (synopsis "Prometheus instrumentation library for Go applications")
  1116. (description "This package provides the Go client library for the
  1117. Prometheus monitoring and alerting system. It has two separate parts, one for
  1118. instrumenting application code, and one for creating clients that talk to the
  1119. Prometheus HTTP API.")
  1120. (home-page "https://github.com/prometheus/client_golang")
  1121. (license asl2.0))))
  1122. (define* (go-github-com-prometheus-union
  1123. #:optional (packages (list go-github-com-client-golang-prometheus
  1124. go-github-com-client-golang-prometheus-promhttp)))
  1125. (package
  1126. (name "go-github-com-prometheus-union")
  1127. (version (package-version go-github-com-client-golang-prometheus))
  1128. (source #f)
  1129. (build-system trivial-build-system)
  1130. (arguments
  1131. '(#:modules ((guix build union))
  1132. #:builder (begin
  1133. (use-modules (ice-9 match)
  1134. (guix build union))
  1135. (match %build-inputs
  1136. (((names . directories) ...)
  1137. (union-build (assoc-ref %outputs "out")
  1138. directories)
  1139. #t)))))
  1140. (inputs (map (lambda (package)
  1141. (list (package-name package) package))
  1142. packages))
  1143. (synopsis "Union of Go Prometheus libraries")
  1144. (description "This is a union of Go Prometheus libraries")
  1145. (home-page (package-home-page go-github-com-client-golang-prometheus))
  1146. (license (package-license go-github-com-client-golang-prometheus))))
  1147. (define-public go-gopkg.in-asn1-ber.v1
  1148. (package
  1149. (name "go-gopkg.in-asn1-ber.v1")
  1150. (version "1.2")
  1151. (source (origin
  1152. (method git-fetch)
  1153. (uri (git-reference
  1154. (url "https://gopkg.in/asn1-ber.v1")
  1155. (commit (string-append "v" version))))
  1156. (file-name (git-file-name name version))
  1157. (sha256
  1158. (base32
  1159. "1y8bvzbxpw0lfnn7pbcdwzqj4l90qj6xf88dvv9pxd9yl5g6cskx"))))
  1160. (build-system go-build-system)
  1161. (arguments
  1162. '(#:import-path "gopkg.in/asn1-ber.v1"
  1163. ;; Tests don't pass "vet" on go-1.11. See
  1164. ;; https://github.com/go-asn1-ber/asn1-ber/issues/20.
  1165. #:phases
  1166. (modify-phases %standard-phases
  1167. (replace 'check
  1168. (lambda* (#:key import-path #:allow-other-keys)
  1169. (invoke "go" "test"
  1170. "-vet=off"
  1171. import-path))))))
  1172. (synopsis "ASN.1 BER encoding and decoding in Go")
  1173. (description "This package provides ASN.1 BER encoding and decoding in the
  1174. Go language.")
  1175. (home-page "https://gopkg.in/asn1-ber.v1")
  1176. (license expat)))
  1177. (define-public go-gopkg.in-ldap.v2
  1178. (package
  1179. (name "go-gopkg.in-ldap.v2")
  1180. (version "2.5.1")
  1181. (source (origin
  1182. (method git-fetch)
  1183. (uri (git-reference
  1184. (url "https://gopkg.in/ldap.v2")
  1185. (commit (string-append "v" version))))
  1186. (file-name (git-file-name name version))
  1187. (sha256
  1188. (base32
  1189. "1wf81wy04nhkqs0dg5zkivr4sh37r83bxrfwjz9vr4jq6vmljr3h"))))
  1190. (build-system go-build-system)
  1191. (arguments
  1192. '(#:import-path "gopkg.in/ldap.v2"
  1193. #:tests? #f)) ; the test suite requires network access
  1194. (propagated-inputs
  1195. `(("go-gopkg.in-asn1-ber.v1" ,go-gopkg.in-asn1-ber.v1)))
  1196. (synopsis "LDAP v3 functionality for Go")
  1197. (description "This package provides basic LDAP v3 functionality in the Go
  1198. language.")
  1199. (home-page "https://gopkg.in/ldap.v2")
  1200. (license expat)))