mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-28 00:24:18 +00:00
f5fa5fa4d6
* pkgs: refactor needless quoting of homepage meta attribute A lot of packages are needlessly quoting the homepage meta attribute (about 1400, 22%), this commit refactors all of those instances. * pkgs: Fixing some links that were wrongfully unquoted in the previous commit * Fixed some instances
45 lines
1.3 KiB
Nix
45 lines
1.3 KiB
Nix
{ stdenv, fetchFromGitHub, gnat, zlib, llvm_35, ncurses, clang, flavour ? "mcode" }:
|
|
|
|
# mcode only works on x86, while the llvm flavour works on both x86 and x86_64.
|
|
|
|
|
|
assert flavour == "llvm" || flavour == "mcode";
|
|
|
|
let
|
|
inherit (stdenv.lib) optional;
|
|
inherit (stdenv.lib) optionals;
|
|
version = "0.33";
|
|
in
|
|
stdenv.mkDerivation rec {
|
|
name = "ghdl-${flavour}-${version}";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "tgingold";
|
|
repo = "ghdl";
|
|
rev = "v${version}";
|
|
sha256 = "0g72rk2yzr0lrpncq2c1qcv71w3mi2hjq84r1yzgjr6d0qm87r2a";
|
|
};
|
|
|
|
buildInputs = [ gnat zlib ] ++ optionals (flavour == "llvm") [ clang ncurses ];
|
|
|
|
configureFlags = optional (flavour == "llvm") "--with-llvm=${llvm_35}";
|
|
|
|
patchPhase = ''
|
|
# Disable warnings-as-errors, because there are warnings (unused things)
|
|
sed -i s/-gnatwae/-gnatwa/ Makefile.in ghdl.gpr.in
|
|
'';
|
|
|
|
hardeningDisable = [ "all" ];
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
meta = {
|
|
homepage = http://sourceforge.net/p/ghdl-updates/wiki/Home/;
|
|
description = "Free VHDL simulator";
|
|
maintainers = with stdenv.lib.maintainers; [viric];
|
|
platforms = with stdenv.lib.platforms; (if flavour == "llvm" then [ "i686-linux" "x86_64-linux" ]
|
|
else [ "i686-linux" ]);
|
|
license = stdenv.lib.licenses.gpl2Plus;
|
|
};
|
|
}
|