bitscope: init at 2017-12-28

authored by David Asabina and committed by Bjørn Forsman 810ec3f8 8dbfe699

+222
+67
pkgs/applications/science/electronics/bitscope/common.nix
··· 1 + { atk 2 + , buildFHSUserEnv 3 + , cairo 4 + , dpkg 5 + , fetchurl 6 + , gdk_pixbuf 7 + , glib 8 + , gtk2-x11 9 + , makeWrapper 10 + , pango 11 + , stdenv 12 + , writeScriptBin 13 + , xorg 14 + }: 15 + 16 + { src, toolName, version, ... } @ attrs: 17 + let 18 + wrapBinary = libPaths: binaryName: '' 19 + wrapProgram "$out/bin/${binaryName}" \ 20 + --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath libPaths}" 21 + ''; 22 + pkg = stdenv.mkDerivation (rec { 23 + inherit (attrs) version src; 24 + 25 + name = "${toolName}-${version}"; 26 + 27 + meta = with stdenv.lib; { 28 + homepage = http://bitscope.com/software/; 29 + license = licenses.unfree; 30 + platforms = [ "x86_64-linux" ]; 31 + maintainers = with maintainers; [ 32 + vidbina 33 + ]; 34 + } // (attrs.meta or {}); 35 + 36 + buildInputs = [ 37 + dpkg 38 + makeWrapper 39 + ]; 40 + 41 + libs = attrs.libs or [ 42 + atk 43 + cairo 44 + gdk_pixbuf 45 + glib 46 + gtk2-x11 47 + pango 48 + xorg.libX11 49 + ]; 50 + 51 + dontBuild = true; 52 + 53 + unpackPhase = attrs.unpackPhase or '' 54 + dpkg-deb -x ${attrs.src} ./ 55 + ''; 56 + 57 + installPhase = attrs.installPhase or '' 58 + mkdir -p "$out/bin" 59 + cp -a usr/* "$out/" 60 + ${(wrapBinary libs) attrs.toolName} 61 + ''; 62 + }); 63 + in buildFHSUserEnv { 64 + name = attrs.toolName; 65 + meta = pkg.meta; 66 + runScript = "${pkg.outPath}/bin/${attrs.toolName}"; 67 + }
+153
pkgs/applications/science/electronics/bitscope/packages.nix
··· 1 + { buildFHSUserEnv 2 + , callPackage 3 + , fetchurl 4 + , makeWrapper 5 + , stdenv 6 + }: 7 + 8 + let 9 + wrapBinary = libPaths: binaryName: '' 10 + wrapProgram "$out/bin/${binaryName}" \ 11 + --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath libPaths}" 12 + ''; 13 + mkBitscope = callPackage (import ./common.nix) { }; 14 + in { 15 + chart = let 16 + toolName = "bitscope-chart"; 17 + version = "2.0.FK22M"; 18 + in mkBitscope { 19 + inherit toolName version; 20 + 21 + meta = { 22 + description = "Multi-channel waveform data acquisition and chart recording application"; 23 + homepage = "http://bitscope.com/software/chart/"; 24 + }; 25 + 26 + src = fetchurl { 27 + url = "http://bitscope.com/download/files/${toolName}_${version}_amd64.deb"; 28 + sha256 = "08mc82pjamyyyhh15sagsv0sc7yx5v5n54bg60fpj7v41wdwrzxw"; 29 + }; 30 + }; 31 + 32 + console = let 33 + toolName = "bitscope-console"; 34 + version = "1.0.FK29A"; 35 + in mkBitscope { 36 + # NOTE: this is meant as a demo by BitScope 37 + inherit toolName version; 38 + 39 + meta = { 40 + description = "Demonstrative communications program designed to make it easy to talk to any model BitScope"; 41 + }; 42 + 43 + src = fetchurl { 44 + url = "http://bitscope.com/download/files/${toolName}_${version}_amd64.deb"; 45 + sha256 = "00b4gxwz7w6pmfrcz14326b24kl44hp0gzzqcqxwi5vws3f0y49d"; 46 + }; 47 + }; 48 + 49 + display = let 50 + toolName = "bitscope-display"; 51 + version = "1.0.EC17A"; 52 + in mkBitscope { 53 + inherit toolName version; 54 + 55 + meta = { 56 + description = "Display diagnostic application for BitScope"; 57 + homepage = "http://bitscope.com/software/display/"; 58 + }; 59 + 60 + src = fetchurl { 61 + url = "http://bitscope.com/download/files/${toolName}_${version}_amd64.deb"; 62 + sha256 = "05xr5mnka1v3ibcasg74kmj6nlv1nmn3lca1wv77whkq85cmz0s1"; 63 + }; 64 + }; 65 + 66 + dso = let 67 + toolName = "bitscope-dso"; 68 + version = "2.8.FE22H"; 69 + in mkBitscope { 70 + inherit toolName version; 71 + 72 + meta = { 73 + description = "Test and measurement software for BitScope"; 74 + homepage = "http://bitscope.com/software/dso/"; 75 + }; 76 + 77 + src = fetchurl { 78 + url = "http://bitscope.com/download/files/${toolName}_${version}_amd64.deb"; 79 + sha256 = "0fc6crfkprj78dxxhvhbn1dx1db5chm0cpwlqpqv8sz6whp12mcj"; 80 + }; 81 + }; 82 + 83 + logic = let 84 + toolName = "bitscope-logic"; 85 + version = "1.2.FC20C"; 86 + in mkBitscope { 87 + inherit toolName version; 88 + 89 + meta = { 90 + description = "Mixed signal logic timing and serial protocol analysis software for BitScope"; 91 + home = "http://bitscope.com/software/logic/"; 92 + }; 93 + 94 + src = fetchurl { 95 + url = "http://bitscope.com/download/files/${toolName}_${version}_amd64.deb"; 96 + sha256 = "0lkb7z9gfkiyxdwh4dq1zxfls8gzdw0na1vrrbgnxfg3klv4xns3"; 97 + }; 98 + }; 99 + 100 + meter = let 101 + toolName = "bitscope-meter"; 102 + version = "2.0.FK22G"; 103 + in mkBitscope { 104 + inherit toolName version; 105 + 106 + meta = { 107 + description = "Automated oscilloscope, voltmeter and frequency meter for BitScope"; 108 + homepage = "http://bitscope.com/software/logic/"; 109 + }; 110 + 111 + src = fetchurl { 112 + url = "http://bitscope.com/download/files/${toolName}_${version}_amd64.deb"; 113 + sha256 = "0nirbci6ymhk4h4bck2s4wbsl5r9yndk2jvvv72zwkg21248mnbp"; 114 + }; 115 + }; 116 + 117 + proto = let 118 + toolName = "bitscope-proto"; 119 + version = "0.9.FG13B"; 120 + in mkBitscope rec { 121 + inherit toolName version; 122 + # NOTE: this is meant as a demo by BitScope 123 + # NOTE: clicking on logo produces error 124 + # TApplication.HandleException Executable not found: "http://bitscope.com/blog/DK/?p=DK15A" 125 + 126 + meta = { 127 + description = "Demonstrative prototype oscilloscope built using the BitScope Library"; 128 + homepage = "http://bitscope.com/blog/DK/?p=DK15A"; 129 + }; 130 + 131 + src = fetchurl { 132 + url = "http://bitscope.com/download/files/${toolName}_${version}_amd64.deb"; 133 + sha256 = "1ybjfbh3narn29ll4nci4b7rnxy0hj3wdfm4v8c6pjr8pfvv9spy"; 134 + }; 135 + }; 136 + 137 + server = let 138 + toolName = "bitscope-server"; 139 + version = "1.0.FK26A"; 140 + in mkBitscope { 141 + inherit toolName version; 142 + 143 + meta = { 144 + description = "Remote access server solution for any BitScope"; 145 + homepage = "http://bitscope.com/software/server/"; 146 + }; 147 + 148 + src = fetchurl { 149 + url = "http://bitscope.com/download/files/${toolName}_${version}_amd64.deb"; 150 + sha256 = "1079n7msq6ks0n4aasx40rd4q99w8j9hcsaci71nd2im2jvjpw9a"; 151 + }; 152 + }; 153 + }
+2
pkgs/top-level/all-packages.nix
··· 14165 14165 14166 14166 bitmeter = callPackage ../applications/audio/bitmeter { }; 14167 14167 14168 + bitscope = callPackage ../applications/science/electronics/bitscope/packages.nix { }; 14169 + 14168 14170 bitwig-studio = callPackage ../applications/audio/bitwig-studio { 14169 14171 inherit (gnome2) zenity; 14170 14172 };