Makefile 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. # $OpenBSD: Makefile,v 1.112 2017/05/31 08:08:17 espie Exp $
  2. BROKEN-alpha= ICE in cupsfilters/image-jpeg.c:316
  3. BROKEN-hppa= ICE on filter/pdftopdf/qpdf_pdftopdf.cc:147
  4. COMMENT= OpenPrinting CUPS filters
  5. DISTNAME= cups-filters-1.14.0
  6. CATEGORIES= print
  7. REVISION= 1
  8. SHARED_LIBS += cupsfilters 1.1 # 1.0
  9. SHARED_LIBS += fontembed 0.0 # 1.0
  10. HOMEPAGE= http://www.linuxfoundation.org/collaborate/workgroups/openprinting
  11. MAINTAINER= Antoine Jacoutot <ajacoutot@openbsd.org>
  12. # GPLv3 - LGPLv2 - GPLv2+ - MIT
  13. PERMIT_PACKAGE_CDROM= Yes
  14. WANTLIB += avahi-client avahi-common avahi-glib c cups cupsimage
  15. WANTLIB += dbus-1 expat ffi fontconfig freetype gio-2.0 glib-2.0
  16. WANTLIB += gmodule-2.0 gmp gnutls gobject-2.0 hogweed iconv idn2
  17. WANTLIB += ijs intl jpeg lcms2 m nettle openjp2 p11-kit pcre
  18. WANTLIB += png poppler pthread pthread-stubs qpdf tasn1 tiff
  19. WANTLIB += unistring z
  20. MASTER_SITES= http://www.openprinting.org/download/cups-filters/
  21. # cc1plus: error: unrecognized command line option "-std=c++0x"
  22. COMPILER = gcc
  23. .if ${MACHINE_ARCH} == "hppa"
  24. CFLAGS += -O0
  25. .endif
  26. # gs cups driver, pdftocairo, mutool
  27. BUILD_DEPENDS= print/ghostscript/gnu \
  28. print/poppler,-utils \
  29. textproc/mupdf
  30. RUN_DEPENDS= print/ghostscript/gnu \
  31. print/poppler,-utils \
  32. textproc/mupdf
  33. LIB_DEPENDS= print/cups,-libs \
  34. print/ijs \
  35. print/poppler \
  36. print/qpdf
  37. # make it easier for users: bring in foomatic-db and allow the
  38. # regeneration of PPD files from share/foomatic/db/source/*/*.xml
  39. RUN_DEPENDS += print/foomatic-db-engine
  40. # don't enforce dependency on colord; it'll be used only if found
  41. #RUN_DEPENDS += graphics/colord
  42. FAKE_FLAGS= pkgfontconfigdir=${PREFIX}/share/examples/cups-filters \
  43. pkgcupsserverrootdir=${PREFIX}/share/examples/cups-filters/cups
  44. CONFIGURE_STYLE=gnu
  45. CONFIGURE_ENV= CPPFLAGS="-I${X11BASE}/include -I${LOCALBASE}/include" \
  46. LDFLAGS="-L${X11BASE}/lib -L${LOCALBASE}/lib"
  47. CONFIGURE_ARGS= --with-gs-path=${LOCALBASE}/bin/gs \
  48. --with-test-font-path=${X11BASE}/lib/X11/fonts/TTF/DejaVuSans.ttf \
  49. --with-shell=/bin/ksh \
  50. --without-php \
  51. --disable-braille
  52. # http://bzr.linuxfoundation.org/loggerhead/openprinting/cups-filters/revision/7554
  53. CONFIGURE_ENV +=ac_cv_prog_CUPS_PDFTOPS=${LOCALBASE}/bin/pdftops
  54. FLAVORS= ldap
  55. FLAVOR?=
  56. .if ${FLAVOR:Mldap}
  57. WANTLIB += crypto lber-2.4 ldap-2.4 sasl2 ssl
  58. LIB_DEPENDS += databases/openldap
  59. .else
  60. CONFIGURE_ARGS += --disable-ldap
  61. .endif
  62. pre-configure:
  63. sed -i -e 's,/usr/share/cups,${LOCALBASE}/share/cups,g;' \
  64. -e 's,/usr/bin,${LOCALBASE}/bin,g' \
  65. ${WRKSRC}/filter/{gstoraster.c,gstopxl}
  66. sed -i 's,/etc/cups,${SYSCONFDIR}/cups,g' \
  67. ${WRKSRC}/filter/foomatic-rip/spooler.c
  68. sed -i 's,/usr/local,${LOCALBASE},g' \
  69. ${WRKSRC}/filter/foomatic-rip/foomaticrip.c
  70. post-install:
  71. rm -rf ${WRKINST}/rc?.d
  72. # handle old filters looking for these
  73. cd ${PREFIX}/libexec/cups/filter && ln -s gstopxl pstopxl
  74. cd ${PREFIX}/libexec/cups/filter && ln -s gstoraster pstoraster
  75. .include <bsd.port.mk>