%global srcname zebraprint %global cups_datadir %(/usr/bin/cups-config --datadir) %global cups_filterdir %{_cups_serverbin}/filter Name: zebraprint Version: 0.6 Release: 1%{?dist} Summary: Zebra CPCL label printer support License: GPLv2+ URL: http://github.com/unipartdigital/%{srcname} VCS: git+https://github.com/unipartdigital/zebraprint.git#7c16c711b6026ae8b3749fe9e20968ce5e833257: Source: zebraprint-0.6.tar.gz BuildRequires: gcc BuildRequires: libxml2-devel BuildRequires: libxslt-devel BuildRequires: cups-devel %description Zebra printers are supported by the CUPS printing system but only as raster image devices. This means that documents to be printed are sent to the printer as a large raster (bitmap) image. On some Zebra printers, this can result in a delay of around 80 seconds before the label is printed. A more efficient method is to use the Comtec Printer Control Language (CPCL). This is a page description language (analogous to PostScript) that can be used to describe the page using built-in primitives for text, barcodes, graphics, etc. Installing this package will allow you to print CPCL or CPCL/XML documents directly to your Zebra printer via CUPS. %prep %autosetup -n %{srcname}-%{version} %build %{make_build} %install mkdir -p $RPM_BUILD_ROOT{%{cups_datadir}/mime,%{cups_filterdir}} %{make_install} CUPS_DATADIR=$RPM_BUILD_ROOT%{cups_datadir} \ CUPS_FILTERDIR=$RPM_BUILD_ROOT%{cups_filterdir} %post systemctl try-restart cups.path cups.socket cups.service &>/dev/null || : %postun systemctl try-restart cups.path cups.socket cups.service &>/dev/null || : %files %license COPYING %dir %{cups_datadir}/zebraprint %{cups_datadir}/zebraprint/cpcl.xsd %{cups_datadir}/zebraprint/cpcl.xslt %{cups_datadir}/mime/zebraprint.types %{cups_datadir}/mime/zebraprint.convs %{cups_filterdir}/xmltocpcl %changelog * Fri Jan 25 2019 Michael Brown 0.6-1 - rpm: Automatically restart CUPS as needed * Thu Nov 22 2018 Michael Brown 0.5-1 - Allow any element to have an "id" attribute * Tue Nov 20 2018 Michael Brown 0.4-1 - Allow for whitespace within element text * Mon Oct 08 2018 Michael Brown 0.3-1 - Add support for bar-sense and gap-sense level specification * Fri Sep 14 2018 Michael Brown 0.2-1 - First production release * Fri Sep 14 2018 Michael Brown 0.1-2 - Add explicit BuildRequires on gcc (for Fedora 29 and later) * Thu Sep 13 2018 Michael Brown 0.1-1 - First packaged version