Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 32 lines 924 B view raw
1{ 2 buildOctavePackage, 3 lib, 4 fetchFromBitbucket, 5}: 6 7buildOctavePackage rec { 8 pname = "octclip"; 9 version = "2.0.3"; 10 11 src = fetchFromBitbucket { 12 owner = "jgpallero"; 13 repo = pname; 14 rev = "OctCLIP-${version}"; 15 sha256 = "sha256-gG2b8Ix6bzO6O7GRACE81JCVxfXW/+ZdfoniigAEq3g="; 16 }; 17 18 # The only compilation problem is that no formatting specifier was provided 19 # for the error function. Because errorText is a string, I provide such a 20 # formatting specifier. 21 patchPhase = '' 22 sed -i s/"error(errorText)"/"error(\"%s\", errorText)"/g src/*.cc 23 ''; 24 25 meta = { 26 name = "GNU Octave Clipping Polygons Tool"; 27 homepage = "https://gnu-octave.github.io/packages/octclip/"; 28 license = with lib.licenses; [ gpl3Plus ]; # modified BSD? 29 maintainers = with lib.maintainers; [ KarlJoad ]; 30 description = "Perform boolean operations with polygons using the Greiner-Hormann algorithm"; 31 }; 32}