public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in app-text/djview/files: djview-4.8-qt48.patch
@ 2012-04-21 17:09 Samuli Suominen (ssuominen)
  0 siblings, 0 replies; 2+ messages in thread
From: Samuli Suominen (ssuominen) @ 2012-04-21 17:09 UTC (permalink / raw
  To: gentoo-commits

ssuominen    12/04/21 17:09:49

  Added:                djview-4.8-qt48.patch
  Log:
  Remove unnecessary djview4 blockers wrt updates/2Q-2012. Fix building with Qt 4.8 (upstream patch) wrt #401517 by Rafał Mużyło.
  
  (Portage version: 2.2.0_alpha100/cvs/Linux x86_64)

Revision  Changes    Path
1.1                  app-text/djview/files/djview-4.8-qt48.patch

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/djview/files/djview-4.8-qt48.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-text/djview/files/djview-4.8-qt48.patch?rev=1.1&content-type=text/plain

Index: djview-4.8-qt48.patch
===================================================================
From: Leon Bottou <leon@bottou.org>
Date: Mon, 2 Apr 2012 14:11:36 +0000 (-0700)
Subject: removed swap (use qSwap instead).
X-Git-Tag: release.4.9~5
X-Git-Url: http://djvu.git.sourceforge.net/git/gitweb.cgi?p=djvu%2Fdjview.git;a=commitdiff_plain;h=7d4802964b9e74506c63f43505b632f6e7b5db3c;hp=6389dcba572c6439acd226d27872c2f0db583875

removed swap (use qSwap instead).

Fixes Gentoo bug 401517, compilation problems with qt-4.8.
Unclear why is namespace std in scope at this point when using qt-4.8...
---

diff --git a/src/qdjvuwidget.cpp b/src/qdjvuwidget.cpp
index 52ac366..8136d07 100644
--- a/src/qdjvuwidget.cpp
+++ b/src/qdjvuwidget.cpp
@@ -152,15 +152,6 @@ all_numbers(const char *s)
   return true;
 }
 
-template<class T> static inline void 
-swap(T& x, T& y)
-{
-  T tmp;
-  tmp = x;
-  x = y;
-  y = tmp;
-}
-
 template<class T> static inline int
 ksmallest(T *v, int n, int k)
 {
@@ -173,11 +164,11 @@ ksmallest(T *v, int n, int k)
       /* Sort v[lo], v[m], v[hi] by insertion */
       m = (lo+hi)/2;
       if (v[lo]>v[m])
-        swap(v[lo],v[m]);
+        qSwap(v[lo],v[m]);
       if (v[m]>v[hi]) {
-        swap(v[m],v[hi]);
+        qSwap(v[m],v[hi]);
         if (v[lo]>v[m])
-          swap(v[lo],v[m]);
+          qSwap(v[lo],v[m]);
       }
       /* Extract pivot, place sentinel */
       pivot = v[m];
@@ -191,7 +182,7 @@ ksmallest(T *v, int n, int k)
       do ++l; while (v[l]<pivot);
       do --h; while (v[h]>pivot);
       if (l < h) { 
-        swap(v[l],v[h]); 
+        qSwap(v[l],v[h]); 
         goto loop; 
       }
       /* Finish up */






^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [gentoo-commits] gentoo-x86 commit in app-text/djview/files: djview-4.8-qt48.patch
@ 2015-03-09  7:59 Alexis Ballier (aballier)
  0 siblings, 0 replies; 2+ messages in thread
From: Alexis Ballier (aballier) @ 2015-03-09  7:59 UTC (permalink / raw
  To: gentoo-commits

aballier    15/03/09 07:59:35

  Removed:              djview-4.8-qt48.patch
  Log:
  remove old
  
  Signed-off-by: aballier@gentoo.org
  (Portage version: 2.2.18/cvs/Linux x86_64, signed Manifest commit with key 160F534A)


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-03-09  7:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-21 17:09 [gentoo-commits] gentoo-x86 commit in app-text/djview/files: djview-4.8-qt48.patch Samuli Suominen (ssuominen)
  -- strict thread matches above, loose matches on Subject: below --
2015-03-09  7:59 Alexis Ballier (aballier)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox