git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #130069 from jshcmpbll/jc/azure-functions-core-tools

func: init at 3.0.3568

commit5fe0dc2e9f6138ad036a02bd564a09fd5ac092a4 authorSandro <sandro.jaeckel@gmail.com> dateThu 15 Jul 2021, 23:45 (5 years ago) parentc9cfa65e435736
2 files changed+76
pkgs/development/tools/azure-functions-core-tools/default.nix+74 pkgs/top-level/all-packages.nix+2
pkgs/development/tools/azure-functions-core-tools/default.nixnew file+74
@@ -0,0 +1,74 @@
1+{ stdenv
2+, lib
3+, config
4+, fetchurl
5+, unzip
6+, makeWrapper
7+, icu
8+, libunwind
9+, curl
10+, zlib
11+, libuuid
12+, dotnetbuildhelpers
13+, dotnetCorePackages
14+, coreclr
15+, openssl
16+}:
17+
18+stdenv.mkDerivation rec {
19+ pname = "azure-functions-core-tools";
20+ version = "3.0.3568";
21+
22+ src = fetchurl {
23+ url = "https://github.com/Azure/${pname}/releases/download/${version}/Azure.Functions.Cli.linux-x64.${version}.zip";
24+ sha256 = "0yxdqc5d1xsixjj2dlvs32d6fz4vh58ih2l00lc456fg15mfw3lg";
25+ };
26+
27+ buildInputs = [
28+ unzip
29+ makeWrapper
30+ dotnetbuildhelpers
31+ ];
32+
33+ nativeBuildInputs = [
34+ icu
35+ libunwind
36+ curl
37+ zlib
38+ dotnetCorePackages.sdk_3_1
39+ ];
40+
41+ libPath = lib.makeLibraryPath [
42+ libunwind
43+ libuuid
44+ stdenv.cc.cc
45+ curl
46+ zlib
47+ icu
48+ openssl
49+ ];
50+
51+ unpackPhase = ''
52+ unzip $src
53+ '';
54+
55+ installPhase = ''
56+ mkdir -p $out/bin
57+ cp -prd * $out/bin
58+ patchelf \
59+ --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" \
60+ --set-rpath "${libPath}" "$out/bin/func"
61+ chmod +x $out/bin/func $out/bin/gozip
62+ find $out/bin -type f -name "*.so" -exec patchelf --set-rpath "${libPath}" {} \;
63+ wrapProgram "$out/bin/func" --prefix LD_LIBRARY_PATH : ${libPath}
64+ '';
65+ dontStrip = true; # Causes rpath patching to break if not set
66+
67+ meta = with lib; {
68+ homepage = "https://github.com/Azure/azure-functions-core-tools";
69+ description = "Command line tools for Azure Functions";
70+ license = licenses.mit;
71+ maintainers = with maintainers; [ jshcmpbll ];
72+ platforms = platforms.linux;
73+ };
74+}
pkgs/top-level/all-packages.nix+2
@@ -1239,6 +1239,8 @@ in
12391239
12401240 azure-cli = callPackage ../tools/admin/azure-cli { };
12411241
1242+ azure-functions-core-tools = callPackage ../development/tools/azure-functions-core-tools { };
1243+
12421244 azure-storage-azcopy = callPackage ../development/tools/azcopy { };
12431245
12441246 azure-vhd-utils = callPackage ../tools/misc/azure-vhd-utils { };