e0464e4788
In preparation for the deprecation of `stdenv.isX`. These shorthands are not conducive to cross-compilation because they hide the platforms. Darwin might get cross-compilation for which the continued usage of `stdenv.isDarwin` will get in the way One example of why this is bad and especially affects compiler packages https://www.github.com/NixOS/nixpkgs/pull/343059 There are too many files to go through manually but a treewide should get users thinking when they see a `hostPlatform.isX` in a place where it doesn't make sense. ``` fd --type f "\.nix" | xargs sd --fixed-strings "stdenv.is" "stdenv.hostPlatform.is" fd --type f "\.nix" | xargs sd --fixed-strings "stdenv'.is" "stdenv'.hostPlatform.is" fd --type f "\.nix" | xargs sd --fixed-strings "clangStdenv.is" "clangStdenv.hostPlatform.is" fd --type f "\.nix" | xargs sd --fixed-strings "gccStdenv.is" "gccStdenv.hostPlatform.is" fd --type f "\.nix" | xargs sd --fixed-strings "stdenvNoCC.is" "stdenvNoCC.hostPlatform.is" fd --type f "\.nix" | xargs sd --fixed-strings "inherit (stdenv) is" "inherit (stdenv.hostPlatform) is" fd --type f "\.nix" | xargs sd --fixed-strings "buildStdenv.is" "buildStdenv.hostPlatform.is" fd --type f "\.nix" | xargs sd --fixed-strings "effectiveStdenv.is" "effectiveStdenv.hostPlatform.is" fd --type f "\.nix" | xargs sd --fixed-strings "originalStdenv.is" "originalStdenv.hostPlatform.is" ```
47 lines
1.2 KiB
Nix
47 lines
1.2 KiB
Nix
{ lib
|
|
, buildDotnetModule
|
|
, fetchFromGitHub
|
|
, dotnetCorePackages
|
|
, stdenv
|
|
}:
|
|
|
|
buildDotnetModule rec {
|
|
pname = "certdump";
|
|
version = "unstable-2023-07-12";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "secana";
|
|
repo = "CertDump";
|
|
rev = "1300005115786b3c214d73fa506de2de06a62cbb";
|
|
sha256 = "sha256-VqKOoW4fAXr0MtY5rgWvRqay1dazF+ZpzJUHkDeXpPs=";
|
|
};
|
|
|
|
projectFile = [ "CertDump.sln" ];
|
|
nugetDeps = ./deps.nix;
|
|
|
|
selfContainedBuild = true;
|
|
executables = [ "CertDump" ];
|
|
xBuildFiles = [ "CertDump/CertDump.csproj" ];
|
|
|
|
dotnet-runtime = dotnetCorePackages.aspnetcore_7_0;
|
|
dotnet-sdk = dotnetCorePackages.sdk_7_0;
|
|
|
|
dotnetFlags = [
|
|
"-property:ImportByWildcardBeforeSolution=false"
|
|
"-property:GenerateAssemblyInfo=false"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "Dump certificates from PE files in different formats";
|
|
mainProgram = "CertDump";
|
|
homepage = "https://github.com/secana/CertDump";
|
|
longDescription = ''
|
|
Cross-Platform tool to dump the signing certificate from a Portable Executable (PE) file.
|
|
'';
|
|
license = licenses.asl20;
|
|
maintainers = [ maintainers.baloo ];
|
|
# net5 has no osx-arm64 target available
|
|
broken = stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64;
|
|
};
|
|
}
|