xfce.xfce4-panel-profiles: Fix missing typelib

Use setupHook to set up the proper GI_TYPELIB_PATH.

+46 -14
+46 -14
pkgs/desktops/xfce/applications/xfce4-panel-profiles/default.nix
··· 1 - { mkXfceDerivation, lib, python3, intltool, gettext, 2 - gtk3, libxfce4ui, libxfce4util, pango, harfbuzz, gdk-pixbuf, atk }: 1 + { stdenv 2 + , lib 3 + , fetchFromGitLab 4 + , gettext 5 + , gobject-introspection 6 + , intltool 7 + , wrapGAppsHook3 8 + , glib 9 + , gtk3 10 + , libxfce4ui 11 + , python3 12 + , gitUpdater 13 + }: 3 14 4 15 let 5 - pythonEnv = python3.withPackages(ps: [ ps.pygobject3 ps.psutil ]); 6 - makeTypelibPath = lib.makeSearchPathOutput "lib/girepository-1.0" "lib/girepository-1.0"; 7 - in mkXfceDerivation { 8 - category = "apps"; 16 + pythonEnv = python3.withPackages (ps: [ 17 + ps.pygobject3 18 + ps.psutil 19 + ]); 20 + in 21 + stdenv.mkDerivation (finalAttrs: { 9 22 pname = "xfce4-panel-profiles"; 10 23 version = "1.0.14"; 11 24 12 - sha256 = "sha256-mGA70t2U4mqEbcrj/DDsPl++EKWyZ8YXzKzzVOrH5h8="; 25 + src = fetchFromGitLab { 26 + domain = "gitlab.xfce.org"; 27 + owner = "apps"; 28 + repo = "xfce4-panel-profiles"; 29 + rev = "xfce4-panel-profiles-${finalAttrs.version}"; 30 + sha256 = "sha256-mGA70t2U4mqEbcrj/DDsPl++EKWyZ8YXzKzzVOrH5h8="; 31 + }; 13 32 14 - nativeBuildInputs = [ intltool gettext ]; 15 - propagatedBuildInputs = [ pythonEnv ]; 33 + nativeBuildInputs = [ 34 + gettext 35 + gobject-introspection 36 + intltool 37 + wrapGAppsHook3 38 + ]; 39 + 40 + buildInputs = [ 41 + glib 42 + gtk3 43 + libxfce4ui 44 + pythonEnv 45 + ]; 16 46 17 47 configurePhase = '' 48 + runHook preConfigure 49 + # This is just a handcrafted script and does not accept additional arguments. 18 50 ./configure --prefix=$out 51 + runHook postConfigure 19 52 ''; 20 53 21 - postFixup = '' 22 - wrapProgram $out/bin/xfce4-panel-profiles \ 23 - --set GI_TYPELIB_PATH ${makeTypelibPath [ gtk3 libxfce4ui libxfce4util pango harfbuzz gdk-pixbuf atk ]} 24 - ''; 54 + passthru.updateScript = gitUpdater { rev-prefix = "xfce4-panel-profiles-"; }; 25 55 26 56 meta = with lib; { 57 + homepage = "https://docs.xfce.org/apps/xfce4-panel-profiles/start"; 27 58 description = "Simple application to manage Xfce panel layouts"; 28 59 mainProgram = "xfce4-panel-profiles"; 29 60 maintainers = with maintainers; [ ] ++ teams.xfce.members; 61 + platforms = platforms.linux; 30 62 }; 31 - } 63 + })