mirror of https://github.com/yshui/picom.git
chore: deduplication and reformat of flake.nix
This commit is contained in:
parent
216bfefd9f
commit
42782689e8
46
flake.nix
46
flake.nix
|
@ -7,34 +7,50 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
outputs = {
|
outputs = {
|
||||||
self, flake-utils, nixpkgs, git-ignore-nix, ...
|
self,
|
||||||
}: flake-utils.lib.eachDefaultSystem (system: let
|
flake-utils,
|
||||||
|
nixpkgs,
|
||||||
|
git-ignore-nix,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
flake-utils.lib.eachDefaultSystem (system: let
|
||||||
overlay = self: super: {
|
overlay = self: super: {
|
||||||
picom = super.picom.overrideAttrs (oldAttrs: rec {
|
picom = super.picom.overrideAttrs (oldAttrs: rec {
|
||||||
|
version = "11";
|
||||||
pname = "picom";
|
pname = "picom";
|
||||||
buildInputs = [
|
buildInputs =
|
||||||
self.pcre2 self.xorg.xcbutil self.libepoxy
|
[
|
||||||
] ++ self.lib.remove self.xorg.libXinerama (
|
self.pcre2
|
||||||
|
self.xorg.xcbutil
|
||||||
|
self.libepoxy
|
||||||
|
]
|
||||||
|
++ self.lib.remove self.xorg.libXinerama (
|
||||||
self.lib.remove self.pcre oldAttrs.buildInputs
|
self.lib.remove self.pcre oldAttrs.buildInputs
|
||||||
);
|
);
|
||||||
src = git-ignore-nix.lib.gitignoreSource ./.;
|
src = git-ignore-nix.lib.gitignoreSource ./.;
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
pkgs = import nixpkgs { inherit system overlays; config.allowBroken = true; };
|
|
||||||
overlays = [ overlay ];
|
pkgs = import nixpkgs {
|
||||||
|
inherit system overlays;
|
||||||
|
config.allowBroken = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
overlays = [overlay];
|
||||||
in rec {
|
in rec {
|
||||||
inherit overlay overlays;
|
inherit
|
||||||
defaultPackage = pkgs.picom.overrideAttrs (o: {
|
overlay
|
||||||
version = "11";
|
overlays
|
||||||
src = ./.;
|
;
|
||||||
buildInputs = o.buildInputs ++ [ pkgs.libepoxy ];
|
defaultPackage = pkgs.picom;
|
||||||
});
|
|
||||||
devShell = defaultPackage.overrideAttrs {
|
devShell = defaultPackage.overrideAttrs {
|
||||||
buildInputs = defaultPackage.buildInputs ++ (with pkgs; [
|
buildInputs =
|
||||||
|
defaultPackage.buildInputs
|
||||||
|
++ (with pkgs; [
|
||||||
clang-tools_17
|
clang-tools_17
|
||||||
llvmPackages_17.clang-unwrapped.python
|
llvmPackages_17.clang-unwrapped.python
|
||||||
]);
|
]);
|
||||||
hardeningDisable = [ "fortify" ];
|
hardeningDisable = ["fortify"];
|
||||||
shellHook = ''
|
shellHook = ''
|
||||||
# Workaround a NixOS limitation on sanitizers:
|
# Workaround a NixOS limitation on sanitizers:
|
||||||
# See: https://github.com/NixOS/nixpkgs/issues/287763
|
# See: https://github.com/NixOS/nixpkgs/issues/287763
|
||||||
|
|
Loading…
Reference in New Issue