diff --git a/pkgs/development/tools/analysis/cppcheck/default.nix b/pkgs/development/tools/analysis/cppcheck/default.nix new file mode 100644 index 000000000000..b152f0537e3b --- /dev/null +++ b/pkgs/development/tools/analysis/cppcheck/default.nix @@ -0,0 +1,26 @@ +{ stdenv, fetchurl }: + +# TODO: add support for "make man" + +let + name = "cppcheck"; + version = "1.53"; +in +stdenv.mkDerivation { + name = "${name}-${version}"; + + src = fetchurl { + url = "mirror://sourceforge/${name}/${name}-${version}.tar.bz2"; + sha256 = "878db83d3954d0c45135362308da951ec0670a160c76a7410466a9b539e8677f"; + }; + + configurePhase = "makeFlags=PREFIX=$out"; + + meta = { + description = "check C/C++ code for memory leaks, mismatching allocation-deallocation, buffer overrun, etc."; + homepage = "http://sourceforge.net/apps/mediawiki/cppcheck/"; + license = "GPL"; + platforms = stdenv.lib.platforms.unix; + maintainers = [ stdenv.lib.maintainers.simons ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 88101ecf2956..f584dfcd26c0 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -2981,6 +2981,8 @@ let cflow = callPackage ../development/tools/misc/cflow { }; + cppcheck = callPackage ../development/tools/analysis/cppcheck { }; + cscope = callPackage ../development/tools/misc/cscope { }; csslint = callPackage ../development/web/csslint { };