nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 60 lines 1.3 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 cmake, 6 llvmPackages, 7 nix-update-script, 8}: 9 10stdenv.mkDerivation (finalAttrs: { 11 pname = "luau"; 12 version = "0.705"; 13 14 src = fetchFromGitHub { 15 owner = "luau-lang"; 16 repo = "luau"; 17 tag = finalAttrs.version; 18 hash = "sha256-M0niHRtx/Xu3H5CJXbqB2VCXFsthvPDNcr29egY3ncI="; 19 }; 20 21 nativeBuildInputs = [ cmake ]; 22 23 buildInputs = lib.optionals stdenv.cc.isClang [ llvmPackages.libunwind ]; 24 25 installPhase = '' 26 runHook preInstall 27 28 install -Dm755 -t $out/bin luau 29 install -Dm755 -t $out/bin luau-analyze 30 install -Dm755 -t $out/bin luau-compile 31 32 runHook postInstall 33 ''; 34 35 doCheck = true; 36 37 checkPhase = '' 38 runHook preCheck 39 40 ./Luau.UnitTest 41 ./Luau.Conformance 42 43 runHook postCheck 44 ''; 45 46 passthru.updateScript = nix-update-script { }; 47 48 meta = { 49 description = "Fast, small, safe, gradually typed embeddable scripting language derived from Lua"; 50 homepage = "https://luau-lang.org/"; 51 changelog = "https://github.com/luau-lang/luau/releases/tag/${finalAttrs.version}"; 52 license = lib.licenses.mit; 53 platforms = lib.platforms.all; 54 maintainers = with lib.maintainers; [ 55 prince213 56 HeitorAugustoLN 57 ]; 58 mainProgram = "luau"; 59 }; 60})