Makefile 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. # $OpenBSD: Makefile,v 1.33 2017/04/10 11:46:21 sthen Exp $
  2. COMMENT= 3D image rendering package
  3. DISTNAME= povray-3.6.1
  4. REVISION= 8
  5. CATEGORIES= graphics
  6. HOMEPAGE= http://www.povray.org/
  7. PERMIT_PACKAGE_CDROM= Perhaps we qualify for commercial distribution
  8. PERMIT_PACKAGE_FTP= Yes
  9. WANTLIB += ICE SM X11 Xpm c jpeg m ${LIBCXX} tiff z
  10. MASTER_SITES= \
  11. http://www.povray.org/ftp/pub/povray/Old-Versions/Official-3.62/Unix/
  12. EXTRACT_SUFX= .tar.bz2
  13. # We replace the included ancient copy of libpng with a later release
  14. # from the 1.2 branch.
  15. EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}
  16. PNG_V= 1.2.57
  17. MASTER_SITES0= ${MASTER_SITE_SOURCEFORGE:=libpng/}
  18. DISTFILES= ${EXTRACT_ONLY} libpng-${PNG_V}.tar.gz:0
  19. LIB_DEPENDS= graphics/jpeg \
  20. graphics/tiff
  21. CONFIGURE_STYLE= gnu
  22. CONFIGURE_ARGS+= --with-x \
  23. --enable-watch-cursor \
  24. --disable-optimiz \
  25. --x-includes="${X11BASE}/include" \
  26. --includedir=${LOCALBASE}
  27. # POV-Ray 3.6 is incompatible with libpng 1.5.
  28. CONFIGURE_ARGS+= ac_cv_search_png_get_libpng_ver=no
  29. CONFIGURE_ENV+= COMPILED_BY="OpenBSD Ports <ports@openbsd.org>" \
  30. CPPFLAGS="-I${LOCALBASE}/include -DPNG_NO_MMX_CODE" \
  31. CXXFLAGS="-I${LOCALBASE}/include" \
  32. LDFLAGS="-L${LOCALBASE}/lib -lm"
  33. MAKE_FLAGS+= povconfdir=${PREFIX}/share/examples/povray/ \
  34. povdocdir=${PREFIX}/share/doc/povray/ \
  35. povlibdir=${PREFIX}/share/povray/
  36. MODGNU_CONFIG_GUESS_DIRS=${WRKSRC}/config ${WRKSRC}/libraries/png
  37. NO_TEST= Yes
  38. # Replace the source files for the included libpng.
  39. post-extract:
  40. cd ${WRKDIST}/libraries; \
  41. tar -xzf ${FULLDISTDIR}/libpng-${PNG_V}.tar.gz \
  42. -s ',^libpng-${PNG_V},png,' 'libpng-${PNG_V}/png*.[ch]'
  43. pre-patch:
  44. cd ${WRKSRC} && find . -type f -name \*.orig | xargs rm
  45. post-configure:
  46. sed -i 's,%INSTALLDIR%,${PREFIX}/share/povray/,g' \
  47. ${WRKSRC}/povray.conf
  48. .for f in povray.1 scripts/allanim.sh scripts/allscene.sh scripts/portfolio.sh
  49. ${SUBST_CMD} ${WRKSRC}/$f
  50. .endfor
  51. .include <bsd.port.mk>