2023-02-09 11:40:11 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchCrate
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "swc";
|
2023-10-09 19:29:22 +00:00
|
|
|
version = "0.91.69";
|
|
|
|
|
|
|
|
env = {
|
|
|
|
# swc depends on nightly features
|
|
|
|
RUSTC_BOOTSTRAP = 1;
|
|
|
|
};
|
2023-02-09 11:40:11 +00:00
|
|
|
|
|
|
|
src = fetchCrate {
|
|
|
|
pname = "swc_cli";
|
|
|
|
inherit version;
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-8zbxE1qkEWeSYt2L5PElZeJPRuK4Yiooy8xDmCD/PYw=";
|
2023-02-09 11:40:11 +00:00
|
|
|
};
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
cargoSha256 = "sha256-kRsRUOvDMRci3bN5NfhiLCWojNkSuLz3K4BfKfGYc7g=";
|
2023-02-09 11:40:11 +00:00
|
|
|
|
|
|
|
buildFeatures = [ "swc_core/plugin_transform_host_native" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Rust-based platform for the Web";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "swc";
|
2023-02-09 11:40:11 +00:00
|
|
|
homepage = "https://github.com/swc-project/swc";
|
|
|
|
license = licenses.asl20;
|
2023-10-09 19:29:22 +00:00
|
|
|
maintainers = with maintainers; [ dit7ya kashw2 ];
|
2023-02-09 11:40:11 +00:00
|
|
|
};
|
|
|
|
}
|