nix format
This commit is contained in:
@@ -18,13 +18,16 @@ buildHomeAssistantComponent rec {
|
||||
hash = "sha256-hxgQsHb0E/XQEZoVFtKOgdHEVsU5UgqhOjjkgKqlI1I=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = with python3Packages; [
|
||||
# gehomesdk
|
||||
slixmpp
|
||||
] ++ (with pkgs.${namespace}; [
|
||||
gehomesdk
|
||||
magicattr
|
||||
]);
|
||||
nativeBuildInputs =
|
||||
with python3Packages;
|
||||
[
|
||||
# gehomesdk
|
||||
slixmpp
|
||||
]
|
||||
++ (with pkgs.${namespace}; [
|
||||
gehomesdk
|
||||
magicattr
|
||||
]);
|
||||
|
||||
meta = {
|
||||
changelog = "https://github.com/simbaja/ha_gehome/releases/tag/${version}";
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
#!/usr/bin/env bash
|
||||
set -eu
|
||||
|
||||
for flavor in cachyos{-gcc,-server,-lts,-rc,-hardened,-lto,-server-lto,-lts-lto,-rc-lto,-hardened-lto}; do
|
||||
# -gcc,-server,-lts,-rc,-hardened,
|
||||
|
||||
for flavor in cachyos{-lto,-server-lto,-lts-lto,-rc-lto,-hardened-lto}; do
|
||||
nom build ".#nixosConfigurations.jallen-nas.pkgs.mjallen.linuxPackages_${flavor}.kernel"
|
||||
attic push nas-cache result*
|
||||
done
|
||||
|
||||
149
packages/superposition/default.nix
Normal file
149
packages/superposition/default.nix
Normal file
@@ -0,0 +1,149 @@
|
||||
{
|
||||
lib,
|
||||
glib,
|
||||
stdenv,
|
||||
dbus,
|
||||
freetype,
|
||||
fontconfig,
|
||||
zlib,
|
||||
libsForQt5,
|
||||
libxinerama,
|
||||
libxcb,
|
||||
libsm,
|
||||
libxi,
|
||||
libglvnd,
|
||||
libxext,
|
||||
libxrandr,
|
||||
mailspring,
|
||||
libx11,
|
||||
libice,
|
||||
libxrender,
|
||||
autoPatchelfHook,
|
||||
makeWrapper,
|
||||
xkeyboard_config,
|
||||
fetchurl,
|
||||
buildFHSEnv,
|
||||
openal,
|
||||
makeDesktopItem,
|
||||
}:
|
||||
|
||||
let
|
||||
pname = "unigine-superposition";
|
||||
version = "1.1";
|
||||
|
||||
superposition = stdenv.mkDerivation rec {
|
||||
inherit pname version;
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://assets.unigine.com/d/Unigine_Superposition-${version}.run";
|
||||
sha256 = "sha256-dJThxzv1nvIWFRPV1cudm/+9hHmSnUl2rFO2lV3lgPg=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
autoPatchelfHook
|
||||
makeWrapper
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
glib
|
||||
stdenv.cc.cc
|
||||
dbus
|
||||
freetype
|
||||
fontconfig
|
||||
zlib
|
||||
libsForQt5.qt5.qtquickcontrols2
|
||||
libxinerama
|
||||
libxcb
|
||||
libsm
|
||||
libxi
|
||||
libglvnd
|
||||
libxext
|
||||
libxrandr
|
||||
mailspring
|
||||
libx11
|
||||
libice
|
||||
libxrender
|
||||
];
|
||||
|
||||
installPhase = ''
|
||||
bash $src --target $name --noexec
|
||||
mkdir -p $out/bin $out/lib/unigine/superposition/
|
||||
cp -r $name/* $out/lib/unigine/superposition/
|
||||
echo "exec $out/lib/unigine/superposition/Superposition" >> $out/bin/superposition
|
||||
chmod +x $out/bin/superposition
|
||||
wrapProgram $out/lib/unigine/superposition/Superposition \
|
||||
--set QT_XKB_CONFIG_ROOT ${xkeyboard_config} \
|
||||
--run "cd $out/lib/unigine/superposition/"
|
||||
'';
|
||||
|
||||
dontUnpack = true;
|
||||
dontWrapQtApps = true;
|
||||
|
||||
postPatchMkspecs = ''
|
||||
cp -f $name/bin/superposition $out/lib/unigine/superposition/bin/superposition
|
||||
'';
|
||||
};
|
||||
|
||||
desktopItem = makeDesktopItem {
|
||||
name = "Superposition";
|
||||
exec = "unigine-superposition";
|
||||
genericName = "A GPU Stress test tool from the UNIGINE";
|
||||
icon = "Superposition";
|
||||
desktopName = "Superposition Benchmark";
|
||||
};
|
||||
|
||||
in
|
||||
|
||||
# We can patch the "/bin/superposition", but "/bin/launcher" checks it for changes.
|
||||
# For that we need use a buildFHSEnv.
|
||||
|
||||
buildFHSEnv {
|
||||
inherit pname version;
|
||||
|
||||
targetPkgs = _pkgs: [
|
||||
superposition
|
||||
glib
|
||||
stdenv.cc.cc
|
||||
dbus
|
||||
freetype
|
||||
fontconfig
|
||||
zlib
|
||||
libsForQt5.qt5.qtquickcontrols2
|
||||
libxinerama
|
||||
libxcb
|
||||
libsm
|
||||
libxi
|
||||
libglvnd
|
||||
libxext
|
||||
libxrandr
|
||||
mailspring
|
||||
libx11
|
||||
libice
|
||||
libxrender
|
||||
openal
|
||||
];
|
||||
runScript = "superposition";
|
||||
|
||||
extraInstallCommands = ''
|
||||
# create directories
|
||||
mkdir -p $out/share/icons/hicolor $out/share/applications
|
||||
# create .desktop file
|
||||
ln -s ${desktopItem}/share/applications/* $out/share/applications
|
||||
# install Superposition.desktop and icon
|
||||
cp ${superposition}/lib/unigine/superposition/Superposition.png $out/share/icons/
|
||||
for RES in 16 24 32 48 64 128 256; do
|
||||
mkdir -p $out/share/icons/hicolor/"$RES"x"$RES"/apps
|
||||
cp ${superposition}/lib/unigine/superposition/icons/superposition_icon_$RES.png $out/share/icons/hicolor/"$RES"x"$RES"/apps/Superposition.png
|
||||
done
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Unigine Superposition GPU benchmarking tool";
|
||||
homepage = "https://benchmark.unigine.com/superposition";
|
||||
sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
|
||||
license = lib.licenses.unfree;
|
||||
maintainers = [ ];
|
||||
platforms = [ "x86_64-linux" ];
|
||||
mainProgram = "unigine-superposition";
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user