nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ lib, stdenv, fetchurl, perl }:
2
3stdenv.mkDerivation rec {
4 version = "6.0.1";
5 pname = "coan";
6
7 src = fetchurl {
8 url = "mirror://sourceforge/project/coan2/v${version}/${pname}-${version}.tar.gz";
9 sha256 = "1d041j0nd1hc0562lbj269dydjm4rbzagdgzdnmwdxr98544yw44";
10 };
11
12 nativeBuildInputs = [ perl ];
13
14 NIX_CFLAGS_COMPILE = [
15 "-std=c++11"
16 ];
17
18 enableParallelBuilding = true;
19
20 postInstall = ''
21 mv -v $out/share/man/man1/coan.1.{1,gz}
22 '';
23
24 meta = with lib; {
25 broken = stdenv.isDarwin;
26 description = "The C preprocessor chainsaw";
27 longDescription = ''
28 A software engineering tool for analysing preprocessor-based
29 configurations of C or C++ source code. Its principal use is to simplify
30 a body of source code by eliminating any parts that are redundant with
31 respect to a specified configuration. Dead code removal is an
32 application of this sort.
33 '';
34 homepage = "http://coan2.sourceforge.net/";
35 license = licenses.bsd3;
36 platforms = platforms.all;
37 };
38}