;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013, 2015, 2018 Ludovic Courtès ;;; Copyright © 2015 Andreas Enge ;;; Copyright © 2015, 2018 Ricardo Wurmus ;;; Copyright © 2016, 2017, 2019, 2020 Efraim Flashner ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2018 Clément Lassieur ;;; Copyright © 2017 Andy Wingo ;;; Copyright © 2018 Fis Trivial ;;; Copyright © 2018 Pierre Neidhardt ;;; Copyright © 2014 Eric Bavier ;;; Copyright © 2013 Andreas Enge ;;; Copyright © 2014 Mark H Weaver ;;; Copyright © 2019 Hartmut Goebel ;;; Copyright © 2020 Maxim Cournoyer ;;; Copyright © 2020 Marius Bakke ;;; Copyright © 2020 Julien Lepiller ;;; ;;; This file is part of GNU Guix. ;;; ;;; GNU Guix is free software; you can redistribute it and/or modify it ;;; under the terms of the GNU General Public License as published by ;;; the Free Software Foundation; either version 3 of the License, or (at ;;; your option) any later version. ;;; ;;; GNU Guix is distributed in the hope that it will be useful, but ;;; WITHOUT ANY WARRANTY; without even the implied warranty of ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;;; GNU General Public License for more details. ;;; ;;; You should have received a copy of the GNU General Public License ;;; along with GNU Guix. If not, see . (define-module (gnu packages code) #:use-module (guix packages) #:use-module (guix utils) #:use-module (guix download) #:use-module (guix git-download) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build-system gnu) #:use-module (guix build-system cmake) #:use-module (guix build-system trivial) #:use-module (gnu packages) #:use-module (gnu packages autogen) #:use-module (gnu packages autotools) #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages c) #:use-module (gnu packages compression) #:use-module (gnu packages cpp) #:use-module (gnu packages curl) #:use-module (gnu packages elf) #:use-module (gnu packages emacs) #:use-module (gnu packages gcc) #:use-module (gnu packages graphviz) #:use-module (gnu packages llvm) #:use-module (gnu packages linux) #:use-module (gnu packages lua) #:use-module (gnu packages ncurses) #:use-module (gnu packages pcre) #:use-module (gnu packages perl) #:use-module (gnu packages perl-compression) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) #:use-module (gnu packages sqlite) #:use-module (gnu packages texinfo) #:use-module (gnu packages web) #:use-module (gnu packages xml)) ;;; Tools to deal with source code: metrics, cross-references, etc. (define-public cflow (package (name "cflow") (version "1.6") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/cflow/cflow-" version ".tar.bz2")) (sha256 (base32 "1mzd3yf0dfv8h2av5vsxxlhpk21nw064h91b2kgfrdz92r0pnj1l")))) (build-system gnu-build-system) ;; Needed to have cflow-mode.el installed. (native-inputs `(("emacs" ,emacs-minimal))) (arguments '(#:configure-flags (list (string-append "CPPFLAGS=" "-D" "CFLOW_PREPROC=\\\"" (assoc-ref %build-inputs "gcc") "/bin/cpp\\\"")))) (home-page "https://www.gnu.org/software/cflow/") (synopsis "Create a graph of control flow within a program") (description "GNU cflow analyzes C source files and produces a graph charting the control flow of the program. It can output the graph in several styles and in either the POSIX format or in an extended GNU format. cflow also includes a major mode for Emacs for examining the flowcharts that it produces.") (license license:gpl3+))) (define-public complexity (package (name "complexity") (version "1.10") (source (origin (method url-fetch) (uri (string-append "mirror://gnu/complexity/complexity-" version ".tar.xz")) (sha256 (base32 "0lr0l9kj2w3jilz9h9y4np9pf9i9ccpy6331lanki2fnz4z8ldvd")))) (build-system gnu-build-system) (native-inputs `(("texinfo" ,texinfo) ("autogen" ,autogen))) (home-page "https://www.gnu.org/software/complexity/") (synopsis "Analyze complexity of C functions") (description "GNU complexity provides tools for finding procedures that are convoluted, overly