| 1 | ;;; GNU Guix --- Functional package management for GNU |
| 2 | ;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il> |
| 3 | ;;; |
| 4 | ;;; This file is part of GNU Guix. |
| 5 | ;;; |
| 6 | ;;; GNU Guix is free software; you can redistribute it and/or modify it |
| 7 | ;;; under the terms of the GNU General Public License as published by |
| 8 | ;;; the Free Software Foundation; either version 3 of the License, or (at |
| 9 | ;;; your option) any later version. |
| 10 | ;;; |
| 11 | ;;; GNU Guix is distributed in the hope that it will be useful, but |
| 12 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 14 | ;;; GNU General Public License for more details. |
| 15 | ;;; |
| 16 | ;;; You should have received a copy of the GNU General Public License |
| 17 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. |
| 18 | |
| 19 | (define-module (gnu packages rust-cbindgen) |
| 20 | #:use-module ((guix licenses) #:prefix license:) |
| 21 | #:use-module (guix packages) |
| 22 | #:use-module (guix download) |
| 23 | #:use-module (guix build-system cargo) |
| 24 | #:use-module (gnu packages crates-io)) |
| 25 | |
| 26 | (define-public rust-cbindgen |
| 27 | (package |
| 28 | (name "rust-cbindgen") |
| 29 | (version "0.9.1") |
| 30 | (source |
| 31 | (origin |
| 32 | (method url-fetch) |
| 33 | (uri (crate-uri "cbindgen" version)) |
| 34 | (file-name (string-append name "-" version ".crate")) |
| 35 | (sha256 |
| 36 | (base32 |
| 37 | "1zgamxahlxmg4warzivaa8m1f8d6b45mhznm7n6d7p5l18acdblx")))) |
| 38 | (build-system cargo-build-system) |
| 39 | (arguments |
| 40 | `(#:cargo-inputs |
| 41 | (("clap" ,rust-clap-2) |
| 42 | ("log" ,rust-log-0.4) |
| 43 | ("proc-macro2" ,rust-proc-macro2-1.0) |
| 44 | ("quote" ,rust-quote-1.0) |
| 45 | ("serde" ,rust-serde-1.0) |
| 46 | ("serde-json" ,rust-serde-json-1.0) |
| 47 | ("syn" ,rust-syn-1.0) |
| 48 | ("tempfile" ,rust-tempfile-3.0) |
| 49 | ("toml" ,rust-toml-0.5)) |
| 50 | #:cargo-development-inputs |
| 51 | (("ansi-term" ,rust-ansi-term-0.11) |
| 52 | ("atty" ,rust-atty-0.2) |
| 53 | ("autocfg" ,rust-autocfg-0.1) |
| 54 | ("bitflags" ,rust-bitflags-1) |
| 55 | ("cfg-if" ,rust-cfg-if-0.1) |
| 56 | ("cloudabi" ,rust-cloudabi-0.0) |
| 57 | ("fuchsia-cprng" ,rust-fuchsia-cprng-0.1) |
| 58 | ("itoa" ,rust-itoa-0.4) |
| 59 | ("libc" ,rust-libc-0.2) |
| 60 | ("numtoa" ,rust-numtoa-0.1) |
| 61 | ("rand" ,rust-rand-0.6) |
| 62 | ("rand-chacha" ,rust-rand-chacha-0.1) |
| 63 | ("rand-core" ,rust-rand-core-0.3) |
| 64 | ("rand-hc" ,rust-rand-hc-0.1) |
| 65 | ("rand-isaac" ,rust-rand-isaac-0.1) |
| 66 | ("rand-jitter" ,rust-rand-jitter-0.1) |
| 67 | ("rand-os" ,rust-rand-os-0.1) |
| 68 | ("rand-pcg" ,rust-rand-pcg-0.1) |
| 69 | ("rand-xorshift" ,rust-rand-xorshift-0.1) |
| 70 | ("rdrand" ,rust-rdrand-0.4) |
| 71 | ("redox-syscall" ,rust-redox-syscall-0.1) |
| 72 | ("redox-termios" ,rust-redox-termios-0.1) |
| 73 | ("remove-dir-all" ,rust-remove-dir-all-0.5) |
| 74 | ("ryu" ,rust-ryu-1.0) |
| 75 | ("serde-derive" ,rust-serde-derive-1.0) |
| 76 | ("strsim" ,rust-strsim-0.8) |
| 77 | ("termion" ,rust-termion-1.5) |
| 78 | ("textwrap" ,rust-textwrap-0.11) |
| 79 | ("unicode-width" ,rust-unicode-width-0.1) |
| 80 | ("unicode-xid" ,rust-unicode-xid-0.2) |
| 81 | ("vec-map" ,rust-vec-map-0.8) |
| 82 | ("winapi" ,rust-winapi-0.3)))) |
| 83 | (home-page "https://github.com/eqrion/cbindgen/") |
| 84 | (synopsis "Tool for generating C bindings to Rust code") |
| 85 | (description |
| 86 | "This package provides a tool for generating C/C++ bindings to Rust code.") |
| 87 | (license license:mpl2.0))) |