author | jjg |
Tue, 09 Jan 2018 17:03:39 -0800 | |
changeset 48503 | 2e5226ca1329 |
parent 47507 | 5a270d2dfa5d |
permissions | -rw-r--r-- |
47507
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
1 |
# |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
2 |
# Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
4 |
# |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
5 |
# This code is free software; you can redistribute it and/or modify it |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
7 |
# published by the Free Software Foundation. Oracle designates this |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
8 |
# particular file as subject to the "Classpath" exception as provided |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
9 |
# by Oracle in the LICENSE file that accompanied this code. |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
10 |
# |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
11 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
12 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
14 |
# version 2 for more details (a copy is included in the LICENSE file that |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
15 |
# accompanied this code). |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
16 |
# |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
17 |
# You should have received a copy of the GNU General Public License version |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
18 |
# 2 along with this work; if not, write to the Free Software Foundation, |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
19 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
20 |
# |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
21 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
22 |
# or visit www.oracle.com if you need additional information or have any |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
23 |
# questions. |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
24 |
# |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
25 |
|
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
26 |
################################################################################ |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
27 |
# Setup fontconfig |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
28 |
################################################################################ |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
29 |
AC_DEFUN_ONCE([LIB_SETUP_FONTCONFIG], |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
30 |
[ |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
31 |
AC_ARG_WITH(fontconfig, [AS_HELP_STRING([--with-fontconfig], |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
32 |
[specify prefix directory for the fontconfig package |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
33 |
(expecting the headers under PATH/include)])]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
34 |
AC_ARG_WITH(fontconfig-include, [AS_HELP_STRING([--with-fontconfig-include], |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
35 |
[specify directory for the fontconfig include files])]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
36 |
|
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
37 |
if test "x$NEEDS_LIB_FONTCONFIG" = xfalse; then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
38 |
if (test "x${with_fontconfig}" != x && test "x${with_fontconfig}" != xno) || \ |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
39 |
(test "x${with_fontconfig_include}" != x && test "x${with_fontconfig_include}" != xno); then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
40 |
AC_MSG_WARN([[fontconfig not used, so --with-fontconfig[-*] is ignored]]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
41 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
42 |
FONTCONFIG_CFLAGS= |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
43 |
else |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
44 |
FONTCONFIG_FOUND=no |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
45 |
|
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
46 |
if test "x${with_fontconfig}" = xno || test "x${with_fontconfig_include}" = xno; then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
47 |
AC_MSG_ERROR([It is not possible to disable the use of fontconfig. Remove the --without-fontconfig option.]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
48 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
49 |
|
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
50 |
if test "x${with_fontconfig}" != x; then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
51 |
AC_MSG_CHECKING([for fontconfig headers]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
52 |
if test -s "${with_fontconfig}/include/fontconfig/fontconfig.h"; then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
53 |
FONTCONFIG_CFLAGS="-I${with_fontconfig}/include" |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
54 |
FONTCONFIG_FOUND=yes |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
55 |
AC_MSG_RESULT([$FONTCONFIG_FOUND]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
56 |
else |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
57 |
AC_MSG_ERROR([Can't find 'include/fontconfig/fontconfig.h' under ${with_fontconfig} given with the --with-fontconfig option.]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
58 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
59 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
60 |
if test "x${with_fontconfig_include}" != x; then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
61 |
AC_MSG_CHECKING([for fontconfig headers]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
62 |
if test -s "${with_fontconfig_include}/fontconfig/fontconfig.h"; then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
63 |
FONTCONFIG_CFLAGS="-I${with_fontconfig_include}" |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
64 |
FONTCONFIG_FOUND=yes |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
65 |
AC_MSG_RESULT([$FONTCONFIG_FOUND]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
66 |
else |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
67 |
AC_MSG_ERROR([Can't find 'fontconfig/fontconfig.h' under ${with_fontconfig_include} given with the --with-fontconfig-include option.]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
68 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
69 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
70 |
if test "x$FONTCONFIG_FOUND" = xno; then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
71 |
# Are the fontconfig headers installed in the default /usr/include location? |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
72 |
AC_CHECK_HEADERS([fontconfig/fontconfig.h], [ |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
73 |
FONTCONFIG_FOUND=yes |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
74 |
FONTCONFIG_CFLAGS= |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
75 |
DEFAULT_FONTCONFIG=yes |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
76 |
]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
77 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
78 |
if test "x$FONTCONFIG_FOUND" = xno; then |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
79 |
HELP_MSG_MISSING_DEPENDENCY([fontconfig]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
80 |
AC_MSG_ERROR([Could not find fontconfig! $HELP_MSG ]) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
81 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
82 |
fi |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
83 |
|
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
84 |
AC_SUBST(FONTCONFIG_CFLAGS) |
5a270d2dfa5d
8170681: Remove fontconfig header files from JDK source tree
prr
parents:
diff
changeset
|
85 |
]) |