1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-25 03:17:13 +00:00
nixpkgs/pkgs/development/tools/clang-tools/default.nix

29 lines
692 B
Nix
Raw Normal View History

{ stdenv, makeWrapper, writeScript, llvmPackages }:
let
clang = llvmPackages.clang-unwrapped;
version = stdenv.lib.getVersion clang;
in
stdenv.mkDerivation {
name = "clang-tools-${version}";
builder = writeScript "builder" ''
source $stdenv/setup
for tool in \
clang-apply-replacements \
clang-check \
clang-format \
clang-rename \
clang-tidy
do
makeWrapper $clang/bin/$tool $out/bin/$tool --argv0 $tool
done
'';
buildInputs = [ makeWrapper ];
inherit clang;
meta = clang.meta // {
description = "Standalone command line tools for C++ development";
maintainers = with stdenv.lib.maintainers; [ aherrmann ];
};
}