aboutsummaryrefslogtreecommitdiff
path: root/print/hplip3/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'print/hplip3/Makefile')
-rw-r--r--print/hplip3/Makefile152
1 files changed, 74 insertions, 78 deletions
diff --git a/print/hplip3/Makefile b/print/hplip3/Makefile
index a8629e452bc8..d7d9025476c8 100644
--- a/print/hplip3/Makefile
+++ b/print/hplip3/Makefile
@@ -6,129 +6,125 @@
#
PORTNAME= hplip
-PORTVERSION= 2.8.2
-PORTREVISION= 5
+PORTVERSION= 3.9.6b
CATEGORIES= print
-MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
-MASTER_SITE_SUBDIR= hplip
+MASTER_SITES= SF
-MAINTAINER= amistry@am-productions.biz
+MAINTAINER= chris@officialunix.com
COMMENT= Drivers and utilities for HP Printers and All-in-One devices
+LATEST_LINK= ${PORTNAME}3
+
LIB_DEPENDS= jpeg.10:${PORTSDIR}/graphics/jpeg \
sane.1:${PORTSDIR}/graphics/sane-backends \
cups.2:${PORTSDIR}/print/cups-base \
+ dbus-1.3:${PORTSDIR}/devel/dbus \
netsnmp.16:${PORTSDIR}/net-mgmt/net-snmp
-
+BUILD_DEPENDS= ppdc:${PORTSDIR}/print/cupsddk
RUN_DEPENDS= ${PYTHON_SITELIBDIR}/reportlab/__init__.py:${PORTSDIR}/print/py-reportlab2 \
+ espgs:${PORTSDIR}/print/cups-pstoraster \
foomatic-rip:${PORTSDIR}/print/foomatic-filters
-CONFLICTS= hpijs-*
+CONFLICTS= hpijs-[0-9]* hplip-[0-9]*
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --disable-dependency-tracking \
--disable-pp-build \
--enable-foomatic-ppd-install \
+ --enable-foomatic-rip-hplip-install \
+ --enable-hpijs-install \
--with-icondir=${LOCALBASE}/share/applications \
--with-cupsbackenddir=${LOCALBASE}/libexec/cups/backend \
--with-cupsfilterdir=${LOCALBASE}/libexec/cups/filter \
- --with-drvdir=${LOCALBASE}/libexec/cups/driver
+ --with-drvdir=${LOCALBASE}/libexec/cups/driver \
+ --with-hppddir=${LOCALBASE}/share/ppd/HP
USE_LDCONFIG= yes
USE_GHOSTSCRIPT_RUN= yes
-USE_PYTHON= yes
-USE_RC_SUBR= hpssd.sh
+USE_PYTHON= 25+
+USE_RC_SUBR= hpssd
MAKE_JOBS_SAFE= yes
+SUB_FILES= pkg-message
-CONFIGURE_ENV= CPPFLAGS="${CPPFLAGS} -I${LOCALBASE}/include" \
- LDFLAGS="${LDFLAGS} -L${LOCALBASE}/lib"
-
-MAKE_ENV= CPPFLAGS="${CPPFLAGS} -I${LOCALBASE}/include" \
- LDFLAGS="${LDFLAGS} -L${LOCALBASE}/lib"
+CPPFLAGS+= -I${LOCALBASE}/include
+LDFLAGS+= -L${LOCALBASE}/lib ${PTHREAD_LIBS}
-PKGDEINSTALL= ${PKGINSTALL}
+CONFIGURE_ENV= CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}"
-OPTIONS= GUI "build with Python QT" on
+OPTIONS= GUI "build with Python QT" on \
+ DBUS "dbus support" on \
+ XSANE "build xsane scanner app" on
PLIST_SUB+= PORTVERSION=${PORTVERSION} IJSVER=2.7.4
-.include <bsd.port.pre.mk>
+.include <bsd.port.options.mk>
.if ${OSVERSION} < 800069
LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb
.endif
-.if !defined(WITHOUT_GUI) || exists(${LOCALBASE}/bin/pylupdate)
-RUN_DEPENDS+= pylupdate:${PORTSDIR}/x11-toolkits/py-qt
-CONFIGURE_ARGS+= --enable-gui-build
+.if !defined(WITHOUT_GUI)
+USE_QT_VER= 4
+QT_COMPONENTS= gui
+CONFIGURE_ARGS+=--enable-qt4
+RUN_DEPENDS+= ${PYTHON_SITELIBDIR}/PyQt4/QtGui.so:${PORTSDIR}/x11-toolkits/py-qt4-gui
+LIB_DEPENDS+= pyglib-2.0:${PORTSDIR}/devel/py-gobject
.endif
-post-extract:
- @${RM} -r ${WRKSRC}/data/images/CVS
+.if !defined(WITHOUT_DBUS)
+RUN_DEPENDS+= ${PYTHON_SITELIBDIR}/dbus/_dbus.py:${PORTSDIR}/devel/py-dbus \
+ ${PYTHON_SITELIBDIR}/dbus/mainloop/qt.so:${PORTSDIR}/devel/py-qt4-dbus
+.endif
+
+.if !defined(WITHOUT_XSANE)
+RUN_DEPENDS+= xsane:${PORTSDIR}/graphics/xsane
+.endif
+
+.if defined(NOPORTDOCS)
+CONFIGURE_ARGS+= --enable-doc-build=no
+.endif
post-patch:
@${REINPLACE_CMD} -e 's|/etc/hp|${LOCALBASE}/etc/hp|g ; \
- s|/etc/sane.d|${LOCALBASE}/etc/sane.d|g' \
- ${WRKSRC}/Makefile.am \
- ${WRKSRC}/Makefile.in \
- ${WRKSRC}/check.py \
- ${WRKSRC}/hpssd.py \
- ${WRKSRC}/base/g.py \
- ${WRKSRC}/doc/release_notes.html \
- ${WRKSRC}/doc/tech_docs/man_pages/hpssd.html \
- ${WRKSRC}/fax/backend/hpfax.py \
+ s|/etc/sane.d|${LOCALBASE}/etc/sane.d|g' \
+ ${WRKSRC}/Makefile.am ${WRKSRC}/Makefile.in \
+ ${WRKSRC}/check.py ${WRKSRC}/hpssd.py \
+ ${WRKSRC}/base/g.py ${WRKSRC}/fax/backend/hpfax.py \
${WRKSRC}/installer/distros.dat \
${WRKSRC}/installer/core_install.py \
- ${WRKSRC}/prnt/hpijs/ljzjs.cpp
-
- @${REINPLACE_CMD} 's|-lpthread|${PTHREAD_LIBS}|g' \
- ${WRKSRC}/configure \
- ${WRKSRC}/configure.in
-.if defined(NOPORTDOCS)
- @${REINPLACE_CMD} -e 's|install-dist_www7DATA install-docDATA|install-dist_www7DATA|g ; \
- s|install-dist_unrelDATA install-dist_www0DATA|install-dist_unrelDATA|g ; \
- s|install-dist_www1DATA install-dist_www21DATA||g ; \
- s|install-dist_www22DATA install-dist_www23DATA||g ; \
- s|install-dist_www241DATA install-dist_www242DATA||g ; \
- s|install-dist_www243DATA install-dist_www24DATA||g ; \
- s|install-dist_www251DATA install-dist_www252DATA||g ; \
- s|install-dist_www261DATA install-dist_www2DATA||g ; \
- s|install-dist_www3DATA install-dist_www4DATA||g ; \
- s|install-dist_www5DATA install-dist_www61DATA||g ; \
- s|install-dist_www6DATA install-dist_www7DATA||g' \
- ${WRKSRC}/Makefile.in
-.endif
+ ${WRKSRC}/prnt/hpijs/ljzjs.cpp \
+ ${WRKSRC}/prnt/hpijs/globals.cpp \
+ ${WRKSRC}/ui/devmgr4.py \
+ ${WRKSRC}/ui4/devmgr5.py
+ @${REINPLACE_CMD} -e 's|/etc/dbus-1/system.d|${LOCALBASE}/etc/dbus-1/system.d|g ; \
+ s|/usr/share/dbus-1/system-services|${LOCALBASE}/share/dbus-1/system-services|g' \
+ ${WRKSRC}/Makefile.am ${WRKSRC}/Makefile.in
+ @${REINPLACE_CMD} 's|/etc/xdg|${PREFIX}&|g; s|-lpthread|${PTHREAD_LIBS}|g' \
+ ${WRKSRC}/configure ${WRKSRC}/configure.in
@${REINPLACE_CMD} -e 's|install-dist_prntSCRIPTS install-dist_rulesDATA|install-dist_prntSCRIPTS|g ; \
- s|install-hpPROGRAMS install-hplip_confDATA|install-hpPROGRAMS|g' \
+ s|install-hpPROGRAMS install-hplip_confDATA|install-hpPROGRAMS|g' \
${WRKSRC}/Makefile.in
-# @${REINPLACE_CMD} -e 's|install-dist_www7DATA install-docDATA|install-dist_www7DATA|g' \
-# ${WRKSRC}/Makefile.in
- @${REINPLACE_CMD} -e 's|-ldld||g ; \
- s|-ldl||g ; \
- s|-dld||g' \
- ${WRKSRC}/configure \
- ${WRKSRC}/configure.in \
- ${WRKSRC}/Makefile.in \
- ${WRKSRC}/Makefile.am \
+ @${REINPLACE_CMD} -e 's|-ldld||g; s|-ldl||g; s|-dld||g' \
+ ${WRKSRC}/configure ${WRKSRC}/configure.in \
+ ${WRKSRC}/Makefile.in ${WRKSRC}/Makefile.am \
${WRKSRC}/aclocal.m4
-
@${REINPLACE_CMD} -e 's|/usr/bin/env python|${LOCALBASE}/bin/python|g' \
${WRKSRC}/hpssd.py
-
-pre-su-install:
- @${MKDIR} ${PREFIX}/share/applications
-
-post-install:
-.if !defined(PACKAGE_BUILDING)
- @${SETENV} PKG_PREFIX=${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
-.endif
- @${LN} -sf ${PREFIX}/share/hplip/hpssd.py ${PREFIX}/sbin/hpssd
- @${MKDIR} ${PREFIX}/etc/hp
- # Auto-generate sample configuration file
- @${INSTALL_DATA} ${WRKSRC}/hplip.conf ${PREFIX}/etc/hp/hplip.conf.sample
-.if !exists(${PREFIX}/etc/hp/hplip.conf)
- @${INSTALL_DATA} ${WRKSRC}/hplip.conf ${PREFIX}/etc/hp/hplip.conf
+.if defined(NOPORTDOCS)
+ @${REINPLACE_CMD} -e '/install-.*install-docDATA.*install-/ s|install-docDATA||' \
+ ${WRKSRC}/Makefile.in
.endif
- @${SED} -e "s|%%PREFIX%%|${PREFIX}|" ${PKGMESSAGE}
-.include <bsd.port.post.mk>
+post-install:
+ ${LN} -sf ${PREFIX}/share/hplip/hpssd.py ${PREFIX}/sbin/hpssd
+ ${INSTALL_DATA} ${WRKSRC}/hplip-systray.desktop ${PREFIX}/etc/xdg/autostart/hplip-systray.desktop
+ ${MKDIR} ${PREFIX}/etc/hp
+ ${INSTALL_DATA} ${WRKSRC}/hplip.conf ${PREFIX}/etc/hp/hplip.conf.sample
+ if [ ! -f ${PREFIX}/etc/hp/hplip.conf ]; then \
+ ${INSTALL_DATA} ${PREFIX}/etc/hp/hplip.conf.sample \
+ ${PREFIX}/etc/hp/hplip.conf; \
+ fi
+ ${ECHO_CMD} hpaio >> ${PREFIX}/etc/sane.d/dll.conf
+ @${CAT} ${PKGMESSAGE}
+
+.include <bsd.port.mk>