]> git.pld-linux.org Git - packages/openjdk9.git/blame - system-lcms.patch
adapterized
[packages/openjdk9.git] / system-lcms.patch
CommitLineData
991454fa
JK
1diff -durN -x '*.orig' jdk8u-jdk8u66-b02.orig/common/autoconf/libraries.m4 jdk8u-jdk8u66-b02/common/autoconf/libraries.m4
2--- jdk8u-jdk8u66-b02.orig/common/autoconf/libraries.m4 2015-09-18 13:16:52.000000000 +0200
3+++ jdk8u-jdk8u66-b02/common/autoconf/libraries.m4 2015-09-18 13:18:24.000000000 +0200
4@@ -666,6 +666,46 @@
5
6 ###############################################################################
7 #
8+ # Check for the lcms2 library
9+ #
10+
11+ AC_ARG_WITH(lcms, [AS_HELP_STRING([--with-lcms],
12+ [use lcms2 from build system or OpenJDK source (system, bundled) @<:@bundled@:>@])])
13+
14+ AC_CHECK_LIB(lcms2, cmsOpenProfileFromFile,
15+ [ LCMS_FOUND=yes ],
16+ [ LCMS_FOUND=no ])
17+
18+ AC_MSG_CHECKING([for which lcms to use])
19+
20+ DEFAULT_LCMS=bundled
21+
22+ #
23+ # If user didn't specify, use DEFAULT_LCMS
24+ #
25+ if test "x${with_lcms}" = "x"; then
26+ with_lcms=${DEFAULT_LCMS}
27+ fi
28+
29+ if test "x${with_lcms}" = "xbundled"; then
30+ USE_EXTERNAL_LCMS=false
31+ AC_MSG_RESULT([bundled])
32+ elif test "x${with_lcms}" = "xsystem"; then
33+ if test "x${LCMS_FOUND}" = "xyes"; then
34+ USE_EXTERNAL_LCMS=true
35+ AC_MSG_RESULT([system])
36+ else
37+ AC_MSG_RESULT([system not found])
38+ AC_MSG_ERROR([--with-lcms=system specified, but no lcms found!])
39+ fi
40+ else
41+ AC_MSG_ERROR([Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'])
42+ fi
43+
44+ AC_SUBST(USE_EXTERNAL_LCMS)
45+
46+ ###############################################################################
47+ #
48 # Check for the png library
49 #
50
51diff -durN -x '*.orig' jdk8u-jdk8u66-b02.orig/jdk/make/lib/Awt2dLibraries.gmk jdk8u-jdk8u66-b02/jdk/make/lib/Awt2dLibraries.gmk
52--- jdk8u-jdk8u66-b02.orig/jdk/make/lib/Awt2dLibraries.gmk 2015-09-18 13:16:52.000000000 +0200
53+++ jdk8u-jdk8u66-b02/jdk/make/lib/Awt2dLibraries.gmk 2015-09-18 13:18:24.000000000 +0200
54@@ -667,8 +667,8 @@
55 ##########################################################################################
56
57 # TODO: Update awt lib path when awt is converted
58-$(eval $(call SetupNativeCompilation,BUILD_LIBLCMS, \
59- LIBRARY := lcms, \
60+$(eval $(call SetupNativeCompilation,BUILD_LIBJAVALCMS, \
61+ LIBRARY := javalcms, \
62 OUTPUT_DIR := $(INSTALL_LIBRARIES_HERE), \
63 SRC := $(JDK_TOPDIR)/src/share/native/sun/java2d/cmm/lcms, \
64 LANG := C, \
65@@ -686,19 +686,19 @@
66 LDFLAGS_windows := $(WIN_AWT_LIB) $(WIN_JAVA_LIB), \
67 LDFLAGS_SUFFIX_solaris := -lawt -ljava -ljvm -lc, \
68 LDFLAGS_SUFFIX_macosx := $(LIBM) -lawt -ljava -ljvm, \
69- LDFLAGS_SUFFIX_linux := -lm -lawt -ljava -ljvm, \
70+ LDFLAGS_SUFFIX_linux := -lm -lawt -ljava -ljvm -llcms2, \
71 LDFLAGS_SUFFIX_aix := -lm -lawt -ljava -ljvm,\
72 VERSIONINFO_RESOURCE := $(JDK_TOPDIR)/src/windows/resource/version.rc, \
73 RC_FLAGS := $(RC_FLAGS) \
74- -D "JDK_FNAME=lcms.dll" \
75- -D "JDK_INTERNAL_NAME=lcms" \
76+ -D "JDK_FNAME=javalcms.dll" \
77+ -D "JDK_INTERNAL_NAME=javalcms" \
78 -D "JDK_FTYPE=0x2L", \
79- OBJECT_DIR := $(JDK_OUTPUTDIR)/objs/liblcms, \
80+ OBJECT_DIR := $(JDK_OUTPUTDIR)/objs/libjavalcms, \
81 DEBUG_SYMBOLS := $(DEBUG_ALL_BINARIES)))
82
83-BUILD_LIBRARIES += $(BUILD_LIBLCMS)
84+BUILD_LIBRARIES += $(BUILD_LIBJAVALCMS)
85
86-$(BUILD_LIBLCMS): $(BUILD_LIBAWT)
87+$(BUILD_LIBJAVALCMS): $(BUILD_LIBAWT)
88
89 ##########################################################################################
90
91diff -durN -x '*.orig' jdk8u-jdk8u66-b02.orig/jdk/src/share/classes/sun/java2d/cmm/lcms/LCMS.java jdk8u-jdk8u66-b02/jdk/src/share/classes/sun/java2d/cmm/lcms/LCMS.java
92--- jdk8u-jdk8u66-b02.orig/jdk/src/share/classes/sun/java2d/cmm/lcms/LCMS.java 2015-07-23 16:17:35.000000000 +0200
93+++ jdk8u-jdk8u66-b02/jdk/src/share/classes/sun/java2d/cmm/lcms/LCMS.java 2015-09-18 13:18:24.000000000 +0200
94@@ -207,7 +207,7 @@
95 * disposer frameworks
96 */
97 System.loadLibrary("awt");
98- System.loadLibrary("lcms");
99+ System.loadLibrary("javalcms");
100 return null;
101 }
102 });
This page took 0.043871 seconds and 4 git commands to generate.