public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in sci-mathematics/octave/files: octave-3.8.0-imagemagick.patch
@ 2014-02-20  3:05 Mark Wright (gienah)
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Wright (gienah) @ 2014-02-20  3:05 UTC (permalink / raw
  To: gentoo-commits

gienah      14/02/20 03:05:52

  Modified:             octave-3.8.0-imagemagick.patch
  Log:
  Fix bug 501768 QuantumRange was not declared in this scope when building =sci-mathematics/octave-3.8.0[imagemagick] when media-gfx/graphicsmagick[cxx] is installed. Thanks to Juergen Rose and Francois Bissey for reporting, Jouni Kosonen for testing.
  
  (Portage version: 2.2.8-r1/cvs/Linux x86_64, signed Manifest commit with key 618E971F)

Revision  Changes    Path
1.2                  sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch?rev=1.2&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch?rev=1.2&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch?r1=1.1&r2=1.2

Index: octave-3.8.0-imagemagick.patch
===================================================================
RCS file: /var/cvsroot/gentoo-x86/sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- octave-3.8.0-imagemagick.patch	19 Feb 2014 00:52:33 -0000	1.1
+++ octave-3.8.0-imagemagick.patch	20 Feb 2014 03:05:51 -0000	1.2
@@ -1,15 +1,23 @@
 --- octave-3.8.0-orig/libinterp/dldfcn/__magick_read__.cc	2013-12-28 08:57:41.000000000 +1100
-+++ octave-3.8.0/libinterp/dldfcn/__magick_read__.cc	2014-02-15 00:12:10.909254448 +1100
-@@ -38,7 +38,7 @@
++++ octave-3.8.0/libinterp/dldfcn/__magick_read__.cc	2014-02-20 13:40:54.981809963 +1100
+@@ -38,8 +38,15 @@
  #include "gripes.h"
  
  #ifdef HAVE_MAGICK
 -
 +#define MAGICKCORE_EXCLUDE_DEPRECATED 1
  #include <Magick++.h>
++#if !defined(QuantumRange) && defined(MaxRGB)
++#define QuantumRange MaxRGB
++#endif
++#if !defined(MAGICKCORE_QUANTUM_DEPTH) && defined(QuantumDepth)
++#define MAGICKCORE_QUANTUM_DEPTH QuantumDepth
++#endif
++
  #include <clocale>
  
-@@ -332,7 +332,10 @@
+ // In theory, it should be enough to check the class:
+@@ -332,7 +339,10 @@
    if (imvec[def_elem].depth () == 32)
      divisor = std::numeric_limits<uint32_t>::max ();
    else
@@ -21,7 +29,7 @@
  
    // FIXME: this workaround should probably be fixed in GM by creating a
    //        new ImageType BilevelMatteType
-@@ -463,7 +466,8 @@
+@@ -463,7 +473,8 @@
                  for (octave_idx_type row = 0; row < nRows; row++)
                    {
                      img_fvec[idx] = pix->red / divisor;
@@ -31,7 +39,7 @@
                      pix += row_shift;
                      idx++;
                    }
-@@ -538,7 +542,8 @@
+@@ -538,7 +549,8 @@
                      rbuf[idx]     = pix->red     / divisor;
                      gbuf[idx]     = pix->green   / divisor;
                      bbuf[idx]     = pix->blue    / divisor;
@@ -41,7 +49,7 @@
                      pix += row_shift;
                      idx++;
                    }
-@@ -620,7 +625,8 @@
+@@ -620,7 +632,8 @@
                      mbuf[idx]     = pix->green   / divisor;
                      ybuf[idx]     = pix->blue    / divisor;
                      kbuf[idx]     = pix->opacity / divisor;
@@ -51,7 +59,7 @@
                      pix += row_shift;
                      idx++;
                    }
-@@ -678,9 +684,10 @@
+@@ -678,9 +691,10 @@
        // Restore locale from before GraphicsMagick initialisation
        setlocale (LC_ALL, locale.c_str ());
  
@@ -64,7 +72,7 @@
  
        initialized = true;
      }
-@@ -1053,8 +1060,9 @@
+@@ -1053,8 +1067,9 @@
    // From GM documentation:
    //  Color arguments are must be scaled to fit the Quantum size according to
    //  the range of MaxRGB
@@ -75,7 +83,7 @@
  
    const P *img_fvec = img.fortran_vec ();
    const P *a_fvec   = alpha.fortran_vec ();
