Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 mkDerivation, 3 lib, 4 fetchFromGitHub, 5 makeWrapper, 6 cmake, 7 qtbase, 8 qttools, 9 fftw, 10 libusb1, 11 libglvnd, 12}: 13 14mkDerivation rec { 15 pname = "openhantek6022"; 16 version = "3.4.0"; 17 18 src = fetchFromGitHub { 19 owner = "OpenHantek"; 20 repo = "OpenHantek6022"; 21 rev = version; 22 sha256 = "sha256-FT+DyfD5WHBblRXWXFnyB2xwoIgoh84oB+QN32wx78c="; 23 }; 24 25 nativeBuildInputs = [ 26 cmake 27 makeWrapper 28 ]; 29 buildInputs = [ 30 fftw 31 libusb1 32 libglvnd 33 qtbase 34 qttools 35 ]; 36 37 postPatch = '' 38 # Fix up install paths & checks 39 sed -i 's#if(EXISTS ".*")#if(1)#g' CMakeLists.txt 40 sed -i 's#/lib/udev#lib/udev#g' CMakeLists.txt 41 sed -i 's#/usr/share#share#g' CMakeLists.txt 42 ''; 43 44 doInstallCheck = true; 45 46 meta = with lib; { 47 description = "Free software for Hantek and compatible (Voltcraft/Darkwire/Protek/Acetech) USB digital signal oscilloscopes"; 48 mainProgram = "OpenHantek"; 49 homepage = "https://github.com/OpenHantek/OpenHantek6022"; 50 license = licenses.gpl3; 51 maintainers = with maintainers; [ baracoder ]; 52 platforms = qtbase.meta.platforms; 53 }; 54}