summaryrefslogtreecommitdiff
path: root/main
diff options
context:
space:
mode:
authorRobin Watts <robin.watts@artifex.com>2011-04-01 18:00:12 +0000
committerRobin Watts <robin.watts@artifex.com>2011-04-01 18:00:12 +0000
commit50ecc84d5463bd013f794a9dd53254c2e295a85e (patch)
treed7bce1f060af15c61d37034fe6f2cc174b9d715e /main
parentb960ff15c895dbe5a7d6baf470ad8a12949ad054 (diff)
Initial import of LittleCMS v2.1 into the Ghostscript/GhostPDL
build, with simple integration. LittleCMS version 1 is still used by default, so no cluster differences expected. The version of little cms imported was taken from the lcms git repository, commit 314bc7201d340ab303b36a0ade2c37cf40b83a3b, and then a couple of small tweaks were applied: * lcms2 currently offers no way to get the input/output format for a transform, so I add 2 functions (cmsGetTransformInputFormat and cmsGetTransformOutputFormat) to do this. * lcms2 currently offers no easy way to redirect malloc/free operations away from it's internal implementation, so we add a define (LCMS_USER_ALLOC) to allow us to be able to define our own functions. This mirrors the work done in lcms1 by Michael, I believe. The choice of which version of lcms to build with is made by the WHICH_CMS define option in the makefile. Currently this is set to lcms by default, but can be changed to lcms2 to allow lcms2 to be used instead. To make this work, various small tweaks have been required. Firstly, we rename gsicc_littlecms.h to gsicc_cms.h, reflecting the fact that this is not littlecms specific - rather, it defines the interface that any cms would have to provide in order to work with Ghostscript/GhostPDL. Secondly, we rename gsicc_littlecms.c to gsicc_lcms.c to make the makefile macros easier. We add a gsicc_lcms2.c file (derived from copying and editing gsicc_lcms.c) that interfaces with lcms2. Currently lcms2 builds and appears to run without crashing, but gives differing results in some cases. This will need to be solved before we can swap over to using lcms2 by default. git-svn-id: http://svn.ghostscript.com/ghostscript/trunk@12340 a1074d23-0009-0410-80fe-cf8c14f379e6
Diffstat (limited to 'main')
-rw-r--r--main/pcl6_gcc.mak3
-rw-r--r--main/pcl6_msvc.mak5
2 files changed, 8 insertions, 0 deletions
diff --git a/main/pcl6_gcc.mak b/main/pcl6_gcc.mak
index 55ad9892a..d07d89a4c 100644
--- a/main/pcl6_gcc.mak
+++ b/main/pcl6_gcc.mak
@@ -58,6 +58,9 @@ SHARE_LIBPNG?=0
LCMSSRCDIR?=../gs/lcms
SHARE_LCMS?=0
+# Specify the location of lcms2
+LCMS2SRCDIR?=../gs/lcms2
+
# Specify the location of imdi
IMDISRCDIR?=../gs/imdi
diff --git a/main/pcl6_msvc.mak b/main/pcl6_msvc.mak
index 3707758b5..849864277 100644
--- a/main/pcl6_msvc.mak
+++ b/main/pcl6_msvc.mak
@@ -83,6 +83,11 @@ SHARE_LIBPNG=0
LCMSSRCDIR=..\gs\lcms
!endif
+# Specify the location of lcms2
+!ifndef LCMS2SRCDIR
+LCMS2SRCDIR=..\gs\lcms2
+!endif
+
# Specify the location of imdi
!ifndef IMDISRCDIR
IMDISRCDIR=..\gs\imdi