Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 86 lines 1.9 kB view raw
1{ 2 mkDerivation, 3 lib, 4 fetchgit, 5 qtbase, 6 qmake, 7 qtscript, 8 flex, 9 bison, 10 qtdeclarative, 11}: 12 13let 14 version = "5.1"; 15 16 src = fetchgit { 17 url = "https://github.com/kmkolasinski/AwesomeBump.git"; 18 rev = "Winx32v${version}"; 19 sha256 = "1c8b9jki0v8kzkvsvyv7q1w3s7j40br6ph15hh2xi0a1mpwckq56"; 20 fetchSubmodules = true; 21 }; 22 23 qtnproperty = mkDerivation { 24 name = "qtnproperty"; 25 inherit src; 26 sourceRoot = "${src.name}/Sources/utils/QtnProperty"; 27 patches = [ ./qtnproperty-parallel-building.patch ]; 28 buildInputs = [ 29 qtscript 30 qtbase 31 qtdeclarative 32 ]; 33 nativeBuildInputs = [ 34 qmake 35 flex 36 bison 37 ]; 38 postInstall = '' 39 install -D bin-linux/QtnPEG $out/bin/QtnPEG 40 ''; 41 }; 42in 43mkDerivation { 44 pname = "awesomebump"; 45 inherit version; 46 47 inherit src; 48 49 buildInputs = [ 50 qtbase 51 qtscript 52 qtdeclarative 53 ]; 54 55 nativeBuildInputs = [ qmake ]; 56 57 preBuild = '' 58 ln -sf ${qtnproperty}/bin/QtnPEG Sources/utils/QtnProperty/bin-linux/QtnPEG 59 ''; 60 61 dontWrapQtApps = true; 62 postInstall = '' 63 d=$out/libexec/AwesomeBump 64 65 mkdir -p $d 66 cp -vr workdir/`cat workdir/current`/bin/AwesomeBump $d/ 67 cp -prd Bin/Configs Bin/Core $d/ 68 69 # AwesomeBump expects to find Core and Configs in its current directory. 70 makeQtWrapper $d/AwesomeBump $out/bin/AwesomeBump \ 71 --chdir "$d" 72 ''; 73 74 # $ cd Sources; qmake; make ../workdir/linux-g++-dgb-gl4/obj/glwidget.o 75 # fatal error: properties/ImageProperties.peg.h: No such file or directory 76 enableParallelBuilding = false; 77 78 meta = { 79 homepage = "https://github.com/kmkolasinski/AwesomeBump"; 80 description = "Program to generate normal, height, specular or ambient occlusion textures from a single image"; 81 license = lib.licenses.gpl3Plus; 82 maintainers = [ ]; 83 platforms = lib.platforms.linux; 84 mainProgram = "AwesomeBump"; 85 }; 86}