1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2016 Daniel Pimentel <d4n1@d4n1.org>
4 ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
6 ;;; This file is part of GNU Guix.
8 ;;; GNU Guix is free software; you can redistribute it and/or modify it
9 ;;; under the terms of the GNU General Public License as published by
10 ;;; the Free Software Foundation; either version 3 of the License, or (at
11 ;;; your option) any later version.
13 ;;; GNU Guix is distributed in the hope that it will be useful, but
14 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
15 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 ;;; GNU General Public License for more details.
18 ;;; You should have received a copy of the GNU General Public License
19 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
21 (define-module (gnu packages protobuf)
22 #:use-module (guix packages)
23 #:use-module (guix download)
24 #:use-module (guix build-system gnu)
25 #:use-module (guix build-system python)
26 #:use-module ((guix licenses)
28 #:use-module (gnu packages compression)
29 #:use-module (gnu packages gcc)
30 #:use-module (gnu packages python))
32 (define-public protobuf
38 (uri (string-append "http://protobuf.googlecode.com/files/protobuf-"
42 "0xxn9gxhvsgzz2sgmihzf6pf75clr05mqj6218camwrwajpcbgqk"))))
43 (build-system gnu-build-system)
44 (inputs `(("zlib" ,zlib)))
45 (home-page "http://code.google.com/p/protobuf/")
46 (synopsis "Data encoding for remote procedure calls (RPCs)")
48 "Protocol Buffers are a way of encoding structured data in an efficient
49 yet extensible format. Google uses Protocol Buffers for almost all of its
50 internal RPC protocols and file formats.")
53 (define-public python-protobuf
55 (name "python-protobuf")
60 (uri (pypi-uri "protobuf" version))
63 "18zvvn8cgbcwi85ws2ny0k4qp33wd525spsb8sxvrj325mbx9cpk"))))
64 (build-system python-build-system)
66 `(("python-six" ,python-six)))
67 (home-page "https://github.com/google/protobuf")
68 (synopsis "Protocol buffers is a data interchange format")
70 "Protocol buffers are a language-neutral, platform-neutral extensible
71 mechanism for serializing structured data.")
73 (properties `((python2-variant . ,(delay python2-protobuf))))))
75 (define-public python2-protobuf
76 (package (inherit (package-with-python2
77 (strip-python2-variant python-protobuf)))
78 (native-inputs `(("python2-setuptools" ,python2-setuptools)))))