-@@ -1105,7 +1113,8 @@
+@@ -1105,7 +1120,8 @@
                    {
                      Magick::Color c;
                      c.redQuantum   (double (*img_fvec) / divisor);
@@ -85,7 +93,7 @@
                      pix[GM_idx] = c;
                      img_fvec++;
                      a_fvec++;
-@@ -1170,10 +1179,11 @@
+@@ -1170,10 +1186,11 @@
                {
                  for (octave_idx_type row = 0; row < nRows; row++)
                    {
@@ -98,7 +106,7 @@
                      pix[GM_idx] = c;
                      img_fvec++;
                      a_fvec++;
-@@ -1247,7 +1257,8 @@
+@@ -1247,7 +1264,8 @@
                                       double (img_fvec[Y_offset]) / divisor,
                                       double (img_fvec[K_offset]) / divisor);
                      pix[GM_idx] = c;





^ permalink raw reply	[flat|nested] 2+ messages in thread
* [gentoo-commits] gentoo-x86 commit in sci-mathematics/octave/files: octave-3.8.0-imagemagick.patch
@ 2014-02-20  8:50 Mark Wright (gienah)
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Wright (gienah) @ 2014-02-20  8:50 UTC (permalink / raw
  To: gentoo-commits

gienah      14/02/20 08:50:37

  Modified:             octave-3.8.0-imagemagick.patch
  Log:
  Fix bug Bug 496650 - sci-mathematics/octave should depend on dev-texlive/texlive-metapost - dvips: ! Couldn't find header file: groff.enc, thanks to Jan Hrabe for reporting. Tweak the octave-3.8.0 iamgemagick patch to fix the compile with media-gfx/imagemagick-6.7.8.7 and media-gfx/imagemagick-6.8.6.8.
  
  (Portage version: 2.2.8-r1/cvs/Linux x86_64, signed Manifest commit with key 618E971F)

Revision  Changes    Path
1.3                  sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch?rev=1.3&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch?rev=1.3&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch?r1=1.2&r2=1.3

Index: octave-3.8.0-imagemagick.patch
===================================================================
RCS file: /var/cvsroot/gentoo-x86/sci-mathematics/octave/files/octave-3.8.0-imagemagick.patch,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- octave-3.8.0-imagemagick.patch	20 Feb 2014 03:05:51 -0000	1.2
+++ octave-3.8.0-imagemagick.patch	20 Feb 2014 08:50:37 -0000	1.3
@@ -1,5 +1,5 @@
 --- octave-3.8.0-orig/libinterp/dldfcn/__magick_read__.cc	2013-12-28 08:57:41.000000000 +1100
-+++ octave-3.8.0/libinterp/dldfcn/__magick_read__.cc	2014-02-20 13:40:54.981809963 +1100
++++ octave-3.8.0/libinterp/dldfcn/__magick_read__.cc	2014-02-20 18:01:35.603737907 +1100
 @@ -38,8 +38,15 @@
  #include "gripes.h"
  
@@ -17,7 +17,26 @@
  #include <clocale>
  
  // In theory, it should be enough to check the class:
-@@ -332,7 +339,10 @@
+@@ -104,12 +111,18 @@
+ get_depth (Magick::Image& img)
+ {
+   octave_idx_type depth = img.depth ();
++#if defined(MagickLibVersion) && (MagickLibVersion <= 0x686)
++#define Magick MagickCore
++#endif
+   if (depth == 8
+       && img.channelDepth (Magick::RedChannel)     == 1
+       && img.channelDepth (Magick::CyanChannel)    == 1
+       && img.channelDepth (Magick::OpacityChannel) == 1
+       && img.channelDepth (Magick::GrayChannel)    == 1)
+     depth = 1;
++#if defined(MagickLibVersion) && (MagickLibVersion <= 0x686)
++#undef Magick
++#endif
+ 
+   return depth;
+ }
+@@ -332,7 +345,10 @@
    if (imvec[def_elem].depth () == 32)
      divisor = std::numeric_limits<uint32_t>::max ();
    else
@@ -29,7 +48,7 @@
  
    // FIXME: this workaround should probably be fixed in GM by creating a
    //        new ImageType BilevelMatteType
-@@ -463,7 +473,8 @@
+@@ -463,7 +479,8 @@
                  for (octave_idx_type row = 0; row < nRows; row++)
                    {
                      img_fvec[idx] = pix->red / divisor;
@@ -39,7 +58,7 @@
                      pix += row_shift;
                      idx++;
                    }
-@@ -538,7 +549,8 @@
+@@ -538,7 +555,8 @@
                      rbuf[idx]     = pix->red     / divisor;
                      gbuf[idx]     = pix->green   / divisor;
                      bbuf[idx]     = pix->blue    / divisor;
@@ -49,7 +68,7 @@
                      pix += row_shift;
                      idx++;
                    }
-@@ -620,7 +632,8 @@
+@@ -620,7 +638,8 @@
                      mbuf[idx]     = pix->green   / divisor;
                      ybuf[idx]     = pix->blue    / divisor;
                      kbuf[idx]     = pix->opacity / divisor;
@@ -59,7 +78,7 @@
                      pix += row_shift;
                      idx++;
                    }
-@@ -678,9 +691,10 @@
+@@ -678,9 +697,10 @@
        // Restore locale from before GraphicsMagick initialisation
        setlocale (LC_ALL, locale.c_str ());
  
@@ -72,7 +91,7 @@
  
        initialized = true;
      }
-@@ -1053,8 +1067,9 @@
+@@ -1053,8 +1073,9 @@
    // From GM documentation:
    //  Color arguments are must be scaled to fit the Quantum size according to
    //  the range of MaxRGB
@@ -83,7 +102,7 @@
  
    const P *img_fvec = img.fortran_vec ();
    const P *a_fvec   = alpha.fortran_vec ();
-@@ -1105,7 +1120,8 @@
+@@ -1105,7 +1126,8 @@
                    {
                      Magick::Color c;
                      c.redQuantum   (double (*img_fvec) / divisor);
@@ -93,7 +112,7 @@
                      pix[GM_idx] = c;
                      img_fvec++;
                      a_fvec++;
-@@ -1170,10 +1186,11 @@
+@@ -1170,10 +1192,11 @@
                {
                  for (octave_idx_type row = 0; row < nRows; row++)
                    {
@@ -106,7 +125,7 @@
                      pix[GM_idx] = c;
                      img_fvec++;
                      a_fvec++;
-@@ -1247,7 +1264,8 @@
+@@ -1247,7 +1270,8 @@
                                       double (img_fvec[Y_offset]) / divisor,
                                       double (img_fvec[K_offset]) / divisor);
                      pix[GM_idx] = c;





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

end of thread, other threads:[~2014-02-20  8:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-20  3:05 [gentoo-commits] gentoo-x86 commit in sci-mathematics/octave/files: octave-3.8.0-imagemagick.patch Mark Wright (gienah)
  -- strict thread matches above, loose matches on Subject: below --
2014-02-20  8:50 Mark Wright (gienah)

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