加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
shell.nix 979 Bytes
一键复制 编辑 原始数据 按行查看 历史
Risto Saarelma 提交于 2021-06-15 21:47 . Update nix scripts
let
pkgs = import <nixpkgs> {};
log_level = "info";
in
pkgs.mkShell {
buildInputs = with pkgs; [
rustc cargo rustfmt rust-analyzer cargo-outdated clippy
# Needed by cargo dependencies.
cmake gcc zlib pkgconfig openssl
# wgpu graphics dependencies
vulkan-loader vulkan-tools
xorg.libXcursor xorg.libXi xorg.libXrandr
# SPIR-V shader compiler
shaderc
# Linker
lld
# Map editor
tiled
];
shellHook = ''
# Dynamic linking for Vulkan stuff for wgpu graphics
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${
with pkgs; pkgs.lib.makeLibraryPath [ vulkan-loader openssl zlib ]
}"
# Run clippy without showing stuff I don't care about.
alias clippy="cargo clippy -- -A clippy::cast_lossless"
'';
RUST_BACKTRACE = "1";
RUSTFLAGS = "-C link-arg=-fuse-ld=lld";
RUST_LOG = "calx-ecs=${log_level},vitral=${log_level},calx=${log_level},display=${log_level},world=${log_level},magog=${log_level}";
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化