[packages/kde4-kde3support] - update cups fixes from fedora - add gcc 6 build fix - disable jasper support (does not work with j
baggins
baggins at pld-linux.org
Wed Mar 1 20:47:08 CET 2017
commit 61964e948d15c2229aa8dd26f4c5c6b48bb3351a
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Wed Mar 1 20:46:17 2017 +0100
- update cups fixes from fedora
- add gcc 6 build fix
- disable jasper support (does not work with jasper 2+)
- rel 57
gcc6.patch | 21 +++++++
kde4-kde3support.spec | 15 +++--
kdelibs-cups2.patch | 40 -------------
kdelibs-cups20.patch | 159 ++++++++++++++++++++++++++++++++++++++++++++++++++
kdelibs-cups22.patch | 11 ++++
5 files changed, 201 insertions(+), 45 deletions(-)
---
diff --git a/kde4-kde3support.spec b/kde4-kde3support.spec
index 51445e4..cb4a0b5 100644
--- a/kde4-kde3support.spec
+++ b/kde4-kde3support.spec
@@ -2,6 +2,7 @@
# Conditional build:
%bcond_without alsa # build without ALSA support
%bcond_with arts # build with aRts support
+%bcond_with jasper # build with jasper support
%bcond_without autoreqdep # don't care about package name deps generated by rpm
%bcond_without kerberos5 # disable kerberos
%bcond_without hidden_visibility # no gcc hidden visibility
@@ -18,7 +19,7 @@ Summary(ru.UTF-8): K Desktop Environment 3 - Библиотеки
Summary(uk.UTF-8): K Desktop Environment 3 - Бібліотеки
Name: kde4-kde3support
Version: 3.5.10
-Release: 56
+Release: 57
License: LGPL v2
Group: X11/Libraries
Source0: ftp://ftp.kde.org/pub/kde/%{_state}/%{version}/src/%{origname}-%{version}.tar.bz2
@@ -37,7 +38,9 @@ Patch8: openssl1.patch
Patch9: %{name}-qt4.patch
Patch10: boost-1.50.patch
Patch11: kdelibs-cups16.patch
-Patch12: kdelibs-cups2.patch
+Patch12: kdelibs-cups20.patch
+Patch13: kdelibs-cups22.patch
+Patch14: gcc6.patch
URL: http://www.kde.org/
BuildRequires: OpenEXR-devel >= 1.4.0.a
BuildRequires: acl-devel
@@ -64,7 +67,7 @@ BuildRequires: gettext-tools
BuildRequires: glibc-devel >= 6:2.4
%{?with_kerberos5:BuildRequires: heimdal-devel}
BuildRequires: hspell-devel
-BuildRequires: jasper-devel >= 1.600
+%{?with_jasper:BuildRequires: jasper-devel >= 1.600}
BuildRequires: libart_lgpl-devel
BuildRequires: libidn-devel
BuildRequires: libjpeg-devel
@@ -250,6 +253,8 @@ KDE.
%patch10 -p1
%patch11 -p1
%patch12 -p1
+%patch13 -p1
+%patch14 -p1
mv -f configure{,.dist}
:>admin/test-driver
@@ -456,7 +461,7 @@ rm -rf $RPM_BUILD_ROOT
%{_datadir}/services/gif.kimgio
%{_datadir}/services/hdr.kimgio
%{_datadir}/services/ico.kimgio
-%{_datadir}/services/jp2.kimgio
+%{?with_jasper:%{_datadir}/services/jp2.kimgio}
%{_datadir}/services/jpeg.kimgio
#%{_datadir}/services/krl.kimgio
%{_datadir}/services/mng.kimgio
@@ -552,7 +557,7 @@ rm -rf $RPM_BUILD_ROOT
%attr(755,root,root) %{_libdir}/kde3/kimg_exr.so
%attr(755,root,root) %{_libdir}/kde3/kimg_hdr.so
%attr(755,root,root) %{_libdir}/kde3/kimg_ico.so
-%attr(755,root,root) %{_libdir}/kde3/kimg_jp2.so
+%{?with_jasper:%attr(755,root,root) %{_libdir}/kde3/kimg_jp2.so}
%attr(755,root,root) %{_libdir}/kde3/kimg_pcx.so
%attr(755,root,root) %{_libdir}/kde3/kimg_psd.so
%attr(755,root,root) %{_libdir}/kde3/kimg_rgb.so
diff --git a/gcc6.patch b/gcc6.patch
new file mode 100644
index 0000000..4a0d958
--- /dev/null
+++ b/gcc6.patch
@@ -0,0 +1,21 @@
+diff -up kdelibs-3.5.10/kate/part/katebuffer.cpp.than kdelibs-3.5.10/kate/part/katebuffer.cpp
+--- kdelibs-3.5.10/kate/part/katebuffer.cpp.than 2016-02-16 22:06:01.830197908 +0100
++++ kdelibs-3.5.10/kate/part/katebuffer.cpp 2016-02-16 23:33:15.810136589 +0100
+@@ -42,6 +42,8 @@
+ #include <qcstring.h>
+ #include <qdatetime.h>
+
++#include <cmath>
++
+ /**
+ * loader block size, load 256 kb at once per default
+ * if file size is smaller, fall back to file size
+@@ -917,7 +919,7 @@ void KateBuffer::updatePreviousNotEmptyL
+ } while (textLine->firstChar()==-1);
+ kdDebug(13020)<<"updatePreviousNotEmptyLine: updating line:"<<(blk->startLine()+current_line)<<endl;
+ QMemArray<uint> foldingList=textLine->foldingListArray();
+- while ( (foldingList.size()>0) && ( abs(foldingList[foldingList.size()-2])==1)) {
++ while ( (foldingList.size()>0) && ( std::abs(foldingList[foldingList.size()-2])==1)) {
+ foldingList.resize(foldingList.size()-2,QGArray::SpeedOptim);
+ }
+ addIndentBasedFoldingInformation(foldingList,addindent,deindent);
diff --git a/kdelibs-cups2.patch b/kdelibs-cups2.patch
deleted file mode 100644
index c4b28b4..0000000
--- a/kdelibs-cups2.patch
+++ /dev/null
@@ -1,40 +0,0 @@
---- kdelibs-3.5.10/kdeprint/cups/cupsdconf2/cups-util.c.orig 2014-11-11 21:07:48.000000000 +0100
-+++ kdelibs-3.5.10/kdeprint/cups/cupsdconf2/cups-util.c 2014-11-11 22:01:12.743376515 +0100
-@@ -167,7 +167,7 @@
- */
-
- snprintf(plain, sizeof(plain), "%s:%s", cupsUser(), pwdstring);
--#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
-+#if (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2) || (CUPS_VERSION_MAJOR > 1)
- httpEncode64_2(encode, sizeof(encode), plain, sizeof(plain));
- #else
- httpEncode64(encode, plain);
-@@ -430,7 +430,7 @@
- */
-
- snprintf(plain, sizeof(plain), "%s:%s", cupsUser(), pwdstring);
--#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
-+#if (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2) || (CUPS_VERSION_MAJOR > 1)
- httpEncode64_2(encode, sizeof(encode), plain, sizeof(plain));
- #else
- httpEncode64(encode, plain);
-@@ -512,7 +512,7 @@
- * See if we are accessing localhost...
- the struct has changed in newer versions - PiggZ (adam at piggz.co.uk)
- */
--#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
-+#if ( CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2 ) || (CUPS_VERSION_MAJOR > 1)
- if (!httpAddrLocalhost(http))
- #else
- if (ntohl(*(int*)&http->hostaddr.sin_addr) != 0x7f000001 &&
---- kdelibs-3.5.10/kdeprint/cups/ipprequest.cpp~ 2014-11-11 21:07:48.000000000 +0100
-+++ kdelibs-3.5.10/kdeprint/cups/ipprequest.cpp 2014-11-11 22:02:13.353376077 +0100
-@@ -751,7 +751,7 @@
- cupsFreeOptions(n, options);
-
- // find an remove that annoying "document-format" attribute
--#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
-+#if (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2) || (CUPS_VERSION_MAJOR > 1)
- ipp_attribute_t *attr = ippFindAttribute(request_, "document-format", IPP_TAG_NAME);
- ippDeleteAttribute(request_, attr);
- #else
diff --git a/kdelibs-cups20.patch b/kdelibs-cups20.patch
new file mode 100644
index 0000000..10e30f5
--- /dev/null
+++ b/kdelibs-cups20.patch
@@ -0,0 +1,159 @@
+diff -ur kdelibs-3.5.10/kdeprint/cups/cupsdconf2/cups-util.c kdelibs-3.5.10-cups20/kdeprint/cups/cupsdconf2/cups-util.c
+--- kdelibs-3.5.10/kdeprint/cups/cupsdconf2/cups-util.c 2007-10-08 11:52:10.000000000 +0200
++++ kdelibs-3.5.10-cups20/kdeprint/cups/cupsdconf2/cups-util.c 2014-11-25 21:41:51.000000000 +0100
+@@ -32,7 +32,7 @@
+ char prompt[1024]; /* Prompt string */
+ int digest_tries; /* Number of tries with Digest */
+ static char filename[HTTP_MAX_URI]; /* Local filename */
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ const char *fqdn = 0;
+ #else
+ char fqdn[ HTTP_MAX_URI ]; /* Server name buffer */
+@@ -118,7 +118,7 @@
+ * See if we should retry the current digest password...
+ */
+
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ www_authenticate = cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE];
+ #else
+ www_authenticate = httpGetField( cups_server, HTTP_FIELD_WWW_AUTHENTICATE );
+@@ -129,7 +129,7 @@
+ /*
+ * Nope - get a password from the user...
+ */
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ fqdn = cups_server->hostname;
+ #else
+ httpGetHostname( cups_server, fqdn, sizeof( fqdn ) );
+@@ -154,7 +154,7 @@
+ * Got a password; encode it for the server...
+ */
+
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ www_authenticate = cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE];
+ #else
+ www_authenticate = httpGetField( cups_server, HTTP_FIELD_WWW_AUTHENTICATE );
+@@ -166,7 +166,7 @@
+ */
+
+ snprintf(plain, sizeof(plain), "%s:%s", cupsUser(), pwdstring);
+-#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
++#if CUPS_VERSION_MAJOR > 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2)
+ httpEncode64_2(encode, sizeof(encode), plain, sizeof(plain));
+ #else
+ httpEncode64(encode, plain);
+@@ -235,7 +235,7 @@
+ */
+
+ while ((bytes =
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ httpRead
+ #else
+ httpRead2
+@@ -265,7 +265,7 @@
+ http_status_t status; /* HTTP status from server */
+ char prompt[1024]; /* Prompt string */
+ int digest_tries; /* Number of tries with Digest */
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ const char *fqdn = 0;
+ #else
+ char fqdn[ HTTP_MAX_URI ]; /* Server name buffer */
+@@ -340,7 +340,7 @@
+ break;
+ }
+ else
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ httpWrite
+ #else
+ httpWrite2
+@@ -349,7 +349,7 @@
+
+ if (status == HTTP_CONTINUE)
+ {
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ httpWrite
+ #else
+ httpWrite2
+@@ -380,7 +380,7 @@
+ * See if we should retry the current digest password...
+ */
+
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ www_authenticate = cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE];
+ #else
+ www_authenticate = httpGetField( cups_server, HTTP_FIELD_WWW_AUTHENTICATE );
+@@ -393,7 +393,7 @@
+ */
+
+
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ fqdn = cups_server->hostname;
+ #else
+ httpGetHostname( cups_server, fqdn, sizeof( fqdn ) );
+@@ -417,7 +417,7 @@
+ * Got a password; encode it for the server...
+ */
+
+-#if CUPS_VERSION_MAJOR - 0 <= 1 && CUPS_VERSION_MINOR - 0 < 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
+ www_authenticate = cups_server->fields[HTTP_FIELD_WWW_AUTHENTICATE];
+ #else
+ www_authenticate = httpGetField( cups_server, HTTP_FIELD_WWW_AUTHENTICATE );
+@@ -429,7 +429,7 @@
+ */
+
+ snprintf(plain, sizeof(plain), "%s:%s", cupsUser(), pwdstring);
+-#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
++#if CUPS_VERSION_MAJOR > 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2)
+ httpEncode64_2(encode, sizeof(encode), plain, sizeof(plain));
+ #else
+ httpEncode64(encode, plain);
+@@ -511,7 +511,7 @@
+ * See if we are accessing localhost...
+ the struct has changed in newer versions - PiggZ (adam at piggz.co.uk)
+ */
+-#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
++#if CUPS_VERSION_MAJOR > 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2)
+ if (!httpAddrLocalhost(http))
+ #else
+ if (ntohl(*(int*)&http->hostaddr.sin_addr) != 0x7f000001 &&
+diff -ur kdelibs-3.5.10/kdeprint/cups/ipprequest.cpp kdelibs-3.5.10-cups20/kdeprint/cups/ipprequest.cpp
+--- kdelibs-3.5.10/kdeprint/cups/ipprequest.cpp 2007-10-08 11:52:10.000000000 +0200
++++ kdelibs-3.5.10-cups20/kdeprint/cups/ipprequest.cpp 2014-11-25 21:41:51.000000000 +0100
+@@ -310,7 +310,7 @@
+ }
+
+ #ifdef HAVE_CUPS_NO_PWD_CACHE
+-#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR <= 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR <= 2)
+ strncpy( HTTP->authstring, cups_authstring.data(), HTTP_MAX_VALUE );
+ #else
+ httpSetAuthString( HTTP, NULL, cups_authstring.data() );
+@@ -324,7 +324,7 @@
+
+ request_ = cupsDoFileRequest(HTTP, request_, (res.isEmpty() ? "/" : res.latin1()), (filename.isEmpty() ? NULL : filename.latin1()));
+ #ifdef HAVE_CUPS_NO_PWD_CACHE
+-#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR <= 2
++#if CUPS_VERSION_MAJOR < 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR <= 2)
+ cups_authstring = HTTP->authstring;
+ #else
+ cups_authstring = httpGetAuthString( HTTP );
+@@ -523,7 +523,7 @@
+ cupsFreeOptions(n, options);
+
+ // find an remove that annoying "document-format" attribute
+-#if CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2
++#if CUPS_VERSION_MAJOR > 1 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR >= 2)
+ ipp_attribute_t *attr = ippFindAttribute(request_, "document-format", IPP_TAG_NAME);
+ ippDeleteAttribute(request_, attr);
+ #else
diff --git a/kdelibs-cups22.patch b/kdelibs-cups22.patch
new file mode 100644
index 0000000..d6b7293
--- /dev/null
+++ b/kdelibs-cups22.patch
@@ -0,0 +1,11 @@
+diff -ur kdelibs-3.5.10/kdeprint/cups/cupsaddsmb2.cpp kdelibs-3.5.10-cups22/kdeprint/cups/cupsaddsmb2.cpp
+--- kdelibs-3.5.10/kdeprint/cups/cupsaddsmb2.cpp 2005-10-10 17:06:30.000000000 +0200
++++ kdelibs-3.5.10-cups22/kdeprint/cups/cupsaddsmb2.cpp 2016-09-28 19:23:09.264863318 +0200
+@@ -39,6 +39,7 @@
+ #include <kstdguiitem.h>
+
+ #include <cups/cups.h>
++#include <cups/ppd.h>
+ #include <ctype.h>
+
+ CupsAddSmb::CupsAddSmb(QWidget *parent, const char *name)
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/kde4-kde3support.git/commitdiff/61964e948d15c2229aa8dd26f4c5c6b48bb3351a
More information about the pld-cvs-commit
mailing list