Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 20 Nov 1997 19:20:02 -0800 (PST)
From:      Matthew Hunt <mph@pobox.com>
To:        freebsd-ports
Subject:   Re: ports/5075: Update: print/c2ps to 4.0
Message-ID:  <199711210320.TAA06188@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR ports/5075; it has been noted by GNATS.

From: Matthew Hunt <mph@pobox.com>
To: Bill Fenner <fenner@parc.xerox.com>
Cc: freebsd-gnats-submit@hub.freebsd.org
Subject: Re: ports/5075: Update: print/c2ps to 4.0
Date: Thu, 20 Nov 1997 22:12:42 -0500

 On Thu, Nov 20, 1997 at 02:58:39PM -0800, Bill Fenner wrote:
 
 > Check out how a2ps handles paper size -- perhaps you could do something
 > like that (especially with putting it in the package name).
 
 Roger that.  Hacked on it for a while, and learned more about make
 than I had planned. :-) This is quite different from anything I've
 done, so let me know if I screwed it up.
 
 For convenience, it uses PAPERSIZE just like a2ps.  It seems to
 correctly make packages c2ps-letter-4.0.tgz and c2ps-a4-4.0.tgz.
 
 
 diff -urN /usr/ports/print/c2ps/Makefile c2ps/Makefile
 --- /usr/ports/print/c2ps/Makefile	Mon Mar 24 14:36:55 1997
 +++ c2ps/Makefile	Thu Nov 20 22:06:32 1997
 @@ -1,20 +1,54 @@
  # New ports collection makefile for:   c2ps
 -# Version required:    3.0
 +# Version required:    4.0
  # Date created:        19 March 1997
  # Whom:                Matthew Hunt <mph@pobox.com>
  #
  # $Id: Makefile,v 1.1.1.1 1997/03/24 19:36:55 obrien Exp $
  #
  
 -DISTNAME=	c2ps-3.0
 +DISTNAME=	c2ps-4.0
 +PKGNAME=	c2ps-${PKGTHINGY}-4.0
  CATEGORIES=	print
  MASTER_SITES=	http://www.geocities.com/SiliconValley/Park/2055/
 -DISTFILES=	c2ps-30.tgz
 -# Also: http://www.cs.technion.ac.il/~c0928189/c2ps/c2ps-3.0.tar.Z
 +DISTFILES=	c2ps-40.tgz
 +# Also: http://www.cs.technion.ac.il/~c0928189/c2ps/c2ps-4.0.tar.Z
 +
 +# The Geocities server is broken
 +FETCH_BEFORE_ARGS=	-t
  
  MAINTAINER=	mph@pobox.com
  
  MAN1=		c2ps.1
  
 +PAPERSIZE?=
 +
 +MAKE_ENV=	DEFAULT_PAPER_TYPE=${DEFAULT_PAPER_TYPE}
 +
 +pre-configure:
 +.if empty(PAPERSIZE)
 +	@echo Paper size unspecified.  Set PAPERSIZE to A4 or LETTTER.
 +	@false
 +.elif $(PAPERSIZE)==LETTER || $(PAPERSIZE)==Letter || $(PAPERSIZE)==letter
 +	@echo PAPERSIZE: Letter
 +	echo LETTER > $(WRKDIR)/.media
 +	echo letter > $(WRKDIR)/.pkgthingy
 +.elif $(PAPERSIZE)==A4 || $(PAPERSIZE)==a4
 +	@echo PAPERSIZE: A4
 +	echo A4 > $(WRKDIR)/.media
 +	echo a4 > $(WRKDIR)/.pkgthingy
 +.else
 +	@echo You must set PAPERSIZE to A4 or LETTER.
 +	@false
 +.endif
 +
  .include <bsd.port.mk>
  
 +.if exists($(WRKDIR)/.media)
 +DEFAULT_PAPER_TYPE=
 +DEFAULT_PAPER_TYPE!=	cat $(WRKDIR)/.media
 +.endif
 +
 +.if exists($(WRKDIR)/.pkgthingy)
 +PKGTHINGY=
 +PKGTHINGY!=		cat $(WRKDIR)/.pkgthingy
 +.endif
 diff -urN /usr/ports/print/c2ps/files/md5 c2ps/files/md5
 --- /usr/ports/print/c2ps/files/md5	Thu Mar 27 02:08:24 1997
 +++ c2ps/files/md5	Mon Nov 17 21:27:14 1997
 @@ -1 +1 @@
 -MD5 (c2ps-30.tgz) = 27f07557444a02d56e88012e900a3bb8
 +MD5 (c2ps-40.tgz) = 195553258f2f18198f164ea8f66362dc
 diff -urN /usr/ports/print/c2ps/patches/patch-aa c2ps/patches/patch-aa
 --- /usr/ports/print/c2ps/patches/patch-aa	Mon Mar 24 14:36:56 1997
 +++ c2ps/patches/patch-aa	Thu Nov 20 22:06:54 1997
 @@ -1,7 +1,7 @@
 ---- Makefile.orig	Thu Jul 18 14:43:18 1996
 -+++ Makefile	Wed Mar 19 13:19:33 1997
 -@@ -1,10 +1,7 @@
 - # Makefile for c2ps ver3.0
 +--- Makefile.orig	Thu May 15 11:50:56 1997
 ++++ Makefile	Thu Nov 20 22:06:51 1997
 +@@ -2,10 +2,7 @@
 + # Last modified: Sat Apr 19 1997
   
   RM	= 	rm -f
  -CC	=	gcc
 @@ -11,3 +11,25 @@
   BIN	=	$(PREFIX)/bin
   MAN	=	$(PREFIX)/man/man1
   
 +@@ -20,8 +17,6 @@
 + FUNCTION_FONT	= \"Bookman-LightItalic\"
 + 
 + COMMENT_DIMMING_DEGREE	= 0.75
 +-DEFAULT_PAPER_TYPE	= A4
 +-# possible values are A4 and LETTER
 + 
 + 
 + #___You don't need to change anything below__________________
 +@@ -39,10 +34,10 @@
 + install:	bininstall maninstall
 + 
 + bininstall:	c2ps
 +-	install -m 755 c2ps $(BIN)
 ++	$(BSD_INSTALL_PROGRAM) c2ps $(BIN)
 + 
 + maninstall:	c2ps.1
 +-	install -m 644 c2ps.1 $(MAN)
 ++	$(BSD_INSTALL_MAN) c2ps.1 $(MAN)
 + 
 + compile:	c2ps.c
 + 	$(CC) $(PREP_OPTIONS) $(CCFLAGS) -o c2ps c2ps.c



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199711210320.TAA06188>