5 subproject ? "library", # one of "library", "reader" or "writer"
12 subdir = lib.getAttr subproject {
13 "library" = "jabcode";
14 "reader" = "jabcodeReader";
15 "writer" = "jabcodeWriter";
18 stdenv.mkDerivation rec {
19 pname = "jabcode-${subproject}";
20 version = "unstable-2022-06-17";
21 src = fetchFromGitHub {
24 rev = "ee0e4c88b9f3c1da46d6f679ee8b69c547907c20";
25 hash = "sha256-GjRkDWefQFdT4i9hRcQhYsY4beMUIXxy38I5lsQytyA=";
32 ] ++ lib.optionals (subproject != "library") [ jabcode ];
34 preConfigure = "cd src/${subdir}";
37 if subproject == "library" then
49 description = "High-capacity 2D color bar code (${subproject})";
50 longDescription = "JAB Code (Just Another Bar Code) is a high-capacity 2D color bar code, which can encode more data than traditional black/white (QR) codes. This is the ${subproject} part.";
51 homepage = "https://jabcode.org/";
52 license = licenses.lgpl21;
53 maintainers = [ maintainers.xaverdh ];
54 platforms = platforms.unix;
55 broken = stdenv.hostPlatform.isDarwin; # never built on Hydra https://hydra.nixos.org/job/nixpkgs/trunk/jabcode.x86_64-darwin