feat: integrate system config

This commit is contained in:
2023-12-23 00:34:40 +01:00
parent f082d6eb65
commit 044e96eda4
140 changed files with 638 additions and 229 deletions

View File

@@ -0,0 +1,32 @@
{
stdenv,
fetchurl,
pkgs,
p7zip,
wineWowPackages,
winetricks,
}:
stdenv.mkDerivation rec {
name = "affinity-photo";
version = "1.10.6";
src = ./affinity-photo-${version}.exe;
dontUnpack = true;
buildInputs = [wineWowPackages.stable winetricks];
installPhase = ''
mkdir -p $out/share/$name
cd $out/share/$name
${p7zip}/bin/7z x $src
mkdir -p $out/bin
cd $out/bin
echo "#!${stdenv.shell}" >> $name
echo "export WINEARCH=win64" >> $name
echo "export WINEPREFIX=~/.config/$name" >> $name
echo "${winetricks}/bin/winetricks -q corefonts dotnet472" >> $name
echo "${wineWowPackages.stable}/bin/wine $out/share/$name/App.exe" >> $name
chmod +x $name
'';
}