Hello community,

here is the log from the commit of package gutenprint for openSUSE:Factory 
checked in at 2015-08-10 09:12:38
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/gutenprint (Old)
 and      /work/SRC/openSUSE:Factory/.gutenprint.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "gutenprint"

Changes:
--------
--- /work/SRC/openSUSE:Factory/gutenprint/gutenprint.changes    2015-07-16 
17:18:32.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.gutenprint.new/gutenprint.changes       
2015-08-10 09:12:39.000000000 +0200
@@ -1,0 +2,10 @@
+Thu Jul 16 10:45:14 CEST 2015 - jsm...@suse.de
+
+- Make it build again for SLE10 (cf. "SLE10" spec file comments).
+- define_GNU_SOURCE_makes_isblank_known.patch adds
+  "#define _GNU_SOURCE" in escputil/d4lib.c because isblank()
+  needs _XOPEN_SOURCE >= 600 (see "man 3 isblank"
+  and "man 7 feature_test_macros") otherwise compile fails
+  with "error: implicit declaration of function 'isblank'".
+
+-------------------------------------------------------------------

New:
----
  define_GNU_SOURCE_makes_isblank_known.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ gutenprint.spec ++++++
--- /var/tmp/diff_new_pack.kYoCPV/_old  2015-08-10 09:12:40.000000000 +0200
+++ /var/tmp/diff_new_pack.kYoCPV/_new  2015-08-10 09:12:40.000000000 +0200
@@ -24,15 +24,15 @@
 %define tarball_version 5.2.11-pre1
 %define gutenprintmajor 5.2
 BuildRequires:  cairo-devel
-# SLE11 and SLE12 need special BuildRequires.
+# SLE10 and SLE11 and SLE12 need special BuildRequires.
 # For suse_version values see 
https://en.opensuse.org/openSUSE:Build_Service_cross_distribution_howto
-%if 0%{?suse_version} != 1110 && 0%{?suse_version} != 1315
-# Anything what is not SLE11 or SLE12 (i.e. all openSUSE versions) have 
"normal" BuildRequires.
+%if 0%{?suse_version} != 1010 && 0%{?suse_version} != 1110 && 
0%{?suse_version} != 1315
+# Anything what is not SLE10 or SLE11 or SLE12 (i.e. all openSUSE versions) 
have "normal" BuildRequires.
 BuildRequires:  cups-ddk
 BuildRequires:  cups-devel
 %endif
-%if 0%{?suse_version} == 1110
-# On SLE11 with its CUPS 1.3.9 there is the separated package cupsddk.
+%if 0%{?suse_version} == 1110 || 0%{?suse_version} == 1010
+# On SLE11 and SLE10 there is the separated package cupsddk.
 BuildRequires:  cups-devel
 BuildRequires:  cupsddk
 %endif
@@ -54,12 +54,26 @@
 BuildRequires:  libusb-1_0-devel
 %endif
 BuildRequires:  pango-devel
+%if 0%{?suse_version} != 1010
+# On SLE10 there is no python-cups. Simply omit it because that BuildRequires 
is only there to
+# add python-cups BuildRequires to have postscriptdriver() Provides for the 
drivers in gutenprint.
 BuildRequires:  python-cups
+%endif
 Summary:        Printer drivers for CUPS from the Gutenprint project
 License:        GPL-2.0+
 Group:          Hardware/Printing
 # The "rastertogutenprint" filter requires CUPS and the "cups" output device 
in Ghostscript:
+%if 0%{?suse_version} == 1010
+# For SLE10 it must be built with --disable-escputil because in SLE10 escputil 
is provided by ghostscript-library
+%define enable_or_disable_escputil disable-escputil
+# For SLE10 it must be built with --disable-cups-1_2-enhancements because 
SLE10 has CUPS 1.1
+%define enable_or_disable_cups_1_2_enhancements disable-cups-1_2-enhancements
+Requires:       cups
+%else
+%define enable_or_disable_escputil enable-escputil
+%define enable_or_disable_cups_1_2_enhancements enable-cups-1_2-enhancements
 Requires:       cups >= 1.2.2
