diff options
Diffstat (limited to '~mtjm')
29 files changed, 790 insertions, 155 deletions
diff --git a/~mtjm/cups-usblp/PKGBUILD b/~mtjm/cups-usblp/PKGBUILD index 5f1c62325..62b12072a 100644..100755 --- a/~mtjm/cups-usblp/PKGBUILD +++ b/~mtjm/cups-usblp/PKGBUILD @@ -1,31 +1,25 @@ -# $Id: PKGBUILD 149429 2012-02-07 16:59:12Z andyrtr $ +# $Id: PKGBUILD 164175 2012-07-26 17:37:45Z andyrtr $ # Maintainer: Andreas Radke <andyrtr@archlinux.org> _pkgname="cups" pkgname="cups-usblp" -pkgver=1.5.2 +pkgver=1.5.4 pkgrel=1 pkgdesc="The CUPS Printing System - daemon package with usblp backend" arch=('i686' 'x86_64' 'mips64el') license=('GPL') url="http://www.cups.org/" -depends=('acl' 'openslp' 'pam' "libcups>=${pkgver}" 'poppler>=0.12.3' 'dbus-core' 'hicolor-icon-theme') -makedepends=('libtiff>=4.0.0' 'libpng>=1.5.7' 'acl' 'openslp' 'pam' 'xdg-utils' 'krb5' 'gnutls>=2.8.3' 'poppler>=0.12.3' - 'xinetd' 'gzip' 'autoconf' 'php' 'dbus-core' 'avahi' 'hicolor-icon-theme') +depends=('acl' 'openslp' 'pam' "libcups>=${pkgver}" 'cups-filters' 'bc' 'libusb' 'dbus-core' 'libsystemd' 'hicolor-icon-theme') +makedepends=('libtiff>=4.0.0' 'libpng>=1.5.7' 'acl' 'openslp' 'pam' 'xdg-utils' 'krb5' 'gnutls>=2.8.3' 'cups-filters' 'bc' + 'xinetd' 'gzip' 'autoconf' 'php' 'libusb' 'dbus-core' 'avahi' 'hicolor-icon-theme' 'systemd') optdepends=('php: for included phpcups.so module' - 'ghostscript: for non-PostScript printers to print with CUPS to convert PostScript to raster images' - 'foomatic-db: drivers use Ghostscript to convert PostScript to a printable form directly' - 'foomatic-db-engine: drivers use Ghostscript to convert PostScript to a printable form directly' 'xdg-utils: xdg .desktop file support') provides=("cups=${pkgver}") conflicts=("cups" "cups-libre") backup=(etc/cups/cupsd.conf - etc/cups/mime.convs - etc/cups/mime.types etc/cups/snmp.conf etc/cups/printers.conf etc/cups/classes.conf - etc/cups/client.conf etc/cups/subscriptions.conf etc/dbus-1/system.d/cups.conf etc/logrotate.d/cups @@ -40,22 +34,24 @@ source=(ftp://ftp.easysw.com/pub/cups/${pkgver}/cups-${pkgver}-source.tar.bz2 cups-avahi-5-services.patch cups-no-export-ssllibs.patch cups-no-gcrypt.patch + cups-no-gzip-man.patch + cups-systemd-socket.patch cups cups.logrotate cups.pam) #options=('!emptydirs') -md5sums=('9471d2a7c920cfbb17133c32d2e6866f' - '8496c48a7ab5918ce546cfb72472def3' - '7df4c2e0a69bf072d7b7e96523df9dce' - '9a207c5d5189b1c2fc55907b7ed09372' - '5da4ba0837f9a685f146797fcfcd455e' - 'fe782a8fd4351741120d485d476abe8a' +md5sums=('de3006e5cf1ee78a9c6145ce62c4e982' + '12c8af5bcd3b8f84240280b3dfaf9e89' + 'cdc1322c8014297ae349e2db78a03c5a' + '1a5112f63958643f2888abc9418dbcac' + 'c37d1bf1bb76acc3fe93362c80d91b7c' + '5d302860559960042f3b47a91b97c5fe' '9b8467a1e51d360096b70e2c3c081e6c' '3733c23e77eb503bd94cc368e02830dc' + 'c9159ba1233902ba6ddbbe6885a46b72' + '4505b8b2c57a7c28ea79e08388bbbbb9' '9657daa21760bb0b5fa3d8b51d5e01a1' 'f861b18f4446c43918c8643dcbbd7f6d' '96f82c38f3f540b53f3e5144900acf17') -# move client.conf man page for next update to the client pkg. - build() { cd ${srcdir}/${_pkgname}-${pkgver} # http://www.cups.org/str.php?L3066 @@ -66,10 +62,15 @@ build() { patch -Np1 -i ${srcdir}/cups-avahi-4-poll.patch patch -Np1 -i ${srcdir}/cups-avahi-5-services.patch + # add systemd socket support - Fedora patch, also used in Gentoo + patch -Np1 -i ${srcdir}/cups-systemd-socket.patch + # Do not export SSL libs in cups-config patch -Np1 -i "${srcdir}/cups-no-export-ssllibs.patch" patch -Np1 -i "${srcdir}/cups-no-gcrypt.patch" + # don't zip man pages in make install, let makepkg do that / Fedora + patch -Np1 -i ${srcdir}/cups-no-gzip-man.patch # Rebuild configure script for --enable-avahi. aclocal -I config-scripts @@ -77,6 +78,7 @@ build() { ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \ --libdir=/usr/lib \ + --with-systemdsystemunitdir=/usr/lib/systemd/system \ --with-logdir=/var/log/cups \ --with-docdir=/usr/share/cups/doc \ --with-cups-user=daemon \ @@ -121,27 +123,32 @@ package() { chmod 755 ${pkgdir}/var/spool chmod 755 ${pkgdir}/etc - # serial backend needs to run as root (http://bugs.archlinux.org/task/20396) - chmod 700 ${pkgdir}/usr/lib/cups/backend/serial - # install ssl directory where to store the certs, solves some samba issues install -dm700 -g lp ${pkgdir}/etc/cups/ssl # remove directory from package, we create it in cups rc.d file rm -rf ${pkgdir}/var/run -# install -dm511 -g lp ${pkgdir}/var/run/cups/certs # install some more configuration files that will get filled by cupsd touch ${pkgdir}/etc/cups/printers.conf touch ${pkgdir}/etc/cups/classes.conf - touch ${pkgdir}/etc/cups/client.conf - echo "# see 'man client.conf'" >> ${pkgdir}/etc/cups/client.conf - echo "ServerName /var/run/cups/cups.sock # alternative: ServerName hostname-or-ip-address[:port] of a remote server" >> ${pkgdir}/etc/cups/client.conf touch ${pkgdir}/etc/cups/subscriptions.conf - chgrp lp ${pkgdir}/etc/cups/{printers.conf,classes.conf,client.conf,subscriptions.conf} + chgrp lp ${pkgdir}/etc/cups/{printers.conf,classes.conf,subscriptions.conf} # fix .desktop file sed -i 's|^Exec=htmlview http://localhost:631/|Exec=xdg-open http://localhost:631/|g' ${pkgdir}/usr/share/applications/cups.desktop # compress some driver files, adopted from Fedora find ${pkgdir}/usr/share/cups/model -name "*.ppd" | xargs gzip -n9f + + # remove client.conf man page + rm -f ${pkgdir}/usr/share/man/man5/client.conf.5 + + # remove files now part of cups-filters - check cups-filters INSTALL for packagers instructions + rm -v ${pkgdir}/usr/lib/cups/backend/{parallel,serial} + rm -v ${pkgdir}/usr/lib/cups/filter/{bannertops,commandtoescpx,commandtopclx,imagetops,imagetoraster,pdftops,rastertoescpx,rastertopclx,texttops} + rm -v ${pkgdir}/usr/share/cups/banners/* + rm -v ${pkgdir}/usr/share/cups/data/{testprint,psglyphs} + rm -v ${pkgdir}/usr/share/cups/fonts/* + # comment out all conversion rules which use any of the removed filters + perl -p -i -e 's:^(.*\s+(pdftops|texttops|imagetops|bannertops|imagetoraster)\s*)$:#\1:' ${pkgdir}/usr/share/cups/mime/mime.convs } diff --git a/~mtjm/cups-usblp/cups b/~mtjm/cups-usblp/cups index 744c8e663..744c8e663 100644..100755 --- a/~mtjm/cups-usblp/cups +++ b/~mtjm/cups-usblp/cups diff --git a/~mtjm/cups-usblp/cups-avahi-1-config.patch b/~mtjm/cups-usblp/cups-avahi-1-config.patch index 663eb39df..304cd2607 100644..100755 --- a/~mtjm/cups-usblp/cups-avahi-1-config.patch +++ b/~mtjm/cups-usblp/cups-avahi-1-config.patch @@ -1,6 +1,6 @@ -diff -up cups-1.5.0/config.h.in.avahi-1-config cups-1.5.0/config.h.in ---- cups-1.5.0/config.h.in.avahi-1-config 2011-06-16 21:12:16.000000000 +0100 -+++ cups-1.5.0/config.h.in 2011-08-05 15:04:09.535759988 +0100 +diff -up cups-1.5.2/config.h.in.avahi-1-config cups-1.5.2/config.h.in +--- cups-1.5.2/config.h.in.avahi-1-config 2011-06-16 21:12:16.000000000 +0100 ++++ cups-1.5.2/config.h.in 2012-03-14 15:04:51.365347165 +0000 @@ -390,6 +390,13 @@ @@ -15,9 +15,9 @@ diff -up cups-1.5.0/config.h.in.avahi-1-config cups-1.5.0/config.h.in * Do we have <sys/ioctl.h>? */ -diff -up cups-1.5.0/config-scripts/cups-dnssd.m4.avahi-1-config cups-1.5.0/config-scripts/cups-dnssd.m4 ---- cups-1.5.0/config-scripts/cups-dnssd.m4.avahi-1-config 2011-05-12 06:21:56.000000000 +0100 -+++ cups-1.5.0/config-scripts/cups-dnssd.m4 2011-08-05 15:04:09.525760307 +0100 +diff -up cups-1.5.2/config-scripts/cups-dnssd.m4.avahi-1-config cups-1.5.2/config-scripts/cups-dnssd.m4 +--- cups-1.5.2/config-scripts/cups-dnssd.m4.avahi-1-config 2011-05-12 06:21:56.000000000 +0100 ++++ cups-1.5.2/config-scripts/cups-dnssd.m4 2012-03-14 15:04:51.365347165 +0000 @@ -23,6 +23,21 @@ AC_ARG_WITH(dnssd-includes, [ --with-dn DNSSDLIBS="" DNSSD_BACKEND="" @@ -39,4 +39,4 @@ diff -up cups-1.5.0/config-scripts/cups-dnssd.m4.avahi-1-config cups-1.5.0/confi + if test x$enable_dnssd != xno; then AC_CHECK_HEADER(dns_sd.h, [ - case "$uname" in + case "$uname" in
\ No newline at end of file diff --git a/~mtjm/cups-usblp/cups-avahi-2-backend.patch b/~mtjm/cups-usblp/cups-avahi-2-backend.patch index 4c0d4989b..00e12a0a3 100644..100755 --- a/~mtjm/cups-usblp/cups-avahi-2-backend.patch +++ b/~mtjm/cups-usblp/cups-avahi-2-backend.patch @@ -1,6 +1,6 @@ -diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c ---- cups-1.5.2/backend/dnssd.c.avahi-2-backend 2012-02-06 11:09:08.318644741 +0100 -+++ cups-1.5.2/backend/dnssd.c 2012-02-06 11:09:08.326644641 +0100 +diff -up cups-1.5.3/backend/dnssd.c.avahi-2-backend cups-1.5.3/backend/dnssd.c +--- cups-1.5.3/backend/dnssd.c.avahi-2-backend 2012-05-15 16:53:18.164774446 +0200 ++++ cups-1.5.3/backend/dnssd.c 2012-05-15 17:09:07.684155704 +0200 @@ -15,14 +15,21 @@ * * Contents: @@ -85,23 +85,24 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c static void browse_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t interfaceIndex, -@@ -93,12 +131,6 @@ static void browse_local_callback(DNSSe - const char *regtype, +@@ -95,13 +133,6 @@ static void browse_local_callback(DNSSe const char *replyDomain, - void *context); + void *context) + __attribute__((nonnull(1,5,6,7,8))); -static int compare_devices(cups_device_t *a, cups_device_t *b); -static void exec_backend(char **argv); -static cups_device_t *get_device(cups_array_t *devices, - const char *serviceName, - const char *regtype, -- const char *replyDomain); +- const char *replyDomain) +- __attribute__((nonnull(1,2,3,4))); static void query_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t interfaceIndex, -@@ -107,9 +139,118 @@ static void query_callback(DNSServiceRe - uint16_t rrclass, uint16_t rdlen, +@@ -111,10 +142,119 @@ static void query_callback(DNSServiceRe const void *rdata, uint32_t ttl, - void *context); + void *context) + __attribute__((nonnull(1,5,9,11))); +#endif /* HAVE_DNSSD */ +#ifdef HAVE_AVAHI +static void avahi_client_callback (AvahiClient *client, @@ -117,7 +118,6 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c + AvahiLookupResultFlags flags, + void *context); +#endif /* HAVE_AVAHI */ -+ +static cups_device_t * find_device (cups_array_t *devices, + cups_txt_records_t *txt, + cups_device_t *dkey); @@ -126,9 +126,11 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c +static cups_device_t *get_device(cups_array_t *devices, + const char *serviceName, + const char *regtype, -+ const char *replyDomain); ++ const char *replyDomain) ++ __attribute__((nonnull(1,2,3,4))); static void sigterm_handler(int sig); - static void unquote(char *dst, const char *src, size_t dstsize); + static void unquote(char *dst, const char *src, size_t dstsize) + __attribute__((nonnull(1,2))); +#ifdef HAVE_AVAHI +static AvahiSimplePoll *simple_poll = NULL; @@ -174,7 +176,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c + */ + + datalen = *data++; -+ if (!datalen || (data + datalen) >= txt->dataend) ++ if (!datalen || (data + datalen) > txt->dataend) + return NULL; + txt->datanext = data + datalen; + @@ -217,7 +219,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c /* * 'main()' - Browse for printers. -@@ -120,6 +261,13 @@ main(int argc, /* I - Number of comm +@@ -125,6 +265,13 @@ main(int argc, /* I - Number of comm char *argv[]) /* I - Command-line arguments */ { const char *name; /* Backend name */ @@ -231,7 +233,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c DNSServiceRef main_ref, /* Main service reference */ fax_ipp_ref, /* IPP fax service reference */ ipp_ref, /* IPP service reference */ -@@ -133,12 +281,11 @@ main(int argc, /* I - Number of comm +@@ -138,12 +285,11 @@ main(int argc, /* I - Number of comm pdl_datastream_ref, /* AppSocket service reference */ printer_ref, /* LPD service reference */ riousbprint_ref; /* Remote IO service reference */ @@ -249,7 +251,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c #if defined(HAVE_SIGACTION) && !defined(HAVE_SIGSET) struct sigaction action; /* Actions for POSIX signals */ #endif /* HAVE_SIGACTION && !HAVE_SIGSET */ -@@ -198,6 +345,49 @@ main(int argc, /* I - Number of comm +@@ -203,6 +349,49 @@ main(int argc, /* I - Number of comm * Browse for different kinds of printers... */ @@ -299,7 +301,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c if (DNSServiceCreateConnection(&main_ref) != kDNSServiceErr_NoError) { perror("ERROR: Unable to create service connection"); -@@ -258,6 +448,7 @@ main(int argc, /* I - Number of comm +@@ -263,6 +452,7 @@ main(int argc, /* I - Number of comm riousbprint_ref = main_ref; DNSServiceBrowse(&riousbprint_ref, kDNSServiceFlagsShareConnection, 0, "_riousbprint._tcp", NULL, browse_callback, devices); @@ -307,7 +309,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c /* * Loop until we are killed... -@@ -265,6 +456,9 @@ main(int argc, /* I - Number of comm +@@ -270,6 +460,9 @@ main(int argc, /* I - Number of comm while (!job_canceled) { @@ -317,7 +319,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c FD_ZERO(&input); FD_SET(fd, &input); -@@ -284,11 +478,35 @@ main(int argc, /* I - Number of comm +@@ -289,11 +482,35 @@ main(int argc, /* I - Number of comm } else { @@ -353,7 +355,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c cups_device_t *best; /* Best matching device */ char device_uri[1024]; /* Device URI */ int count; /* Number of queries */ -@@ -302,6 +520,7 @@ main(int argc, /* I - Number of comm +@@ -307,6 +524,7 @@ main(int argc, /* I - Number of comm if (device->sent) sent ++; @@ -361,7 +363,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c if (device->ref) count ++; -@@ -333,14 +552,23 @@ main(int argc, /* I - Number of comm +@@ -338,14 +556,23 @@ main(int argc, /* I - Number of comm count ++; } } @@ -386,7 +388,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c if (!best) best = device; -@@ -401,6 +629,7 @@ main(int argc, /* I - Number of comm +@@ -406,6 +633,7 @@ main(int argc, /* I - Number of comm } @@ -394,7 +396,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c /* * 'browse_callback()' - Browse devices. */ -@@ -489,6 +718,7 @@ browse_local_callback( +@@ -494,6 +722,7 @@ browse_local_callback( device->fullName); device->sent = 1; } @@ -402,7 +404,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c /* -@@ -569,6 +799,41 @@ exec_backend(char **argv) /* I - Comman +@@ -574,6 +803,41 @@ exec_backend(char **argv) /* I - Comman /* @@ -444,7 +446,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c * 'get_device()' - Create or update a device. */ -@@ -589,20 +854,7 @@ get_device(cups_array_t *devices, /* I - +@@ -594,20 +858,7 @@ get_device(cups_array_t *devices, /* I - */ key.name = (char *)serviceName; @@ -466,7 +468,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c for (device = cupsArrayFind(devices, &key); device; -@@ -622,8 +874,14 @@ get_device(cups_array_t *devices, /* I - +@@ -627,8 +878,14 @@ get_device(cups_array_t *devices, /* I - free(device->domain); device->domain = strdup(replyDomain); @@ -481,7 +483,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c free(device->fullName); device->fullName = strdup(fullName); } -@@ -643,6 +901,9 @@ get_device(cups_array_t *devices, /* I - +@@ -648,6 +905,9 @@ get_device(cups_array_t *devices, /* I - device->domain = strdup(replyDomain); device->type = key.type; device->priority = 50; @@ -491,7 +493,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c cupsArrayAdd(devices, device); -@@ -650,13 +911,20 @@ get_device(cups_array_t *devices, /* I - +@@ -655,13 +915,20 @@ get_device(cups_array_t *devices, /* I - * Set the "full name" of this service, which is used for queries... */ @@ -512,7 +514,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c /* * 'query_callback()' - Process query data. */ -@@ -680,7 +948,7 @@ query_callback( +@@ -685,7 +952,7 @@ query_callback( *ptr; /* Pointer into string */ cups_device_t dkey, /* Search key */ *device; /* Device */ @@ -521,7 +523,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c fprintf(stderr, "DEBUG2: query_callback(sdRef=%p, flags=%x, " "interfaceIndex=%d, errorCode=%d, fullName=\"%s\", " -@@ -714,94 +982,233 @@ query_callback( +@@ -719,94 +986,233 @@ query_callback( if ((ptr = strstr(name, "._")) != NULL) *ptr = '\0'; @@ -638,7 +640,8 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c else - dkey.type = CUPS_DEVICE_RIOUSBPRINT; + fprintf (stderr, "DEBUG: Ignoring TXT record for \"%s\"...\n", name); -+ + +- for (device = cupsArrayFind(devices, &dkey); + avahi_service_resolver_free (resolver); +} + @@ -713,8 +716,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c +} +#endif /* HAVE_AVAHI */ + - -- for (device = cupsArrayFind(devices, &dkey); ++ +/* + * 'find_device()' - Find a device from its name and domain. + */ @@ -817,7 +819,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c { /* * Add USB device ID information... -@@ -856,6 +1263,10 @@ query_callback( +@@ -861,6 +1267,10 @@ query_callback( if (device->type == CUPS_DEVICE_PRINTER) device->sent = 1; } @@ -828,7 +830,7 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c } if (device->device_id) -@@ -912,11 +1323,9 @@ query_callback( +@@ -917,11 +1327,9 @@ query_callback( } } @@ -841,9 +843,9 @@ diff -up cups-1.5.2/backend/dnssd.c.avahi-2-backend cups-1.5.2/backend/dnssd.c /* * 'sigterm_handler()' - Handle termination signals... */ -diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-support.c ---- cups-1.5.2/cups/http-support.c.avahi-2-backend 2011-09-26 20:46:46.000000000 +0200 -+++ cups-1.5.2/cups/http-support.c 2012-02-06 11:09:08.327644629 +0100 +diff -up cups-1.5.3/cups/http-support.c.avahi-2-backend cups-1.5.3/cups/http-support.c +--- cups-1.5.3/cups/http-support.c.avahi-2-backend 2012-02-15 02:06:12.000000000 +0100 ++++ cups-1.5.3/cups/http-support.c 2012-05-15 17:04:51.045944634 +0200 @@ -43,6 +43,10 @@ * http_copy_decode() - Copy and decode a URI. * http_copy_encode() - Copy and encode a URI. @@ -892,7 +894,7 @@ diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-sup /* * 'httpAssembleURI()' - Assemble a uniform resource identifier from its -@@ -1431,6 +1458,9 @@ _httpResolveURI( +@@ -1434,6 +1461,9 @@ _httpResolveURI( if (strstr(hostname, "._tcp")) { @@ -902,7 +904,7 @@ diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-sup #ifdef HAVE_DNSSD # ifdef WIN32 # pragma comment(lib, "dnssd.lib") -@@ -1449,6 +1479,17 @@ _httpResolveURI( +@@ -1452,6 +1482,17 @@ _httpResolveURI( fd_set input_set; /* Input set for select() */ struct timeval stimeout; /* Timeout value for select() */ #endif /* HAVE_POLL */ @@ -920,7 +922,7 @@ diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-sup if (options & _HTTP_RESOLVE_STDERR) fprintf(stderr, "DEBUG: Resolving \"%s\"...\n", hostname); -@@ -1485,9 +1526,16 @@ _httpResolveURI( +@@ -1488,9 +1529,16 @@ _httpResolveURI( if (domain) *domain++ = '\0'; @@ -937,7 +939,7 @@ diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-sup resolved_uri[0] = '\0'; DEBUG_printf(("6_httpResolveURI: Resolving hostname=\"%s\", regtype=\"%s\", " -@@ -1501,6 +1549,7 @@ _httpResolveURI( +@@ -1504,6 +1552,7 @@ _httpResolveURI( uri = NULL; @@ -945,7 +947,7 @@ diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-sup if (DNSServiceCreateConnection(&ref) == kDNSServiceErr_NoError) { localref = ref; -@@ -1608,6 +1657,36 @@ _httpResolveURI( +@@ -1611,6 +1660,36 @@ _httpResolveURI( DNSServiceRefDeallocate(ref); } @@ -982,7 +984,7 @@ diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-sup if (options & _HTTP_RESOLVE_STDERR) { -@@ -1619,13 +1698,13 @@ _httpResolveURI( +@@ -1622,13 +1701,13 @@ _httpResolveURI( fputs("STATE: -connecting-to-device,offline-report\n", stderr); } @@ -998,10 +1000,10 @@ diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-sup if ((options & _HTTP_RESOLVE_STDERR) && !uri) _cupsLangPrintFilter(stderr, "ERROR", _("Unable to find printer.")); -@@ -1914,6 +1993,116 @@ http_resolve_cb( +@@ -1916,6 +1995,115 @@ http_resolve_cb( + } #endif /* HAVE_DNSSD */ - +#ifdef HAVE_AVAHI +/* + * 'avahi_resolve_uri_client_cb()' - Avahi client callback for resolving URI. @@ -1111,7 +1113,6 @@ diff -up cups-1.5.2/cups/http-support.c.avahi-2-backend cups-1.5.2/cups/http-sup +} +#endif /* HAVE_AVAHI */ + -+ + /* - * End of "$Id: http-support.c 10017 2011-09-26 18:46:46Z mike $". - */ + * End of "$Id: http-support.c 10284 2012-02-15 01:06:12Z mike $".
\ No newline at end of file diff --git a/~mtjm/cups-usblp/cups-avahi-3-timeouts.patch b/~mtjm/cups-usblp/cups-avahi-3-timeouts.patch index 1c547c042..daf852a0f 100644..100755 --- a/~mtjm/cups-usblp/cups-avahi-3-timeouts.patch +++ b/~mtjm/cups-usblp/cups-avahi-3-timeouts.patch @@ -1,6 +1,6 @@ -diff -up cups-1.5.0/scheduler/cupsd.h.avahi-3-timeouts cups-1.5.0/scheduler/cupsd.h ---- cups-1.5.0/scheduler/cupsd.h.avahi-3-timeouts 2011-05-11 23:17:34.000000000 +0100 -+++ cups-1.5.0/scheduler/cupsd.h 2011-10-07 13:20:41.522867324 +0100 +diff -up cups-1.5.2/scheduler/cupsd.h.avahi-3-timeouts cups-1.5.2/scheduler/cupsd.h +--- cups-1.5.2/scheduler/cupsd.h.avahi-3-timeouts 2011-05-11 23:17:34.000000000 +0100 ++++ cups-1.5.2/scheduler/cupsd.h 2012-03-14 15:06:36.509476983 +0000 @@ -140,6 +140,15 @@ extern const char *cups_hstrerror(int); typedef void (*cupsd_selfunc_t)(void *data); @@ -50,9 +50,9 @@ diff -up cups-1.5.0/scheduler/cupsd.h.avahi-3-timeouts cups-1.5.0/scheduler/cups /* * End of "$Id: cupsd.h 9766 2011-05-11 22:17:34Z mike $". -diff -up cups-1.5.0/scheduler/main.c.avahi-3-timeouts cups-1.5.0/scheduler/main.c ---- cups-1.5.0/scheduler/main.c.avahi-3-timeouts 2011-10-07 13:20:36.875954675 +0100 -+++ cups-1.5.0/scheduler/main.c 2011-10-07 13:20:41.524867282 +0100 +diff -up cups-1.5.2/scheduler/main.c.avahi-3-timeouts cups-1.5.2/scheduler/main.c +--- cups-1.5.2/scheduler/main.c.avahi-3-timeouts 2012-03-14 15:04:17.655305548 +0000 ++++ cups-1.5.2/scheduler/main.c 2012-03-14 15:06:36.511476986 +0000 @@ -146,6 +146,10 @@ main(int argc, /* I - Number of comm int launchd_idle_exit; /* Idle exit on select timeout? */ @@ -116,8 +116,8 @@ diff -up cups-1.5.0/scheduler/main.c.avahi-3-timeouts cups-1.5.0/scheduler/main. + * See if there are any scheduled timed callbacks to run. + */ + -+ tmo = cupsdNextTimeout (&tmo_delay); -+ if (tmo) ++ if ((tmo = cupsdNextTimeout(&tmo_delay)) != NULL && ++ (now + tmo_delay) < timeout) + { + timeout = tmo_delay; + why = "run a timed callback"; @@ -127,9 +127,9 @@ diff -up cups-1.5.0/scheduler/main.c.avahi-3-timeouts cups-1.5.0/scheduler/main. /* * Check whether we are accepting new connections... */ -diff -up cups-1.5.0/scheduler/Makefile.avahi-3-timeouts cups-1.5.0/scheduler/Makefile ---- cups-1.5.0/scheduler/Makefile.avahi-3-timeouts 2011-10-07 13:20:36.955953170 +0100 -+++ cups-1.5.0/scheduler/Makefile 2011-10-07 13:20:41.521867343 +0100 +diff -up cups-1.5.2/scheduler/Makefile.avahi-3-timeouts cups-1.5.2/scheduler/Makefile +--- cups-1.5.2/scheduler/Makefile.avahi-3-timeouts 2012-03-14 15:04:17.685305586 +0000 ++++ cups-1.5.2/scheduler/Makefile 2012-03-14 15:06:36.508476980 +0000 @@ -39,7 +39,8 @@ CUPSDOBJS = \ server.o \ statbuf.o \ @@ -140,9 +140,9 @@ diff -up cups-1.5.0/scheduler/Makefile.avahi-3-timeouts cups-1.5.0/scheduler/Mak LIBOBJS = \ filter.o \ mime.o \ -diff -up cups-1.5.0/scheduler/timeout.c.avahi-3-timeouts cups-1.5.0/scheduler/timeout.c ---- cups-1.5.0/scheduler/timeout.c.avahi-3-timeouts 2011-10-07 13:20:41.525867259 +0100 -+++ cups-1.5.0/scheduler/timeout.c 2011-10-07 13:20:41.525867259 +0100 +diff -up cups-1.5.2/scheduler/timeout.c.avahi-3-timeouts cups-1.5.2/scheduler/timeout.c +--- cups-1.5.2/scheduler/timeout.c.avahi-3-timeouts 2012-03-14 15:06:36.552477037 +0000 ++++ cups-1.5.2/scheduler/timeout.c 2012-03-14 15:06:36.552477037 +0000 @@ -0,0 +1,235 @@ +/* + * "$Id$" diff --git a/~mtjm/cups-usblp/cups-avahi-4-poll.patch b/~mtjm/cups-usblp/cups-avahi-4-poll.patch index 189e83da6..d7fa5fd56 100644..100755 --- a/~mtjm/cups-usblp/cups-avahi-4-poll.patch +++ b/~mtjm/cups-usblp/cups-avahi-4-poll.patch @@ -1,6 +1,6 @@ -diff -up cups-1.5.0/scheduler/avahi.c.avahi-4-poll cups-1.5.0/scheduler/avahi.c ---- cups-1.5.0/scheduler/avahi.c.avahi-4-poll 2011-10-11 10:56:50.102288037 +0100 -+++ cups-1.5.0/scheduler/avahi.c 2011-10-11 10:56:50.102288037 +0100 +diff -up cups-1.5.2/scheduler/avahi.c.avahi-4-poll cups-1.5.2/scheduler/avahi.c +--- cups-1.5.2/scheduler/avahi.c.avahi-4-poll 2012-03-14 15:07:29.477542381 +0000 ++++ cups-1.5.2/scheduler/avahi.c 2012-03-14 15:07:29.477542381 +0000 @@ -0,0 +1,441 @@ +/* + * "$Id$" @@ -443,9 +443,9 @@ diff -up cups-1.5.0/scheduler/avahi.c.avahi-4-poll cups-1.5.0/scheduler/avahi.c +/* + * End of "$Id$". + */ -diff -up cups-1.5.0/scheduler/avahi.h.avahi-4-poll cups-1.5.0/scheduler/avahi.h ---- cups-1.5.0/scheduler/avahi.h.avahi-4-poll 2011-10-11 10:56:50.102288037 +0100 -+++ cups-1.5.0/scheduler/avahi.h 2011-10-11 10:56:50.119287724 +0100 +diff -up cups-1.5.2/scheduler/avahi.h.avahi-4-poll cups-1.5.2/scheduler/avahi.h +--- cups-1.5.2/scheduler/avahi.h.avahi-4-poll 2012-03-14 15:07:29.477542381 +0000 ++++ cups-1.5.2/scheduler/avahi.h 2012-03-14 15:07:29.477542381 +0000 @@ -0,0 +1,69 @@ +/* + * "$Id$" @@ -516,9 +516,9 @@ diff -up cups-1.5.0/scheduler/avahi.h.avahi-4-poll cups-1.5.0/scheduler/avahi.h +/* + * End of "$Id$". + */ -diff -up cups-1.5.0/scheduler/Makefile.avahi-4-poll cups-1.5.0/scheduler/Makefile ---- cups-1.5.0/scheduler/Makefile.avahi-4-poll 2011-10-11 10:56:45.868365861 +0100 -+++ cups-1.5.0/scheduler/Makefile 2011-10-11 10:56:50.101288055 +0100 +diff -up cups-1.5.2/scheduler/Makefile.avahi-4-poll cups-1.5.2/scheduler/Makefile +--- cups-1.5.2/scheduler/Makefile.avahi-4-poll 2012-03-14 15:06:36.508476980 +0000 ++++ cups-1.5.2/scheduler/Makefile 2012-03-14 15:07:29.476542380 +0000 @@ -17,6 +17,7 @@ include ../Makedefs CUPSDOBJS = \ diff --git a/~mtjm/cups-usblp/cups-avahi-5-services.patch b/~mtjm/cups-usblp/cups-avahi-5-services.patch index 9713bbc53..820b3c32b 100644..100755 --- a/~mtjm/cups-usblp/cups-avahi-5-services.patch +++ b/~mtjm/cups-usblp/cups-avahi-5-services.patch @@ -1,6 +1,6 @@ -diff -up cups-1.5.0/cgi-bin/admin.c.avahi-5-services cups-1.5.0/cgi-bin/admin.c ---- cups-1.5.0/cgi-bin/admin.c.avahi-5-services 2011-05-20 04:49:49.000000000 +0100 -+++ cups-1.5.0/cgi-bin/admin.c 2011-10-19 11:53:32.123177998 +0100 +diff -up cups-1.5.2/cgi-bin/admin.c.avahi-5-services cups-1.5.2/cgi-bin/admin.c +--- cups-1.5.2/cgi-bin/admin.c.avahi-5-services 2011-08-17 22:01:53.000000000 +0100 ++++ cups-1.5.2/cgi-bin/admin.c 2012-03-14 15:08:25.701611799 +0000 @@ -1643,7 +1643,7 @@ do_config_server(http_t *http) /* I - H else local_protocols[0] = '\0'; @@ -31,10 +31,75 @@ diff -up cups-1.5.0/cgi-bin/admin.c.avahi-5-services cups-1.5.0/cgi-bin/admin.c #ifdef HAVE_LDAP cgiSetVariable("HAVE_LDAP", "1"); -diff -up cups-1.5.0/scheduler/client.c.avahi-5-services cups-1.5.0/scheduler/client.c ---- cups-1.5.0/scheduler/client.c.avahi-5-services 2011-06-10 22:16:18.000000000 +0100 -+++ cups-1.5.0/scheduler/client.c 2011-10-19 11:53:32.127177926 +0100 -@@ -4987,7 +4987,7 @@ valid_host(cupsd_client_t *con) /* I - +diff -up cups-1.5.2/scheduler/avahi.h.avahi-5-services cups-1.5.2/scheduler/avahi.h +--- cups-1.5.2/scheduler/avahi.h.avahi-5-services 2012-03-14 15:07:29.477542381 +0000 ++++ cups-1.5.2/scheduler/avahi.h 2012-03-14 15:08:25.701611799 +0000 +@@ -3,7 +3,7 @@ + * + * Avahi poll implementation for the CUPS scheduler. + * +- * Copyright (C) 2010, 2011 Red Hat, Inc. ++ * Copyright (C) 2010, 2011, 2012 Red Hat, Inc. + * Authors: + * Tim Waugh <twaugh@redhat.com> + * +@@ -32,37 +32,40 @@ + * OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +-#include <config.h> ++#ifndef _CUPS_AVAHI_H_ ++# define _CUPS_AVAHI_H_ + +-#ifdef HAVE_AVAHI +-# include <avahi-client/client.h> +-# include <avahi-client/publish.h> +-#endif /* HAVE_AVAHI */ ++/* ++ * Include necessary headers... ++ */ + +-#ifdef HAVE_AUTHORIZATION_H +-# include <Security/Authorization.h> +-#endif /* HAVE_AUTHORIZATION_H */ ++# include <config.h> + ++# ifdef HAVE_AVAHI ++# include <avahi-client/client.h> ++# include <avahi-client/publish.h> ++# endif /* HAVE_AVAHI */ + +-#ifdef HAVE_AVAHI ++# ifdef HAVE_AVAHI + typedef struct + { + AvahiPoll api; + cups_array_t *watched_fds; + cups_array_t *timeouts; + } AvahiCupsPoll; +-#endif /* HAVE_AVAHI */ ++# endif /* HAVE_AVAHI */ + + /* + * Prototypes... + */ + +-#ifdef HAVE_AVAHI ++# ifdef HAVE_AVAHI + extern AvahiCupsPoll * avahi_cups_poll_new(void); + extern void avahi_cups_poll_free(AvahiCupsPoll *cups_poll); + extern const AvahiPoll *avahi_cups_poll_get(AvahiCupsPoll *cups_poll); +-#endif /* HAVE_AVAHI */ ++# endif /* HAVE_AVAHI */ + ++#endif /* !_CUPS_AVAHI_H_ */ + + /* + * End of "$Id$". +diff -up cups-1.5.2/scheduler/client.c.avahi-5-services cups-1.5.2/scheduler/client.c +--- cups-1.5.2/scheduler/client.c.avahi-5-services 2012-01-13 23:00:22.000000000 +0000 ++++ cups-1.5.2/scheduler/client.c 2012-03-14 15:08:25.703611797 +0000 +@@ -4989,7 +4989,7 @@ valid_host(cupsd_client_t *con) /* I - !strncmp(host, "[::1]:", 6)); } @@ -43,7 +108,7 @@ diff -up cups-1.5.0/scheduler/client.c.avahi-5-services cups-1.5.0/scheduler/cli /* * Check if the hostname is something.local (Bonjour); if so, allow it. */ -@@ -4996,7 +4996,7 @@ valid_host(cupsd_client_t *con) /* I - +@@ -4998,7 +4998,7 @@ valid_host(cupsd_client_t *con) /* I - (!_cups_strcasecmp(end, ".local") || !_cups_strncasecmp(end, ".local:", 7) || !_cups_strcasecmp(end, ".local.") || !_cups_strncasecmp(end, ".local.:", 8))) return (1); @@ -52,10 +117,10 @@ diff -up cups-1.5.0/scheduler/client.c.avahi-5-services cups-1.5.0/scheduler/cli /* * Check if the hostname is an IP address... -diff -up cups-1.5.0/scheduler/conf.c.avahi-5-services cups-1.5.0/scheduler/conf.c ---- cups-1.5.0/scheduler/conf.c.avahi-5-services 2011-10-19 11:53:31.895182225 +0100 -+++ cups-1.5.0/scheduler/conf.c 2011-10-19 11:53:32.131177850 +0100 -@@ -651,7 +651,7 @@ cupsdReadConfiguration(void) +diff -up cups-1.5.2/scheduler/conf.c.avahi-5-services cups-1.5.2/scheduler/conf.c +--- cups-1.5.2/scheduler/conf.c.avahi-5-services 2012-03-14 15:04:17.636305526 +0000 ++++ cups-1.5.2/scheduler/conf.c 2012-03-14 15:08:25.706611803 +0000 +@@ -652,7 +652,7 @@ cupsdReadConfiguration(void) Browsing = CUPS_DEFAULT_BROWSING; DefaultShared = CUPS_DEFAULT_DEFAULT_SHARED; @@ -64,9 +129,9 @@ diff -up cups-1.5.0/scheduler/conf.c.avahi-5-services cups-1.5.0/scheduler/conf. cupsdSetString(&DNSSDRegType, "_ipp._tcp,_cups"); #endif /* HAVE_DNSSD */ -diff -up cups-1.5.0/scheduler/dirsvc.c.avahi-5-services cups-1.5.0/scheduler/dirsvc.c ---- cups-1.5.0/scheduler/dirsvc.c.avahi-5-services 2011-10-19 11:53:32.011180075 +0100 -+++ cups-1.5.0/scheduler/dirsvc.c 2011-10-19 11:53:58.916681461 +0100 +diff -up cups-1.5.2/scheduler/dirsvc.c.avahi-5-services cups-1.5.2/scheduler/dirsvc.c +--- cups-1.5.2/scheduler/dirsvc.c.avahi-5-services 2012-03-14 15:04:17.674305572 +0000 ++++ cups-1.5.2/scheduler/dirsvc.c 2012-03-14 15:08:25.709611806 +0000 @@ -27,6 +27,7 @@ * ldap_connect() - Start new LDAP connection * ldap_reconnect() - Reconnect to LDAP Server @@ -799,15 +864,31 @@ diff -up cups-1.5.0/scheduler/dirsvc.c.avahi-5-services cups-1.5.0/scheduler/dir /* * De-register the individual printers -@@ -2906,6 +3292,7 @@ dnssdStop(void) - p = (cupsd_printer_t *)cupsArrayNext(Printers)) - dnssdDeregisterPrinter(p); - -+#ifdef HAVE_DNSSD - /* +@@ -2910,12 +3296,23 @@ dnssdStop(void) * Shutdown the rest of the service refs... */ -@@ -2926,14 +3313,17 @@ dnssdStop(void) + ++#ifdef HAVE_DNSSD + if (WebIFRef) + { + DNSServiceRefDeallocate(WebIFRef); + WebIFRef = NULL; + } ++#endif /* HAVE_DNSSD */ ++#ifdef HAVE_AVAHI ++ if (AvahiWebIFGroup) ++ { ++ avahi_entry_group_reset (AvahiWebIFGroup); ++ avahi_entry_group_free (AvahiWebIFGroup); ++ AvahiWebIFGroup = NULL; ++ } ++#endif /* HAVE_AVAHI */ + ++#ifdef HAVE_DNSSD + if (RemoteRef) + { + DNSServiceRefDeallocate(RemoteRef); +@@ -2926,14 +3323,17 @@ dnssdStop(void) DNSServiceRefDeallocate(DNSSDRef); DNSSDRef = NULL; @@ -825,7 +906,7 @@ diff -up cups-1.5.0/scheduler/dirsvc.c.avahi-5-services cups-1.5.0/scheduler/dir /* * 'dnssdUpdate()' - Handle DNS-SD queries. */ -@@ -2955,6 +3345,153 @@ dnssdUpdate(void) +@@ -2955,6 +3355,153 @@ dnssdUpdate(void) #endif /* HAVE_DNSSD */ @@ -979,9 +1060,9 @@ diff -up cups-1.5.0/scheduler/dirsvc.c.avahi-5-services cups-1.5.0/scheduler/dir /* * 'get_auth_info_required()' - Get the auth-info-required value to advertise. */ -diff -up cups-1.5.0/scheduler/dirsvc.h.avahi-5-services cups-1.5.0/scheduler/dirsvc.h ---- cups-1.5.0/scheduler/dirsvc.h.avahi-5-services 2011-03-21 02:12:14.000000000 +0000 -+++ cups-1.5.0/scheduler/dirsvc.h 2011-10-19 11:53:32.138177721 +0100 +diff -up cups-1.5.2/scheduler/dirsvc.h.avahi-5-services cups-1.5.2/scheduler/dirsvc.h +--- cups-1.5.2/scheduler/dirsvc.h.avahi-5-services 2011-03-21 02:12:14.000000000 +0000 ++++ cups-1.5.2/scheduler/dirsvc.h 2012-03-14 15:08:25.711611808 +0000 @@ -31,6 +31,10 @@ # endif /* HAVE_LDAP_SSL_H */ #endif /* HAVE_LDAP */ @@ -1054,10 +1135,10 @@ diff -up cups-1.5.0/scheduler/dirsvc.h.avahi-5-services cups-1.5.0/scheduler/dir #ifdef HAVE_LDAP extern void cupsdUpdateLDAPBrowse(void); #endif /* HAVE_LDAP */ -diff -up cups-1.5.0/scheduler/ipp.c.avahi-5-services cups-1.5.0/scheduler/ipp.c ---- cups-1.5.0/scheduler/ipp.c.avahi-5-services 2011-10-19 11:53:31.978180686 +0100 -+++ cups-1.5.0/scheduler/ipp.c 2011-10-19 11:53:32.147177555 +0100 -@@ -6096,7 +6096,7 @@ copy_printer_attrs( +diff -up cups-1.5.2/scheduler/ipp.c.avahi-5-services cups-1.5.2/scheduler/ipp.c +--- cups-1.5.2/scheduler/ipp.c.avahi-5-services 2012-03-14 15:04:17.665305560 +0000 ++++ cups-1.5.2/scheduler/ipp.c 2012-03-14 15:08:25.715611813 +0000 +@@ -6099,7 +6099,7 @@ copy_printer_attrs( ippAddDate(con->response, IPP_TAG_PRINTER, "printer-current-time", ippTimeToDate(curtime)); @@ -1066,7 +1147,7 @@ diff -up cups-1.5.0/scheduler/ipp.c.avahi-5-services cups-1.5.0/scheduler/ipp.c if (!ra || cupsArrayFind(ra, "printer-dns-sd-name")) { if (printer->reg_name) -@@ -6106,7 +6106,7 @@ copy_printer_attrs( +@@ -6109,7 +6109,7 @@ copy_printer_attrs( ippAddInteger(con->response, IPP_TAG_PRINTER, IPP_TAG_NOVALUE, "printer-dns-sd-name", 0); } @@ -1075,9 +1156,9 @@ diff -up cups-1.5.0/scheduler/ipp.c.avahi-5-services cups-1.5.0/scheduler/ipp.c if (!ra || cupsArrayFind(ra, "printer-error-policy")) ippAddString(con->response, IPP_TAG_PRINTER, IPP_TAG_NAME, -diff -up cups-1.5.0/scheduler/main.c.avahi-5-services cups-1.5.0/scheduler/main.c ---- cups-1.5.0/scheduler/main.c.avahi-5-services 2011-10-19 11:53:32.101178406 +0100 -+++ cups-1.5.0/scheduler/main.c 2011-10-19 11:53:32.151177479 +0100 +diff -up cups-1.5.2/scheduler/main.c.avahi-5-services cups-1.5.2/scheduler/main.c +--- cups-1.5.2/scheduler/main.c.avahi-5-services 2012-03-14 15:06:36.511476986 +0000 ++++ cups-1.5.2/scheduler/main.c 2012-03-14 15:08:25.718611817 +0000 @@ -120,6 +120,10 @@ main(int argc, /* I - Number of comm cupsd_listener_t *lis; /* Current listener */ time_t current_time, /* Current time */ @@ -1116,9 +1197,9 @@ diff -up cups-1.5.0/scheduler/main.c.avahi-5-services cups-1.5.0/scheduler/main. #endif /* HAVE_AVAHI */ #ifndef __APPLE__ -diff -up cups-1.5.0/scheduler/printers.c.avahi-5-services cups-1.5.0/scheduler/printers.c ---- cups-1.5.0/scheduler/printers.c.avahi-5-services 2011-10-19 11:53:31.916181835 +0100 -+++ cups-1.5.0/scheduler/printers.c 2011-10-19 11:53:32.156177388 +0100 +diff -up cups-1.5.2/scheduler/printers.c.avahi-5-services cups-1.5.2/scheduler/printers.c +--- cups-1.5.2/scheduler/printers.c.avahi-5-services 2012-03-14 15:04:17.646305537 +0000 ++++ cups-1.5.2/scheduler/printers.c 2012-03-14 15:08:25.720611819 +0000 @@ -883,9 +883,9 @@ cupsdDeletePrinter( cupsdClearString(&p->alert); cupsdClearString(&p->alert_description); @@ -1149,9 +1230,9 @@ diff -up cups-1.5.0/scheduler/printers.c.avahi-5-services cups-1.5.0/scheduler/p } -diff -up cups-1.5.0/scheduler/printers.h.avahi-5-services cups-1.5.0/scheduler/printers.h ---- cups-1.5.0/scheduler/printers.h.avahi-5-services 2011-03-18 18:42:46.000000000 +0000 -+++ cups-1.5.0/scheduler/printers.h 2011-10-19 11:53:32.157177369 +0100 +diff -up cups-1.5.2/scheduler/printers.h.avahi-5-services cups-1.5.2/scheduler/printers.h +--- cups-1.5.2/scheduler/printers.h.avahi-5-services 2011-03-18 18:42:46.000000000 +0000 ++++ cups-1.5.2/scheduler/printers.h 2012-03-14 15:08:25.721611820 +0000 @@ -16,6 +16,9 @@ #ifdef HAVE_DNSSD # include <dns_sd.h> diff --git a/~mtjm/cups-usblp/cups-no-export-ssllibs.patch b/~mtjm/cups-usblp/cups-no-export-ssllibs.patch index 9be3c819b..9be3c819b 100644..100755 --- a/~mtjm/cups-usblp/cups-no-export-ssllibs.patch +++ b/~mtjm/cups-usblp/cups-no-export-ssllibs.patch diff --git a/~mtjm/cups-usblp/cups-no-gcrypt.patch b/~mtjm/cups-usblp/cups-no-gcrypt.patch index 42f71d0d4..42f71d0d4 100644..100755 --- a/~mtjm/cups-usblp/cups-no-gcrypt.patch +++ b/~mtjm/cups-usblp/cups-no-gcrypt.patch diff --git a/~mtjm/cups-usblp/cups-no-gzip-man.patch b/~mtjm/cups-usblp/cups-no-gzip-man.patch new file mode 100755 index 000000000..6786c4430 --- /dev/null +++ b/~mtjm/cups-usblp/cups-no-gzip-man.patch @@ -0,0 +1,18 @@ +diff -up cups-1.5b1/config-scripts/cups-manpages.m4.no-gzip-man cups-1.5b1/config-scripts/cups-manpages.m4 +--- cups-1.5b1/config-scripts/cups-manpages.m4.no-gzip-man 2011-05-12 07:21:56.000000000 +0200 ++++ cups-1.5b1/config-scripts/cups-manpages.m4 2011-05-23 17:25:50.000000000 +0200 +@@ -69,10 +69,10 @@ case "$uname" in + ;; + Linux* | GNU* | Darwin*) + # Linux, GNU Hurd, and Mac OS X +- MAN1EXT=1.gz +- MAN5EXT=5.gz +- MAN7EXT=7.gz +- MAN8EXT=8.gz ++ MAN1EXT=1 ++ MAN5EXT=5 ++ MAN7EXT=7 ++ MAN8EXT=8 + MAN8DIR=8 + ;; + *) diff --git a/~mtjm/cups-usblp/cups-systemd-socket.patch b/~mtjm/cups-usblp/cups-systemd-socket.patch new file mode 100755 index 000000000..09d17d415 --- /dev/null +++ b/~mtjm/cups-usblp/cups-systemd-socket.patch @@ -0,0 +1,527 @@ +diff -up cups-1.5.2/config.h.in.systemd-socket cups-1.5.2/config.h.in +--- cups-1.5.2/config.h.in.systemd-socket 2012-03-16 14:50:57.089449755 +0000 ++++ cups-1.5.2/config.h.in 2012-03-16 14:50:57.146449787 +0000 +@@ -503,6 +503,13 @@ + + + /* ++ * Do we have systemd support? ++ */ ++ ++#undef HAVE_SYSTEMD ++ ++ ++/* + * Various scripting languages... + */ + +diff -up cups-1.5.2/config-scripts/cups-systemd.m4.systemd-socket cups-1.5.2/config-scripts/cups-systemd.m4 +--- cups-1.5.2/config-scripts/cups-systemd.m4.systemd-socket 2012-03-16 14:50:57.146449787 +0000 ++++ cups-1.5.2/config-scripts/cups-systemd.m4 2012-03-16 14:50:57.146449787 +0000 +@@ -0,0 +1,36 @@ ++dnl ++dnl "$Id$" ++dnl ++dnl systemd stuff for CUPS. ++ ++dnl Find whether systemd is available ++ ++SDLIBS="" ++AC_ARG_WITH([systemdsystemunitdir], ++ AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files]), ++ [], [with_systemdsystemunitdir=$($PKGCONFIG --variable=systemdsystemunitdir systemd)]) ++if test "x$with_systemdsystemunitdir" != xno; then ++ AC_MSG_CHECKING(for libsystemd-daemon) ++ if $PKGCONFIG --exists libsystemd-daemon; then ++ AC_MSG_RESULT(yes) ++ SDCFLAGS=`$PKGCONFIG --cflags libsystemd-daemon` ++ SDLIBS=`$PKGCONFIG --libs libsystemd-daemon` ++ AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir]) ++ AC_DEFINE(HAVE_SYSTEMD) ++ else ++ AC_MSG_RESULT(no) ++ fi ++fi ++ ++if test -n "$with_systemdsystemunitdir" -a "x$with_systemdsystemunitdir" != xno ; then ++ SYSTEMD_UNITS="cups.service cups.socket cups.path" ++else ++ SYSTEMD_UNITS="" ++fi ++ ++AC_SUBST(SYSTEMD_UNITS) ++AC_SUBST(SDLIBS) ++ ++dnl ++dnl "$Id$" ++dnl +diff -up cups-1.5.2/configure.in.systemd-socket cups-1.5.2/configure.in +--- cups-1.5.2/configure.in.systemd-socket 2011-08-31 02:36:33.000000000 +0100 ++++ cups-1.5.2/configure.in 2012-03-16 14:50:57.146449787 +0000 +@@ -37,6 +37,7 @@ sinclude(config-scripts/cups-pam.m4) + sinclude(config-scripts/cups-largefile.m4) + sinclude(config-scripts/cups-dnssd.m4) + sinclude(config-scripts/cups-launchd.m4) ++sinclude(config-scripts/cups-systemd.m4) + sinclude(config-scripts/cups-defaults.m4) + sinclude(config-scripts/cups-pdf.m4) + sinclude(config-scripts/cups-scripting.m4) +@@ -71,6 +72,9 @@ AC_OUTPUT(Makedefs + conf/snmp.conf + cups-config + data/testprint ++ data/cups.service ++ data/cups.socket ++ data/cups.path + desktop/cups.desktop + doc/help/ref-cupsd-conf.html + doc/help/standard.html +diff -up cups-1.5.2/cups/usersys.c.systemd-socket cups-1.5.2/cups/usersys.c +--- cups-1.5.2/cups/usersys.c.systemd-socket 2012-03-16 14:50:57.054449734 +0000 ++++ cups-1.5.2/cups/usersys.c 2012-03-16 14:50:57.148449788 +0000 +@@ -778,7 +778,7 @@ cups_read_client_conf( + struct stat sockinfo; /* Domain socket information */ + + if (!stat(CUPS_DEFAULT_DOMAINSOCKET, &sockinfo) && +- (sockinfo.st_mode & S_IRWXO) == S_IRWXO) ++ (sockinfo.st_mode & (S_IROTH | S_IWOTH)) == (S_IROTH | S_IWOTH)) + cups_server = CUPS_DEFAULT_DOMAINSOCKET; + else + #endif /* CUPS_DEFAULT_DOMAINSOCKET */ +diff -up cups-1.5.2/data/cups.path.in.systemd-socket cups-1.5.2/data/cups.path.in +--- cups-1.5.2/data/cups.path.in.systemd-socket 2012-03-16 14:50:57.148449788 +0000 ++++ cups-1.5.2/data/cups.path.in 2012-03-16 14:50:57.148449788 +0000 +@@ -0,0 +1,8 @@ ++[Unit] ++Description=CUPS Printer Service Spool ++ ++[Path] ++PathExistsGlob=@CUPS_REQUESTS@/d* ++ ++[Install] ++WantedBy=multi-user.target +diff -up cups-1.5.2/data/cups.service.in.systemd-socket cups-1.5.2/data/cups.service.in +--- cups-1.5.2/data/cups.service.in.systemd-socket 2012-03-16 14:50:57.149449788 +0000 ++++ cups-1.5.2/data/cups.service.in 2012-03-16 14:50:57.149449788 +0000 +@@ -0,0 +1,10 @@ ++[Unit] ++Description=CUPS Printing Service ++ ++[Service] ++ExecStart=@sbindir@/cupsd -f ++PrivateTmp=true ++ ++[Install] ++Also=cups.socket cups.path ++WantedBy=printer.target +diff -up cups-1.5.2/data/cups.socket.in.systemd-socket cups-1.5.2/data/cups.socket.in +--- cups-1.5.2/data/cups.socket.in.systemd-socket 2012-03-16 14:50:57.150449788 +0000 ++++ cups-1.5.2/data/cups.socket.in 2012-03-16 14:50:57.150449788 +0000 +@@ -0,0 +1,11 @@ ++[Unit] ++Description=CUPS Printing Service Sockets ++ ++[Socket] ++ListenStream=@CUPS_DEFAULT_DOMAINSOCKET@ ++ListenStream=631 ++ListenDatagram=0.0.0.0:631 ++BindIPv6Only=ipv6-only ++ ++[Install] ++WantedBy=sockets.target +diff -up cups-1.5.2/data/Makefile.systemd-socket cups-1.5.2/data/Makefile +--- cups-1.5.2/data/Makefile.systemd-socket 2011-05-12 06:21:56.000000000 +0100 ++++ cups-1.5.2/data/Makefile 2012-03-16 14:50:57.151449789 +0000 +@@ -112,6 +112,12 @@ install-data: + $(INSTALL_DATA) $$file $(DATADIR)/ppdc; \ + done + $(INSTALL_DIR) -m 755 $(DATADIR)/profiles ++ if test "x$(SYSTEMD_UNITS)" != "x" ; then \ ++ $(INSTALL_DIR) -m 755 $(SYSTEMDUNITDIR); \ ++ for file in $(SYSTEMD_UNITS); do \ ++ $(INSTALL_DATA) $$file $(SYSTEMDUNITDIR); \ ++ done; \ ++ fi + + + # +@@ -159,6 +165,9 @@ uninstall: + -$(RMDIR) $(DATADIR)/charsets + -$(RMDIR) $(DATADIR)/banners + -$(RMDIR) $(DATADIR) ++ for file in $(SYSTEMD_UNITS); do \ ++ $(RM) $(SYSTEMDUNITDIR)/$$file; \ ++ done + + + # +diff -up cups-1.5.2/Makedefs.in.systemd-socket cups-1.5.2/Makedefs.in +--- cups-1.5.2/Makedefs.in.systemd-socket 2012-03-16 14:50:57.081449751 +0000 ++++ cups-1.5.2/Makedefs.in 2012-03-16 14:50:57.152449790 +0000 +@@ -143,6 +143,7 @@ CXXFLAGS = @CPPFLAGS@ @CXXFLAGS@ + CXXLIBS = @CXXLIBS@ + DBUS_NOTIFIER = @DBUS_NOTIFIER@ + DBUS_NOTIFIERLIBS = @DBUS_NOTIFIERLIBS@ ++SYSTEMD_UNITS = @SYSTEMD_UNITS@ + DNSSD_BACKEND = @DNSSD_BACKEND@ + DSOFLAGS = -L../cups @DSOFLAGS@ + DSOLIBS = @DSOLIBS@ $(COMMONLIBS) +@@ -151,6 +152,7 @@ FONTS = @FONTS@ + IMGLIBS = @IMGLIBS@ + IMGFILTERS = @IMGFILTERS@ + LAUNCHDLIBS = @LAUNCHDLIBS@ ++SDLIBS = @SDLIBS@ + LDFLAGS = -L../cgi-bin -L../cups -L../filter -L../ppdc \ + -L../scheduler @LDARCHFLAGS@ \ + @LDFLAGS@ @RELROFLAGS@ @PIEFLAGS@ $(OPTIM) +@@ -267,6 +269,7 @@ PAMFILE = @PAMFILE@ + + DEFAULT_LAUNCHD_CONF = @DEFAULT_LAUNCHD_CONF@ + DBUSDIR = @DBUSDIR@ ++SYSTEMDUNITDIR = $(BUILDROOT)@systemdsystemunitdir@ + + + # +diff -up cups-1.5.2/scheduler/client.h.systemd-socket cups-1.5.2/scheduler/client.h +--- cups-1.5.2/scheduler/client.h.systemd-socket 2011-03-25 21:25:38.000000000 +0000 ++++ cups-1.5.2/scheduler/client.h 2012-03-16 14:50:57.153449791 +0000 +@@ -75,6 +75,9 @@ typedef struct + int fd; /* File descriptor for this server */ + http_addr_t address; /* Bind address of socket */ + http_encryption_t encryption; /* To encrypt or not to encrypt... */ ++#ifdef HAVE_SYSTEMD ++ int is_systemd; /* Is this a systemd socket? */ ++#endif /* HAVE_SYSTEMD */ + } cupsd_listener_t; + + +diff -up cups-1.5.2/scheduler/dirsvc.c.systemd-socket cups-1.5.2/scheduler/dirsvc.c +--- cups-1.5.2/scheduler/dirsvc.c.systemd-socket 2012-03-16 14:50:57.112449768 +0000 ++++ cups-1.5.2/scheduler/dirsvc.c 2012-03-16 14:50:57.155449792 +0000 +@@ -1512,7 +1512,7 @@ cupsdStartBrowsing(void) + } + } + +- if (BrowseSocket >= 0) ++ if (BrowseSocket >= 0 && !BrowseSocketIsSystemd) + { + /* + * Bind the socket to browse port... +@@ -1556,13 +1556,17 @@ cupsdStartBrowsing(void) + cupsdLogMessage(CUPSD_LOG_ERROR, "Unable to set broadcast mode - %s.", + strerror(errno)); + ++ if (!BrowseSocketIsSystemd) ++ { + #ifdef WIN32 +- closesocket(BrowseSocket); ++ closesocket(BrowseSocket); + #else +- close(BrowseSocket); ++ close(BrowseSocket); + #endif /* WIN32 */ + +- BrowseSocket = -1; ++ BrowseSocket = -1; ++ } ++ + BrowseLocalProtocols &= ~BROWSE_CUPS; + BrowseRemoteProtocols &= ~BROWSE_CUPS; + +@@ -1885,15 +1889,22 @@ cupsdStopBrowsing(void) + if (((BrowseLocalProtocols | BrowseRemoteProtocols) & BROWSE_CUPS) && + BrowseSocket >= 0) + { +- /* +- * Close the socket and remove it from the input selection set. +- */ ++ if (!BrowseSocketIsSystemd) ++ { ++ /* ++ * Close the socket. ++ */ + + #ifdef WIN32 +- closesocket(BrowseSocket); ++ closesocket(BrowseSocket); + #else +- close(BrowseSocket); ++ close(BrowseSocket); + #endif /* WIN32 */ ++ } ++ ++ /* ++ * Remove it from the input selection set. ++ */ + + cupsdRemoveSelect(BrowseSocket); + BrowseSocket = -1; +@@ -5693,11 +5704,14 @@ update_cups_browse(void) + strerror(errno)); + cupsdLogMessage(CUPSD_LOG_ERROR, "CUPS browsing turned off."); + ++ if (!BrowseSocketIsSystemd) ++ { + #ifdef WIN32 +- closesocket(BrowseSocket); ++ closesocket(BrowseSocket); + #else +- close(BrowseSocket); ++ close(BrowseSocket); + #endif /* WIN32 */ ++ } + + cupsdRemoveSelect(BrowseSocket); + BrowseSocket = -1; +diff -up cups-1.5.2/scheduler/dirsvc.h.systemd-socket cups-1.5.2/scheduler/dirsvc.h +--- cups-1.5.2/scheduler/dirsvc.h.systemd-socket 2012-03-16 14:50:57.113449769 +0000 ++++ cups-1.5.2/scheduler/dirsvc.h 2012-03-16 14:50:57.157449792 +0000 +@@ -100,6 +100,8 @@ VAR int Browsing VALUE(TRUE), + /* Short names for remote printers? */ + BrowseSocket VALUE(-1), + /* Socket for browsing */ ++ BrowseSocketIsSystemd VALUE(0), ++ /* BrowseSocket is systemd-provided? */ + BrowsePort VALUE(IPP_PORT), + /* Port number for broadcasts */ + BrowseInterval VALUE(DEFAULT_INTERVAL), +diff -up cups-1.5.2/scheduler/listen.c.systemd-socket cups-1.5.2/scheduler/listen.c +--- cups-1.5.2/scheduler/listen.c.systemd-socket 2011-04-16 00:38:13.000000000 +0100 ++++ cups-1.5.2/scheduler/listen.c 2012-03-16 14:50:57.158449792 +0000 +@@ -401,7 +401,11 @@ cupsdStopListening(void) + lis; + lis = (cupsd_listener_t *)cupsArrayNext(Listeners)) + { +- if (lis->fd != -1) ++ if (lis->fd != -1 ++#ifdef HAVE_SYSTEMD ++ && !lis->is_systemd ++#endif /* HAVE_SYSTEMD */ ++ ) + { + #ifdef WIN32 + closesocket(lis->fd); +diff -up cups-1.5.2/scheduler/main.c.systemd-socket cups-1.5.2/scheduler/main.c +--- cups-1.5.2/scheduler/main.c.systemd-socket 2012-03-16 14:50:57.121449773 +0000 ++++ cups-1.5.2/scheduler/main.c 2012-03-16 14:51:55.409483636 +0000 +@@ -26,6 +26,8 @@ + * launchd_checkin() - Check-in with launchd and collect the listening + * fds. + * launchd_checkout() - Update the launchd KeepAlive file as needed. ++ * systemd_checkin() - Check-in with systemd and collect the ++ * listening fds. + * parent_handler() - Catch USR1/CHLD signals... + * process_children() - Process all dead children... + * select_timeout() - Calculate the select timeout value. +@@ -62,6 +64,10 @@ + # endif /* !LAUNCH_JOBKEY_SERVICEIPC */ + #endif /* HAVE_LAUNCH_H */ + ++#ifdef HAVE_SYSTEMD ++#include <systemd/sd-daemon.h> ++#endif /* HAVE_SYSTEMD */ ++ + #if defined(HAVE_MALLOC_H) && defined(HAVE_MALLINFO) + # include <malloc.h> + #endif /* HAVE_MALLOC_H && HAVE_MALLINFO */ +@@ -78,6 +84,9 @@ + static void launchd_checkin(void); + static void launchd_checkout(void); + #endif /* HAVE_LAUNCHD */ ++#ifdef HAVE_SYSTEMD ++static void systemd_checkin(void); ++#endif /* HAVE_SYSTEMD */ + static void parent_handler(int sig); + static void process_children(void); + static void sigchld_handler(int sig); +@@ -537,6 +546,13 @@ main(int argc, /* I - Number of comm + } + #endif /* HAVE_LAUNCHD */ + ++#ifdef HAVE_SYSTEMD ++ /* ++ * If we were started by systemd get the listen sockets file descriptors... ++ */ ++ systemd_checkin(); ++#endif /* HAVE_SYSTEMD */ ++ + /* + * Startup the server... + */ +@@ -759,6 +775,15 @@ main(int argc, /* I - Number of comm + } + #endif /* HAVE_LAUNCHD */ + ++#ifdef HAVE_SYSTEMD ++ /* ++ * If we were started by systemd get the listen sockets file ++ * descriptors... ++ */ ++ ++ systemd_checkin(); ++#endif /* HAVE_SYSTEMD */ ++ + /* + * Startup the server... + */ +@@ -1584,6 +1609,139 @@ launchd_checkout(void) + } + #endif /* HAVE_LAUNCHD */ + ++#ifdef HAVE_SYSTEMD ++static void ++systemd_checkin(void) ++{ ++ int n, fd; ++ ++ n = sd_listen_fds(0); ++ if (n < 0) ++ { ++ cupsdLogMessage(CUPSD_LOG_ERROR, ++ "systemd_checkin: Failed to acquire sockets from systemd - %s", ++ strerror(-n)); ++ exit(EXIT_FAILURE); ++ return; ++ } ++ ++ if (n == 0) ++ return; ++ ++ for (fd = SD_LISTEN_FDS_START; fd < SD_LISTEN_FDS_START + n; fd ++) ++ { ++ http_addr_t addr; ++ socklen_t addrlen = sizeof (addr); ++ int r; ++ cupsd_listener_t *lis; ++ char s[256]; ++ ++ r = sd_is_socket(fd, AF_UNSPEC, SOCK_STREAM, 1); ++ if (r < 0) ++ { ++ cupsdLogMessage(CUPSD_LOG_ERROR, ++ "systemd_checkin: Unable to verify socket type - %s", ++ strerror(-r)); ++ continue; ++ } ++ ++ if (!r) ++ { ++ if (Browsing && ++ ((BrowseLocalProtocols | BrowseRemoteProtocols) & BROWSE_CUPS)) ++ { ++ r = sd_is_socket(fd, AF_UNSPEC, SOCK_DGRAM, 0); ++ if (r < 0) ++ { ++ cupsdLogMessage(CUPSD_LOG_ERROR, ++ "systemd_checkin: Unable to verify socket type - %s", ++ strerror(-r)); ++ continue; ++ } ++ ++ if (r) ++ { ++ /* ++ * This is the browse socket. ++ */ ++ ++ char addrstr[256]; ++ if (getsockname(fd, (struct sockaddr*) &addr, &addrlen)) ++ { ++ cupsdLogMessage(CUPSD_LOG_ERROR, ++ "systemd_checkin: Unable to get local address - %s", ++ strerror(errno)); ++ continue; ++ } ++ ++ httpAddrString (&addr, addrstr, sizeof (addrstr)); ++ BrowseSocket = fd; ++ BrowseSocketIsSystemd = 1; ++ cupsdLogMessage(CUPSD_LOG_DEBUG, ++ "systemd_checkin: Matched browse (port %d) with fd %d:%s...", ++ BrowsePort, fd, addrstr); ++ continue; ++ } ++ ++ } ++ cupsdLogMessage(CUPSD_LOG_ERROR, ++ "systemd_checkin: Socket not of the right type"); ++ continue; ++ } ++ ++ if (getsockname(fd, (struct sockaddr*) &addr, &addrlen)) ++ { ++ cupsdLogMessage(CUPSD_LOG_ERROR, ++ "systemd_checkin: Unable to get local address - %s", ++ strerror(errno)); ++ continue; ++ } ++ ++ /* ++ * Try to match the systemd socket address to one of the listeners... ++ */ ++ ++ for (lis = (cupsd_listener_t *)cupsArrayFirst(Listeners); ++ lis; ++ lis = (cupsd_listener_t *)cupsArrayNext(Listeners)) ++ if (httpAddrEqual(&lis->address, &addr)) ++ break; ++ ++ if (lis) ++ { ++ cupsdLogMessage(CUPSD_LOG_DEBUG, ++ "systemd_checkin: Matched existing listener %s with fd %d...", ++ httpAddrString(&(lis->address), s, sizeof(s)), fd); ++ } ++ else ++ { ++ cupsdLogMessage(CUPSD_LOG_DEBUG, ++ "systemd_checkin: Adding new listener %s with fd %d...", ++ httpAddrString(&addr, s, sizeof(s)), fd); ++ ++ if ((lis = calloc(1, sizeof(cupsd_listener_t))) == NULL) ++ { ++ cupsdLogMessage(CUPSD_LOG_ERROR, ++ "systemd_checkin: Unable to allocate listener - " ++ "%s.", strerror(errno)); ++ exit(EXIT_FAILURE); ++ } ++ ++ cupsArrayAdd(Listeners, lis); ++ ++ memcpy(&lis->address, &addr, sizeof(lis->address)); ++ } ++ ++ lis->fd = fd; ++ lis->is_systemd = 1; ++ ++# ifdef HAVE_SSL ++ if (_httpAddrPort(&(lis->address)) == 443) ++ lis->encryption = HTTP_ENCRYPT_ALWAYS; ++# endif /* HAVE_SSL */ ++ } ++} ++#endif /* HAVE_SYSTEMD */ + + /* + * 'parent_handler()' - Catch USR1/CHLD signals... +diff -up cups-1.5.2/scheduler/Makefile.systemd-socket cups-1.5.2/scheduler/Makefile +--- cups-1.5.2/scheduler/Makefile.systemd-socket 2012-03-16 14:50:57.130449778 +0000 ++++ cups-1.5.2/scheduler/Makefile 2012-03-16 14:50:57.160449794 +0000 +@@ -382,7 +382,7 @@ cupsd: $(CUPSDOBJS) $(LIBCUPSMIME) ../cu + $(CC) $(LDFLAGS) -o cupsd $(CUPSDOBJS) -L. -lcupsmime \ + $(LIBZ) $(SSLLIBS) $(LIBSLP) $(LIBLDAP) $(PAMLIBS) \ + $(LIBPAPER) $(LIBMALLOC) $(SERVERLIBS) $(DNSSDLIBS) $(LIBS) \ +- $(LIBGSSAPI) $(LIBWRAP) ++ $(LIBGSSAPI) $(LIBWRAP) $(SDLIBS) + + cupsd-static: $(CUPSDOBJS) libcupsmime.a ../cups/$(LIBCUPSSTATIC) + echo Linking $@... +@@ -390,7 +390,7 @@ cupsd-static: $(CUPSDOBJS) libcupsmime.a + $(LIBZ) $(SSLLIBS) $(LIBSLP) $(LIBLDAP) $(PAMLIBS) \ + ../cups/$(LIBCUPSSTATIC) $(COMMONLIBS) $(LIBZ) $(LIBPAPER) \ + $(LIBMALLOC) $(SERVERLIBS) $(DNSSDLIBS) $(LIBGSSAPI) \ +- $(LIBWRAP) ++ $(LIBWRAP) $(SDLIBS) + + + # diff --git a/~mtjm/cups-usblp/cups.install b/~mtjm/cups-usblp/cups.install index 47c3d9b82..47c3d9b82 100644..100755 --- a/~mtjm/cups-usblp/cups.install +++ b/~mtjm/cups-usblp/cups.install diff --git a/~mtjm/cups-usblp/cups.logrotate b/~mtjm/cups-usblp/cups.logrotate index 9c49bbdaf..9c49bbdaf 100644..100755 --- a/~mtjm/cups-usblp/cups.logrotate +++ b/~mtjm/cups-usblp/cups.logrotate diff --git a/~mtjm/cups-usblp/cups.pam b/~mtjm/cups-usblp/cups.pam index 53724d1f8..53724d1f8 100644..100755 --- a/~mtjm/cups-usblp/cups.pam +++ b/~mtjm/cups-usblp/cups.pam diff --git a/~mtjm/debootstrap/PKGBUILD b/~mtjm/debootstrap/PKGBUILD index 8da48c3a0..20ff27fcb 100644..100755 --- a/~mtjm/debootstrap/PKGBUILD +++ b/~mtjm/debootstrap/PKGBUILD @@ -1,25 +1,26 @@ # Maintainer: Michał Masłowski <mtjm@mtjm.eu> pkgname=debootstrap -_version=1.0.29 -_ubuntu=1 -_trisquel=5.0 -_trisquelrev=2 +_version=1.0.37 +_ubuntu=0 +_trisquel=5.5 +_trisquelrev=1 pkgver=$_version.$_ubuntu.$_trisquel.$_trisquelrev pkgrel=1 pkgdesc="Bootstrap a basic Trisquel system" arch=('any') -url="http://packages.trisquel.info/source/dagda/debootstrap" +url="http://packages.trisquel.info/source/brigantia/debootstrap" license=('custom') depends=('sh') makedepends=('makedev') backup=() -source=("http://archive.trisquel.info/trisquel/pool/main/d/debootstrap/debootstrap_${_version}ubuntu${_ubuntu}+${_trisquel}trisquel${_trisquelrev}.tar.gz") -md5sums=('22f8ddf5e11153c6fae8309a579e3376') +#source=("http://archive.trisquel.info/trisquel/pool/main/d/debootstrap/debootstrap_${_version}ubuntu${_ubuntu}+${_trisquel}trisquel${_trisquelrev}.tar.gz") +source=("http://archive.trisquel.info/trisquel/pool/main/d/debootstrap/debootstrap_${_version}+${_trisquel}trisquel${_trisquelrev}.tar.gz") +sha256sums=('13ce77c840dc83ce84b52e850275b5ef6371bb72d068663933a2e1eefbd13e1e') package() { cd "$srcdir/source" - sed -i 's;MAKEDEV := /sbin/MAKEDEV;MAKEDEV := /usr/sbin/MAKEDEV;' Makefile # fix Arch compatibility + sed -i 's;MAKEDEV := /sbin/MAKEDEV;MAKEDEV := /usr/sbin/MAKEDEV -d .;' Makefile # fix Arch compatibility sed -i 's; consoleonly;;' Makefile # doesn't work, not sure why make all # not in build, since it needs root priviledges make DESTDIR="$pkgdir/" install diff --git a/~mtjm/python-coverage/LICENSE b/~mtjm/python-coverage/LICENSE index 304031cb6..304031cb6 100644..100755 --- a/~mtjm/python-coverage/LICENSE +++ b/~mtjm/python-coverage/LICENSE diff --git a/~mtjm/python-coverage/PKGBUILD b/~mtjm/python-coverage/PKGBUILD index f9acc0d94..f9acc0d94 100644..100755 --- a/~mtjm/python-coverage/PKGBUILD +++ b/~mtjm/python-coverage/PKGBUILD diff --git a/~mtjm/python-getmediumurl/PKGBUILD b/~mtjm/python-getmediumurl/PKGBUILD index 172f6dcd9..172f6dcd9 100644..100755 --- a/~mtjm/python-getmediumurl/PKGBUILD +++ b/~mtjm/python-getmediumurl/PKGBUILD diff --git a/~mtjm/python-urlreader/PKGBUILD b/~mtjm/python-urlreader/PKGBUILD index 4ffe93c6f..4ffe93c6f 100644..100755 --- a/~mtjm/python-urlreader/PKGBUILD +++ b/~mtjm/python-urlreader/PKGBUILD diff --git a/~mtjm/python2-openid/PKGBUILD b/~mtjm/python2-openid/PKGBUILD index 31cdf3290..31cdf3290 100644..100755 --- a/~mtjm/python2-openid/PKGBUILD +++ b/~mtjm/python2-openid/PKGBUILD diff --git a/~mtjm/python2-postfix-policyd-spf/PKGBUILD b/~mtjm/python2-postfix-policyd-spf/PKGBUILD index 237b6c9bd..237b6c9bd 100644..100755 --- a/~mtjm/python2-postfix-policyd-spf/PKGBUILD +++ b/~mtjm/python2-postfix-policyd-spf/PKGBUILD diff --git a/~mtjm/python2-pydns/PKGBUILD b/~mtjm/python2-pydns/PKGBUILD index cf5f4b388..cf5f4b388 100644..100755 --- a/~mtjm/python2-pydns/PKGBUILD +++ b/~mtjm/python2-pydns/PKGBUILD diff --git a/~mtjm/python2-pyflakes/PKGBUILD b/~mtjm/python2-pyflakes/PKGBUILD index 397c487b7..397c487b7 100644..100755 --- a/~mtjm/python2-pyflakes/PKGBUILD +++ b/~mtjm/python2-pyflakes/PKGBUILD diff --git a/~mtjm/python2-pyspf/PKGBUILD b/~mtjm/python2-pyspf/PKGBUILD index abb3bfa5f..abb3bfa5f 100644..100755 --- a/~mtjm/python2-pyspf/PKGBUILD +++ b/~mtjm/python2-pyspf/PKGBUILD diff --git a/~mtjm/thinkfan/PKGBUILD b/~mtjm/thinkfan/PKGBUILD index 9bb9a4793..9bb9a4793 100644..100755 --- a/~mtjm/thinkfan/PKGBUILD +++ b/~mtjm/thinkfan/PKGBUILD diff --git a/~mtjm/thinkfan/thinkfan b/~mtjm/thinkfan/thinkfan index d37c81424..d37c81424 100644..100755 --- a/~mtjm/thinkfan/thinkfan +++ b/~mtjm/thinkfan/thinkfan diff --git a/~mtjm/ttf-beteckna/PKGBUILD b/~mtjm/ttf-beteckna/PKGBUILD index ff338e0d4..ff338e0d4 100644..100755 --- a/~mtjm/ttf-beteckna/PKGBUILD +++ b/~mtjm/ttf-beteckna/PKGBUILD diff --git a/~mtjm/ttf-beteckna/ttf.install b/~mtjm/ttf-beteckna/ttf.install index 33b7d6549..33b7d6549 100644..100755 --- a/~mtjm/ttf-beteckna/ttf.install +++ b/~mtjm/ttf-beteckna/ttf.install diff --git a/~mtjm/zbar/PKGBUILD b/~mtjm/zbar/PKGBUILD index 64b47b5dc..64b47b5dc 100644..100755 --- a/~mtjm/zbar/PKGBUILD +++ b/~mtjm/zbar/PKGBUILD |