Skip to content

Commit

Permalink
xppen_{3,4}: deduplicate common code
Browse files Browse the repository at this point in the history
  • Loading branch information
gepbird committed Nov 7, 2024
1 parent 1bcff45 commit a8c8e13
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 72 deletions.
18 changes: 18 additions & 0 deletions pkgs/applications/misc/xppen/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
callPackage,
}:

{
xppen_3 = callPackage ./generic.nix {
pname = "xppen_3";
version = "3.4.9-240131";
url = "https://www.xp-pen.com/download/file.html?id=2829&pid=1016&ext=gz";
hash = "sha256-udUjkOW6nGo8zvMhVl6Iepa6OzCVz/M9m+DMqNKrfFg=";
};
xppen_4 = callPackage ./generic.nix {
pname = "xppen_4";
version = "4.0.4-240815";
url = "https://www.xp-pen.com/download/file.html?id=3325&pid=1016&ext=gz";
hash = "sha256-NVO9VaUmcQDI4rL76BBQDmII8vpmmo9qgcGetv6CIFE=";
};
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,18 @@
autoPatchelfHook,
qt5,
libusb1,
pname,
version,
url,
hash,
}:

stdenv.mkDerivation {
pname = "xppen_3";
version = "3.4.9-240131";
inherit pname version;

# to update: try to find the latest 3.x.x .tar.gz on https://www.xp-pen.com/download
src = fetchzip {
extension = "tar.gz";
url = "https://www.xp-pen.com/download/file.html?id=2829&pid=1016&ext=gz";
hash = "sha256-udUjkOW6nGo8zvMhVl6Iepa6OzCVz/M9m+DMqNKrfFg=";
inherit url hash;
};

nativeBuildInputs = [
Expand Down
67 changes: 0 additions & 67 deletions pkgs/by-name/xp/xppen_4/package.nix

This file was deleted.

3 changes: 3 additions & 0 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -33708,6 +33708,9 @@ with pkgs;

xpano = callPackage ../applications/graphics/xpano { };

inherit (callPackage ../applications/misc/xppen { })
xppen_3 xppen_4;

xv = callPackage ../applications/graphics/xv { };

xygrib = libsForQt5.callPackage ../applications/misc/xygrib { };
Expand Down

0 comments on commit a8c8e13

Please sign in to comment.