+%endif
 # Up to openSUSE 12.1 the package cups has "Requires: ghostscript_any" so that 
the above
 # "Requires: cups" is sufficient to also get the "cups" output device in 
Ghostscript.
 # Since openSUSE 12.2 the package cups has only "Recommends: ghostscript" to 
avoid
@@ -76,9 +90,10 @@
 Source0:        gutenprint-%{tarball_version}.tar.bz2
 # Patch0...Patch9 is for patches from upstream:
 # Patch10...Patch99 is for openSUSE patches which which are intended for 
upstream:
-# Patch10 escputil-send_nulls-void.patch makes send_nulls a void function
-# because nowhere is a return value of send_nulls used in escputil.c
-# to fix a "no-return-in-nonvoid-function escputil.c:683" compiler error:
+# Patch10 define_GNU_SOURCE_makes_isblank_known.patch adds "#define 
_GNU_SOURCE" in escputil/d4lib.c
+# because isblank() needs _XOPEN_SOURCE >= 600 (see "man 3 isblank" and "man 7 
feature_test_macros")
+# otherwise compile fails with "error: implicit declaration of function 
'isblank'":
+Patch10:        define_GNU_SOURCE_makes_isblank_known.patch
 
 %description
 The Gutenprint (formerly Gimp-Print) printer drivers for CUPS.
@@ -109,6 +124,10 @@
 %prep
 # Be quiet when unpacking:
 %setup -q -n gutenprint-%{tarball_version}
+# Patch10 define_GNU_SOURCE_makes_isblank_known.patch adds "#define 
_GNU_SOURCE" in escputil/d4lib.c
+# because isblank() needs _XOPEN_SOURCE >= 600 (see "man 3 isblank" and "man 7 
feature_test_macros")
+# otherwise compile fails with "error: implicit declaration of function 
'isblank'":
+%patch10
 
 %build
 CFLAGS="$RPM_OPT_FLAGS -fstack-protector -fno-strict-aliasing 
-I/usr/include/gtk-2.0 -I/usr/include/cairo -I/usr/include/glib-2.0 
-I%{_libdir}/gtk-2.0/include -I%{_libdir}/glib-2.0/include 
-I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/gimp-2.0" 
./configure \
@@ -125,7 +144,8 @@
        --disable-libgutenprintui \
        --enable-libgutenprintui2 \
        --enable-samples \
-       --enable-escputil \
+       --%{enable_or_disable_escputil} \
+       --%{enable_or_disable_cups_1_2_enhancements} \
        --with-pic=yes \
        --without-foomatic \
        --without-foomatic3 \
@@ -145,7 +165,7 @@
 # Work with upstream compliant CUPS 1.4 on all platforms
 # which means to have a fixed "/usr/lib/cups/" directory
 # on all platforms (see Novell/Suse Bugzilla bnc#575544).
-# Do not do this for SLE11 with its CUPS 1.3.9 where still /usr/lib64/cups/ is 
used on x86_64:
+# Do not do this for SLE11 and SLE10 where still /usr/lib64/cups/ is used on 
x86_64:
 %if 0%{?suse_version} > 1110
 for D in lib32 lib64
 do for F in commandtocanon commandtoepson rastertogutenprint.%{gutenprintmajor}
@@ -159,17 +179,20 @@
    fi
 done
 %endif
+%if 0%{?suse_version} != 1010
+# Skip that on SLE10 because there is no .../cups/driver/ directory.
 # Disable the run-time PPD generator /usr/lib/cups/driver/gutenprint.5.2
 # so that it is not executed by the cups-driverd (e.g. in response to a 
"lpinfo -m" request)
 # to avoid duplicated PPDs because we create the PPDs during compile-time (via 
--enable-cups-ppds)
 # and provide ready-made PPDs in /usr/share/cups/model/gutenprint/... in the 
RPM package
 # see "Regarding CUPS PPD files" at 
