571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
81 lines
1.4 KiB
Nix
81 lines
1.4 KiB
Nix
{ lib, stdenv
|
|
, fetchFromGitHub
|
|
, aws-c-auth
|
|
, aws-c-cal
|
|
, aws-c-common
|
|
, aws-c-compression
|
|
, aws-c-event-stream
|
|
, aws-c-http
|
|
, aws-c-io
|
|
, aws-c-mqtt
|
|
, aws-c-s3
|
|
, aws-checksums
|
|
, cmake
|
|
, s2n-tls
|
|
, nix
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "aws-crt-cpp";
|
|
version = "0.26.12";
|
|
|
|
outputs = [ "out" "dev" ];
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "awslabs";
|
|
repo = "aws-crt-cpp";
|
|
rev = "v${version}";
|
|
sha256 = "sha256-mVihmcl24gFLnF3A/qLSvr2npOotMlBH7TqU5vOwI9g=";
|
|
};
|
|
|
|
patches = [
|
|
# Correct include path for split outputs.
|
|
# https://github.com/awslabs/aws-crt-cpp/pull/325
|
|
./0001-build-Make-includedir-properly-overrideable.patch
|
|
];
|
|
|
|
postPatch = ''
|
|
substituteInPlace CMakeLists.txt --replace '-Werror' ""
|
|
'';
|
|
|
|
nativeBuildInputs = [
|
|
cmake
|
|
];
|
|
|
|
propagatedBuildInputs = [
|
|
aws-c-auth
|
|
aws-c-cal
|
|
aws-c-common
|
|
aws-c-compression
|
|
aws-c-event-stream
|
|
aws-c-http
|
|
aws-c-io
|
|
aws-c-mqtt
|
|
aws-c-s3
|
|
aws-checksums
|
|
s2n-tls
|
|
];
|
|
|
|
cmakeFlags = [
|
|
"-DBUILD_DEPS=OFF"
|
|
"-DBUILD_SHARED_LIBS=ON"
|
|
];
|
|
|
|
postInstall = ''
|
|
# Prevent dependency cycle.
|
|
moveToOutput lib/aws-crt-cpp/cmake "$dev"
|
|
'';
|
|
|
|
passthru.tests = {
|
|
inherit nix;
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "C++ wrapper around the aws-c-* libraries";
|
|
homepage = "https://github.com/awslabs/aws-crt-cpp";
|
|
license = licenses.asl20;
|
|
platforms = platforms.unix;
|
|
maintainers = with maintainers; [ r-burns ];
|
|
};
|
|
}
|