Merge pull request #19020 from aherrmann/pr_clang_tools

clang-tools: New package
This commit is contained in:
Joachim F 2016-09-29 13:16:20 +02:00 committed by GitHub
commit f2e0484292
2 changed files with 30 additions and 0 deletions

View File

@ -0,0 +1,28 @@
{ 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 ];
};
}

View File

@ -4432,6 +4432,8 @@ in
clang_35 = wrapCC llvmPackages_35.clang;
clang_34 = wrapCC llvmPackages_34.clang;
clang-tools = callPackage ../development/tools/clang-tools { };
clang-analyzer = callPackage ../development/tools/analysis/clang-analyzer { };
clangUnwrapped = llvm: pkg: callPackage pkg { inherit llvm; };