[76664] trunk/dports/graphics/MyPaint

ryandesign at macports.org ryandesign at macports.org
Fri Mar 4 14:11:53 PST 2011


Revision: 76664
          http://trac.macports.org/changeset/76664
Author:   ryandesign at macports.org
Date:     2011-03-04 14:11:53 -0800 (Fri, 04 Mar 2011)
Log Message:
-----------
MyPaint: update to 0.9.1

Modified Paths:
--------------
    trunk/dports/graphics/MyPaint/Portfile
    trunk/dports/graphics/MyPaint/files/patch-SConstruct.diff

Removed Paths:
-------------
    trunk/dports/graphics/MyPaint/files/patch-MyPaint.diff

Modified: trunk/dports/graphics/MyPaint/Portfile
===================================================================
--- trunk/dports/graphics/MyPaint/Portfile	2011-03-04 20:04:48 UTC (rev 76663)
+++ trunk/dports/graphics/MyPaint/Portfile	2011-03-04 22:11:53 UTC (rev 76664)
@@ -5,8 +5,7 @@
 
 name                        MyPaint
 set my_name                 mypaint
-version                     0.9.0
-revision                    2
+version                     0.9.1
 homepage                    http://mypaint.info/
 categories                  graphics
 maintainers                 ryandesign
@@ -25,22 +24,26 @@
 
 master_sites                http://download.gna.org/mypaint/
 
-checksums                   sha1    6c733a1bc87e237be18389aefb26a034b1229d24 \
-                            rmd160  07c83e5012400b9931a03bb750bf3f97da73bbd3
+checksums                   sha1    b2fe2e311619a4c4815cd698abd41e99b6692b43 \
+                            rmd160  16bd0492b567822b5ea4d6e3153e73436828a728
 
 depends_build               port:pkgconfig \
                             port:scons \
                             port:swig-python
 
 depends_lib                 port:protobuf-python26 \
+                            port:libpng \
                             port:py26-numpy \
                             port:py26-gtk
 
 depends_run                 port:tango-icon-theme
 
-patchfiles                  patch-SConstruct.diff \
-                            patch-MyPaint.diff
+patchfiles                  patch-SConstruct.diff
 
+post-patch {
+    reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/SConstruct
+}
+
 use_configure               no
 
 build.cmd                   scons

Deleted: trunk/dports/graphics/MyPaint/files/patch-MyPaint.diff
===================================================================
--- trunk/dports/graphics/MyPaint/files/patch-MyPaint.diff	2011-03-04 20:04:48 UTC (rev 76663)
+++ trunk/dports/graphics/MyPaint/files/patch-MyPaint.diff	2011-03-04 22:11:53 UTC (rev 76664)
@@ -1,74 +0,0 @@
---- lib/colorchanger.hpp
-+++ lib/colorchanger.hpp
-@@ -7,10 +7,10 @@
-  * (at your option) any later version.
-  */
- 
-+const int size = 256;
-+
- class ColorChanger {
- public:
--  static const int size = 256;
--
-   float brush_h, brush_s, brush_v;
-   void set_brush_color(float h, float s, float v)
-   {
---- lib/colorring.hpp
-+++ lib/colorring.hpp
-@@ -10,10 +10,18 @@
- #include <cmath> // atan2, sqrt or hypot
- #include "helpers2.hpp"
- 
-+const int colorring_size = 256; // diameter of Swiss Cheese Wheel Color Selector(TM)
-+const int center = (colorring_size/2); // radii/center coordinate of SCWCS
-+
-+// Frequently used constants
-+const float RAD_TO_ONE = 0.5f/M_PI;
-+const float TWO_PI = 2.0f*M_PI;
-+// Calculate these as precise as the hosting system can once and for all
-+const float ONE_OVER_THREE = 1.0f/3.0f;
-+const float TWO_OVER_THREE = 2.0f/3.0f;
-+  
- class SCWSColorSelector {
- public:
--  static const int size = 256; // diameter of Swiss Cheese Wheel Color Selector(TM)
--  static const int center = (size/2); // radii/center coordinate of SCWCS
- 
-   /*
-     --------- Swiss Cheese Wheel Color Selector(TM) --------- 
-@@ -25,13 +33,6 @@
-     
-   */
-   
--  // Frequently used constants
--  static const float RAD_TO_ONE = 0.5f/M_PI;
--  static const float TWO_PI = 2.0f*M_PI;
--  // Calculate these as precise as the hosting system can once and for all
--  static const float ONE_OVER_THREE = 1.0f/3.0f;
--  static const float TWO_OVER_THREE = 2.0f/3.0f;
--  
-   float brush_h, brush_s, brush_v;
-   void set_brush_color(float h, float s, float v)
-   {
-@@ -127,8 +128,8 @@
-   {
-     assert(PyArray_ISCARRAY(arr));
-     assert(PyArray_NDIM(arr) == 3);
--    assert(PyArray_DIM(arr, 0) == size);
--    assert(PyArray_DIM(arr, 1) == size);
-+    assert(PyArray_DIM(arr, 0) == colorring_size);
-+    assert(PyArray_DIM(arr, 1) == colorring_size);
-     assert(PyArray_DIM(arr, 2) == 4);  // memory width of pixel data ( 3 = RGB, 4 = RGBA )
-     guchar* pixels = (guchar*)((PyArrayObject*)arr)->data;
-   
-@@ -138,8 +139,8 @@
-   
-     float ofs_h = ((brush_h+ONE_OVER_THREE)>1.0f)?(brush_h-TWO_OVER_THREE):(brush_h+ONE_OVER_THREE); // offset hue
- 
--    for(float y=0; y<size; y++) {
--      for(float x=0; x<size; x++) {
-+    for(float y=0; y<colorring_size; y++) {
-+      for(float x=0; x<colorring_size; x++) {
-         get_hsva_at(&h, &s, &v, &a, x, y, false, false, ofs_h);
-         hsv_to_rgb_range_one(&h,&s,&v); // convert from HSV [0,1] to RGB [0,255]
-         pixels[0] = h; pixels[1] = s; pixels[2] = v; pixels[3] = a;

Modified: trunk/dports/graphics/MyPaint/files/patch-SConstruct.diff
===================================================================
--- trunk/dports/graphics/MyPaint/files/patch-SConstruct.diff	2011-03-04 20:04:48 UTC (rev 76663)
+++ trunk/dports/graphics/MyPaint/files/patch-SConstruct.diff	2011-03-04 22:11:53 UTC (rev 76664)
@@ -1,9 +1,21 @@
---- SConstruct.orig	2010-10-30 14:27:59.000000000 -0500
-+++ SConstruct	2010-11-07 16:59:43.000000000 -0600
-@@ -44,9 +44,6 @@
- if sys.platform == "win32":
-     env.ParseConfig('pkg-config --cflags --libs python25') # These two '.pc' files you probably have to make for yourself.
-     env.ParseConfig('pkg-config --cflags --libs numpy')    # Place them among the other '.pc' files ( where the 'glib-2.0.pc' is located .. probably )
+--- SConstruct.orig	2011-03-04 08:44:59.000000000 -0600
++++ SConstruct	2011-03-04 16:04:30.000000000 -0600
+@@ -20,10 +20,7 @@
+ 
+ SConsignFile() # no .scsonsign into $PREFIX please
+ 
+-if sys.platform == "darwin":
+-    default_prefix = '/opt/local/'
+-else:
+-    default_prefix = '/usr/local/'
++default_prefix = '@PREFIX@/'
+ 
+ opts = Variables()
+ opts.Add(PathVariable('prefix', 'autotools-style installation prefix', default_prefix, validator=PathVariable.PathIsDirCreate))
+@@ -50,9 +47,6 @@
+     from distutils import sysconfig
+     pre,inc = sysconfig.get_config_vars('exec_prefix', 'INCLUDEPY')
+     env.Append(CPPPATH=inc, LIBPATH=pre+'\libs', LIBS='python'+sys.version[0]+sys.version[2])
 -elif sys.platform == "darwin":
 -    env.ParseConfig('python-config --cflags')
 -    env.ParseConfig('python-config --ldflags')
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20110304/1a479e24/attachment.html>


More information about the macports-changes mailing list