summaryrefslogtreecommitdiff
path: root/print
diff options
context:
space:
mode:
authorAlan Eldridge <alane@FreeBSD.org>2003-01-25 16:20:46 +0000
committerAlan Eldridge <alane@FreeBSD.org>2003-01-25 16:20:46 +0000
commit31b3988864139796533991ef6eea4e2dea1c1b4f (patch)
treefaf8d952b2cfaf4189cca3870e7287a566ea357e /print
parentAdd gauche-gl 0.2.1, openGL binding for Gauche. (diff)
Fixed "Print Test Page" bug with help from Mike at Easy SW. Portrevision
bumped to 4. Changed package message back to package-users-only message. PR: 47423
Notes
Notes: svn path=/head/; revision=73986
Diffstat (limited to 'print')
-rw-r--r--print/cups-base/Makefile2
-rw-r--r--print/cups-base/files/patch-cgi-bin-ipp-var.c-1.1.1967
-rw-r--r--print/cups-base/pkg-message14
-rw-r--r--print/cups/Makefile.common2
4 files changed, 68 insertions, 17 deletions
diff --git a/print/cups-base/Makefile b/print/cups-base/Makefile
index 7cb1ed4b5e88..390a205885aa 100644
--- a/print/cups-base/Makefile
+++ b/print/cups-base/Makefile
@@ -32,8 +32,6 @@ post-install:
cd ${CUPS_ETCDIR};\
if test ! -f ${f}.N; then cp -p ${f} ${f}.N; else true; fi
.endfor # classes.conf client.conf cupsd.conf printers.conf
- ${ECHO_CMD}
- ${CAT} ${PKGMESSAGE}; sleep 2
.include "${.CURDIR}/../../print/cups/Makefile.common"
.include <bsd.port.pre.mk>
diff --git a/print/cups-base/files/patch-cgi-bin-ipp-var.c-1.1.19 b/print/cups-base/files/patch-cgi-bin-ipp-var.c-1.1.19
new file mode 100644
index 000000000000..2d2b7b520e9e
--- /dev/null
+++ b/print/cups-base/files/patch-cgi-bin-ipp-var.c-1.1.19
@@ -0,0 +1,67 @@
+--- cgi-bin/ipp-var.c.orig Sat Jan 25 10:07:30 2003
++++ cgi-bin/ipp-var.c Sat Jan 25 10:08:15 2003
+@@ -1,5 +1,5 @@
+ /*
+- * "$Id: ipp-var.c,v 1.30 2002/12/17 18:56:36 swdev Exp $"
++ * "$Id: ipp-var.c,v 1.31 2003/01/15 20:30:28 mike Exp $"
+ *
+ * IPP variable routines for the Common UNIX Printing System (CUPS).
+ *
+@@ -103,14 +103,35 @@
+ int port; /* URI data */
+ int ishttps; /* Using encryption? */
+ const char *server; /* Name of server */
++ char servername[1024];/* Locale server name */
+ struct tm *date; /* Date information */
+
+
++ /*
++ * Set common CGI template variables...
++ */
++
+ ippSetServerVersion();
+
+- server = getenv("SERVER_NAME");
++ /*
++ * Get the server name associated with the client interface as well as
++ * the locally configured hostname. We'll check *both* of these to
++ * see if the printer URL is local...
++ */
++
++ server = getenv("SERVER_NAME");
++ gethostname(servername, sizeof(servername));
++
++ /*
++ * Flag whether we are using SSL on this connection...
++ */
++
+ ishttps = getenv("HTTPS") != NULL;
+
++ /*
++ * Loop through the attributes and set them for the template...
++ */
++
+ for (attr = response->attrs;
+ attr && attr->group_tag == IPP_TAG_OPERATION;
+ attr = attr->next);
+@@ -239,10 +260,11 @@
+ strcmp(method, "http") == 0)
+ {
+ /*
+- * Map localhost access to localhost and local port...
++ * Map local access to a local URI...
+ */
+
+- if (strcasecmp(hostname, server) == 0)
++ if (strcasecmp(hostname, server) == 0 ||
++ strcasecmp(hostname, servername) == 0)
+ {
+ /*
+ * Make URI relative to the current server...
+@@ -300,5 +322,5 @@
+
+
+ /*
+- * End of "$Id: ipp-var.c,v 1.30 2002/12/17 18:56:36 swdev Exp $".
++ * End of "$Id: ipp-var.c,v 1.31 2003/01/15 20:30:28 mike Exp $".
+ */
diff --git a/print/cups-base/pkg-message b/print/cups-base/pkg-message
index 266682cd840e..d740e8680c3c 100644
--- a/print/cups-base/pkg-message
+++ b/print/cups-base/pkg-message
@@ -11,20 +11,6 @@ Once the package is installed, please do the following (as root):
mkdir -p cups/tmp
chown -R root:daemon cups
-NOTE FOR *ALL* USERS OF CUPS:
-=============================
-There's another problem: in the installed configuration, the "Print Test
-Page" function in the web interface does not work. This is due to a bug in
-the URL constructed for it.
-
-To work around this bug, edit the file /usr/local/etc/cups/cupsd.conf
-(as root). Find the line that says "Allow From 127.0.0.1". After that
-line, insert a line that reads "Allow From <myhost>.<mydomain>", filling
-in your own hostname and domainname where I have written <myhost> and
-<mydomain>. Restart cupsd. The "Print Test Page" function will now work.
-
-I'll try to have a code patch to fix the errant URL soon.
-
Thanks.
--
diff --git a/print/cups/Makefile.common b/print/cups/Makefile.common
index a197317dd9f1..888f0c69ccb0 100644
--- a/print/cups/Makefile.common
+++ b/print/cups/Makefile.common
@@ -12,7 +12,7 @@ CUPS_MASTER_SITES=\
CUPS_VERSION= 1.1.18
CUPS_REVISION= 0
CUPS_PORTVER= ${CUPS_VERSION}.${CUPS_REVISION}
-CUPS_PORTREV= 3
+CUPS_PORTREV= 4
CUPS_PORTEPOCH= 0
CUPS_FILESDIR= ${.CURDIR}/../../print/cups/files
CUPS_ETCDIR= ${PREFIX}/etc/cups