envision: init at 0-unstable-2024-06-25
This commit is contained in:
parent
6b251b07d2
commit
b9d225182c
2530
pkgs/by-name/en/envision-unwrapped/Cargo.lock
generated
Normal file
2530
pkgs/by-name/en/envision-unwrapped/Cargo.lock
generated
Normal file
File diff suppressed because it is too large
Load Diff
100
pkgs/by-name/en/envision-unwrapped/package.nix
Normal file
100
pkgs/by-name/en/envision-unwrapped/package.nix
Normal file
@ -0,0 +1,100 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
fetchFromGitLab,
|
||||
writeScript,
|
||||
appstream-glib,
|
||||
cargo,
|
||||
meson,
|
||||
ninja,
|
||||
pkg-config,
|
||||
rustPlatform,
|
||||
rustc,
|
||||
wrapGAppsHook4,
|
||||
cairo,
|
||||
desktop-file-utils,
|
||||
gdb,
|
||||
gdk-pixbuf,
|
||||
glib,
|
||||
gtk4,
|
||||
gtksourceview5,
|
||||
libadwaita,
|
||||
libgit2,
|
||||
libusb1,
|
||||
openssl,
|
||||
pango,
|
||||
vte-gtk4,
|
||||
zlib,
|
||||
unstableGitUpdater,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "envision-unwrapped";
|
||||
version = "0-unstable-2024-06-25";
|
||||
|
||||
src = fetchFromGitLab {
|
||||
owner = "gabmus";
|
||||
repo = "envision";
|
||||
rev = "b594f75778961c281daca398011914e9ac14b753";
|
||||
hash = "sha256-felt9KdgVrXSgoufw/+gDlluqdv8vySDqwskQ0t2JOM=";
|
||||
};
|
||||
|
||||
strictDeps = true;
|
||||
|
||||
cargoDeps = rustPlatform.importCargoLock {
|
||||
lockFile = ./Cargo.lock;
|
||||
outputHashes = {
|
||||
"libmonado-rs-0.1.0" = "sha256-PsNgfpgso3HhIMXKky/u6Xw8phk1isRpNXKLhvN1wIE=";
|
||||
};
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
appstream-glib
|
||||
desktop-file-utils
|
||||
cargo
|
||||
meson
|
||||
ninja
|
||||
pkg-config
|
||||
rustPlatform.cargoSetupHook
|
||||
rustc
|
||||
wrapGAppsHook4
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
cairo
|
||||
gdk-pixbuf
|
||||
glib
|
||||
gtk4
|
||||
gtksourceview5
|
||||
libadwaita
|
||||
libgit2
|
||||
libusb1
|
||||
openssl
|
||||
pango
|
||||
vte-gtk4
|
||||
zlib
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
wrapProgram $out/bin/envision \
|
||||
--prefix PATH : "${lib.makeBinPath [ gdb ]}"
|
||||
'';
|
||||
|
||||
passthru.updateScript = writeScript "envision-update" ''
|
||||
source ${builtins.head (unstableGitUpdater { })}
|
||||
|
||||
cp $tmpdir/Cargo.lock ./pkgs/by-name/en/envision-unwrapped/Cargo.lock
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "UI for building, configuring and running Monado, the open source OpenXR runtime";
|
||||
homepage = "https://gitlab.com/gabmus/envision";
|
||||
license = lib.licenses.agpl3Only;
|
||||
mainProgram = "envision";
|
||||
maintainers = with lib.maintainers; [
|
||||
pandapip1
|
||||
Scrumplex
|
||||
];
|
||||
platforms = lib.platforms.linux;
|
||||
};
|
||||
})
|
93
pkgs/by-name/en/envision/package.nix
Normal file
93
pkgs/by-name/en/envision/package.nix
Normal file
@ -0,0 +1,93 @@
|
||||
{ buildFHSEnv, envision-unwrapped }:
|
||||
|
||||
buildFHSEnv {
|
||||
name = "envision";
|
||||
|
||||
extraOutputsToInstall = [ "dev" ];
|
||||
|
||||
strictDeps = true;
|
||||
|
||||
targetPkgs =
|
||||
pkgs:
|
||||
[ pkgs.envision-unwrapped ]
|
||||
++ (with pkgs; [
|
||||
glibc
|
||||
gcc
|
||||
])
|
||||
++ (
|
||||
# OpenHMD dependencies
|
||||
pkgs.openhmd.buildInputs ++ pkgs.openhmd.nativeBuildInputs
|
||||
)
|
||||
++ (
|
||||
# OpenComposite dependencies
|
||||
pkgs.opencomposite.buildInputs ++ pkgs.opencomposite.nativeBuildInputs ++ [ pkgs.boost ]
|
||||
)
|
||||
++ (
|
||||
# Monado dependencies
|
||||
(
|
||||
pkgs.monado.buildInputs
|
||||
++ pkgs.monado.nativeBuildInputs
|
||||
++ (with pkgs; [
|
||||
# Additional dependencies required by Monado when built using Envision
|
||||
mesa
|
||||
shaderc
|
||||
xorg.libX11
|
||||
xorg.libxcb
|
||||
xorg.libXrandr
|
||||
xorg.libXrender
|
||||
xorg.xorgproto
|
||||
])
|
||||
)
|
||||
)
|
||||
++ (
|
||||
# SteamVR driver dependencies
|
||||
[ pkgs.zlib ])
|
||||
++ (
|
||||
# WiVRn dependencies
|
||||
# TODO: Replace with https://github.com/NixOS/nixpkgs/pull/316975 once merged
|
||||
(with pkgs; [
|
||||
avahi
|
||||
cmake
|
||||
cli11
|
||||
ffmpeg
|
||||
git
|
||||
gst_all_1.gstreamer
|
||||
gst_all_1.gst-plugins-base
|
||||
libmd
|
||||
libdrm
|
||||
libpulseaudio
|
||||
libva
|
||||
ninja
|
||||
nlohmann_json
|
||||
openxr-loader
|
||||
pipewire
|
||||
systemdLibs # udev
|
||||
vulkan-loader
|
||||
vulkan-headers
|
||||
x264
|
||||
])
|
||||
++ (with pkgs; [
|
||||
android-tools # For adb installing WiVRn APKs
|
||||
])
|
||||
);
|
||||
|
||||
profile = ''
|
||||
export CMAKE_LIBRARY_PATH=/usr/lib
|
||||
export CMAKE_INCLUDE_PATH=/usr/include
|
||||
export PKG_CONFIG_PATH=/usr/lib/pkgconfig:/usr/share/pkgconfig
|
||||
'';
|
||||
|
||||
extraInstallCommands = ''
|
||||
mkdir -p $out/share/applications $out/share/metainfo
|
||||
ln -s ${envision-unwrapped}/share/envision $out/share
|
||||
ln -s ${envision-unwrapped}/share/icons $out/share
|
||||
ln -s ${envision-unwrapped}/share/applications/org.gabmus.envision.desktop $out/share/applications
|
||||
ln -s ${envision-unwrapped}/share/metainfo/org.gabmus.envision.appdata.xml $out/share/metainfo
|
||||
'';
|
||||
|
||||
runScript = "envision";
|
||||
|
||||
meta = envision-unwrapped.meta // {
|
||||
description = "${envision-unwrapped.meta.description} (with build environment)";
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue
Block a user