pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: pkg/49961: Properly handle bash shell in print/cups-filters
The following reply was made to PR pkg/49961; it has been noted by GNATS.
From: Leonardo Taccari <iamleot%gmail.com@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc:
Subject: Re: pkg/49961: Properly handle bash shell in print/cups-filters
Date: Thu, 11 Jun 2015 21:08:17 +0200
Hello Aleksej,
Aleksej Saushev writes:
> This sounds as a step for another phase, either patch or configure,
> thus it should be post-patch or pre- or post-configure rather.
> =
> Because of the above, could you consider adding it as a configuration pa=
rameter?
> Perhaps just CPPFLAGS is enough. Configuration parameter could be easier=
accepted upstream.
Nice idea! Here another version of the patches that adds "--with-shell"
option to the configure script. If it looks ok and it will imported I
will then take care to contact upstream in order to import it.
Thank you!
Ciao,
L.
------------------8<------------------8<------------------8<--------------=
----
Index: Makefile
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /cvsroot/pkgsrc/print/cups-filters/Makefile,v
retrieving revision 1.20
diff -u -r1.20 Makefile
--- Makefile 25 Apr 2015 14:24:45 -0000 1.20
+++ Makefile 11 Jun 2015 13:52:56 -0000
@@ -1,7 +1,7 @@
# $NetBSD: Makefile,v 1.20 2015/04/25 14:24:45 tnn Exp $
=
DISTNAME=3D cups-filters-1.0.68
-PKGREVISION=3D 1
+PKGREVISION=3D 2
CATEGORIES=3D print
MASTER_SITES=3D http://openprinting.org/download/cups-filters/
EXTRACT_SUFX=3D .tar.xz
@@ -9,11 +9,12 @@
MAINTAINER=3D pkgsrc-users%NetBSD.org@localhost
HOMEPAGE=3D http://www.linuxfoundation.org/collaborate/workgroups/openpri=
nting/cups-filters
COMMENT=3D Backends, filters, and other software for cups
-#LICENSE=3D # TODO: (see mk/license.mk)
+LICENSE=3D gnu-gpl-v2 AND gnu-gpl-v3 AND gnu-lgpl-v2 AND mit
=
GNU_CONFIGURE=3D yes
USE_LIBTOOL=3D yes
USE_TOOLS+=3D bash:run pkg-config
+USE_TOOLS+=3D autoconf
USE_LANGUAGES=3D c c++
=
CONFLICTS+=3D cups<1.6
@@ -26,12 +27,16 @@
=
CONFIGURE_ARGS+=3D --with-rcdir=3D${PREFIX}/share/examples/rc.d
CONFIGURE_ARGS+=3D --with-rclevels=3D""
+CONFIGURE_ARGS+=3D --with-shell=3D${TOOLS_PATH.bash}
=
INSTALL_MAKE_FLAGS+=3D sysconfdir=3D${PREFIX}/share/examples/cups-filters
=
CONF_FILES=3D ${PREFIX}/share/examples/cups-filters/fonts/conf.d/99pdfto=
opvp.conf ${PKG_SYSCONFDIR}/fonts/conf.d/99pdftoopvp.conf
CONF_FILES=3D ${PREFIX}/share/examples/cups-filters/cups-browsed.conf ${=
PKG_SYSCONFDIR}/cups/cups-browsed.conf
=
+pre-configure:
+ cd ${WRKSRC} && autoconf
+
post-install:
${MV} ${DESTDIR}${PREFIX}/etc/cups/cups-browsed.conf ${DESTDIR}${PREFIX}=
/share/examples/cups-filters/cups-browsed.conf
=
Index: distinfo
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /cvsroot/pkgsrc/print/cups-filters/distinfo,v
retrieving revision 1.15
diff -u -r1.15 distinfo
--- distinfo 19 Apr 2015 18:44:25 -0000 1.15
+++ distinfo 11 Jun 2015 13:52:56 -0000
@@ -3,3 +3,5 @@
SHA1 (cups-filters-1.0.68.tar.xz) =3D 3564711352e93fe315774200375bedc2fec=
dde97
RMD160 (cups-filters-1.0.68.tar.xz) =3D ae0e9e0f3c20175f2e178167459e08cf5=
87d36fd
Size (cups-filters-1.0.68.tar.xz) =3D 1336216 bytes
+SHA1 (patch-configure.ac) =3D 189a6b77d53a4026bcb070ec5722551b9ce7bc1e
+SHA1 (patch-filter_foomatic-rip_foomaticrip.c) =3D 0cb7be02d76ce64dd167e6=
a1b849393fc09baeea
Index: patches/patch-configure.ac
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: patches/patch-configure.ac
diff -N patches/patch-configure.ac
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-configure.ac 11 Jun 2015 13:52:56 -0000
@@ -0,0 +1,32 @@
+$NetBSD$
+
+Add a --with-shell option in order to avoid hardcoding "/bin/bash" inside
+filter/foomaticrip.c.
+
+--- configure.ac.orig 2015-04-13 14:47:41.000000000 +0000
++++ configure.ac
+@@ -622,6 +622,16 @@ fi
+ AC_SUBST(SED_EXTENDED_REGEX_OPT)
+ AC_SUBST(CUPS_GHOSTSCRIPT)
+ =
++# =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D
++# Select a different shell instead of the default /bin/bash
++# =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D
++AC_ARG_WITH([shell],
++ [AS_HELP_STRING([--with-shell=3Dpath], [Specify path for a modern shell=
.])],
++ [with_shell=3D"$withval"],
++ [with_shell=3D"/bin/bash"]
++)
++AC_DEFINE_UNQUOTED([SHELL], "$with_shell", [Path for a modern shell])]
++
+ # =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
+ # Prepare all .in files
+ # =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
+@@ -659,6 +669,7 @@ Build configuration:
+ png: ${with_png}
+ php: ${with_php}
+ php-config: ${with_php_config}
++ shell: ${with_shell}
+ test-font: ${with_test_font_path}
+ tiff: ${with_tiff}
+ avahi: ${enable_avahi}
Index: patches/patch-filter_foomatic-rip_foomaticrip.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: patches/patch-filter_foomatic-rip_foomaticrip.c
diff -N patches/patch-filter_foomatic-rip_foomaticrip.c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-filter_foomatic-rip_foomaticrip.c 11 Jun 2015 13:52:56 -=
0000
@@ -0,0 +1,15 @@
+$NetBSD$
+
+Adjust according the --with-shell option.
+
+--- filter/foomatic-rip/foomaticrip.c.orig 2015-02-13 22:36:44.000000000 =
+0000
++++ filter/foomatic-rip/foomaticrip.c
+@@ -174,7 +174,7 @@ char cupsfilterpath[PATH_MAX] =3D "/usr/lo
+ "/opt/cups/filter:"
+ "/usr/lib/cups/filter";
+ =
+-char modern_shell[64] =3D "/bin/bash";
++char modern_shell[64] =3D SHELL;
+ =
+ void config_set_option(const char *key, const char *value)
+ {
Home |
Main Index |
Thread Index |
Old Index