hyprland: 0.41.2 -> 0.42.0

This commit is contained in:
Mihai Fufezan 2024-08-07 23:10:09 +03:00
parent 6404fe89d6
commit 73bad3c5e4
No known key found for this signature in database
3 changed files with 121 additions and 117 deletions

View File

@ -1,7 +1,7 @@
{
"branch": "main",
"commit_hash": "918d8340afd652b011b937d29d5eea0be08467f5",
"commit_message": "flake.lock: update",
"date": "2024-06-25",
"tag": "v0.41.2"
"commit_hash": "9a09eac79b85c846e3a865a9078a3f8ff65a9259",
"commit_message": "props: bump version to 0.42.0",
"date": "2024-08-07",
"tag": "v0.42.0"
}

View File

@ -1,77 +1,78 @@
{ lib
, stdenv
, fetchFromGitHub
, pkg-config
, makeWrapper
, meson
, cmake
, ninja
, binutils
, cairo
, epoll-shim
, expat
, fribidi
, git
, hyprcursor
, hyprland-protocols
, hyprlang
, hyprutils
, hyprwayland-scanner
, jq
, libGL
, libdrm
, libdatrie
, libexecinfo
, libinput
, libselinux
, libsepol
, libthai
, libuuid
, libxkbcommon
, mesa
, pango
, pciutils
, pcre2
, pkgconf
, python3
, systemd
, tomlplusplus
, wayland
, wayland-protocols
, wayland-scanner
, xwayland
, hwdata
, seatd
, libdisplay-info
, libliftoff
, xorg
, debug ? false
, enableXWayland ? true
, legacyRenderer ? false
, withSystemd ? lib.meta.availableOn stdenv.hostPlatform systemd
, wrapRuntimeDeps ? true
{
lib,
stdenv,
fetchFromGitHub,
pkg-config,
makeWrapper,
cmake,
ninja,
aquamarine,
binutils,
cairo,
epoll-shim,
expat,
fribidi,
git,
hwdata,
hyprcursor,
hyprlang,
hyprutils,
hyprwayland-scanner,
jq,
libGL,
libdatrie,
libdisplay-info,
libdrm,
libexecinfo,
libinput,
libliftoff,
libselinux,
libsepol,
libthai,
libuuid,
libxkbcommon,
mesa,
pango,
pciutils,
pcre2,
pkgconf,
python3,
seatd,
systemd,
tomlplusplus,
wayland,
wayland-protocols,
wayland-scanner,
xorg,
xwayland,
debug ? false,
enableXWayland ? true,
legacyRenderer ? false,
withSystemd ? lib.meta.availableOn stdenv.hostPlatform systemd,
wrapRuntimeDeps ? true,
# deprecated flags
, nvidiaPatches ? false
, hidpiXWayland ? false
, enableNvidiaPatches ? false
nvidiaPatches ? false,
hidpiXWayland ? false,
enableNvidiaPatches ? false,
}:
let
info = builtins.fromJSON (builtins.readFile ./info.json);
in
assert lib.assertMsg (!nvidiaPatches) "The option `nvidiaPatches` has been removed.";
assert lib.assertMsg (!enableNvidiaPatches) "The option `enableNvidiaPatches` has been removed.";
assert lib.assertMsg (!hidpiXWayland) "The option `hidpiXWayland` has been removed. Please refer https://wiki.hyprland.org/Configuring/XWayland";
assert lib.assertMsg (!hidpiXWayland)
"The option `hidpiXWayland` has been removed. Please refer https://wiki.hyprland.org/Configuring/XWayland";
stdenv.mkDerivation (finalAttrs: {
pname = "hyprland" + lib.optionalString debug "-debug";
version = "0.41.2";
version = "0.42.0";
src = fetchFromGitHub {
owner = "hyprwm";
repo = "hyprland";
fetchSubmodules = true;
rev = "refs/tags/v${finalAttrs.version}";
hash = "sha256-JmfnYz+9a4TjNl3mAus1VpoWtTI9d1xkW9MHbkcV0Po=";
hash = "sha256-deu8zvgseDg2gQEnZiCda4TrbA6pleE9iItoZlsoMtE=";
};
postPatch = ''
@ -97,16 +98,14 @@ stdenv.mkDerivation (finalAttrs: {
];
nativeBuildInputs = [
hwdata
hyprwayland-scanner
jq
makeWrapper
cmake
meson # for wlroots
ninja
pkg-config
wayland-scanner
python3 # for udis86
wayland-scanner
];
outputs = [
@ -115,54 +114,54 @@ stdenv.mkDerivation (finalAttrs: {
"dev"
];
buildInputs = [
cairo
expat
fribidi
git
hyprcursor.dev
hyprland-protocols
hyprlang
hyprutils
libGL
libdatrie
libdrm
libinput
libselinux
libsepol
libthai
libuuid
libxkbcommon
mesa
wayland
wayland-protocols
pango
pciutils
pcre2
tomlplusplus
# for subproject wlroots-hyprland
seatd
libliftoff
libdisplay-info
xorg.xcbutilerrors
xorg.xcbutilrenderutil
]
++ lib.optionals stdenv.hostPlatform.isBSD [ epoll-shim ]
++ lib.optionals stdenv.hostPlatform.isMusl [ libexecinfo ]
++ lib.optionals enableXWayland [
xorg.libxcb
xorg.libXdmcp
xorg.xcbutil
xorg.xcbutilwm
xwayland
]
++ lib.optionals withSystemd [ systemd ];
buildInputs =
[
aquamarine
cairo
expat
fribidi
git
hwdata
hyprcursor.dev
hyprlang
hyprutils
libGL
libdatrie
libdisplay-info
libdrm
libinput
libliftoff
libselinux
libsepol
libthai
libuuid
libxkbcommon
mesa
pango
pciutils
pcre2
seatd
tomlplusplus
wayland
wayland-protocols
]
++ lib.optionals stdenv.hostPlatform.isBSD [ epoll-shim ]
++ lib.optionals stdenv.hostPlatform.isMusl [ libexecinfo ]
++ lib.optionals enableXWayland [
xorg.libxcb
xorg.libXcursor
xorg.libXdmcp
xorg.xcbutil
xorg.xcbutilerrors
xorg.xcbutilrenderutil
xorg.xcbutilwm
xwayland
]
++ lib.optionals withSystemd [ systemd ];
cmakeBuildType =
if debug
then "Debug"
else "RelWithDebInfo";
cmakeBuildType = if debug then "Debug" else "RelWithDebInfo";
dontStrip = debug;
cmakeFlags = [
(lib.cmakeBool "NO_XWAYLAND" (!enableXWayland))
@ -173,7 +172,13 @@ stdenv.mkDerivation (finalAttrs: {
postInstall = ''
${lib.optionalString wrapRuntimeDeps ''
wrapProgram $out/bin/Hyprland \
--suffix PATH : ${lib.makeBinPath [binutils pciutils pkgconf]}
--suffix PATH : ${
lib.makeBinPath [
binutils
pciutils
pkgconf
]
}
''}
'';
@ -191,6 +196,6 @@ stdenv.mkDerivation (finalAttrs: {
wozeparrot
];
mainProgram = "Hyprland";
platforms = lib.platforms.linux;
platforms = lib.platforms.linux ++ lib.platforms.freebsd;
};
})

View File

@ -22,9 +22,8 @@ date=${date%T*}
# update version; otherwise fail
update-source-version hyprland "$version" --ignore-same-hash
# find hyprland dir
files="$(fd --full-path /hyprland/ | head -1)"
dir="${files%/*}"
# set hyprland dir
dir="pkgs/by-name/hy/hyprland"
echo -e '{
"branch": "'"$branch"'",
@ -32,4 +31,4 @@ echo -e '{
"commit_message": "'"$commit_message"'",
"date": "'"$date"'",
"tag": "'"$tag"'"
}' >"$dir/info.json"
}' >"$dir/info.json" || echo "Please run the script in the root of the Nixpkgs repo"