https://bugzilla.novell.com/show_bug.cgi?id=514994#c9
 %if 0%{?suse_version} == 1110
-# On SLE11 with its CUPS 1.3.9 there is still /usr/lib64/cups/ used on x86_64.
+# On SLE11 there is still /usr/lib64/cups/ used on x86_64.
 chmod a-x $RPM_BUILD_ROOT%_libdir/cups/driver/gutenprint.%{gutenprintmajor}
 %else
 chmod a-x $RPM_BUILD_ROOT/usr/lib/cups/driver/gutenprint.%{gutenprintmajor}
 %endif
+%endif
 # Move the special testpattern generator away from the usual bin directory:
 mv $RPM_BUILD_ROOT/%{_bindir}/testpattern 
$RPM_BUILD_ROOT/%{_libdir}/gutenprint/%{gutenprintmajor}
 # Remove dispensable .po files (only the .mo files are needed on the 
end-users's system):
@@ -194,7 +217,10 @@
 %defattr(-,root,root)
 %config /etc/cups/command.types
 %{_bindir}/cups-calibrate
+%if 0%{?suse_version} != 1010
+# In SLE10 escputil is provided by ghostscript-library
 %{_bindir}/escputil
+%endif
 %{_sbindir}/cups-genppd*
 %dir %{_libdir}/gutenprint
 %dir %{_libdir}/gutenprint/%{gutenprintmajor}
@@ -207,10 +233,13 @@
 %dir /usr/share/cups/model/gutenprint/%{gutenprintmajor}
 %dir /usr/share/cups/model/gutenprint/%{gutenprintmajor}/C
 /usr/share/cups/model/gutenprint/%{gutenprintmajor}/C/*
-%if 0%{?suse_version} == 1110
-# On SLE11 with its CUPS 1.3.9 there is still /usr/lib64/cups/ used on x86_64.
+%if 0%{?suse_version} == 1110 || 0%{?suse_version} == 1010
+# On SLE11 and SLE10 there is still /usr/lib64/cups/ used on x86_64.
+%if 0%{?suse_version} != 1010
+# On SLE10 there is no .../cups/driver/ directory
 %dir %_libdir/cups/driver
 %_libdir/cups/driver/gutenprint.%{gutenprintmajor}
+%endif
 %_libdir/cups/filter/commandtocanon
 %_libdir/cups/filter/commandtoepson
 %_libdir/cups/filter/rastertogutenprint.%{gutenprintmajor}
@@ -247,9 +276,17 @@
 
 %files gimpplugin
 %defattr(-,root,root)
+%if 0%{?suse_version} == 1010
+# On SLE10 it gets installed as /opt/gnome/lib[64]/gimp/2.0/plug-ins/print
+%dir /opt/gnome/%{_lib}/gimp
+%dir /opt/gnome/%{_lib}/gimp/2.0
+%dir /opt/gnome/%{_lib}/gimp/2.0/plug-ins
+/opt/gnome/%{_lib}/gimp/2.0/plug-ins/*
+%else
 %dir %{_libdir}/gimp
 %dir %{_libdir}/gimp/2.0
 %dir %{_libdir}/gimp/2.0/plug-ins
 %{_libdir}/gimp/2.0/plug-ins/*
+%endif
 
 %changelog

++++++ define_GNU_SOURCE_makes_isblank_known.patch ++++++
--- src/escputil/d4lib.c.orig   2014-01-13 03:55:22.000000000 +0100
+++ src/escputil/d4lib.c        2015-07-16 14:26:26.000000000 +0200
@@ -34,7 +34,11 @@
  * Programming knowledge will be helpfull for this.
  *
  */
- 
+
+/* isblank() needs _XOPEN_SOURCE >= 600 (see "man 3 isblank" and "man 7 
feature_test_macros")
+ * otherwise compile fails with "error: implicit declaration of function 
'isblank'"
+ */
+#define _XOPEN_SOURCE 600
 
 #include <stdio.h>
 #include <stdlib.h>

Reply via email to