summaryrefslogtreecommitdiff
path: root/print
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2003-11-22 00:18:52 +0000
committerPav Lucistnik <pav@FreeBSD.org>2003-11-22 00:18:52 +0000
commita4d9d6e1c4b1d7887d42d86f5ad345a4c90e1330 (patch)
tree098283a6da389d70a3210a3170a96d9eb584bea9 /print
parent- Let package create necessary config directories (diff)
- Move lpr binaries in base away, so cups binaries in /usr/local/bin
get picked. - Move them back on deinstall. - Give maintainershop to submitter. PR: ports/57938 Submitted by: Sergey Akifyev <asa@gascom.ru> Reviewed by: marcus Approved by: adamw (mentor)
Notes
Notes: svn path=/head/; revision=94683
Diffstat (limited to 'print')
-rw-r--r--print/cups-lpr/Makefile4
-rw-r--r--print/cups-lpr/pkg-deinstall17
-rw-r--r--print/cups-lpr/pkg-install17
-rw-r--r--print/cups-lpr/pkg-message10
4 files changed, 47 insertions, 1 deletions
diff --git a/print/cups-lpr/Makefile b/print/cups-lpr/Makefile
index 5853b3a17126..b453e2ca8cef 100644
--- a/print/cups-lpr/Makefile
+++ b/print/cups-lpr/Makefile
@@ -14,7 +14,7 @@ PORTEPOCH= ${CUPS_PORTEPOCH}
CATEGORIES= print
MASTER_SITES= ${CUPS_MASTER_SITES}
-MAINTAINER= ports@FreeBSD.org
+MAINTAINER= asa@gascom.ru
COMMENT= The CUPS BSD and system V compatibility binaries (lp* commands)
USE_REINPLACE= yes
@@ -30,6 +30,8 @@ post-patch:
post-install:
${FIND} ${PREFIX}/man/cat* -type l -name '*.0' -delete
${FIND} ${PREFIX}/man/fr/cat* -type l -name '*.0' -delete
+ ${SH} ${PKGINSTALL} placeholder POST-INSTALL
+ @${CAT} ${PKGMESSAGE}
.include "${.CURDIR}/../../print/cups/Makefile.common"
.include <bsd.port.pre.mk>
diff --git a/print/cups-lpr/pkg-deinstall b/print/cups-lpr/pkg-deinstall
new file mode 100644
index 000000000000..b5fde98a584c
--- /dev/null
+++ b/print/cups-lpr/pkg-deinstall
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+REPLACES_BINARIES="/bin/lpr
+ /bin/lp
+ /bin/lpq
+ /bin/lprm
+ /bin/lpstat
+ /sbin/lpc"
+
+case $2 in
+POST-DEINSTALL)
+ for FILE in ${REPLACES_BINARIES}; do
+ [ -e "${FILE}.bak" ] && mv "${FILE}.bak" "${FILE}"
+ done
+;;
+esac
+exit 0
diff --git a/print/cups-lpr/pkg-install b/print/cups-lpr/pkg-install
new file mode 100644
index 000000000000..765d935458bc
--- /dev/null
+++ b/print/cups-lpr/pkg-install
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+REPLACES_BINARIES="/bin/lpr
+ /bin/lp
+ /bin/lpq
+ /bin/lprm
+ /bin/lpstat
+ /sbin/lpc"
+
+case $2 in
+POST-INSTALL)
+ for FILE in ${REPLACES_BINARIES}; do
+ [ -e "${FILE}" ] && mv "${FILE}" "${FILE}.bak"
+ done
+;;
+esac
+exit 0
diff --git a/print/cups-lpr/pkg-message b/print/cups-lpr/pkg-message
new file mode 100644
index 000000000000..9c8a815160a3
--- /dev/null
+++ b/print/cups-lpr/pkg-message
@@ -0,0 +1,10 @@
+**********************************************************************
+**********************************************************************
+PLEASE NOTE:
+============
+
+This port will move lpr binaries located in /usr/bin and
+/usr/sbin to unshade cups-lpr binaries in PATH variable
+
+**********************************************************************
+**********************************************************************