nur-packages

My NUR packages
git clone git://git.sikmir.ru/nur-packages
Log | Files | Refs | README | LICENSE

commit a6edacf2d28b1cf65e6c65a40a4f8bdf3000f52f
parent dc10087ea770602b8bbec62f683cc7a3673a30d1
Author: Nikolay Korotkiy <sikmir@gmail.com>
Date:   Fri, 18 Sep 2020 09:31:00 +0300

Add qvge

Diffstat:
Mnix/sources.json | 14++++++++++++++
Apkgs/applications/qvge/default.nix | 39+++++++++++++++++++++++++++++++++++++++
Apkgs/applications/qvge/fix-config.patch | 53+++++++++++++++++++++++++++++++++++++++++++++++++++++
Mpkgs/default.nix | 1+
4 files changed, 107 insertions(+), 0 deletions(-)

diff --git a/nix/sources.json b/nix/sources.json @@ -771,6 +771,20 @@ "url": "https://github.com/tumic0/QtPBFImagePlugin-styles/archive/577bb119641c80e1736815ed70a0b99c942c63e0.tar.gz", "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" }, + "qvge": { + "branch": "master", + "builtin": false, + "date": "2020-08-21T06:52:43Z", + "description": "Qt Visual Graph Editor", + "homepage": "https://arsmasiuk.github.io/qvge/", + "owner": "ArsMasiuk", + "repo": "qvge", + "rev": "1fc861f939a7fb28d7159fa9621197a27e8f486c", + "sha256": "19cafjf7qwjr8c6kyiaqc48xwb8xf18blbrna11skaby6k4by68n", + "type": "tarball", + "url": "https://github.com/ArsMasiuk/qvge/archive/1fc861f939a7fb28d7159fa9621197a27e8f486c.tar.gz", + "url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz" + }, "redict": { "branch": "master", "builtin": false, diff --git a/pkgs/applications/qvge/default.nix b/pkgs/applications/qvge/default.nix @@ -0,0 +1,39 @@ +{ lib +, stdenv +, mkDerivation +, substituteAll +, ogdf +, qmake +, qtx11extras +, sources +}: +let + pname = "qvge"; + date = lib.substring 0 10 sources.qvge.date; + version = "unstable-" + date; +in +mkDerivation { + inherit pname version; + src = sources.qvge; + + patches = (substituteAll { + src = ./fix-config.patch; + inherit ogdf; + }); + + preConfigure = "cd src"; + + nativeBuildInputs = [ qmake ]; + + buildInputs = [ ogdf qtx11extras ]; + + qmakeFlags = [ "-r" ]; + + meta = with lib; { + inherit (sources.qvge) description homepage; + license = licenses.mit; + maintainers = [ maintainers.sikmir ]; + platforms = with platforms; linux; + skip.ci = stdenv.isDarwin; + }; +} diff --git a/pkgs/applications/qvge/fix-config.patch b/pkgs/applications/qvge/fix-config.patch @@ -0,0 +1,53 @@ +diff --git i/src/app.pri w/src/app.pri +index 83ef422..3658b52 100644 +--- i/src/app.pri ++++ w/src/app.pri +@@ -27,7 +27,7 @@ USE_LOCAL_OGDF{ + } + + USE_EXTERNAL_OGDF{ +- LIBS += -l$$OGDF_LIB_NAME -L$$OGDF_LIB_PATH ++ LIBS += $$OGDF_LIB_PATH/libOGDF.a $$OGDF_LIB_PATH/libCOIN.a + INCLUDEPATH += $$OGDF_INCLUDE_PATH + } + +diff --git i/src/config.pri w/src/config.pri +index 64e585f..d506d84 100644 +--- i/src/config.pri ++++ w/src/config.pri +@@ -5,9 +5,9 @@ + # + # It can be used freely, maintaining the information above. + +-CONFIG += BUILD_OGDF ++#CONFIG += BUILD_OGDF + #CONFIG += USE_LOCAL_OGDF +-#CONFIG += USE_EXTERNAL_OGDF ++CONFIG += USE_EXTERNAL_OGDF + + BUILD_OGDF{ + CONFIG += USE_LOCAL_OGDF +@@ -31,8 +31,8 @@ USE_EXTERNAL_OGDF{ + + # system-specific OGDF setup + OGDF_LIB_NAME = ogdf +- OGDF_LIB_PATH = +- OGDF_INCLUDE_PATH = /usr/share/ogdf/include ++ OGDF_LIB_PATH = @ogdf@/lib ++ OGDF_INCLUDE_PATH = @ogdf@/include + } + + USE_OGDF{ +diff --git i/src/qvgeapp/qvgeapp.pro w/src/qvgeapp/qvgeapp.pro +index 86135f6..dbce621 100644 +--- i/src/qvgeapp/qvgeapp.pro ++++ w/src/qvgeapp/qvgeapp.pro +@@ -55,7 +55,7 @@ unix{ + desktop.files = $$PWD/linux/qvge.desktop + INSTALLS += desktop + +- icon.path = $PREFIX_DIR/share/pixmaps ++ icon.path = $$PREFIX_DIR/share/pixmaps + icon.files = $$PWD/linux/qvge.png + INSTALLS += icon + diff --git a/pkgs/default.nix b/pkgs/default.nix @@ -33,6 +33,7 @@ lib.makeScope newScope ( qgis-ltr-bin = qgis-bin.override { releaseType = "ltr"; }; qmapshack-bin = callPackage ./applications/qmapshack/bin.nix { }; qutebrowser-bin = callPackage ./applications/qutebrowser/bin.nix { }; + qvge = libsForQt5.callPackage ../applications/qvge { }; redict = libsForQt5.callPackage ./applications/redict { inherit sources; };