Merge pull request #185794 from lilyinstarlight/pkg/kodelife-1.0.5.161

kodelife: 0.9.8.143 -> 1.0.5.161
This commit is contained in:
Pavol Rusnak 2022-08-09 17:08:26 +02:00 committed by GitHub
commit 13433e1f0a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 81 additions and 39 deletions

View file

@ -1,15 +1,51 @@
{ lib, stdenv { lib
, fetchzip , stdenv
, fetchurl
, makeWrapper
, autoPatchelfHook
, dpkg
, alsa-lib , alsa-lib
, glib , curl
, gst_all_1 , avahi
, libGLU, libGL , gstreamer
, xorg , gst-plugins-base
, libxcb
, libX11
, libXcursor
, libXext
, libXi
, libXinerama
, libXrandr
, libXrender
, libXxf86vm
, libglvnd
, gnome
}: }:
let
runLibDeps = [
curl
avahi
libxcb
libX11
libXcursor
libXext
libXi
libXinerama
libXrandr
libXrender
libXxf86vm
libglvnd
];
runBinDeps = [
gnome.zenity
];
in
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "kodelife"; pname = "kodelife";
version = "0.9.8.143"; version = "1.0.5.161";
suffix = { suffix = {
aarch64-linux = "linux-arm64"; aarch64-linux = "linux-arm64";
@ -17,51 +53,55 @@ stdenv.mkDerivation rec {
x86_64-linux = "linux-x86_64"; x86_64-linux = "linux-x86_64";
}.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}"); }.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
src = fetchzip { src = fetchurl {
url = "https://hexler.net/pub/${pname}/${pname}-${version}-${suffix}.zip"; url = "https://hexler.net/pub/${pname}/${pname}-${version}-${suffix}.deb";
sha256 = { hash = {
aarch64-linux = "0ryjmpzpfqdqrvqpq851vvrjd8ld5g91gcigpv9rxp3z1b7qdand"; aarch64-linux = "sha256-6QZ5jCxINCH46GQx+V68FpkIAOIOFw4Kd0tUQTKBRzU=";
armv7l-linux = "08nlwn8ixndqil4m7j6c8gjxmwx8zi3in86arnwf13shk6cds5nb"; armv7l-linux = "sha256-eToNjPttY62EzNuRSVvJsHttO6Ux6LXRPRuuIKnvaxM=";
x86_64-linux = "0kbz7pvh4i4a3pj1vzbzzslha825i888isvsigcqsqvipjr4798q"; x86_64-linux = "sha256-5M2tgpF74RmrCLI44RBNXK5t0hMAOHtmcjWu7fypc0U=";
}.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}"); }.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
}; };
dontConfigure = true; unpackCmd = "mkdir root; dpkg-deb -x $curSrc root";
dontBuild = true;
dontStrip = true; strictDeps = true;
dontPatchELF = true;
preferLocalBuild = true; nativeBuildInputs = [
makeWrapper
autoPatchelfHook
dpkg
];
buildInputs = [
stdenv.cc.cc.lib
alsa-lib
gstreamer
gst-plugins-base
];
installPhase = '' installPhase = ''
runHook preInstall runHook preInstall
mkdir -p $out
cp -r usr/share $out/share
mkdir -p $out/bin mkdir -p $out/bin
mv KodeLife $out/bin cp opt/kodelife/KodeLife $out/bin/KodeLife
wrapProgram $out/bin/KodeLife \
--prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath runLibDeps} \
--prefix PATH : ${lib.makeBinPath runBinDeps}
runHook postInstall runHook postInstall
''; '';
preFixup = let
libPath = lib.makeLibraryPath [
stdenv.cc.cc.lib
alsa-lib
glib
gst_all_1.gstreamer
gst_all_1.gst-plugins-base
libGLU libGL
xorg.libX11
];
in ''
patchelf \
--set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" \
--set-rpath "${libPath}" \
$out/bin/KodeLife
'';
meta = with lib; { meta = with lib; {
homepage = "https://hexler.net/products/kodelife"; homepage = "https://hexler.net/kodelife";
description = "Real-time GPU shader editor"; description = "Real-time GPU shader editor";
sourceProvenance = with sourceTypes; [ binaryNativeCode ]; sourceProvenance = with sourceTypes; [ binaryNativeCode ];
license = licenses.unfree; license = licenses.unfree;
maintainers = with maintainers; [ prusnak ]; maintainers = with maintainers; [ prusnak lilyinstarlight ];
platforms = [ "aarch64-linux" "armv7l-linux" "x86_64-linux" ]; platforms = [ "aarch64-linux" "armv7l-linux" "x86_64-linux" ];
mainProgram = "KodeLife";
}; };
} }

View file

@ -36229,7 +36229,9 @@ with pkgs;
uhubctl = callPackage ../tools/misc/uhubctl {}; uhubctl = callPackage ../tools/misc/uhubctl {};
kodelife = callPackage ../applications/graphics/kodelife {}; kodelife = callPackage ../applications/graphics/kodelife {
inherit (gst_all_1) gstreamer gst-plugins-base;
};
bunnyfetch = callPackage ../tools/misc/bunnyfetch {}; bunnyfetch = callPackage ../tools/misc/bunnyfetch {};