nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 41 lines 1.0 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 bison, 6 flex, 7}: 8 9stdenv.mkDerivation { 10 pname = "pcalc"; 11 version = "20181202"; 12 13 src = fetchFromGitHub { 14 owner = "vapier"; 15 repo = "pcalc"; 16 rev = "d93be9e19ecc0b2674cf00ec91cbb79d32ccb01d"; 17 sha256 = "sha256-m4xdsEJGKxLgp/d5ipxQ+cKG3z7rlvpPL6hELnDu6Hk="; 18 }; 19 20 # Since C23, coercing functions with different parameter lists to a function pointer with no 21 # parameter specified triggers a hard error: `symbol.c:92:22: error: initialization of 22 # 'int (*)(void)' from incompatible pointer type 'int (*)(double)' [-Wincompatible-pointer-types]` 23 env.NIX_CFLAGS_COMPILE = "-std=gnu17"; 24 25 makeFlags = [ "DESTDIR= BINDIR=$(out)/bin" ]; 26 nativeBuildInputs = [ 27 bison 28 flex 29 ]; 30 31 enableParallelBuilding = true; 32 33 meta = { 34 homepage = "https://vapier.github.io/pcalc/"; 35 description = "Programmer's calculator"; 36 mainProgram = "pcalc"; 37 license = lib.licenses.gpl2Plus; 38 maintainers = with lib.maintainers; [ ftrvxmtrx ]; 39 platforms = lib.platforms.unix; 40 }; 41}