tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: cups support for print/a2ps (patch incl.)



Hi,

On Wed, 25 Jul 2012 01:58:15 +0900, iMil <imil%home.imil.net@localhost> wrote:

Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/print/a2ps/Makefile,v
retrieving revision 1.71
diff -u -r1.71 Makefile
--- Makefile    22 Apr 2011 13:42:07 -0000      1.71
+++ Makefile    24 Jul 2012 16:48:16 -0000
@@ -30,7 +30,19 @@

  USE_PKGLOCALEDIR=     YES
  GNU_CONFIGURE=                YES
+
+PKG_OPTIONS_VAR=       PKG_OPTIONS.a2ps
+PKG_SUPPORTED_OPTIONS= cups
+PKG_SUGGESTED_OPTIONS= cups
+.include "../../mk/bsd.options.mk"
+
+.if !empty(PKG_OPTIONS:Mcups)
+CONFIGURE_ENV+=                LPR=${PREFIX}/bin/lpr
+.include "../../print/cups/buildlink3.mk"
+.else
  CONFIGURE_ENV+=               LPR=lpr
+.endif
+
  CONFIGURE_ARGS+=      --with-medium=${PAPERSIZE:Q}
  CONFIGURE_ARGS+=      --sysconfdir=${PKG_SYSCONFDIR:Q}
  CONFIGURE_ARGS+=      --disable-dependency-tracking

Just runtime dependency on lpr command, so no need to buildlink.
You should use DEPENDS and find its prefix with mk/find-prefix.mk.

But I feel it is runtime configurable matter:
1. put ${LOCALBASE}/bin on $PATH before /usr/bin
or
2. edit a2ps.cfg so that lpr point to wanted one.

--
OBATA Akio / obache%NetBSD.org@localhost


Home | Main Index | Thread Index | Old Index