You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

default.nix 2.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. { stdenv
  2. , fetchFromGitHub
  3. , qtbase
  4. , qtmultimedia
  5. , qscintilla
  6. , bison
  7. , flex
  8. , eigen
  9. , boost
  10. , libGLU_combined
  11. , glew
  12. , opencsg
  13. , cgal
  14. , mpfr
  15. , gmp
  16. , glib
  17. , pkgconfig
  18. , harfbuzz
  19. , gettext
  20. , freetype
  21. , fontconfig
  22. , double-conversion
  23. , lib3mf
  24. , libzip
  25. , mkDerivation
  26. , qtmacextras
  27. , qmake
  28. }:
  29. mkDerivation rec {
  30. pname = "openscad";
  31. version = "2019.05";
  32. src = fetchFromGitHub {
  33. owner = "openscad";
  34. repo = "openscad";
  35. rev = "${pname}-${version}";
  36. sha256 = "1qz384jqgk75zxk7sqd22ma9pyd94kh4h6a207ldx7p9rny6vc5l";
  37. };
  38. nativeBuildInputs = [ bison flex pkgconfig gettext qmake ];
  39. buildInputs = [
  40. eigen boost glew opencsg cgal mpfr gmp glib
  41. harfbuzz lib3mf libzip double-conversion freetype fontconfig
  42. qtbase qtmultimedia qscintilla
  43. ] ++ stdenv.lib.optional stdenv.isLinux libGLU_combined
  44. ++ stdenv.lib.optional stdenv.isDarwin qtmacextras
  45. ;
  46. qmakeFlags = [ "VERSION=${version}" ];
  47. # src/lexer.l:36:10: fatal error: parser.hxx: No such file or directory
  48. enableParallelBuilding = false; # true by default due to qmake
  49. postInstall = stdenv.lib.optionalString stdenv.isDarwin ''
  50. mkdir $out/Applications
  51. mv $out/bin/*.app $out/Applications
  52. rmdir $out/bin || true
  53. mv --target-directory=$out/Applications/OpenSCAD.app/Contents/Resources \
  54. $out/share/openscad/{examples,color-schemes,locale,libraries,fonts}
  55. rmdir $out/share/openscad
  56. '';
  57. meta = {
  58. description = "3D parametric model compiler";
  59. longDescription = ''
  60. OpenSCAD is a software for creating solid 3D CAD objects. It is free
  61. software and available for Linux/UNIX, MS Windows and macOS.
  62. Unlike most free software for creating 3D models (such as the famous
  63. application Blender) it does not focus on the artistic aspects of 3D
  64. modelling but instead on the CAD aspects. Thus it might be the
  65. application you are looking for when you are planning to create 3D models of
  66. machine parts but pretty sure is not what you are looking for when you are more
  67. interested in creating computer-animated movies.
  68. '';
  69. homepage = http://openscad.org/;
  70. license = stdenv.lib.licenses.gpl2;
  71. platforms = stdenv.lib.platforms.unix;
  72. maintainers = with stdenv.lib.maintainers;
  73. [ bjornfor raskin the-kenny gebner ];
  74. };
  75. }