depot/third_party/nixpkgs/pkgs/applications/science/electronics/nvc/default.nix
Default email fa5436e0a7 Project import generated by Copybara.
GitOrigin-RevId: e8057b67ebf307f01bdcc8fba94d94f75039d1f6
2024-06-05 17:53:02 +02:00

66 lines
1 KiB
Nix

{ lib
, stdenv
, fetchFromGitHub
, autoreconfHook
, check
, flex
, pkg-config
, which
, elfutils
, libffi
, llvm
, zlib
, zstd
}:
stdenv.mkDerivation rec {
pname = "nvc";
version = "1.12.2";
src = fetchFromGitHub {
owner = "nickg";
repo = "nvc";
rev = "r${version}";
hash = "sha256-9nqho+iDqy8oQLSxBppXoafzEuS6AkcUuqEY3xxfFs4=";
};
nativeBuildInputs = [
autoreconfHook
check
flex
pkg-config
which
];
buildInputs = [
libffi
llvm
zlib
zstd
] ++ lib.optionals (lib.meta.availableOn stdenv.hostPlatform elfutils) [
elfutils
];
preConfigure = ''
mkdir build
cd build
'';
configureScript = "../configure";
configureFlags = [
"--enable-vhpi"
"--disable-lto"
];
doCheck = true;
meta = with lib; {
description = "VHDL compiler and simulator";
mainProgram = "nvc";
homepage = "https://www.nickg.me.uk/nvc/";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ wegank ];
platforms = platforms.unix;
};
}