Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

graphui: init at 1.1.1 #78021

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
75 changes: 75 additions & 0 deletions pkgs/applications/graphics/graphui/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
{ stdenv
, fetchFromGitHub
, meson
, ninja
, vala
, pkg-config
, pantheon
, python3
, desktop-file-utils
, glib
, graphviz
, gtk3
, gtksourceview
, libgee
, substituteAll
, wrapGAppsHook
}:

stdenv.mkDerivation rec {
pname = "graphui";
version = "1.1.1";

src = fetchFromGitHub {
owner = "artemanufrij";
repo = pname;
rev = version;
sha256 = "19r44rw0chvj7yrqf35rvpg1yziv25d43h392qnwbmifnq1kbfcs";
};

patches = [
(substituteAll {
src = ./fix-paths.patch;
graphviz = "${graphviz}/bin/";
})
];

nativeBuildInputs = [
meson
ninja
vala
pkg-config
python3
desktop-file-utils
wrapGAppsHook
];

buildInputs = [
glib
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it doesn't seem they include this as a dependency object in meson. Will PR that.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gtk3
gtksourceview
graphviz
libgee
pantheon.granite
];

postPatch = ''
chmod +x meson/post_install.py
patchShebangs meson/post_install.py
'';

passthru = {
updateScript = pantheon.updateScript {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe nix-update-script?

attrPath = pname;
};
};

meta = with stdenv.lib; {
description = "Graph visualization based on graphviz";
homepage = "https://github.com/artemanufrij/graphui";
maintainers = with maintainers; [ kjuvi ] ++ pantheon.maintainers;
platforms = platforms.linux;
license = licenses.lgpl2Plus;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

they're missing like LICENSE or COPYING file in their repo.
The debian packaging mentions gpl-3.0, but the preambles are different.
I think that needs to be sorted?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I opened an issue: artemanufrij/graphui#18

};
}

13 changes: 13 additions & 0 deletions pkgs/applications/graphics/graphui/fix-paths.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/src/Services/GraphViz.vala b/src/Services/GraphViz.vala
index 213d4e5..192b8dd 100644
--- a/src/Services/GraphViz.vala
+++ b/src/Services/GraphViz.vala
@@ -76,7 +76,7 @@ namespace GraphUI.Services {
}
output_image = GraphUIApp.instance.CACHE_FOLDER + "/output.svg";

- string[] spawn_args = {format, "-T%s".printf (type), "%s".printf (output_txt), "-o", "%s".printf (output_image)};
+ string[] spawn_args = {"@graphviz@" + format, "-T%s".printf (type), "%s".printf (output_txt), "-o", "%s".printf (output_image)};
string[] spawn_env = Environ.get ();

string processout = "";
2 changes: 2 additions & 0 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -19333,6 +19333,8 @@ in

graphicsmagick-imagemagick-compat = callPackage ../applications/graphics/graphicsmagick/compat.nix { };

graphui = callPackage ../applications/graphics/graphui/default.nix { };

grisbi = callPackage ../applications/office/grisbi { gtk = gtk3; };

gtkpod = callPackage ../applications/audio/gtkpod { };
Expand Down