diff options
author | Julien Lepiller <julien@lepiller.eu> | 2017-08-11 20:41:39 +0200 |
---|---|---|
committer | Julien Lepiller <julien@lepiller.eu> | 2017-08-26 13:01:11 +0200 |
commit | 6febda9443e34adda38b7c365ff2d7368f589995 (patch) | |
tree | ae9b45c34a3e23c9de62fef8bac6f5065783e8bc /gnu/packages/engineering.scm | |
parent | d987a006dc35db60f0024557ea8cfcad3252dfc1 (diff) | |
download | gnu-guix-6febda9443e34adda38b7c365ff2d7368f589995.tar gnu-guix-6febda9443e34adda38b7c365ff2d7368f589995.tar.gz |
gnu: Add capstone.
* gnu/packages/engineering.scm (capstone): New variable.
Diffstat (limited to 'gnu/packages/engineering.scm')
-rw-r--r-- | gnu/packages/engineering.scm | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm index 650ac2b89c..db8dbff1eb 100644 --- a/gnu/packages/engineering.scm +++ b/gnu/packages/engineering.scm @@ -5,6 +5,7 @@ ;;; Copyright © 2016 David Thompson <davet@gnu.org> ;;; Copyright © 2016, 2017 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2016, 2017 Theodoros Foradis <theodoros.for@openmailbox.org> +;;; Copyright © 2017 Julien Lepiller <julien@lepiller.eu> ;;; ;;; This file is part of GNU Guix. ;;; @@ -1013,3 +1014,40 @@ specified in high-level description language into ready-to-compile C code for the API of spice simulators. Based on transformations specified in XML language, ADMS transforms Verilog-AMS code into other target languages.") (license license:gpl3))) + +(define-public capstone + (package + (name "capstone") + (version "3.0.5-rc2") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/aquynh/capstone/archive/" + version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 + (base32 + "1cqms9r2p43aiwp5spd84zaccp16ih03r7sjhrv16nddahj0jz2q")))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f + #:make-flags (list (string-append "PREFIX=" %output) + "CC=gcc") + #:phases + (modify-phases %standard-phases + (delete 'configure) + ;; cstool's Makefile overrides LDFLAGS, so we cannot pass it as a make flag. + (add-before 'build 'fix-cstool-ldflags + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "cstool/Makefile" + (("LDFLAGS =") + (string-append "LDFLAGS = -Wl,-rpath=" (assoc-ref outputs "out") + "/lib"))) + #t))))) + (home-page "http://www.capstone-engine.org") + (synopsis "Lightweight multi-platform, multi-architecture disassembly framework") + (description + "Capstone is a lightweight multi-platform, multi-architecture disassembly +framework. Capstone can disassemble machine code for many supported architectures +such as x86, x86_64, arm, arm64, mips, ppc, sparc, sysz and xcore. It provides +bindings for Python, Java, OCaml and more.") + (license license:bsd-3))) |