blob: d986815ceef33a99a7b3354a45da7bc4040c1d50 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
|
{
stdenv,
fetchFromGitHub,
cmake,
ninja,
curl,
libxml2,
nix-update-script,
meta,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "azure-sdk-for-cpp-core";
version = "1.16.3";
outputs = [
"out"
"dev"
];
src = fetchFromGitHub {
owner = "Azure";
repo = "azure-sdk-for-cpp";
tag = "azure-core_${finalAttrs.version}";
hash = "sha256-1OLyTwjfSunwvDMbMTNw0w8txhJxXthtAVeFf7abrIs=";
};
sourceRoot = "${finalAttrs.src.name}/sdk/core/azure-core";
postPatch = ''
sed -i '/CMAKE_CXX_STANDARD/d' CMakeLists.txt
'';
strictDeps = true;
nativeBuildInputs = [
cmake
ninja
];
propagatedBuildInputs = [
curl
libxml2
];
env = {
AZURE_SDK_DISABLE_AUTO_VCPKG = 1;
};
cmakeFlags = [
"-DBUILD_SHARED_LIBS=ON"
"-DBUILD_TRANSPORT_CURL=ON"
"-DWARNINGS_AS_ERRORS=OFF"
];
postInstall = ''
moveToOutput "share" "$dev"
moveToOutput "share/$(basename "$sourceRoot")-cpp/copyright" "$out"
'';
passthru.updateScript = nix-update-script {
extraArgs = [
"--version-regex"
"azure-core_(.*)"
];
};
# Testing this is moderately involved, see:
# https://github.com/Azure/azure-sdk-for-cpp/blob/main/CONTRIBUTING.md#testing-the-project
# Unless issues arise, it does not seem worth the effort.
doCheck = false;
meta = (
meta
// {
description = "Azure SDK Core Library for C++";
changelog = "https://github.com/Azure/azure-sdk-for-cpp/blob/main/sdk/core/azure-core/CHANGELOG.md";
}
);
})
|