my own fork
This commit is contained in:
parent
a8656e8021
commit
6ff166120c
4 changed files with 2565 additions and 1402 deletions
116
flake.nix
116
flake.nix
|
@ -1,28 +1,100 @@
|
|||
{
|
||||
description = "A video widget";
|
||||
|
||||
inputs = {
|
||||
flakeCompat = {
|
||||
url = "github:edolstra/flake-compat";
|
||||
flake = false;
|
||||
};
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
nixCargoIntegration = {
|
||||
url = "github:yusdacra/nix-cargo-integration";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
naersk.url = "github:nix-community/naersk";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
fenix.url = "github:nix-community/fenix";
|
||||
};
|
||||
|
||||
outputs = inputs:
|
||||
inputs.nixCargoIntegration.lib.makeOutputs {
|
||||
root = ./.;
|
||||
overrides = {
|
||||
shell = common: prev: {
|
||||
env = prev.env ++ [
|
||||
{
|
||||
name = "GST_PLUGIN_PATH";
|
||||
value = "${common.pkgs.gst_all_1.gstreamer}:${common.pkgs.gst_all_1.gst-plugins-bad}:${common.pkgs.gst_all_1.gst-plugins-ugly}:${common.pkgs.gst_all_1.gst-plugins-good}:${common.pkgs.gst_all_1.gst-plugins-base}";
|
||||
}
|
||||
outputs = inputs: with inputs;
|
||||
flake-utils.lib.eachDefaultSystem
|
||||
(system:
|
||||
let
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
overlays = [fenix.overlays.default];
|
||||
# overlays = [cargo2nix.overlays.default];
|
||||
};
|
||||
naersk' = pkgs.callPackage naersk {};
|
||||
nbi = with pkgs; [
|
||||
# Rust tools
|
||||
alejandra
|
||||
(pkgs.fenix.stable.withComponents [
|
||||
"cargo"
|
||||
"clippy"
|
||||
"rust-src"
|
||||
"rustc"
|
||||
"rustfmt"
|
||||
])
|
||||
rust-analyzer
|
||||
vulkan-loader
|
||||
wayland
|
||||
wayland-protocols
|
||||
libxkbcommon
|
||||
pkg-config
|
||||
sccache
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
bi = with pkgs; [
|
||||
gcc
|
||||
stdenv
|
||||
gnumake
|
||||
gdb
|
||||
lldb
|
||||
cmake
|
||||
makeWrapper
|
||||
vulkan-headers
|
||||
vulkan-loader
|
||||
vulkan-tools
|
||||
libGL
|
||||
cargo-flamegraph
|
||||
|
||||
fontconfig
|
||||
glib
|
||||
alsa-lib
|
||||
gst_all_1.gst-libav
|
||||
gst_all_1.gst-plugins-bad
|
||||
gst_all_1.gst-plugins-good
|
||||
gst_all_1.gst-plugins-ugly
|
||||
gst_all_1.gst-plugins-base
|
||||
gst_all_1.gst-plugins-rs
|
||||
gst_all_1.gst-vaapi
|
||||
gst_all_1.gstreamer
|
||||
# podofo
|
||||
# mpv
|
||||
ffmpeg-full
|
||||
# yt-dlp
|
||||
|
||||
just
|
||||
cargo-watch
|
||||
];
|
||||
in rec
|
||||
{
|
||||
devShell = pkgs.mkShell.override {
|
||||
# stdenv = pkgs.stdenvAdapters.useMoldLinker pkgs.clangStdenv;
|
||||
} {
|
||||
nativeBuildInputs = nbi;
|
||||
buildInputs = bi;
|
||||
LD_LIBRARY_PATH = "$LD_LIBRARY_PATH:${
|
||||
with pkgs;
|
||||
pkgs.lib.makeLibraryPath [
|
||||
pkgs.vulkan-loader
|
||||
pkgs.wayland
|
||||
pkgs.wayland-protocols
|
||||
pkgs.libxkbcommon
|
||||
]
|
||||
}";
|
||||
};
|
||||
defaultPackage = naersk'.buildPackage {
|
||||
src = ./.;
|
||||
};
|
||||
packages = {
|
||||
default = naersk'.buildPackage {
|
||||
src = ./.;
|
||||
};
|
||||
};
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue