Bug 128522 - Patch for graphics/lcms to add python binding
Summary: Patch for graphics/lcms to add python binding
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Stanislav Sedov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-11-01 16:30 UTC by Sergei Golyashov
Modified: 2009-10-13 12:30 UTC (History)
0 users

See Also:


Attachments
file.diff (1.67 KB, patch)
2008-11-01 16:30 UTC, Sergei Golyashov
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sergei Golyashov 2008-11-01 16:30:08 UTC
Python binding present in lcms but not installed by port. This patch corrects the given omission.
Python binding for lcms is necessary for some programs. For example sK1.

Fix: Patch attached with submission follows:
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2008-11-01 16:30:21 UTC
Responsible Changed
From-To: freebsd-ports-bugs->stas

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Stanislav Sedov freebsd_committer freebsd_triage 2008-12-06 15:13:18 UTC
Hi!

I think python bindings should be added as a separate port -
it is the only way we can depend on these bindings properly.
Could you work on such port?

Also, some patches were requred in my system for bindings to
compiled, i. e.:
--- python/lcms_wrap.cxx.orig	2008-12-06 17:36:51.000000000 +0300
+++ python/lcms_wrap.cxx	2008-12-06 17:37:14.000000000 +0300
@@ -2915,7 +2915,7 @@
 {
   if (PyString_Check(obj)) {
     char *cstr; int len;
-    PyString_AsStringAndSize(obj, &cstr, &len);
+    PyString_AsStringAndSize(obj, &cstr, (Py_ssize_t*)&len);
     if (cptr)  {
       if (alloc) {
 	/* 

and

--- python/Makefile.in.orig	2008-12-06 17:52:25.000000000 +0300
+++ python/Makefile.in	2008-12-06 17:52:52.000000000 +0300
@@ -157,7 +157,7 @@
 PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@
 PYTHON_PLATFORM = @PYTHON_PLATFORM@
 PYTHON_PREFIX = @PYTHON_PREFIX@
-PYTHON_VERSION = @PYTHON_VERSION@
+PYTH_VERSION = @PYTHON_VERSION@
 RANLIB = @RANLIB@
 SED = @SED@
 SET_MAKE = @SET_MAKE@
@@ -243,9 +243,9 @@
 _lcms_la_LDFLAGS = -no-undefined -module -avoid-version \
                     -L$(LCMS_PYLIB)/config 
 
-_lcms_la_LIBADD = $(top_builddir)/src/liblcms.la -lpython$(PYTHON_VERSION)
+_lcms_la_LIBADD = $(top_builddir)/src/liblcms.la -lpython$(PYTH_VERSION)
 _lcms_la_SOURCES = lcms_wrap.cxx
-_lcms_la_CPPFLAGS = -I$(PYTHON_PREFIX)/include/python$(PYTHON_VERSION) \
+_lcms_la_CPPFLAGS = -I$(PYTHON_PREFIX)/include/python$(PYTH_VERSION) \
 		    -I$(LCMS_PYINCLUDE) \
                     $(AM_CPPFLAGS)

The last one is required for avoiding the bug in build system that replaces
PYTHON_VERSION  with python2.5 instead of plain 2.5 at some point.

-- 
Stanislav Sedov
ST4096-RIPE
Comment 3 Stanislav Sedov freebsd_committer freebsd_triage 2008-12-06 15:30:48 UTC
State Changed
From-To: open->feedback

Ask for submitter fix.
Comment 4 Sergei Golyashov 2008-12-19 05:50:11 UTC
> I think python bindings should be added as a separate port
I like this idea. To easier check dependences.
But I don't see as it is possible to make in lcms sources...
May be compile all package, but install only python binding...

Still I have noticed that sK1 works very unstably and at falling leaves
python.core that can specify in unstable work lcms binding =(

---
Regards,
Sergei Golyashov
Comment 5 Pav Lucistnik freebsd_committer freebsd_triage 2009-03-25 15:38:50 UTC
Any update on this one?

-- 
Pav Lucistnik <pav@oook.cz>
              <pav@FreeBSD.org>

End users have trouble keeping food off their keyboard and sorting
messages in Outlook.  Try explaining this problem to them.
Comment 6 dfilter service freebsd_committer freebsd_triage 2009-10-13 12:20:48 UTC
stas        2009-10-13 11:20:29 UTC

  FreeBSD ports repository

  Modified files:
    graphics             Makefile 
  Added files:
    graphics/lcms-python Makefile distinfo pkg-descr 
    graphics/lcms-python/files patch-icc34 
                               patch-python_Makefile.in 
                               patch-python_lcms_wrap.cxx 
  Log:
  - Add port for lcms python bindings.
  
  PR:             ports/128522
  Requested by:   Sergei Golyashov <svvord@spline-studio.ru>
  
  Revision  Changes    Path
  1.1284    +1 -0      ports/graphics/Makefile
  1.1       +40 -0     ports/graphics/lcms-python/Makefile (new)
  1.1       +3 -0      ports/graphics/lcms-python/distinfo (new)
  1.1       +14 -0     ports/graphics/lcms-python/files/patch-icc34 (new)
  1.1       +31 -0     ports/graphics/lcms-python/files/patch-python_Makefile.in (new)
  1.1       +11 -0     ports/graphics/lcms-python/files/patch-python_lcms_wrap.cxx (new)
  1.1       +12 -0     ports/graphics/lcms-python/pkg-descr (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 7 Stanislav Sedov freebsd_committer freebsd_triage 2009-10-13 12:22:20 UTC
State Changed
From-To: feedback->closed

The port added as graphics/lcms-python