Merge commit '29bb9a4'
This commit is contained in:
@@ -163,10 +163,10 @@
|
|||||||
tailscale
|
tailscale
|
||||||
|
|
||||||
# Thunar stuff
|
# Thunar stuff
|
||||||
thunar
|
xfce.thunar
|
||||||
thunar-volman
|
xfce.thunar-volman
|
||||||
thunar-vcs-plugin
|
xfce.thunar-vcs-plugin
|
||||||
thunar-archive-plugin
|
xfce.thunar-archive-plugin
|
||||||
|
|
||||||
# Apps
|
# Apps
|
||||||
pavucontrol
|
pavucontrol
|
||||||
|
|||||||
@@ -22,12 +22,23 @@
|
|||||||
SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", MODE="0666", GROUP="plugdev"
|
SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", MODE="0666", GROUP="plugdev"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
hardware.amdgpu.initrd.enable = true;
|
||||||
|
|
||||||
# Opengl and vulkan
|
# Opengl and vulkan
|
||||||
hardware.graphics = {
|
hardware.graphics = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enable32Bit = true;
|
enable32Bit = true;
|
||||||
|
extraPackages = with pkgs; [
|
||||||
|
# This is the most critical package for AMD OpenCL
|
||||||
|
rocmPackages.clr.icd
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
boot.kernelParams = [
|
||||||
|
"amdgpu.noretry=0"
|
||||||
|
"amdgpu.gpu_recovery=1"
|
||||||
|
];
|
||||||
|
|
||||||
# Wake on Lan
|
# Wake on Lan
|
||||||
networking.interfaces.enp5s0.wakeOnLan.enable = true;
|
networking.interfaces.enp5s0.wakeOnLan.enable = true;
|
||||||
networking.firewall.enable = false;
|
networking.firewall.enable = false;
|
||||||
|
|||||||
20
flake.lock
generated
20
flake.lock
generated
@@ -57,11 +57,11 @@
|
|||||||
"systems": "systems_2"
|
"systems": "systems_2"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1769093894,
|
"lastModified": 1769329000,
|
||||||
"narHash": "sha256-Ka1uvhSq66yp0IlNFFpx7h+NlysbN52/yUbQKvI4AiA=",
|
"narHash": "sha256-0vibWqmCsG1t4xL2euR6PScB3M4QZigB5JGl+BIH4NY=",
|
||||||
"owner": "abenz1267",
|
"owner": "abenz1267",
|
||||||
"repo": "elephant",
|
"repo": "elephant",
|
||||||
"rev": "b34dd272ab5dc60096157d7cc7ff781f359c48b1",
|
"rev": "1988112d1f54dd76e8a90f551945df763586bdad",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -133,11 +133,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1769018530,
|
"lastModified": 1770197578,
|
||||||
"narHash": "sha256-MJ27Cy2NtBEV5tsK+YraYr2g851f3Fl1LpNHDzDX15c=",
|
"narHash": "sha256-AYqlWrX09+HvGs8zM6ebZ1pwUqjkfpnv8mewYwAo+iM=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "88d3861acdd3d2f0e361767018218e51810df8a1",
|
"rev": "00c21e4c93d963c50d4c0c89bfa84ed6e0694df2",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -181,16 +181,16 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_4": {
|
"nixpkgs_4": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1769018530,
|
"lastModified": 1770136044,
|
||||||
"narHash": "sha256-MJ27Cy2NtBEV5tsK+YraYr2g851f3Fl1LpNHDzDX15c=",
|
"narHash": "sha256-tlFqNG/uzz2++aAmn4v8J0vAkV3z7XngeIIB3rM3650=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "88d3861acdd3d2f0e361767018218e51810df8a1",
|
"rev": "e576e3c9cf9bad747afcddd9e34f51d18c855b4e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"ref": "nixos-unstable",
|
"ref": "nixos-25.11",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
description = "Master flake for Voidarc nix config";
|
description = "Master flake for Voidarc nix config";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.11";
|
||||||
elephant.url = "github:abenz1267/elephant";
|
elephant.url = "github:abenz1267/elephant";
|
||||||
chataigne.url = "./modules/chataigne";
|
chataigne.url = "./modules/chataigne";
|
||||||
doot.url = "github:voidarclabs/nixos.doot";
|
doot.url = "github:voidarclabs/nixos.doot";
|
||||||
|
|||||||
@@ -1,26 +1,22 @@
|
|||||||
|
# Tested on Davinci 20.2.2. It works for loading videos and exporting in H264/5 & AV1
|
||||||
|
# Even if following this guide https://www.reddit.com/r/LinuxCrackSupport/comments/1nfqhld/davinci_resolve_studio_202_fix_linux_crack_guide/
|
||||||
|
# nixpkgs rev used for this tests: 4652ba995a945108fb891191c1e910b9a6ed9064
|
||||||
|
|
||||||
{ lib, pkgs, ... }:
|
{ lib, pkgs, ... }:
|
||||||
let
|
let
|
||||||
# 1. Pin Nixpkgs to your specific commit
|
pkgs = import (builtins.fetchTarball {
|
||||||
pinnedPkgs =
|
url = "https://github.com/NixOS/nixpkgs/archive/4652ba995a945108fb891191c1e910b9a6ed9064.tar.gz";
|
||||||
import
|
sha256 = "sha256:1pmmbasd84z3yi06919jnl9gvpm37cfr30rba3mc8mgig8ansfhf"; # You can find this using nix-prefetch-url
|
||||||
(builtins.fetchTarball {
|
}) { config.allowUnfree = true; };
|
||||||
url = "https://github.com/NixOS/nixpkgs/archive/d457818da697aa7711ff3599be23ab8850573a46.tar.gz";
|
ffmpeg-encoder-plugin = pkgs.stdenv.mkDerivation (finalAttrs: {
|
||||||
# Replace this with the hash from the nix-prefetch-url command above
|
|
||||||
sha256 = "11lf0nq7d4c5mgxiy0n9h8qdzvww6k0vmd5h1a75in6dnkry5l3z";
|
|
||||||
})
|
|
||||||
{
|
|
||||||
inherit (pkgs) system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
};
|
|
||||||
ffmpeg-encoder-plugin = pinnedPkgs.stdenv.mkDerivation (finalAttrs: {
|
|
||||||
pname = "ffmpeg-encoder-plugin";
|
pname = "ffmpeg-encoder-plugin";
|
||||||
version = "1.1.0";
|
version = "1.2.1";
|
||||||
|
|
||||||
src = pkgs.fetchFromGitHub {
|
src = pkgs.fetchFromGitHub {
|
||||||
owner = "EdvinNilsson";
|
owner = "EdvinNilsson";
|
||||||
repo = "ffmpeg_encoder_plugin";
|
repo = "ffmpeg_encoder_plugin";
|
||||||
tag = "v${finalAttrs.version}";
|
tag = "v${finalAttrs.version}";
|
||||||
hash = "sha256-orghLIzz9rUnUwka9C71Z2nj+qxHuggrKNlYjLKswQw=";
|
hash = "sha256-F4Q8YCXD5UldTwLbWK4nHacNPQ/B+4yLL96sq7xZurM=";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = with pkgs; [
|
nativeBuildInputs = with pkgs; [
|
||||||
@@ -32,15 +28,17 @@ let
|
|||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
runHook preInstall
|
runHook preInstall
|
||||||
|
|
||||||
mkdir -p $out
|
mkdir -p $out
|
||||||
cp ffmpeg_encoder_plugin.dvcp $out/
|
cp ffmpeg_encoder_plugin.dvcp $out/
|
||||||
|
|
||||||
runHook postInstall
|
runHook postInstall
|
||||||
'';
|
'';
|
||||||
});
|
});
|
||||||
|
|
||||||
davinci-resolve-studio-cracked =
|
davinci-resolve-studio-cracked =
|
||||||
let
|
let
|
||||||
davinci-patched = pinnedPkgs.davinci-resolve-studio.davinci.overrideAttrs (old: {
|
davinci-patched = pkgs.davinci-resolve-studio.davinci.overrideAttrs (old: {
|
||||||
# script based on https://www.reddit.com/r/LinuxCrackSupport/comments/1nfqhld/davinci_resolve_studio_202_fix_linux_crack_guide/
|
# script based on https://www.reddit.com/r/LinuxCrackSupport/comments/1nfqhld/davinci_resolve_studio_202_fix_linux_crack_guide/
|
||||||
#
|
#
|
||||||
# Additionally, it will install ffmpeg_encoder_plugin to enable H264/5 & AV1 exports:
|
# Additionally, it will install ffmpeg_encoder_plugin to enable H264/5 & AV1 exports:
|
||||||
@@ -55,6 +53,7 @@ let
|
|||||||
${lib.getExe pkgs.perl} -pi -e 's/\x41\xb6\x01\x84\xc0\x0f\x84\xb0\x00\x00\x00\x48\x85\xdb\x74\x08\x45\x31\xf6\xe9\xa3\x00\x00\x00/\x41\xb6\x00\x84\xc0\x0f\x84\xb0\x00\x00\x00\x48\x85\xdb\x74\x08\x45\x31\xf6\xe9\xa3\x00\x00\x00/' $out/bin/resolve
|
${lib.getExe pkgs.perl} -pi -e 's/\x41\xb6\x01\x84\xc0\x0f\x84\xb0\x00\x00\x00\x48\x85\xdb\x74\x08\x45\x31\xf6\xe9\xa3\x00\x00\x00/\x41\xb6\x00\x84\xc0\x0f\x84\xb0\x00\x00\x00\x48\x85\xdb\x74\x08\x45\x31\xf6\xe9\xa3\x00\x00\x00/' $out/bin/resolve
|
||||||
touch $out/.license/blackmagic.lic
|
touch $out/.license/blackmagic.lic
|
||||||
echo -e "LICENSE blackmagic davinciresolvestudio 999999 permanent uncounted\n hostid=ANY issuer=CGP customer=CGP issued=28-dec-2023\n akey=0000-0000-0000-0000 _ck=00 sig=\"00\"" > $out/.license/blackmagic.lic
|
echo -e "LICENSE blackmagic davinciresolvestudio 999999 permanent uncounted\n hostid=ANY issuer=CGP customer=CGP issued=28-dec-2023\n akey=0000-0000-0000-0000 _ck=00 sig=\"00\"" > $out/.license/blackmagic.lic
|
||||||
|
|
||||||
mkdir -p $out/IOPlugins/ffmpeg_encoder_plugin.dvcp.bundle/Contents/Linux-x86-64/
|
mkdir -p $out/IOPlugins/ffmpeg_encoder_plugin.dvcp.bundle/Contents/Linux-x86-64/
|
||||||
cp ${ffmpeg-encoder-plugin}/ffmpeg_encoder_plugin.dvcp $out/IOPlugins/ffmpeg_encoder_plugin.dvcp.bundle/Contents/Linux-x86-64/
|
cp ${ffmpeg-encoder-plugin}/ffmpeg_encoder_plugin.dvcp $out/IOPlugins/ffmpeg_encoder_plugin.dvcp.bundle/Contents/Linux-x86-64/
|
||||||
'';
|
'';
|
||||||
@@ -64,12 +63,12 @@ let
|
|||||||
# the following was copied from davinci's derivation from nixpkgs.
|
# the following was copied from davinci's derivation from nixpkgs.
|
||||||
# if davinci updates, this should be updated too
|
# if davinci updates, this should be updated too
|
||||||
# but remember to replace "davinci" with "davinci-patched"
|
# but remember to replace "davinci" with "davinci-patched"
|
||||||
pinnedPkgs.buildFHSEnv {
|
pkgs.buildFHSEnv {
|
||||||
inherit (davinci-patched) pname version;
|
inherit (davinci-patched) pname version;
|
||||||
|
|
||||||
targetPkgs =
|
targetPkgs =
|
||||||
pkgs:
|
pkgs:
|
||||||
with pinnedPkgs;
|
with pkgs;
|
||||||
[
|
[
|
||||||
alsa-lib
|
alsa-lib
|
||||||
aprutil
|
aprutil
|
||||||
@@ -118,6 +117,10 @@ let
|
|||||||
xorg.xcbutilwm
|
xorg.xcbutilwm
|
||||||
xorg.xkeyboardconfig
|
xorg.xkeyboardconfig
|
||||||
zlib
|
zlib
|
||||||
|
ocl-icd
|
||||||
|
rocmPackages.clr.icd
|
||||||
|
libGL
|
||||||
|
libGLU
|
||||||
]
|
]
|
||||||
++ [ davinci-patched ];
|
++ [ davinci-patched ];
|
||||||
|
|
||||||
@@ -133,6 +136,12 @@ let
|
|||||||
export QT_XKB_CONFIG_ROOT="${pkgs.xkeyboard_config}/share/X11/xkb"
|
export QT_XKB_CONFIG_ROOT="${pkgs.xkeyboard_config}/share/X11/xkb"
|
||||||
export QT_PLUGIN_PATH="${davinci-patched}/libs/plugins:$QT_PLUGIN_PATH"
|
export QT_PLUGIN_PATH="${davinci-patched}/libs/plugins:$QT_PLUGIN_PATH"
|
||||||
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib:/usr/lib32:${davinci-patched}/libs
|
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib:/usr/lib32:${davinci-patched}/libs
|
||||||
|
# Force Resolve to use X11 (via XWayland) to avoid Aquamarine/Hyprland conflicts
|
||||||
|
export QT_QPA_PLATFORM=xcb
|
||||||
|
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${davinci-patched}/libs
|
||||||
|
|
||||||
|
# Prevent Resolve from trying to talk to the Wayland socket directly
|
||||||
|
unset WAYLAND_DISPLAY
|
||||||
${davinci-patched}/bin/resolve
|
${davinci-patched}/bin/resolve
|
||||||
''}";
|
''}";
|
||||||
|
|
||||||
@@ -157,10 +166,13 @@ let
|
|||||||
drv=pkgs/by-name/da/davinci-resolve/package.nix
|
drv=pkgs/by-name/da/davinci-resolve/package.nix
|
||||||
currentVersion=${lib.escapeShellArg davinci-patched.version}
|
currentVersion=${lib.escapeShellArg davinci-patched.version}
|
||||||
downloadsJSON="$(curl --fail --silent https://www.blackmagicdesign.com/api/support/us/downloads.json)"
|
downloadsJSON="$(curl --fail --silent https://www.blackmagicdesign.com/api/support/us/downloads.json)"
|
||||||
|
|
||||||
latestLinuxVersion="$(echo "$downloadsJSON" | jq '[.downloads[] | select(.urls.Linux) | .urls.Linux[] | select(.downloadTitle | test("DaVinci Resolve")) | .downloadTitle]' | grep -oP 'DaVinci Resolve \K\d+\.\d+(\.\d+)?' | sort | tail -n 1)"
|
latestLinuxVersion="$(echo "$downloadsJSON" | jq '[.downloads[] | select(.urls.Linux) | .urls.Linux[] | select(.downloadTitle | test("DaVinci Resolve")) | .downloadTitle]' | grep -oP 'DaVinci Resolve \K\d+\.\d+(\.\d+)?' | sort | tail -n 1)"
|
||||||
update-source-version davinci-resolve "$latestLinuxVersion" --source-key=davinci.src
|
update-source-version davinci-resolve "$latestLinuxVersion" --source-key=davinci.src
|
||||||
|
|
||||||
# Since the standard and studio both use the same version we need to reset it before updating studio
|
# Since the standard and studio both use the same version we need to reset it before updating studio
|
||||||
sed -i -e "s/""$latestLinuxVersion""/""$currentVersion""/" "$drv"
|
sed -i -e "s/""$latestLinuxVersion""/""$currentVersion""/" "$drv"
|
||||||
|
|
||||||
latestStudioLinuxVersion="$(echo "$downloadsJSON" | jq '[.downloads[] | select(.urls.Linux) | .urls.Linux[] | select(.downloadTitle | test("DaVinci Resolve")) | .downloadTitle]' | grep -oP 'DaVinci Resolve Studio \K\d+\.\d+(\.\d+)?' | sort | tail -n 1)"
|
latestStudioLinuxVersion="$(echo "$downloadsJSON" | jq '[.downloads[] | select(.urls.Linux) | .urls.Linux[] | select(.downloadTitle | test("DaVinci Resolve")) | .downloadTitle]' | grep -oP 'DaVinci Resolve Studio \K\d+\.\d+(\.\d+)?' | sort | tail -n 1)"
|
||||||
update-source-version davinci-resolve-studio "$latestStudioLinuxVersion" --source-key=davinci.src
|
update-source-version davinci-resolve-studio "$latestStudioLinuxVersion" --source-key=davinci.src
|
||||||
'';
|
'';
|
||||||
@@ -173,22 +185,7 @@ in
|
|||||||
environment.systemPackages = [ davinci-resolve-studio-cracked ];
|
environment.systemPackages = [ davinci-resolve-studio-cracked ];
|
||||||
|
|
||||||
# following configuration was taken from
|
# following configuration was taken from
|
||||||
# https://wiki.nixos.org/wiki/DaVinci_Resolve#AMD
|
# https://wiki.nixos.org/wiki/DaVinci_Resolve
|
||||||
#
|
|
||||||
# Tested and working with AMD cards.
|
|
||||||
# I don't know any configurations for Nvidia cards!
|
|
||||||
environment.variables = {
|
|
||||||
RUSTICL_ENABLE = "radeonsi";
|
|
||||||
};
|
|
||||||
hardware = {
|
|
||||||
# this option sets hardware.graphics.enable to true
|
|
||||||
# and installs rocmPackages.clr/.icd
|
|
||||||
amdgpu.opencl.enable = true;
|
|
||||||
graphics.extraPackages = with pkgs; [
|
|
||||||
# Enables Rusticl (OpenCL) support
|
|
||||||
# Without this, videos won't load in davinci
|
|
||||||
mesa.opencl
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
|
# Zynix
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user