nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at devShellTools-shell 125 lines 3.8 kB view raw
1# For upstream versions, download links, and change logs see https://www.qoppa.com/pdfstudio/versions 2# 3# PDF Studio license is for a specific year, so we need different packages for different years. 4# All versions of PDF Studio Viewer are free, so we package only the latest year. 5# Thus, packages are pdfstudioviewer, pdfstudio2021, pdfstudio2022, etc. 6# Variables: 7# - program is either "pdfstudio" or "pdfstudioviewer", defaults to "pdfstudio". 8# - year identifies the year portion of the version, defaults to most recent year. 9# - pname is either "pdfstudio${year}" or "pdfstudioviewer". 10 11{ 12 lib, 13 stdenv, 14 program ? "pdfstudio", 15 year ? "2024", 16 fetchurl, 17 callPackage, 18 jdk11, 19 jdk17, 20}: 21let 22 longDescription = '' 23 PDF Studio is an easy to use, full-featured PDF editing software. This is the standard/pro edition, which requires a license. For the free PDF Studio Viewer see the package pdfstudioviewer. 24 ''; 25 pname = if (program == "pdfstudio") then "${program}${year}" else program; 26 desktopName = if (program == "pdfstudio") then "PDF Studio ${year}" else "PDF Studio Viewer"; 27 dot2dash = str: builtins.replaceStrings [ "." ] [ "_" ] str; 28in 29{ 30 pdfstudioviewer = callPackage ./common.nix rec { 31 inherit 32 desktopName 33 pname 34 program 35 year 36 ; 37 version = "${year}.0.1"; 38 longDescription = '' 39 PDF Studio Viewer is an easy to use, full-featured PDF editing software. This is the free edition. For the standard/pro edition, see the package pdfstudio. 40 ''; 41 src = fetchurl { 42 url = "https://web.archive.org/web/20241201121627/https://download.qoppa.com/pdfstudioviewer/PDFStudioViewer_linux64.deb"; 43 hash = "sha256-hxReGuyGsBiEr7wWxWzQUQvxk11sgF9HkJ07L9i+e+0="; 44 }; 45 jdk = jdk17; 46 }; 47 48 pdfstudio2021 = callPackage ./common.nix rec { 49 inherit 50 desktopName 51 longDescription 52 pname 53 program 54 year 55 ; 56 version = "${year}.2.2"; 57 src = fetchurl { 58 url = "https://download.qoppa.com/pdfstudio/v${year}/PDFStudio_v${dot2dash version}_linux64.deb"; 59 hash = "sha256-HdkwRMqwquAaW6l3AukGReFtw2f5n36tZ8vXo6QiPvU="; 60 }; 61 extraBuildInputs = [ 62 (lib.getLib stdenv.cc.cc) # for libstdc++.so.6 and libgomp.so.1 63 ]; 64 jdk = jdk11; 65 }; 66 67 pdfstudio2022 = callPackage ./common.nix rec { 68 inherit 69 desktopName 70 longDescription 71 pname 72 program 73 year 74 ; 75 version = "${year}.2.5"; 76 src = fetchurl { 77 url = "https://download.qoppa.com/pdfstudio/v${year}/PDFStudio_v${dot2dash version}_linux64.deb"; 78 hash = "sha256-3faZyWUnFe//S+gOskWhsZ6jzHw67FRsv/xP77R1jj4="; 79 }; 80 extraBuildInputs = [ 81 (lib.getLib stdenv.cc.cc) # for libstdc++.so.6 and libgomp.so.1 82 ]; 83 jdk = jdk17; 84 }; 85 86 pdfstudio2023 = callPackage ./common.nix rec { 87 inherit 88 desktopName 89 longDescription 90 pname 91 program 92 year 93 ; 94 version = "${year}.0.4"; 95 src = fetchurl { 96 url = "https://download.qoppa.com/pdfstudio/v${year}/PDFStudio_v${dot2dash version}_linux64.deb"; 97 hash = "sha256-TTh0yzpCOpxFKGfrakvnu1Y+l9NI0nfWlVuvSWpkRkE="; 98 }; 99 extraBuildInputs = [ 100 (lib.getLib stdenv.cc.cc) # for libstdc++.so.6 and libgomp.so.1 101 ]; 102 jdk = jdk17; 103 }; 104 105 pdfstudio2024 = callPackage ./common.nix rec { 106 inherit 107 desktopName 108 longDescription 109 pname 110 program 111 year 112 ; 113 version = "${year}.0.1"; 114 src = fetchurl { 115 url = "https://download.qoppa.com/pdfstudio/v${year}/PDFStudio_v${dot2dash version}_linux64.deb"; 116 hash = "sha256-dptpkWPlocp4U9QSp+AJTOSVWA3RRs8GrFfXhCYzOJc="; 117 }; 118 extraBuildInputs = [ 119 (lib.getLib stdenv.cc.cc) # for libstdc++.so.6 and libgomp.so.1 120 ]; 121 jdk = jdk17; 122 }; 123 124} 125.${pname}