Cristy | d842011 | 2021-01-01 14:52:00 -0500 | [diff] [blame] | 1 | # Copyright 1999-2021 ImageMagick Studio LLC, a non-profit organization |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2 | # dedicated to making software imaging solutions freely available. |
| 3 | # |
| 4 | # You may not use this file except in compliance with the License. You may |
| 5 | # obtain a copy of the License at |
| 6 | # |
Cristy | 1eccad3 | 2018-09-09 19:34:39 -0400 | [diff] [blame] | 7 | # https://imagemagick.org/script/license.php |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 8 | # |
| 9 | # Unless required by applicable law or agreed to in writing, software |
| 10 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | # See the License for the specific language governing permissions and |
| 13 | # limitations under the License. |
| 14 | # |
| 15 | # Copyright (C) 2003 - 2008 GraphicsMagick Group |
cristy | 568c2d4 | 2012-07-27 01:41:20 +0000 | [diff] [blame] | 16 | # |
| 17 | # Copying and distribution of this file, with or without modification, |
| 18 | # are permitted in any medium without royalty provided the copyright |
| 19 | # notice and this notice are preserved. |
cristy | c8051dc | 2012-08-20 23:50:31 +0000 | [diff] [blame] | 20 | AC_PREREQ(2.69) |
cristy | fddf775 | 2011-02-26 19:25:10 +0000 | [diff] [blame] | 21 | |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 22 | # ============================================================================== |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 23 | # Initialize Automake |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 24 | # ============================================================================== |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 25 | m4_include([m4/version.m4]) |
| 26 | m4_define([magick_base_version], |
| 27 | [magick_major_version.magick_minor_version.magick_micro_version]) |
cristy | fddf775 | 2011-02-26 19:25:10 +0000 | [diff] [blame] | 28 | m4_define([magick_version], |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 29 | [magick_base_version-magick_patchlevel_version]) |
| 30 | m4_define([magick_lib_version_number], |
| 31 | [magick_major_version,magick_minor_version,magick_micro_version,magick_patchlevel_version]) |
Cristy | ed7fd17 | 2019-12-07 10:52:28 -0500 | [diff] [blame] | 32 | m4_define([magick_git_revision], |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 33 | m4_esyscmd([ |
Cristy | ed7fd17 | 2019-12-07 10:52:28 -0500 | [diff] [blame] | 34 | c=$(git log --full-history --format=tformat:. HEAD | wc -l) |
| 35 | h=$(git rev-parse --short HEAD) |
| 36 | d=$(date +%Y%m%d) |
| 37 | printf %s "$c:$h:$d" |
| 38 | ])) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 39 | m4_define([magick_release_date], |
| 40 | m4_esyscmd([ |
| 41 | d=$(date +%F -r ./ChangeLog) |
| 42 | printf %s "$d" |
| 43 | ])) |
cristy | fddf775 | 2011-02-26 19:25:10 +0000 | [diff] [blame] | 44 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 45 | AC_INIT([magick_name], |
Cristy | 6720ed7 | 2016-02-09 09:27:35 -0500 | [diff] [blame] | 46 | [magick_version], |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 47 | [magick_bugreport], |
| 48 | [magick_tarname], |
| 49 | [magick_url]) |
| 50 | |
cristy | 4c08aed | 2011-07-01 19:47:50 +0000 | [diff] [blame] | 51 | AC_CONFIG_SRCDIR([MagickCore/MagickCore.h]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 52 | AC_CONFIG_AUX_DIR([config]) |
cristy | bc55645 | 2012-08-17 19:44:03 +0000 | [diff] [blame] | 53 | AC_REQUIRE_AUX_FILE([tap-driver.sh]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 54 | AC_CONFIG_MACRO_DIR([m4]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 55 | AC_CONFIG_HEADERS([config/config.h]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 56 | AX_PREFIX_CONFIG_H([MagickCore/magick-baseconfig.h],[MagickCore]) |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 57 | AC_CANONICAL_SYSTEM |
| 58 | AC_CANONICAL_TARGET |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 59 | |
| 60 | AM_INIT_AUTOMAKE([foreign no-define color-tests parallel-tests -Wall -Wno-portability subdir-objects dist-bzip2 dist-lzip dist-xz dist-zip tar-ustar]) |
| 61 | |
Cristy | 6720ed7 | 2016-02-09 09:27:35 -0500 | [diff] [blame] | 62 | AM_SILENT_RULES([yes]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 63 | AC_SUBST([CONFIGURE_DEPENDENCIES],["$CONFIGURE_DEPENDENCIES \$(top_srcdir)/ChangeLog \$(top_srcdir)/m4/version.m4"]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 64 | |
| 65 | # |
| 66 | # Save initial user-tunable values |
| 67 | # |
| 68 | USER_LIBS=$LIBS |
Cristy | ed7fd17 | 2019-12-07 10:52:28 -0500 | [diff] [blame] | 69 | for var in CC CFLAGS CPPFLAGS CXX CXXCPP LDFLAGS AR_FLAGS LIBS ; do |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 70 | eval isset=\${$var+set} |
| 71 | if test "$isset" = 'set'; then |
| 72 | eval val=$`echo $var` |
| 73 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS}'${var}=${val}' " |
| 74 | fi |
| 75 | done |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 76 | AC_SUBST([DISTCHECK_CONFIG_FLAGS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 77 | |
| 78 | CONFIGURE_ARGS="$0 ${ac_configure_args}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 79 | AC_SUBST([CONFIGURE_ARGS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 80 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 81 | echo "Configuring ${PACKAGE_NAME} ${PACKAGE_VERSION}" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 82 | |
cristy | 19615b8 | 2011-04-13 20:02:01 +0000 | [diff] [blame] | 83 | MAGICK_TARGET_CPU=$host_cpu |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 84 | AC_SUBST([MAGICK_TARGET_CPU]) |
| 85 | AC_DEFINE_UNQUOTED([MAGICK_TARGET_CPU],[$MAGICK_TARGET_CPU],[Target Host CPU]) |
cristy | 3225a07 | 2010-04-17 01:47:28 +0000 | [diff] [blame] | 86 | |
cristy | 19615b8 | 2011-04-13 20:02:01 +0000 | [diff] [blame] | 87 | MAGICK_TARGET_VENDOR=$host_vendor |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 88 | AC_SUBST([MAGICK_TARGET_VENDOR]) |
| 89 | AC_DEFINE_UNQUOTED([MAGICK_TARGET_VENDOR],[$MAGICK_TARGET_VENDOR],[Target Host Vendor]) |
cristy | 3225a07 | 2010-04-17 01:47:28 +0000 | [diff] [blame] | 90 | |
cristy | 19615b8 | 2011-04-13 20:02:01 +0000 | [diff] [blame] | 91 | MAGICK_TARGET_OS=$host_os |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 92 | AC_SUBST([MAGICK_TARGET_OS]) |
| 93 | AC_DEFINE_UNQUOTED([MAGICK_TARGET_OS],[$MAGICK_TARGET_OS],[Target Host OS]) |
cristy | 3225a07 | 2010-04-17 01:47:28 +0000 | [diff] [blame] | 94 | |
cristy | 3744276 | 2013-02-10 21:07:23 +0000 | [diff] [blame] | 95 | |
| 96 | # Substitute versioning |
| 97 | AC_SUBST([MAGICK_MAJOR_VERSION],[magick_major_version]) |
| 98 | AC_SUBST([MAGICK_MINOR_VERSION],[magick_minor_version]) |
| 99 | AC_SUBST([MAGICK_MICRO_VERSION],[magick_micro_version]) |
| 100 | AC_SUBST([MAGICK_PATCHLEVEL_VERSION],[magick_patchlevel_version]) |
| 101 | AC_SUBST([MAGICK_VERSION],[magick_version]) |
Cristy | fbb8d80 | 2015-09-02 11:41:34 -0400 | [diff] [blame] | 102 | AC_SUBST([MAGICK_GIT_REVISION],[magick_git_revision]) |
cristy | 3744276 | 2013-02-10 21:07:23 +0000 | [diff] [blame] | 103 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 104 | # Substitute library versioning |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 105 | AC_SUBST([MAGICK_LIBRARY_CURRENT],[magick_library_current])dnl |
| 106 | AC_SUBST([MAGICK_LIBRARY_REVISION],[magick_library_revision])dnl |
| 107 | AC_SUBST([MAGICK_LIBRARY_AGE],[magick_library_age])dnl |
cristy | bab87c3 | 2010-02-09 20:54:22 +0000 | [diff] [blame] | 108 | AC_SUBST([MAGICK_LIBRARY_CURRENT_MIN], |
| 109 | [`expr $MAGICK_LIBRARY_CURRENT - $MAGICK_LIBRARY_AGE`]) |
| 110 | AC_SUBST([MAGICK_LIBRARY_VERSION_INFO], |
| 111 | [$MAGICK_LIBRARY_CURRENT:$MAGICK_LIBRARY_REVISION:$MAGICK_LIBRARY_AGE]) |
cristy | 3744276 | 2013-02-10 21:07:23 +0000 | [diff] [blame] | 112 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 113 | AC_SUBST([MAGICKPP_LIBRARY_CURRENT],[magickpp_library_current])dnl |
| 114 | AC_SUBST([MAGICKPP_LIBRARY_REVISION],[magickpp_library_revision])dnl |
| 115 | AC_SUBST([MAGICKPP_LIBRARY_AGE],[magickpp_library_age])dnl |
cristy | 5ed9c6e | 2013-07-14 21:20:31 +0000 | [diff] [blame] | 116 | AC_SUBST([MAGICKPP_LIBRARY_CURRENT_MIN], |
| 117 | [`expr $MAGICKPP_LIBRARY_CURRENT - $MAGICKPP_LIBRARY_AGE`]) |
| 118 | AC_SUBST([MAGICKPP_LIBRARY_VERSION_INFO], |
| 119 | [$MAGICKPP_LIBRARY_CURRENT:$MAGICKPP_LIBRARY_REVISION:$MAGICKPP_LIBRARY_AGE]) |
| 120 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 121 | AC_SUBST([PACKAGE_BASE_VERSION],[magick_base_version]) |
| 122 | AC_SUBST([PACKAGE_PATCHLEVEL_VERSION],[magick_patchlevel_version]) |
| 123 | AC_SUBST([PACKAGE_VERSION_ADDENDUM],[-magick_patchlevel_version]) |
| 124 | AC_SUBST([PACKAGE_LIB_VERSION],[magick_lib_version]) |
| 125 | AC_SUBST([PACKAGE_LIB_VERSION_NUMBER],[magick_lib_version_number]) |
| 126 | AC_SUBST([PACKAGE_RELEASE_DATE],[magick_release_date]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 127 | |
| 128 | # Ensure that make can run correctly |
| 129 | AM_SANITY_CHECK |
| 130 | |
cristy | f279b69 | 2014-08-13 12:01:27 +0000 | [diff] [blame] | 131 | # versioning of library |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 132 | MAGICK_LIB_VERSION="0x" |
| 133 | if test ${MAGICK_LIBRARY_CURRENT} -lt 10 ; then |
| 134 | MAGICK_LIB_VERSION=${MAGICK_LIB_VERSION}0 |
| 135 | fi |
| 136 | MAGICK_LIB_VERSION=${MAGICK_LIB_VERSION}${MAGICK_LIBRARY_CURRENT} |
| 137 | if test ${MAGICK_LIBRARY_AGE} -lt 10 ; then |
| 138 | MAGICK_LIB_VERSION=${MAGICK_LIB_VERSION}0 |
| 139 | fi |
| 140 | MAGICK_LIB_VERSION=${MAGICK_LIB_VERSION}${MAGICK_LIBRARY_AGE} |
| 141 | if test ${MAGICK_LIBRARY_REVISION} -lt 10 ; then |
| 142 | MAGICK_LIB_VERSION=${MAGICK_LIB_VERSION}0 |
| 143 | fi |
| 144 | MAGICK_LIB_VERSION=${MAGICK_LIB_VERSION}${MAGICK_LIBRARY_REVISION} |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 145 | AC_SUBST([MAGICK_LIB_VERSION]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 146 | |
| 147 | # Definition used to define MagickLibVersionText in version.h |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 148 | MAGICK_LIB_VERSION_TEXT="${PACKAGE_BASE_VERSION}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 149 | AC_SUBST([MAGICK_LIB_VERSION_TEXT]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 150 | |
| 151 | # Definition used to define MagickLibVersionNumber in version.h |
| 152 | MAGICK_LIB_VERSION_NUMBER="${MAGICK_LIBRARY_CURRENT},${MAGICK_LIBRARY_AGE},${MAGICK_LIBRARY_REVISION}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 153 | AC_SUBST([MAGICK_LIB_VERSION_NUMBER]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 154 | |
cristy | 5ed9c6e | 2013-07-14 21:20:31 +0000 | [diff] [blame] | 155 | MAGICKPP_LIB_VERSION="0x" |
| 156 | if test ${MAGICKPP_LIBRARY_CURRENT} -lt 10 ; then |
| 157 | MAGICKPP_LIB_VERSION=${MAGICKPP_LIB_VERSION}0 |
| 158 | fi |
| 159 | MAGICKPP_LIB_VERSION=${MAGICKPP_LIB_VERSION}${MAGICKPP_LIBRARY_CURRENT} |
| 160 | if test ${MAGICKPP_LIBRARY_AGE} -lt 10 ; then |
| 161 | MAGICKPP_LIB_VERSION=${MAGICKPP_LIB_VERSION}0 |
| 162 | fi |
| 163 | MAGICKPP_LIB_VERSION=${MAGICKPP_LIB_VERSION}${MAGICKPP_LIBRARY_AGE} |
| 164 | if test ${MAGICKPP_LIBRARY_REVISION} -lt 10 ; then |
| 165 | MAGICKPP_LIB_VERSION=${MAGICKPP_LIB_VERSION}0 |
| 166 | fi |
| 167 | MAGICKPP_LIB_VERSION=${MAGICKPP_LIB_VERSION}${MAGICKPP_LIBRARY_REVISION} |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 168 | AC_SUBST([MAGICKPP_LIB_VERSION]) |
cristy | 5ed9c6e | 2013-07-14 21:20:31 +0000 | [diff] [blame] | 169 | |
| 170 | # Definition used to define MagickLibVersionText in version.h |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 171 | MAGICKPP_LIB_VERSION_TEXT="${PACKAGE_BASE_VERSION}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 172 | AC_SUBST([MAGICKPP_LIB_VERSION_TEXT]) |
cristy | 5ed9c6e | 2013-07-14 21:20:31 +0000 | [diff] [blame] | 173 | |
| 174 | # Definition used to define MagickLibVersionNumber in version.h |
| 175 | MAGICK_LIB_VERSION_NUMBER="${MAGICK_LIBRARY_CURRENT},${MAGICK_LIBRARY_AGE},${MAGICK_LIBRARY_REVISION}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 176 | AC_SUBST([MAGICK_LIB_VERSION_NUMBER]) |
cristy | 5ed9c6e | 2013-07-14 21:20:31 +0000 | [diff] [blame] | 177 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 178 | PERLMAINCC=$CC |
| 179 | |
| 180 | MAGICK_CFLAGS='' |
| 181 | MAGICK_CPPFLAGS=$CPPFLAGS_USER |
| 182 | MAGICK_PCFLAGS=$CPPFLAGS_USER |
| 183 | MAGICK_LDFLAGS='' |
| 184 | MAGICK_LIBS='' |
cristy | fd9dcd4 | 2010-08-08 18:07:02 +0000 | [diff] [blame] | 185 | MAGICK_FEATURES='' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 186 | |
| 187 | # |
| 188 | # Evaluate shell variable equivalents to Makefile directory variables |
| 189 | # |
| 190 | if test "x$prefix" = xNONE; then |
| 191 | prefix=$ac_default_prefix |
| 192 | fi |
| 193 | # Let make expand exec_prefix. |
| 194 | if test "x$exec_prefix" = xNONE; then |
| 195 | exec_prefix='${prefix}' |
| 196 | fi |
| 197 | |
| 198 | # |
| 199 | eval "eval PREFIX_DIR=${prefix}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 200 | AC_SUBST([PREFIX_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 201 | eval "eval EXEC_PREFIX_DIR=${exec_prefix}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 202 | AC_SUBST([EXEC_PREFIX_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 203 | eval "eval BIN_DIR=$bindir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 204 | AC_SUBST([BIN_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 205 | eval "eval SBIN_DIR=$sbindir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 206 | AC_SUBST([SBIN_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 207 | eval "eval LIBEXEC_DIR=$libexecdir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 208 | AC_SUBST([LIBEXEC_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 209 | eval "eval DATA_DIR=$datadir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 210 | AC_SUBST([DATA_DIR]) |
Cristy | e35bdc6 | 2015-09-19 18:29:00 -0400 | [diff] [blame] | 211 | eval "eval DOC_DIR=$datadir/doc" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 212 | AC_SUBST([DOC_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 213 | eval "eval SYSCONF_DIR=$sysconfdir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 214 | AC_SUBST([SYSCONF_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 215 | eval "eval SHAREDSTATE_DIR=$sharedstatedir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 216 | AC_SUBST([SHAREDSTATE_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 217 | eval "eval LOCALSTATE_DIR=$localstatedir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 218 | AC_SUBST([LOCALSTATE_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 219 | eval "eval LIB_DIR=$libdir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 220 | AC_SUBST([LIB_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 221 | eval "eval INCLUDE_DIR=$includedir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 222 | AC_SUBST([INCLUDE_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 223 | eval "eval PERSISTINCLUDE_DIR=$oldincludedir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 224 | AC_SUBST([PERSISTINCLUDE_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 225 | eval "eval INFO_DIR=$infodir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 226 | AC_SUBST([INFO_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 227 | eval "eval MAN_DIR=$mandir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 228 | AC_SUBST([MAN_DIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 229 | |
| 230 | # Get full paths to source and build directories |
| 231 | srcdirfull="`cd $srcdir && pwd`" |
| 232 | builddir="`pwd`" |
| 233 | |
| 234 | # |
| 235 | # Compute variables useful for running uninstalled software. |
| 236 | # |
| 237 | MAGICK_CODER_MODULE_PATH="${builddir}/coders" |
| 238 | MAGICK_CONFIGURE_SRC_PATH="${srcdirfull}/config" |
| 239 | MAGICK_CONFIGURE_BUILD_PATH="${builddir}/config" |
| 240 | MAGICK_FILTER_MODULE_PATH="${builddir}/filters" |
| 241 | DIRSEP=':' |
| 242 | case "${build_os}" in |
| 243 | mingw* ) |
| 244 | MAGICK_CODER_MODULE_PATH=`$WinPathScript "${MAGICK_CODER_MODULE_PATH}" 0` |
| 245 | MAGICK_CONFIGURE_SRC_PATH=`$WinPathScript "${MAGICK_CONFIGURE_SRC_PATH}" 0` |
| 246 | MAGICK_CONFIGURE_BUILD_PATH=`$WinPathScript "${MAGICK_CONFIGURE_BUILD_PATH}" 0` |
| 247 | MAGICK_FILTER_MODULE_PATH=`$WinPathScript "${MAGICK_FILTER_MODULE_PATH}" 0` |
| 248 | DIRSEP=';' |
| 249 | ;; |
| 250 | esac |
| 251 | case "${host_os}" in |
| 252 | mingw* ) |
| 253 | DIRSEP=';' |
| 254 | ;; |
| 255 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 256 | AC_SUBST([MAGICK_CODER_MODULE_PATH]) |
| 257 | AC_SUBST([MAGICK_CONFIGURE_SRC_PATH]) |
| 258 | AC_SUBST([MAGICK_CONFIGURE_BUILD_PATH]) |
| 259 | AC_SUBST([MAGICK_FILTER_MODULE_PATH]) |
| 260 | AC_SUBST([DIRSEP]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 261 | |
cristy | a0b81c3 | 2010-01-22 02:54:33 +0000 | [diff] [blame] | 262 | |
| 263 | # |
| 264 | # Enable OS features. |
| 265 | # |
| 266 | AC_USE_SYSTEM_EXTENSIONS |
| 267 | |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 268 | # ============================================================================== |
| 269 | # Find required base packages |
| 270 | # ============================================================================== |
| 271 | m4_ifdef([AM_PROG_AR], [AM_PROG_AR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 272 | AC_PROG_CC |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 273 | AC_PROG_CPP |
| 274 | AC_PROG_LD |
Cristy | 1245273 | 2020-10-02 16:23:46 +0000 | [diff] [blame] | 275 | LT_PATH_LD |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 276 | AC_SUBST([LD]) |
cristy | 837d6dc | 2010-02-27 01:16:57 +0000 | [diff] [blame] | 277 | AC_PROG_CC_C99 |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 278 | AM_PROG_CC_C_O |
cristy | 92703d8 | 2010-04-26 00:18:18 +0000 | [diff] [blame] | 279 | AX_CFLAGS_WARN_ALL |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 280 | AC_PROG_INSTALL |
| 281 | AC_PROG_MAKE_SET |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 282 | AC_PROG_LN_S |
cristy | 8d0ff76 | 2013-03-10 20:33:28 +0000 | [diff] [blame] | 283 | AC_PROG_SED |
cristy | bc55645 | 2012-08-17 19:44:03 +0000 | [diff] [blame] | 284 | AC_PROG_AWK |
Cristy | b123ba3 | 2019-05-16 07:47:17 -0400 | [diff] [blame] | 285 | AC_PROG_MKDIR_P |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 286 | AC_PROG_RANLIB |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 287 | AM_WITH_DMALLOC |
cristy | 92703d8 | 2010-04-26 00:18:18 +0000 | [diff] [blame] | 288 | AX_C___ATTRIBUTE__ |
Cristy | 01043c6 | 2019-10-05 11:39:30 -0400 | [diff] [blame] | 289 | AX_GCC_ARCHFLAG([yes]) |
Cristy | 6720ed7 | 2016-02-09 09:27:35 -0500 | [diff] [blame] | 290 | PKG_PROG_PKG_CONFIG([0.20]) |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 291 | AC_CANONICAL_BUILD |
| 292 | AC_CANONICAL_HOST |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 293 | |
cristy | d95b7a5 | 2013-10-23 13:12:53 +0000 | [diff] [blame] | 294 | AX_COMPILER_VENDOR |
cristy | d95b7a5 | 2013-10-23 13:12:53 +0000 | [diff] [blame] | 295 | |
| 296 | if test "x$GCC" = "xyes"; then |
| 297 | CFLAGS="$CFLAGS -fexceptions" |
| 298 | touch local.exp |
| 299 | else |
| 300 | cat > local.exp <<EOF |
| 301 | set CC_FOR_TARGET "$CC" |
| 302 | EOF |
| 303 | fi |
| 304 | |
cristy | 496c090 | 2013-02-26 12:57:44 +0000 | [diff] [blame] | 305 | # Check for linker script support |
cristy | 9b86f20 | 2012-11-28 21:55:35 +0000 | [diff] [blame] | 306 | gl_LD_VERSION_SCRIPT |
| 307 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 308 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 309 | # Enable run-time checking. |
| 310 | # |
| 311 | AC_ARG_ENABLE([bounds-checking], |
cristy | a382469 | 2012-03-30 17:22:07 +0000 | [diff] [blame] | 312 | [AC_HELP_STRING([--enable-bounds-checking], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 313 | [enable run-time bounds-checking])], |
| 314 | [enable_bounds_checking=$enableval], |
| 315 | [enable_bounds_checking='no']) |
| 316 | |
| 317 | if test "$enable_bounds_checking" = yes; then |
| 318 | AC_DEFINE([_FORTIFY_SOURCE], [2], |
| 319 | [enable run-time bounds-checking]) |
| 320 | fi |
| 321 | |
| 322 | # |
| 323 | # Tests for Windows |
| 324 | # |
| 325 | AC_EXEEXT |
| 326 | AC_OBJEXT |
| 327 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 328 | native_win32_build='no' |
| 329 | cygwin_build='no' |
| 330 | case "${host_os}" in |
| 331 | cygwin* ) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 332 | cygwin_build='yes' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 333 | ;; |
| 334 | mingw* ) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 335 | native_win32_build='yes' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 336 | ;; |
| 337 | esac |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 338 | AM_CONDITIONAL([WIN32_NATIVE_BUILD],[test "${native_win32_build}" = 'yes']) |
| 339 | AM_CONDITIONAL([CYGWIN_BUILD],[test "${cygwin_build}" = 'yes']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 340 | |
| 341 | WinPathScript="${srcdirfull}/winpath.sh" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 342 | AC_SUBST([WinPathScript]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 343 | |
| 344 | # |
| 345 | # Compiler flags tweaks |
| 346 | # |
| 347 | if test "${GCC}" != "yes"; then |
| 348 | case "${host}" in |
| 349 | *-*-hpux* ) |
| 350 | # aCC: HP ANSI C++ B3910B A.03.34 |
| 351 | CFLAGS="${CFLAGS} -Wp,-H30000" |
| 352 | if test -n "${CXXFLAGS}"; then |
| 353 | CXXFLAGS='-AA' |
| 354 | else |
| 355 | CXXFLAGS="${CXXFLAGS} -AA" |
| 356 | fi |
| 357 | ;; |
| 358 | *-dec-osf5.* ) |
| 359 | # Compaq alphaev68-dec-osf5.1 compiler |
| 360 | if test -n "${CXXFLAGS}"; then |
| 361 | CXXFLAGS='-std strict_ansi -noimplicit_include' |
| 362 | else |
| 363 | CXXFLAGS="${CXXFLAGS} -std strict_ansi -noimplicit_include" |
| 364 | fi |
| 365 | esac |
| 366 | fi |
| 367 | |
| 368 | # Check for lazy-loading. |
| 369 | AC_CACHE_CHECK([for linker lazyload option],[im_cv_ld_lazyload], |
| 370 | [ |
| 371 | im_cv_ld_lazyload='none' |
| 372 | case "${host}" in |
| 373 | *-*-solaris2.8 | *-*-solaris2.9 | *-*-solaris2.1? ) |
| 374 | if test "$lt_cv_prog_gnu_ld" != 'yes' ; then |
| 375 | im_cv_ld_lazyload='-Wl,-zlazyload' |
| 376 | fi |
| 377 | ;; |
| 378 | esac |
| 379 | ]) |
| 380 | if test "${im_cv_ld_lazyload}" != 'none' ; then |
| 381 | if test -z "${LDFLAGS}" ; then |
| 382 | LDFLAGS="${im_cv_ld_lazyload}" |
| 383 | else |
| 384 | LDFLAGS="${im_cv_ld_lazyload} ${LDFLAGS}" |
| 385 | fi |
| 386 | fi |
| 387 | |
| 388 | dnl Platform-specific stuff |
| 389 | case "$host" in |
cristy | c37574e | 2013-02-16 01:04:55 +0000 | [diff] [blame] | 390 | *darwin* | *-macos10*) |
| 391 | dnl Disable FORTIFY_SOURCE to fix a bug in LVVM / OpenMP support |
cristy | b3b90d3 | 2013-02-16 15:44:08 +0000 | [diff] [blame] | 392 | CFLAGS="${CFLAGS} -D_FORTIFY_SOURCE=0" |
cristy | c37574e | 2013-02-16 01:04:55 +0000 | [diff] [blame] | 393 | dnl OS X universal binary support, requires --disable-dependency-tracking |
| 394 | AC_ARG_ENABLE([osx-universal-binary], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 395 | AC_HELP_STRING([--enable-osx-universal-binary], |
| 396 | [build universal binary on OS X [[default=no]]]), |
| 397 | [build_osxuniversal="${enableval}"], [build_osxuniversal=no]) |
| 398 | |
cristy | c37574e | 2013-02-16 01:04:55 +0000 | [diff] [blame] | 399 | if test "${build_osxuniversal}" != no ; then |
| 400 | if test "$enable_dependency_tracking" != no ; then |
| 401 | AC_MSG_ERROR([--enable-osx-universal-binary requires --disable-dependency-tracking. |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 402 | Please re-run configure with these options: |
| 403 | --disable-dependency-tracking --enable-osx-universal-binary |
| 404 | ]) |
cristy | c37574e | 2013-02-16 01:04:55 +0000 | [diff] [blame] | 405 | fi |
| 406 | CFLAGS="$CFLAGS -isysroot /Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386" |
| 407 | CXXFLAGS="$CXXFLAGS -isysroot /Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386" |
| 408 | LDFLAGS="$LDFLAGS -Wl,-syslibroot,/Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 409 | fi |
| 410 | ;; |
| 411 | esac |
| 412 | |
cristy | 0151ae1 | 2011-10-28 16:32:29 +0000 | [diff] [blame] | 413 | # |
| 414 | # ARCH specific include directory |
| 415 | # |
cristy | 670aa3c | 2011-11-03 00:54:00 +0000 | [diff] [blame] | 416 | AC_ARG_WITH([includearch-dir], |
| 417 | [AC_HELP_STRING([--includearch-dir=DIR], |
cristy | 0151ae1 | 2011-10-28 16:32:29 +0000 | [diff] [blame] | 418 | [ARCH specific include directory])], |
cristy | 670aa3c | 2011-11-03 00:54:00 +0000 | [diff] [blame] | 419 | [includearch_dir=$withval], |
| 420 | [includearch_dir=$INCLUDE_DIR]) |
cristy | 0151ae1 | 2011-10-28 16:32:29 +0000 | [diff] [blame] | 421 | |
cristy | d286fd7 | 2013-02-24 19:25:33 +0000 | [diff] [blame] | 422 | eval "eval INCLUDEARCH_DIR=$includearch_dir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 423 | AC_SUBST([INCLUDEARCH_DIR]) |
cristy | 0151ae1 | 2011-10-28 16:32:29 +0000 | [diff] [blame] | 424 | |
| 425 | # |
| 426 | # ARCH specific configuration directory |
| 427 | # |
cristy | 670aa3c | 2011-11-03 00:54:00 +0000 | [diff] [blame] | 428 | AC_ARG_WITH([sharearch-dir], |
| 429 | [AC_HELP_STRING([--sharearch-dir=DIR], |
cristy | 0151ae1 | 2011-10-28 16:32:29 +0000 | [diff] [blame] | 430 | [ARCH specific config directory])], |
cristy | 670aa3c | 2011-11-03 00:54:00 +0000 | [diff] [blame] | 431 | [sharearch_dir=$withval], |
cristy | 408ebcd | 2011-11-14 01:36:57 +0000 | [diff] [blame] | 432 | [sharearch_dir="${LIB_DIR}"]) |
cristy | 0151ae1 | 2011-10-28 16:32:29 +0000 | [diff] [blame] | 433 | |
cristy | 670aa3c | 2011-11-03 00:54:00 +0000 | [diff] [blame] | 434 | eval "eval SHAREARCH_DIR=$sharearch_dir" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 435 | AC_SUBST([SHAREARCH_DIR]) |
cristy | 0151ae1 | 2011-10-28 16:32:29 +0000 | [diff] [blame] | 436 | |
cristy | 496c090 | 2013-02-26 12:57:44 +0000 | [diff] [blame] | 437 | # Path to the pkgconfig folder |
cristy | 2ec87cc | 2013-02-18 17:46:50 +0000 | [diff] [blame] | 438 | AC_ARG_WITH([pkgconfigdir], AS_HELP_STRING([--with-pkgconfigdir=DIR], |
| 439 | [Path to the pkgconfig directory @<:@LIBDIR/pkgconfig@:>@]), |
| 440 | [pkgconfigdir="$withval"], [pkgconfigdir='${libdir}/pkgconfig']) |
| 441 | AC_SUBST([pkgconfigdir]) |
| 442 | |
cristy | 0151ae1 | 2011-10-28 16:32:29 +0000 | [diff] [blame] | 443 | # |
Cristy | ad9483d | 2018-11-10 18:43:37 -0500 | [diff] [blame] | 444 | # Enable support for POSIX thread APIs |
cristy | 1ae5c99 | 2013-07-30 14:55:07 +0000 | [diff] [blame] | 445 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 446 | AC_ARG_WITH([threads], |
Cristy | ad9483d | 2018-11-10 18:43:37 -0500 | [diff] [blame] | 447 | [AC_HELP_STRING([--without-threads], [disable POSIX threads API support])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 448 | [with_threads=$withval], |
| 449 | [with_threads='yes']) |
| 450 | |
cristy | 1ae5c99 | 2013-07-30 14:55:07 +0000 | [diff] [blame] | 451 | THREAD_LIBS='' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 452 | have_threads=no |
| 453 | if test "$with_threads" != 'no'; then |
cristy | f6fcb5d | 2010-09-24 01:19:13 +0000 | [diff] [blame] | 454 | AX_PTHREAD() |
cristy | 7acf8fb | 2010-09-23 19:58:53 +0000 | [diff] [blame] | 455 | if test "$ax_pthread_ok" = yes; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 456 | have_threads=yes |
| 457 | DEF_THREAD="$PTHREAD_CFLAGS" |
| 458 | CFLAGS="$CFLAGS $DEF_THREAD" |
| 459 | CXXFLAGS="$CXXFLAGS $DEF_THREAD" |
Cristy | ad9483d | 2018-11-10 18:43:37 -0500 | [diff] [blame] | 460 | THREAD_LIBS="$PTHREAD_LIBS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 461 | if test "$CC" != "$PTHREAD_CC"; then |
| 462 | AC_MSG_WARN([Replacing compiler $CC with compiler $PTHREAD_CC to support pthreads.]) |
| 463 | CC="$PTHREAD_CC" |
| 464 | fi |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 465 | AC_DEFINE([THREAD_SUPPORT],[1],[Define if you have POSIX threads libraries and header files.]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 466 | fi |
| 467 | fi |
cristy | 1ae5c99 | 2013-07-30 14:55:07 +0000 | [diff] [blame] | 468 | LIBS="$LIBS $THREAD_LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 469 | AC_SUBST([THREAD_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 470 | |
| 471 | # Enable support for OpenMP |
| 472 | if test "$have_threads" != 'yes'; then |
| 473 | ac_cv_prog_c_openmp=unsupported |
| 474 | fi |
| 475 | AC_OPENMP([C]) |
| 476 | CFLAGS="$OPENMP_CFLAGS $CFLAGS" |
| 477 | MAGICK_PCFLAGS="$MAGICK_PCFLAGS $OPENMP_CFLAGS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 478 | AC_SUBST([OPENMP_CFLAGS]) |
cristy | 391f1ce | 2010-09-09 17:23:28 +0000 | [diff] [blame] | 479 | if test "$enable_openmp" != no; then |
| 480 | if test "$ac_cv_prog_c_openmp" != 'unsupported'; then |
| 481 | MAGICK_FEATURES="OpenMP $MAGICK_FEATURES" |
| 482 | fi |
| 483 | fi |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 484 | |
cristy | 736173a | 2009-09-20 21:18:22 +0000 | [diff] [blame] | 485 | # Enable support for OpenCL |
Cristy | 2a67d0e | 2020-08-25 20:17:54 -0400 | [diff] [blame] | 486 | no_cl=yes |
Cristy | d08a994 | 2020-08-25 16:46:18 -0400 | [diff] [blame] | 487 | AX_HAVE_OPENCL([C]) |
Cristy | 2a67d0e | 2020-08-25 20:17:54 -0400 | [diff] [blame] | 488 | if test "X$no_cl" != 'Xyes'; then |
Cristy | 141a300 | 2019-10-29 17:10:27 -0400 | [diff] [blame] | 489 | MAGICK_FEATURES="OpenCL $MAGICK_FEATURES" |
cristy | fd9dcd4 | 2010-08-08 18:07:02 +0000 | [diff] [blame] | 490 | fi |
cristy | 736173a | 2009-09-20 21:18:22 +0000 | [diff] [blame] | 491 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 492 | ######## |
| 493 | # |
| 494 | # Check for large file support |
| 495 | # |
| 496 | ######## |
| 497 | AC_SYS_LARGEFILE |
| 498 | AC_FUNC_FSEEKO |
| 499 | LFS_CPPFLAGS='' |
| 500 | if test "$enable_largefile" != no; then |
cristy | c1e0cc1 | 2011-09-21 16:41:16 +0000 | [diff] [blame] | 501 | case $ac_cv_sys_file_offset_bits in |
| 502 | no) |
| 503 | # nothing to do here as the host supports LFS fine |
| 504 | ;; |
| 505 | unknown) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 506 | AC_MSG_CHECKING([for native large file support]) |
cristy | da16f16 | 2011-02-19 23:52:17 +0000 | [diff] [blame] | 507 | AC_RUN_IFELSE([AC_LANG_PROGRAM([#include <unistd.h> |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 508 | main () { |
| 509 | exit(!(sizeof(off_t) == 8)); |
cristy | da16f16 | 2011-02-19 23:52:17 +0000 | [diff] [blame] | 510 | }])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 511 | [ac_cv_sys_file_offset_bits=64; AC_DEFINE(_FILE_OFFSET_BITS,64) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 512 | AC_MSG_RESULT([yes])], |
| 513 | [AC_MSG_RESULT([no])]) |
cristy | c1e0cc1 | 2011-09-21 16:41:16 +0000 | [diff] [blame] | 514 | ;; |
| 515 | *) |
| 516 | LFS_CPPFLAGS="$LFS_CPPFLAGS -D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits" |
| 517 | ;; |
| 518 | esac |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 519 | if test "$ac_cv_sys_large_files" != 'no'; then |
| 520 | LFS_CPPFLAGS="$LFS_CPPFLAGS -D_LARGE_FILES=1" |
| 521 | fi |
| 522 | if test "$ac_cv_sys_largefile_source" != 'no'; then |
| 523 | LFS_CPPFLAGS="$LFS_CPPFLAGS -D_LARGEFILE_SOURCE=1" |
| 524 | fi |
| 525 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 526 | AC_SUBST([LFS_CPPFLAGS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 527 | |
Cristy | 745f17d | 2020-05-05 16:37:32 -0400 | [diff] [blame] | 528 | # |
Cristy | 6654e6d | 2020-10-05 21:57:31 +0000 | [diff] [blame] | 529 | # Check for sendfile support |
| 530 | # |
| 531 | ######## |
| 532 | AC_CACHE_CHECK([Linux compatible sendfile()],ac_cv_have_linux_sendfile,[ |
| 533 | AC_TRY_LINK([ |
| 534 | #undef _FILE_OFFSET_BITS |
| 535 | #include <sys/types.h> |
| 536 | #include <sys/socket.h> |
| 537 | #include <sys/sendfile.h> |
| 538 | ], [ |
| 539 | sendfile(0, 0, (void *) 0, 0); |
| 540 | ], [ |
| 541 | ac_cv_have_linux_sendfile=yes |
| 542 | ], [ |
| 543 | ac_cv_have_linux_sendfile=no |
| 544 | ]) |
| 545 | ]) |
| 546 | if test $ac_cv_have_linux_sendfile = yes; then |
| 547 | AC_DEFINE([HAVE_LINUX_SENDFILE],[1], [Define if you have Linux-compatible sendfile()]) |
| 548 | fi |
| 549 | |
| 550 | # |
Cristy | 745f17d | 2020-05-05 16:37:32 -0400 | [diff] [blame] | 551 | # Set SETJMP_IS_THREAD_SAFE define. |
| 552 | # |
| 553 | case "${host_os}" in |
| 554 | solaris2* ) ;; |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 555 | *) AC_DEFINE([SETJMP_IS_THREAD_SAFE],[1],[Setjmp/longjmp are thread safe]) ;; |
Cristy | 745f17d | 2020-05-05 16:37:32 -0400 | [diff] [blame] | 556 | esac |
| 557 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 558 | # Configure libtool |
Cristy | ed7fd17 | 2019-12-07 10:52:28 -0500 | [diff] [blame] | 559 | : ${AR_FLAGS=cr} |
Cristy | 6ca2abc | 2020-10-04 00:04:30 +0000 | [diff] [blame] | 560 | LT_INIT([win32-dll dlopen]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 561 | LT_LANG([C++]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 562 | AC_SUBST([LIBTOOL_DEPS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 563 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 564 | # Check to see if building shared libraries |
| 565 | libtool_build_shared_libs='no' |
| 566 | if test "$enable_shared" = 'yes'; then |
| 567 | libtool_build_shared_libs='yes' |
| 568 | fi |
| 569 | |
| 570 | # Check to see if building static libraries |
| 571 | libtool_build_static_libs='no' |
| 572 | if test "$enable_static" = 'yes'; then |
| 573 | libtool_build_static_libs='yes' |
| 574 | fi |
| 575 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 576 | AM_CONDITIONAL([WITH_SHARED_LIBS],[test "${libtool_build_shared_libs}" = 'yes']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 577 | # |
| 578 | # Enable support for building loadable modules |
| 579 | # |
cristy | af4cbf3 | 2012-10-16 23:47:41 +0000 | [diff] [blame] | 580 | build_modules='no' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 581 | AC_ARG_WITH([modules], |
| 582 | [AC_HELP_STRING([--with-modules], |
| 583 | [enable building dynamically loadable modules])], |
| 584 | [with_modules=$withval], |
cristy | 5a1cefd | 2010-01-06 20:42:35 +0000 | [diff] [blame] | 585 | [with_modules='no']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 586 | |
| 587 | # Only allow building loadable modules if we are building shared libraries |
| 588 | if test "$with_modules" != 'no' ; then |
| 589 | if test "$libtool_build_shared_libs" = 'no'; then |
| 590 | AC_MSG_WARN([Modules may only be built if building shared libraries is enabled.]) |
cristy | c672209 | 2012-10-14 00:19:31 +0000 | [diff] [blame] | 591 | build_modules='no' |
| 592 | else |
| 593 | build_modules='yes' |
| 594 | fi |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 595 | fi |
cristy | c672209 | 2012-10-14 00:19:31 +0000 | [diff] [blame] | 596 | if test "$build_modules" != 'no' ; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 597 | AC_DEFINE([BUILD_MODULES],[1],[Define if coders and filters are to be built as modules.]) |
cristy | e78d253 | 2012-12-17 20:41:10 +0000 | [diff] [blame] | 598 | MAGICK_FEATURES="$MAGICK_FEATURES Modules" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 599 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 600 | AM_CONDITIONAL([WITH_MODULES],[test "$build_modules" != 'no']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 601 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 602 | # Enable build using delegate libraries built in subdirectories rather than installed |
Christopher Chianelli | 7a1a92c | 2020-08-02 10:16:01 -0400 | [diff] [blame] | 603 | # delegate libraries (bzlib fftw fpx gslib jp2 jbig jpeg lcms lzma png tiff ttf wmf xml zlib zip) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 604 | AC_ARG_ENABLE([delegate-build], |
| 605 | [AC_HELP_STRING([--enable-delegate-build], |
| 606 | [look for delegate libraries in build directory])], |
| 607 | [enable_delegate_build=$enableval], |
| 608 | [enable_delegate_build='no']) |
| 609 | |
| 610 | AC_ARG_ENABLE([deprecated], |
| 611 | [AC_HELP_STRING([--disable-deprecated], |
cristy | 3a75f06 | 2012-09-08 23:29:40 +0000 | [diff] [blame] | 612 | [exclude deprecated methods in MagickCore and MagickWand APIs])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 613 | [enable_deprecated=$enableval], |
| 614 | [enable_deprecated='no']) |
| 615 | |
| 616 | if test "$enable_deprecated" = 'yes'; then |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 617 | AC_DEFINE([EXCLUDE_DEPRECATED],[1],[exclude deprecated methods in MagickCore API]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 618 | else |
| 619 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --disable-deprecated " |
| 620 | fi |
| 621 | |
| 622 | # Build a version of ImageMagick which operates uninstalled. |
| 623 | # Used to build distributions located via MAGICK_HOME / executable path |
| 624 | AC_ARG_ENABLE([installed], |
| 625 | [AC_HELP_STRING([--disable-installed], |
| 626 | [Formally install ImageMagick under PREFIX])], |
| 627 | [enable_installed=$enableval], |
| 628 | [enable_installed='yes']) |
| 629 | |
| 630 | if test "$enable_installed" = 'yes'; then |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 631 | AC_DEFINE([INSTALLED_SUPPORT],[1],[ImageMagick is formally installed under prefix]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 632 | else |
| 633 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --disable-installed " |
| 634 | fi |
| 635 | |
| 636 | # Permit enciphering and deciphering image pixels. |
| 637 | AC_ARG_ENABLE([cipher], |
| 638 | [AC_HELP_STRING([--disable-cipher], |
| 639 | [disable enciphering and deciphering image pixels])], |
| 640 | [enable_cipher=$enableval], |
| 641 | [enable_cipher='yes']) |
| 642 | |
| 643 | if test "$enable_cipher" = 'yes'; then |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 644 | AC_DEFINE([CIPHER_SUPPORT],[1],[permit enciphering and deciphering image pixels]) |
cristy | 0f6fc2d | 2015-05-30 00:49:11 +0000 | [diff] [blame] | 645 | MAGICK_FEATURES="Cipher $MAGICK_FEATURES" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 646 | fi |
| 647 | |
cristy | 6e3607c | 2011-09-13 13:59:17 +0000 | [diff] [blame] | 648 | # Build a zero-configuration version of ImageMagick. |
| 649 | AC_ARG_ENABLE([zero-configuration], |
| 650 | [AC_HELP_STRING([--enable-zero-configuration], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 651 | [enable self-contained, embeddable, zero-configuration ImageMagick])], |
cristy | 6e3607c | 2011-09-13 13:59:17 +0000 | [diff] [blame] | 652 | [enable_zero_configuration=$enableval], |
| 653 | [enable_zero_configuration='no']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 654 | |
cristy | 6e3607c | 2011-09-13 13:59:17 +0000 | [diff] [blame] | 655 | if test "$enable_zero_configuration" = 'yes'; then |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 656 | AC_DEFINE([ZERO_CONFIGURATION_SUPPORT],[1],[Build self-contained, embeddable, zero-configuration ImageMagick]) |
cristy | 0f6fc2d | 2015-05-30 00:49:11 +0000 | [diff] [blame] | 657 | MAGICK_FEATURES="Zero-configuration $MAGICK_FEATURES" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 658 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 659 | AM_CONDITIONAL([MAGICKCORE_ZERO_CONFIGURATION_SUPPORT],[test "$enable_zero_configuration" = yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 660 | |
| 661 | # Build a high dynamic range version of ImageMagick. |
| 662 | AC_ARG_ENABLE([hdri], |
cristy | f314dbd | 2012-11-15 13:35:28 +0000 | [diff] [blame] | 663 | [AC_HELP_STRING([--enable-hdri], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 664 | [accurately represent the wide range of intensity levels found in real scenes])], |
| 665 | [enable_hdri=$enableval], |
cristy | 191c0b7 | 2012-08-12 16:29:52 +0000 | [diff] [blame] | 666 | [enable_hdri='yes']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 667 | |
| 668 | MAGICK_HDRI="" |
| 669 | if test "$enable_hdri" = 'yes'; then |
| 670 | MAGICK_HDRI="HDRI" |
cristy | e52f12f | 2012-12-31 15:32:36 +0000 | [diff] [blame] | 671 | magick_hdri_enable='1'; |
cristy | fd9dcd4 | 2010-08-08 18:07:02 +0000 | [diff] [blame] | 672 | MAGICK_FEATURES="HDRI $MAGICK_FEATURES" |
cristy | e52f12f | 2012-12-31 15:32:36 +0000 | [diff] [blame] | 673 | else |
| 674 | magick_hdri_enable='0' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 675 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 676 | AC_DEFINE_UNQUOTED([HDRI_ENABLE_OBSOLETE_IN_H],[$magick_hdri_enable],[Whether hdri is enabled or not]) |
| 677 | AC_SUBST([MAGICK_HDRI])dnl |
cristy | e52f12f | 2012-12-31 15:32:36 +0000 | [diff] [blame] | 678 | MAGICK_PCFLAGS="$MAGICK_PCFLAGS -DMAGICKCORE_HDRI_ENABLE=$magick_hdri_enable" |
| 679 | CFLAGS="$CFLAGS -DMAGICKCORE_HDRI_ENABLE=$magick_hdri_enable" |
cristy | 7206238 | 2012-12-31 16:49:52 +0000 | [diff] [blame] | 680 | CPPFLAGS="$CPPFLAGS -DMAGICKCORE_HDRI_ENABLE=$magick_hdri_enable" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 681 | |
Cristy | 697159d | 2016-05-31 07:21:31 -0400 | [diff] [blame] | 682 | # Enable pipes (|) in filenames. |
| 683 | AC_ARG_ENABLE([pipes], |
| 684 | [AC_HELP_STRING([--enable-pipes], |
| 685 | [enable pipes (|) in filenames])], |
| 686 | [enable_pipes=$enableval], |
| 687 | [enable_pipes='no']) |
| 688 | |
| 689 | if test "$enable_pipes" = 'yes'; then |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 690 | AC_DEFINE([PIPES_SUPPORT],[1],[enable pipes (|) in filenames]) |
Cristy | 697159d | 2016-05-31 07:21:31 -0400 | [diff] [blame] | 691 | MAGICK_FEATURES="Pipes $MAGICK_FEATURES" |
| 692 | fi |
| 693 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 694 | # Build a version of ImageMagick with assert statements. |
| 695 | AC_ARG_ENABLE([assert], |
| 696 | [AC_HELP_STRING([--disable-assert], |
| 697 | [disable assert() statements in build])], |
| 698 | [enable_assert=$enableval], |
| 699 | [enable_assert='yes']) |
| 700 | |
| 701 | if test "$enable_assert" = 'no'; then |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 702 | AC_DEFINE([NDEBUG],[1],[Turn off assert statements]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 703 | fi |
| 704 | |
cristy | a448bd2 | 2011-10-14 12:38:13 +0000 | [diff] [blame] | 705 | # Don't emit "rebuild rules" for configure, Makefile.ins, etc. |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 706 | AM_MAINTAINER_MODE |
| 707 | |
cristy | 944e51f | 2013-04-16 18:45:02 +0000 | [diff] [blame] | 708 | # Enable hugepages support |
| 709 | AC_ARG_ENABLE([hugepages], |
| 710 | [AC_HELP_STRING([--enable-hugepages], |
| 711 | [enable 'huge pages' support])], |
| 712 | [enable_hugepages=$enableval], |
| 713 | [enable_hugepages='no']) |
| 714 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 715 | # Enable ccmalloc memory debugging support |
| 716 | AC_ARG_ENABLE([ccmalloc], |
| 717 | [AC_HELP_STRING([--enable-ccmalloc], |
| 718 | [enable 'ccmalloc' memory debug support])], |
| 719 | [enable_ccmalloc=$enableval], |
| 720 | [enable_ccmalloc='no']) |
| 721 | |
| 722 | # Enable Electric Fence memory debugging support |
| 723 | AC_ARG_ENABLE([efence], |
| 724 | [AC_HELP_STRING([--enable-efence], |
| 725 | [enable 'efence' memory debug support])], |
| 726 | [enable_efence=$enableval], |
| 727 | [enable_efence='no']) |
| 728 | |
| 729 | # Enable prof-based profiling support |
| 730 | AC_ARG_ENABLE([prof], |
| 731 | [AC_HELP_STRING([--enable-prof], |
| 732 | [enable 'prof' profiling support])], |
| 733 | [enable_prof=$enableval], |
| 734 | [enable_prof='no']) |
| 735 | |
| 736 | # Enable gprof-based profiling support |
| 737 | AC_ARG_ENABLE([gprof], |
| 738 | [AC_HELP_STRING([--enable-gprof], |
| 739 | [enable 'gprof' profiling support])], |
| 740 | [enable_gprof=$enableval], |
| 741 | [enable_gprof='no']) |
| 742 | |
| 743 | # Enable gcov-based profiling support |
| 744 | AC_ARG_ENABLE([gcov], |
| 745 | [AC_HELP_STRING([--enable-gcov], |
| 746 | [enable 'gcov' profiling support])], |
| 747 | [enable_gcov=$enableval], |
| 748 | [enable_gcov='no']) |
| 749 | |
| 750 | enable_profiling='no' |
| 751 | if test "$enable_prof" = 'yes' || test "$enable_gprof" = 'yes' || test "$enable_gcov" = 'yes'; then |
| 752 | enable_profiling='yes' |
| 753 | if test "$libtool_build_shared_libs" = 'yes'; then |
| 754 | echo "Warning: Can not profile code using shared libraries" |
| 755 | fi |
| 756 | fi |
| 757 | |
| 758 | # Magick API method prefix |
| 759 | AC_ARG_WITH([method-prefix], |
| 760 | [AC_HELP_STRING([--with-method-prefix=PREFIX], |
| 761 | [prefix MagickCore API methods])], |
cristy | fc3d022 | 2012-02-07 15:05:57 +0000 | [diff] [blame] | 762 | [with_method_prefix=$withval], |
| 763 | [with_method_prefix='no']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 764 | |
cristy | fc3d022 | 2012-02-07 15:05:57 +0000 | [diff] [blame] | 765 | if test "$with_method_prefix" != 'no'; then |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 766 | AC_DEFINE_UNQUOTED([NAMESPACE_PREFIX],[$with_method_prefix],[Magick API method prefix]) |
| 767 | AC_DEFINE_UNQUOTED([NAMESPACE_PREFIX_TAG],[$with_method_prefix],[Magick API method prefix tag]) |
cristy | fc3d022 | 2012-02-07 15:05:57 +0000 | [diff] [blame] | 768 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-method-prefix " |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 769 | fi |
| 770 | |
cristy | 71d8c20 | 2012-03-20 17:05:01 +0000 | [diff] [blame] | 771 | # Enable legacy support (default no) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 772 | AC_ARG_ENABLE([legacy-support], |
Cristy | 519e005 | 2016-10-16 15:28:40 -0400 | [diff] [blame] | 773 | [ --enable-legacy-support install legacy command-line utilities (default disabled)], |
cristy | 71d8c20 | 2012-03-20 17:05:01 +0000 | [diff] [blame] | 774 | [with_legacy_support=$enableval], |
| 775 | [with_legacy_support='no']) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 776 | AM_CONDITIONAL([LEGACY_SUPPORT],[test "$with_legacy_support" != 'no']) |
cristy | 71d8c20 | 2012-03-20 17:05:01 +0000 | [diff] [blame] | 777 | |
Paul Kehrer | 6ac3723 | 2018-03-31 10:33:53 -0500 | [diff] [blame] | 778 | # Enable building command line utilities (default yes) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 779 | AC_ARG_WITH([utilities], |
Cristy | e3723ab | 2019-09-11 08:21:22 -0400 | [diff] [blame] | 780 | [ --with-utilities enable building command-line utilities (default yes)], |
Paul Kehrer | 6ac3723 | 2018-03-31 10:33:53 -0500 | [diff] [blame] | 781 | [with_utilities=$withval], [with_utilities='yes']) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 782 | AM_CONDITIONAL([WITH_UTILITIES],[test "$with_utilities" = 'yes']) |
Paul Kehrer | 6ac3723 | 2018-03-31 10:33:53 -0500 | [diff] [blame] | 783 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 784 | # Number of bits in a Quantum |
| 785 | AC_ARG_WITH([quantum-depth], |
| 786 | [AC_HELP_STRING([--with-quantum-depth=DEPTH], |
| 787 | [number of bits in a pixel quantum (default 16)])], |
| 788 | [with_quantum_depth=$withval], |
| 789 | [with_quantum_depth=16]) |
| 790 | |
| 791 | if test "$with_quantum_depth" != '8'; then |
| 792 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-quantum-depth=$with_quantum_depth " |
| 793 | fi |
| 794 | |
| 795 | case "${with_quantum_depth}" in |
| 796 | 8 ) ;; |
| 797 | 16 ) ;; |
| 798 | 32 ) ;; |
| 799 | 64 ) ;; |
cristy | cdae12a | 2010-09-19 02:24:31 +0000 | [diff] [blame] | 800 | * ) AC_MSG_ERROR("Pixel quantum depth must have value of 8, 16, 32, or 64") ;; |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 801 | esac |
| 802 | QUANTUM_DEPTH="$with_quantum_depth" |
Matthew Dawson | 2fd2bcc | 2020-10-22 06:52:12 -0400 | [diff] [blame] | 803 | AC_DEFINE_UNQUOTED([QUANTUM_DEPTH_OBSOLETE_IN_H],[$QUANTUM_DEPTH],[Number of bits in a pixel Quantum (8/16/32/64)]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 804 | AC_SUBST([QUANTUM_DEPTH])dnl |
cristy | 0a9565b | 2013-01-30 19:57:08 +0000 | [diff] [blame] | 805 | MAGICK_PCFLAGS="$MAGICK_PCFLAGS -DMAGICKCORE_QUANTUM_DEPTH=$QUANTUM_DEPTH" |
cristy | e52f12f | 2012-12-31 15:32:36 +0000 | [diff] [blame] | 806 | CFLAGS="$CFLAGS -DMAGICKCORE_QUANTUM_DEPTH=$QUANTUM_DEPTH" |
cristy | 7206238 | 2012-12-31 16:49:52 +0000 | [diff] [blame] | 807 | CPPFLAGS="$CPPFLAGS -DMAGICKCORE_QUANTUM_DEPTH=$QUANTUM_DEPTH" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 808 | |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 809 | # define a lib suffix for abi purpose |
cristy | 7a26abd | 2012-12-03 00:18:59 +0000 | [diff] [blame] | 810 | MAGICK_ABI_SUFFIX="Q${QUANTUM_DEPTH}" |
cristy | e386d19 | 2012-12-01 21:05:20 +0000 | [diff] [blame] | 811 | if test "$enable_hdri" = 'yes'; then |
cristy | 7a26abd | 2012-12-03 00:18:59 +0000 | [diff] [blame] | 812 | MAGICK_ABI_SUFFIX="Q${QUANTUM_DEPTH}${MAGICK_HDRI}" |
cristy | e386d19 | 2012-12-01 21:05:20 +0000 | [diff] [blame] | 813 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 814 | AC_SUBST([MAGICK_ABI_SUFFIX]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 815 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 816 | # Set pixel cache threshold |
| 817 | AC_ARG_WITH([cache], |
| 818 | [AC_HELP_STRING([--with-cache=THRESHOLD], |
| 819 | [set pixel cache threshhold in MB (default available memory)])], |
| 820 | [with_cache=$withval], |
| 821 | [with_cache='']) |
| 822 | |
| 823 | if test "$with_cache" != ''; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 824 | AC_DEFINE_UNQUOTED([PixelCacheThreshold],["$with_cache"],[Pixel cache threshold in MB (defaults to available memory)]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 825 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-cache=$with_cache " |
| 826 | fi |
| 827 | |
| 828 | # Disable/Enable support for full delegate paths |
| 829 | AC_ARG_WITH([frozenpaths], |
| 830 | [AC_HELP_STRING([--with-frozenpaths], |
| 831 | [freeze delegate paths])], |
| 832 | [with_frozenpaths=$withval], |
| 833 | [with_frozenpaths='no']) |
| 834 | |
| 835 | # Enable build/install of Magick++ |
| 836 | AC_ARG_WITH([magick-plus-plus], |
| 837 | [AC_HELP_STRING([--without-magick-plus-plus], |
| 838 | [disable build/install of Magick++])], |
| 839 | [with_magick_plus_plus=$withval], |
| 840 | [with_magick_plus_plus='yes']) |
| 841 | |
cristy | 3a75f06 | 2012-09-08 23:29:40 +0000 | [diff] [blame] | 842 | # Encode the this name into the shared library. |
| 843 | AC_ARG_WITH([package-release-name], |
| 844 | [AC_HELP_STRING([--with-package-release-name=NAME], |
| 845 | [encode this name into the shared library])], |
| 846 | [MAGICK_LT_RELEASE_OPTS="-release $withval"]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 847 | AC_SUBST([MAGICK_LT_RELEASE_OPTS]) |
cristy | 3a75f06 | 2012-09-08 23:29:40 +0000 | [diff] [blame] | 848 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 849 | # Disable build/install of PerlMagick. |
| 850 | AC_ARG_WITH([perl], |
| 851 | [AC_HELP_STRING([--with-perl], |
| 852 | [enable build/install of PerlMagick])], |
| 853 | [with_perl=$withval], |
cristy | b5f4e2f | 2010-04-25 00:49:11 +0000 | [diff] [blame] | 854 | [with_perl='no']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 855 | |
| 856 | # Options to pass when configuring PerlMagick |
| 857 | AC_ARG_WITH([perl-options], |
| 858 | [AC_HELP_STRING([--with-perl-options=OPTIONS], |
cristy | fc3d022 | 2012-02-07 15:05:57 +0000 | [diff] [blame] | 859 | [options to pass on command-line when generating PerlMagick build file])], |
cristy | 949301e | 2010-01-06 01:38:40 +0000 | [diff] [blame] | 860 | PERL_MAKE_OPTIONS=$withval) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 861 | AC_SUBST([PERL_MAKE_OPTIONS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 862 | |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 863 | # Enable jemalloc, object-caching memory allocation library. |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 864 | AC_ARG_WITH([jemalloc], |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 865 | [ --with-jemalloc enable jemalloc memory allocation library support], |
| 866 | [with_jemalloc=$withval], |
| 867 | [with_jemalloc='no']) |
| 868 | if test "$with_jemalloc" != 'yes' ; then |
| 869 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-jemalloc=$with_jemalloc " |
| 870 | fi |
| 871 | |
Cristy | 001b1da | 2019-09-11 08:38:23 -0400 | [diff] [blame] | 872 | # Enable use of TCMalloc library. |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 873 | AC_ARG_WITH([tcmalloc], |
Cristy | 001b1da | 2019-09-11 08:38:23 -0400 | [diff] [blame] | 874 | AS_HELP_STRING([--with-tcmalloc], |
| 875 | [enable tcmalloc memory allocation library support]), |
| 876 | [with_tcmalloc=$withval], |
| 877 | [with_tcmalloc='no']) |
| 878 | if test "$with_tcmalloc" != 'no' ; then |
| 879 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-tcmalloc=$with_tcmalloc " |
| 880 | fi |
| 881 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 882 | # Enable umem, object-caching memory allocation library. |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 883 | AC_ARG_WITH([umem], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 884 | [ --with-umem enable umem memory allocation library support], |
| 885 | [with_umem=$withval], |
| 886 | [with_umem='no']) |
| 887 | if test "$with_umem" != 'yes' ; then |
| 888 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-umem=$with_umem " |
| 889 | fi |
| 890 | |
| 891 | # |
| 892 | # Specify path to shared libstdc++ if not in normal location |
| 893 | # |
| 894 | AC_ARG_WITH([libstdc], |
| 895 | [AC_HELP_STRING([--with-libstdc=DIR], |
| 896 | [ use libstdc++ in DIR (for GNU C++)])], |
| 897 | [with_libstdc=$withval], |
| 898 | [with_libstdc='']) |
| 899 | |
| 900 | if test "$with_libstdc" != ''; then |
| 901 | if test -d "$with_libstdc"; then |
| 902 | LIBSTDCLDFLAGS="-L$with_libstdc" |
| 903 | fi |
| 904 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 905 | AC_SUBST([LIBSTDCLDFLAGS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 906 | |
| 907 | # Does gcc required -traditional? |
| 908 | AC_PROG_GCC_TRADITIONAL |
| 909 | |
| 910 | ######## |
| 911 | # |
| 912 | # Set defines required to build DLLs and modules using MinGW |
| 913 | # |
| 914 | ######## |
| 915 | # These options are set for multi-thread DLL module build |
| 916 | # libMagickCore: _DLL _MAGICKMOD_ _MAGICKLIB_ |
| 917 | # module: _DLL |
| 918 | # executable/Magick++: _DLL _MAGICKMOD_ |
| 919 | MODULE_EXTRA_CPPFLAGS='' |
| 920 | LIBRARY_EXTRA_CPPFLAGS='' |
| 921 | if test "${native_win32_build}" = 'yes'; then |
| 922 | if test "${libtool_build_shared_libs}" = 'yes'; then |
| 923 | CPPFLAGS="$CPPFLAGS -D_DLL" |
| 924 | MAGICK_CPPFLAGS="$MAGICK_CPPFLAGS -D_DLL" |
| 925 | MAGICK_PCFLAGS="$MAGICK_PCFLAGS -D_DLL" |
| 926 | LIBRARY_EXTRA_CPPFLAGS="$LIBRARY_EXTRA_CPPFLAGS -D_MAGICKLIB_" |
cristy | c672209 | 2012-10-14 00:19:31 +0000 | [diff] [blame] | 927 | if test "$build_modules" = 'yes'; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 928 | LIBRARY_EXTRA_CPPFLAGS="$LIBRARY_EXTRA_CPPFLAGS -D_MAGICKMOD_" |
| 929 | else |
| 930 | MODULE_EXTRA_CPPFLAGS="$MODULE_EXTRA_CPPFLAGS -D_MAGICKLIB_" |
| 931 | fi |
| 932 | else |
| 933 | CPPFLAGS="$CPPFLAGS -D_LIB" |
| 934 | MAGICK_CPPFLAGS="$MAGICK_CPPFLAGS -D_LIB" |
| 935 | MAGICK_PCFLAGS="$MAGICK_PCFLAGS -D_LIB" |
| 936 | fi |
| 937 | if test "$with_threads" = 'yes'; then |
| 938 | CPPFLAGS="$CPPFLAGS -D_MT" |
| 939 | MAGICK_CPPFLAGS="$MAGICK_CPPFLAGS -D_MT" |
| 940 | MAGICK_PCFLAGS="$MAGICK_PCFLAGS -D_MT" |
| 941 | fi |
| 942 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 943 | AC_SUBST([MODULE_EXTRA_CPPFLAGS]) |
| 944 | AC_SUBST([LIBRARY_EXTRA_CPPFLAGS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 945 | |
| 946 | # Check standard headers |
| 947 | AC_HEADER_STDC |
| 948 | if ! test x"$ac_cv_header_stdc" = x"yes"; then |
| 949 | AC_MSG_WARN([configure has detected that you do not have the ANSI standard C |
| 950 | header files. Compilation cannot proceed. Please install the ANSI C |
| 951 | headers and rerun this script.]); |
| 952 | fi |
cristy | a0b81c3 | 2010-01-22 02:54:33 +0000 | [diff] [blame] | 953 | AC_HEADER_ASSERT |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 954 | AC_HEADER_DIRENT |
| 955 | |
| 956 | # Check additional headers |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 957 | AC_CHECK_HEADERS(arm/limits.h arpa/inet.h complex.h errno.h fcntl.h float.h limits.h linux/unistd.h locale.h machine/param.h mach-o/dyld.h malloc.h netdb.h netinet/in.h OS.h process.h sun_prefetch.h stdarg.h stddef.h sys/ipc.h sys/mman.h sys/resource.h sys/sendfile.h sys/socket.h sys/syslimits.h sys/time.h sys/timeb.h sys/times.h sys/uio.h sys/wait.h utime.h wchar.h xlocale.h) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 958 | |
| 959 | ######## |
| 960 | # |
| 961 | # Checks for typedefs, structures, and compiler characteristics. |
| 962 | # |
| 963 | ######## |
| 964 | |
| 965 | AC_HEADER_STDBOOL |
| 966 | AC_C_VOLATILE |
| 967 | AC_C_STRINGIZE |
| 968 | AC_HEADER_STAT |
| 969 | AC_HEADER_TIME |
| 970 | AC_STRUCT_TM |
cristy | 92703d8 | 2010-04-26 00:18:18 +0000 | [diff] [blame] | 971 | AC_STRUCT_TIMEZONE |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 972 | AC_SYS_INTERPRETER |
| 973 | |
cristy | a9ee284 | 2013-01-08 15:56:39 +0000 | [diff] [blame] | 974 | # |
| 975 | # Checks for language qualifiers and semantics. |
| 976 | # |
| 977 | AC_C_CHAR_UNSIGNED |
| 978 | AC_C_CONST |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 979 | AC_C_INLINE |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 980 | AC_C_RESTRICT |
cristy | a9ee284 | 2013-01-08 15:56:39 +0000 | [diff] [blame] | 981 | AC_C_VOLATILE |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 982 | |
| 983 | # If words are stored with the most significant byte first (like |
| 984 | # Motorola and SPARC CPUs), define `WORDS_BIGENDIAN'. |
| 985 | AC_C_BIGENDIAN |
| 986 | |
cristy | 501c804 | 2011-05-26 17:46:28 +0000 | [diff] [blame] | 987 | # Define to a suitable type, if standard headers do not define it. |
| 988 | AC_TYPE_INT8_T |
| 989 | AC_TYPE_INT16_T |
| 990 | AC_TYPE_INT32_T |
| 991 | AC_TYPE_INT64_T |
| 992 | AC_TYPE_INTMAX_T |
| 993 | AC_TYPE_INTPTR_T |
cristy | 501c804 | 2011-05-26 17:46:28 +0000 | [diff] [blame] | 994 | AC_TYPE_MBSTATE_T |
| 995 | AC_TYPE_MODE_T |
| 996 | AC_TYPE_OFF_T |
| 997 | AC_TYPE_PID_T |
| 998 | AC_TYPE_SIZE_T |
| 999 | AC_TYPE_SSIZE_T |
| 1000 | AC_TYPE_UID_T |
| 1001 | AC_TYPE_UINT8_T |
| 1002 | AC_TYPE_UINT16_T |
| 1003 | AC_TYPE_UINT32_T |
| 1004 | AC_TYPE_UINT64_T |
| 1005 | AC_TYPE_UINTMAX_T |
| 1006 | AC_TYPE_UINTPTR_T |
cristy | 98beafc | 2015-05-14 19:55:55 +0000 | [diff] [blame] | 1007 | |
cristy | fec3182 | 2013-05-23 12:32:12 +0000 | [diff] [blame] | 1008 | # Float_t and double_t are intended to be the the most efficient type. |
cristy | fec3182 | 2013-05-23 12:32:12 +0000 | [diff] [blame] | 1009 | AC_CHECK_SIZEOF([float_t], [], [[#include <math.h>]]) |
| 1010 | AC_CHECK_SIZEOF([double_t], [], [[#include <math.h>]]) |
| 1011 | |
cristy | 9b86f20 | 2012-11-28 21:55:35 +0000 | [diff] [blame] | 1012 | # Get size of float, double and long double for comparaison. |
| 1013 | AC_CHECK_SIZEOF([float]) |
| 1014 | AC_CHECK_SIZEOF([double]) |
cristy | 9e2b624 | 2014-03-25 11:49:41 +0000 | [diff] [blame] | 1015 | AC_CHECK_SIZEOF([long double]) |
cristy | f0cf9a2 | 2012-10-24 12:05:01 +0000 | [diff] [blame] | 1016 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1017 | # Obtain size of a 'unsigned long long' and define as |
| 1018 | # SIZEOF_UNSIGNED_LONG_LONG. If 'unsigned long long' is not |
| 1019 | # supported then the value defined is zero. |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1020 | AC_CHECK_SIZEOF([unsigned long long]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1021 | AC_CHECK_SIZEOF([ssize_t]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1022 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1023 | AC_CHECK_SIZEOF([void *]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1024 | |
| 1025 | AC_MSG_CHECKING([whether our compiler supports __func__]) |
| 1026 | AC_TRY_COMPILE([], |
| 1027 | [{ const char *func = __func__; return(func != 0 ? 0 : 1); }], |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1028 | AC_MSG_RESULT([yes]), |
| 1029 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1030 | AC_MSG_CHECKING([whether our compiler supports __FUNCTION__]) |
| 1031 | AC_TRY_COMPILE([], |
| 1032 | [{ const char *func = __FUNCTION__; return(func != 0 ? 0 : 1); }], |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1033 | AC_MSG_RESULT([yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1034 | AC_DEFINE(__func__, __FUNCTION__, |
iplxp00j | 62abaa3 | 2019-05-30 21:28:20 +0200 | [diff] [blame] | 1035 | [Define to appropriate substitute if compiler does not have __func__]), |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1036 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1037 | AC_DEFINE(__func__, __FILE__, |
iplxp00j | 62abaa3 | 2019-05-30 21:28:20 +0200 | [diff] [blame] | 1038 | [Define to appropriate substitute if compiler does not have __func__]))) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1039 | |
| 1040 | ######## |
| 1041 | # |
| 1042 | # Check for functions |
| 1043 | # |
| 1044 | ######## |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1045 | AC_FUNC_CLOSEDIR_VOID |
| 1046 | AC_FUNC_MMAP |
| 1047 | AC_FUNC_FORK |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1048 | AC_FUNC_MALLOC |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1049 | AC_FUNC_MEMCMP |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1050 | AC_FUNC_REALLOC |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1051 | AC_FUNC_SELECT_ARGTYPES |
| 1052 | AC_FUNC_SETVBUF_REVERSED |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1053 | AC_FUNC_STRTOD |
cristy | 7d4a1d6 | 2011-10-13 15:54:12 +0000 | [diff] [blame] | 1054 | AC_FUNC_STRERROR_R |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1055 | AC_FUNC_VPRINTF |
| 1056 | |
cristy | 161b926 | 2010-03-20 19:34:32 +0000 | [diff] [blame] | 1057 | # |
| 1058 | # Find math library |
| 1059 | # |
| 1060 | MATH_LIBS='' |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1061 | AC_CHECK_LIB([m],[sqrt],[MATH_LIBS="-lm"],[]) |
cristy | 161b926 | 2010-03-20 19:34:32 +0000 | [diff] [blame] | 1062 | LIBS="$MATH_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1063 | AC_SUBST([MATH_LIBS]) |
cristy | 161b926 | 2010-03-20 19:34:32 +0000 | [diff] [blame] | 1064 | |
cristy | 8557216 | 2013-01-04 19:19:32 +0000 | [diff] [blame] | 1065 | # |
| 1066 | # Find socket library |
| 1067 | # |
cristy | 8557216 | 2013-01-04 19:19:32 +0000 | [diff] [blame] | 1068 | AC_SEARCH_LIBS(gethostbyname, resolv nsl) |
cristy | 8a5d7f4 | 2013-01-06 15:24:33 +0000 | [diff] [blame] | 1069 | AC_SEARCH_LIBS(socket, socket, |
| 1070 | [ |
| 1071 | AC_DEFINE([HAVE_SOCKET],[1],[Define to 1 if you have socket support.]) |
cristy | fac0334 | 2013-01-12 02:03:32 +0000 | [diff] [blame] | 1072 | MAGICK_FEATURES="DPC $MAGICK_FEATURES" |
cristy | 8a5d7f4 | 2013-01-06 15:24:33 +0000 | [diff] [blame] | 1073 | ]) |
cristy | 8557216 | 2013-01-04 19:19:32 +0000 | [diff] [blame] | 1074 | |
cristy | e43a45e | 2009-09-28 14:49:00 +0000 | [diff] [blame] | 1075 | # |
| 1076 | # Check for clock_gettime(). |
| 1077 | # |
| 1078 | AC_SEARCH_LIBS(clock_gettime, rt, |
| 1079 | [ |
| 1080 | AC_DEFINE([HAVE_CLOCK_GETTIME],[1],[Define to 1 if you have clock_gettime.]) |
| 1081 | AC_MSG_CHECKING([whether clock_gettime supports CLOCK_REALTIME]) |
cristy | da16f16 | 2011-02-19 23:52:17 +0000 | [diff] [blame] | 1082 | AC_COMPILE_IFELSE([ |
cristy | e43a45e | 2009-09-28 14:49:00 +0000 | [diff] [blame] | 1083 | AC_LANG_PROGRAM( |
| 1084 | [[#include <time.h>]], |
cristy | da16f16 | 2011-02-19 23:52:17 +0000 | [diff] [blame] | 1085 | [[clockid_t clockType = CLOCK_REALTIME;]])], |
cristy | e43a45e | 2009-09-28 14:49:00 +0000 | [diff] [blame] | 1086 | [ |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1087 | AC_MSG_RESULT([yes]) |
glennrp | 3fc1c21 | 2013-01-10 01:52:32 +0000 | [diff] [blame] | 1088 | AC_DEFINE([HAVE_CLOCK_REALTIME],[1], |
cristy | e43a45e | 2009-09-28 14:49:00 +0000 | [diff] [blame] | 1089 | [Define to 1 if clock_gettime supports CLOCK_REALTIME.]) |
| 1090 | ], |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1091 | AC_MSG_RESULT([no]) |
cristy | e43a45e | 2009-09-28 14:49:00 +0000 | [diff] [blame] | 1092 | ) |
| 1093 | ], |
| 1094 | [ |
| 1095 | AC_CHECK_FUNCS([gettimeofday ftime], [break]) |
| 1096 | ] |
| 1097 | ) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1098 | |
| 1099 | ######## |
| 1100 | # |
| 1101 | # Check for function prototypes |
| 1102 | # |
| 1103 | ######## |
| 1104 | |
| 1105 | AC_CHECK_DECLS([pread, pwrite],[],[],[ |
| 1106 | #include <unistd.h>]) |
| 1107 | |
| 1108 | AC_CHECK_DECLS([strlcpy],[],[],[ |
| 1109 | #include <strings.h>]) |
| 1110 | |
| 1111 | AC_CHECK_DECLS([vsnprintf],[],[],[ |
| 1112 | #include <stdio.h> |
| 1113 | #include <stdarg.h>]) |
| 1114 | |
| 1115 | ######## |
| 1116 | # |
| 1117 | # C++ Support Tests (For Magick++) |
| 1118 | # |
| 1119 | ######## |
| 1120 | have_magick_plus_plus='no' |
| 1121 | if test "$with_magick_plus_plus" = 'yes'; then |
| 1122 | OLIBS="$LIBS" |
| 1123 | LIBS='' |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1124 | AC_LANG_PUSH([C++]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1125 | |
| 1126 | # Full set of headers used... |
| 1127 | # algorithm cctype cerrno cmath cstdio cstdlib cstring ctime exception |
| 1128 | # functional iomanip iosfwd iostream iterator list string strstream utility |
| 1129 | AC_LANG([C++]) |
| 1130 | AC_PROG_CXX |
cristy | 964cb7f | 2010-04-25 23:18:00 +0000 | [diff] [blame] | 1131 | AX_CXX_BOOL |
| 1132 | AX_CXX_NAMESPACES |
| 1133 | AX_CXX_NAMESPACE_STD |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1134 | AC_CXX_HAVE_STD_LIBS |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1135 | AC_OPENMP([C++]) |
| 1136 | AC_LANG_POP |
| 1137 | |
| 1138 | AC_MSG_CHECKING([whether C++ compiler is sufficient for Magick++]) |
| 1139 | if \ |
cristy | 964cb7f | 2010-04-25 23:18:00 +0000 | [diff] [blame] | 1140 | test $ax_cv_cxx_bool = 'yes' && \ |
cristy | 964cb7f | 2010-04-25 23:18:00 +0000 | [diff] [blame] | 1141 | test $ax_cv_cxx_namespaces = 'yes' && \ |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1142 | test $ac_cv_cxx_have_std_libs = 'yes' && \ |
cristy | 964cb7f | 2010-04-25 23:18:00 +0000 | [diff] [blame] | 1143 | test $ax_cv_cxx_have_std_namespace = 'yes'; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1144 | have_magick_plus_plus='yes' |
| 1145 | else |
| 1146 | have_magick_plus_plus='no (failed tests)' |
| 1147 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1148 | AC_MSG_RESULT([$have_magick_plus_plus]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1149 | LIBS="$OLIBS" |
| 1150 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1151 | AM_CONDITIONAL([WITH_MAGICK_PLUS_PLUS],[test "$have_magick_plus_plus" = 'yes']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1152 | |
| 1153 | # Only check for delegate libraries in subdirectories if requested. |
| 1154 | if test "$enable_delegate_build" != 'no'; then |
| 1155 | # Check for delegate sub-directories and add -I & -L options as required. |
| 1156 | # This presumes that delegates are installed as detailed in the ImageMagick |
| 1157 | # README. If delegates are installed in a standard location where the |
| 1158 | # compiler will automatically find them then these options should not be |
| 1159 | # required. |
| 1160 | |
| 1161 | # |
| 1162 | # Most delegates have includes in the same directory as the library, but not all... |
| 1163 | # |
| 1164 | # Includes |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1165 | for dir in bzlib fftw fpx gslib/src jp2 jbig/libjbig jpeg lcms/include lzma magick openjp2/include png tiff/libtiff ttf/include wand webp/src wmf/include xml/include zlib zip; do |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1166 | if test -d "$builddir/$dir"; then |
| 1167 | CPPFLAGS="$CPPFLAGS -I$builddir/$dir" |
| 1168 | else |
| 1169 | if test -d "$srcdirfull/$dir"; then |
| 1170 | CPPFLAGS="$CPPFLAGS -I$srcdirfull/$dir" |
| 1171 | fi |
| 1172 | fi |
| 1173 | done |
| 1174 | |
| 1175 | # Libraries |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1176 | for dir in bzlib fftw fpx gslib/src jbig/libjbig jpeg lcms/src lzma magick openjp2 png tiff/libtiff ttf/objs wand webp wmf/src xml zlib zip; do |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1177 | if test -d "$builddir/$dir/.libs"; then |
| 1178 | LDFLAGS="$LDFLAGS -L$builddir/$dir/.libs" |
| 1179 | else |
| 1180 | if test -d "$srcdirfull/$dir/.libs"; then |
| 1181 | LDFLAGS="$LDFLAGS -L$srcdirfull/$dir/.libs" |
| 1182 | fi |
| 1183 | fi |
| 1184 | if test -d "$builddir/$dir"; then |
| 1185 | LDFLAGS="$LDFLAGS -L$builddir/$dir" |
| 1186 | else |
| 1187 | if test -d "$srcdirfull/$dir"; then |
| 1188 | LDFLAGS="$LDFLAGS -L$srcdirfull/$dir" |
| 1189 | fi |
| 1190 | fi |
| 1191 | done |
| 1192 | fi |
| 1193 | |
| 1194 | # Assume that delegate headers reside under same directory as ImageMagick |
| 1195 | # installation prefix. |
cristy | bdabdd6 | 2013-03-04 17:43:36 +0000 | [diff] [blame] | 1196 | MAGICK_CPPFLAGS="-I$INCLUDE_DIR/${PACKAGE_NAME}-$MAGICK_MAJOR_VERSION $MAGICK_CPPFLAGS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1197 | |
| 1198 | # |
| 1199 | # Find the X11 RGB database |
| 1200 | # |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1201 | AC_CACHE_CHECK([for X11 configure files],[im_cv_x_configure], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1202 | [# Look for the header file in a standard set of common directories. |
| 1203 | # Check X11 before X11Rn because it is often a symlink to the current release. |
| 1204 | for ac_dir in \ |
| 1205 | /lib/usr/lib/X11 \ |
| 1206 | /usr/X11/lib \ |
| 1207 | /usr/X11R4/lib \ |
| 1208 | /usr/X11R5/lib \ |
| 1209 | /usr/X11R6/lib \ |
| 1210 | /usr/X11R7/lib \ |
| 1211 | /usr/X386/lib \ |
| 1212 | /usr/XFree86/lib/X11 \ |
| 1213 | /usr/athena/lib \ |
| 1214 | /usr/lib \ |
| 1215 | /usr/lib/X11 \ |
| 1216 | /usr/lib/X11R4 \ |
| 1217 | /usr/lib/X11R5 \ |
| 1218 | /usr/lib/X11R6 \ |
| 1219 | /usr/lib/X11R7 \ |
| 1220 | /usr/local/X11/lib \ |
| 1221 | /usr/local/X11R4/lib \ |
| 1222 | /usr/local/X11R5/lib \ |
| 1223 | /usr/local/X11R6/lib \ |
| 1224 | /usr/local/lib \ |
| 1225 | /usr/local/lib/X11 \ |
| 1226 | /usr/local/lib/X11R4 \ |
| 1227 | /usr/local/lib/X11R5 \ |
| 1228 | /usr/local/lib/X11R6 \ |
| 1229 | /usr/local/lib/X11R7 \ |
| 1230 | /usr/local/x11r5/lib \ |
| 1231 | /usr/lpp/Xamples/lib \ |
| 1232 | /usr/openwin/lib \ |
| 1233 | /usr/openwin/share/lib \ |
| 1234 | /usr/unsupported/lib \ |
| 1235 | /usr/x386/lib \ |
| 1236 | ; do |
| 1237 | if test -f "$ac_dir/X11/rgb.txt"; then |
| 1238 | im_cv_x_configure="$ac_dir/X11/" |
| 1239 | break |
| 1240 | elif test -f "$ac_dir/rgb.txt"; then |
| 1241 | im_cv_x_configure="$ac_dir/" |
| 1242 | break |
| 1243 | fi |
| 1244 | |
| 1245 | done]) |
| 1246 | X11_CONFIGURE_PATH="$im_cv_x_configure" |
| 1247 | case "${build_os}" in |
| 1248 | mingw* ) |
| 1249 | X11ConfigurePath=`$WinPathScript "$X11ConfigurePath=" 1` |
| 1250 | ;; |
| 1251 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1252 | AC_DEFINE_UNQUOTED([X11_CONFIGURE_PATH],["$X11ConfigurePath"],[Location of X11 configure files]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1253 | |
| 1254 | # |
| 1255 | # Find OpenMP library |
| 1256 | # |
| 1257 | GOMP_LIBS='' |
| 1258 | if test "$enable_openmp" != 'no'; then |
| 1259 | if test "${GCC}" = "yes"; then |
cristy | 18307f1 | 2011-12-30 01:20:16 +0000 | [diff] [blame] | 1260 | # Open64 (passes for GCC but uses different OpenMP implementation) |
| 1261 | if test "x$GOMP_LIBS" = x ; then |
| 1262 | if $CC --version 2>&1 | grep Open64 > /dev/null ; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1263 | AC_CHECK_LIB([openmp],[omp_get_num_procs],[GOMP_LIBS="-lopenmp"],[],[]) |
cristy | 18307f1 | 2011-12-30 01:20:16 +0000 | [diff] [blame] | 1264 | fi |
| 1265 | fi |
Cristy | 530d3d7 | 2016-08-07 08:42:26 -0400 | [diff] [blame] | 1266 | # Clang (passes for GCC but uses different OpenMP implementation) |
| 1267 | if test "x$LIB_OMP" = x ; then |
| 1268 | if $CC --version 2>&1 | grep clang > /dev/null ; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1269 | AC_CHECK_LIB([omp],[GOMP_parallel_start],[LIB_OMP="-lomp"],[],[]) |
Cristy | 530d3d7 | 2016-08-07 08:42:26 -0400 | [diff] [blame] | 1270 | fi |
| 1271 | fi |
cristy | 18307f1 | 2011-12-30 01:20:16 +0000 | [diff] [blame] | 1272 | # GCC |
| 1273 | if test "x$GOMP_LIBS" = x ; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1274 | AC_CHECK_LIB([gomp],[GOMP_parallel_start],[GOMP_LIBS="-lgomp"],[],[]) |
cristy | 18307f1 | 2011-12-30 01:20:16 +0000 | [diff] [blame] | 1275 | fi |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1276 | else |
cristy | 18307f1 | 2011-12-30 01:20:16 +0000 | [diff] [blame] | 1277 | # Sun CC |
| 1278 | if test "x$GOMP_LIBS" = x ; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1279 | AC_CHECK_LIB([mtsk],[sunw_mp_register_warn],[GOMP_LIBS="-lmtsk"],[],[]) |
cristy | 18307f1 | 2011-12-30 01:20:16 +0000 | [diff] [blame] | 1280 | fi |
| 1281 | # AIX xlc |
| 1282 | if test "x$GOMP_LIBS" = x ; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1283 | AC_CHECK_LIB([xlsmp],[_xlsmpFlush],[GOMP_LIBS="-lxlsmp"],[],[]) |
cristy | 18307f1 | 2011-12-30 01:20:16 +0000 | [diff] [blame] | 1284 | fi |
| 1285 | # SGI IRIX 6.5 MIPSpro C/C++ |
| 1286 | if test "x$GOMP_LIBS" = x ; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1287 | AC_CHECK_LIB([mp],[mp_destroy],[GOMP_LIBS="-lmp"],[],[]) |
cristy | 18307f1 | 2011-12-30 01:20:16 +0000 | [diff] [blame] | 1288 | fi |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1289 | fi |
| 1290 | LIBS="$GOMP_LIBS $LIBS" |
| 1291 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1292 | AC_SUBST([GOMP_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1293 | |
cristy | 12ac819 | 2014-11-04 13:59:13 +0000 | [diff] [blame] | 1294 | # |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 1295 | # Check for jemalloc. |
cristy | 12ac819 | 2014-11-04 13:59:13 +0000 | [diff] [blame] | 1296 | # |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 1297 | have_jemalloc='no' |
| 1298 | JEMALLOC_LIBS='' |
| 1299 | if test "$with_jemalloc" != 'no'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1300 | AC_MSG_CHECKING([for JEMALLOC support]) |
| 1301 | AC_MSG_RESULT([]) |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 1302 | failed=0 |
| 1303 | passed=0 |
cristy | 22007ae | 2014-11-04 15:59:22 +0000 | [diff] [blame] | 1304 | AC_CHECK_HEADER([jemalloc/jemalloc.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1305 | AC_CHECK_LIB([jemalloc],[malloc_stats_print],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 1306 | AC_MSG_CHECKING([if jemalloc memory allocation library is complete]) |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 1307 | if test $passed -gt 0; then |
| 1308 | if test $failed -gt 0; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1309 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 1310 | have_jemalloc='no (failed tests)' |
| 1311 | else |
| 1312 | JEMALLOC_LIBS='-ljemalloc' |
| 1313 | LIBS="$JEMALLOC_LIBS $LIBS" |
Cristy | cf715c7 | 2020-12-30 07:48:03 -0500 | [diff] [blame] | 1314 | AC_DEFINE([HAVE_JEMALLOC],[1],[Define if you have jemalloc memory allocation library]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1315 | AC_MSG_RESULT([yes]) |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 1316 | have_jemalloc='yes' |
| 1317 | fi |
| 1318 | else |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1319 | AC_MSG_RESULT([no]) |
cristy | 3b0097d | 2014-11-04 15:34:47 +0000 | [diff] [blame] | 1320 | fi |
| 1321 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1322 | AM_CONDITIONAL([HAVE_JEMALLOC],[test "$have_jemalloc" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1323 | AC_SUBST([JEMALLOC_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1324 | |
| 1325 | # |
Cristy | 001b1da | 2019-09-11 08:38:23 -0400 | [diff] [blame] | 1326 | # Check for TCMalloc library |
| 1327 | # |
| 1328 | have_tcmalloc='no' |
| 1329 | TCMALLOC_LIBS='' |
| 1330 | OLIBS="$LIBS" |
| 1331 | if test "$have_threads" = 'yes' -a "$with_tcmalloc" != 'no'; then |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1332 | AC_MSG_CHECKING([tcmalloc library support]) |
Cristy | 001b1da | 2019-09-11 08:38:23 -0400 | [diff] [blame] | 1333 | AC_MSG_RESULT([]) |
| 1334 | failed=0 |
| 1335 | passed=0 |
| 1336 | |
| 1337 | AC_CHECK_LIB([tcmalloc_minimal],[mallinfo],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 1338 | |
| 1339 | if test $passed -gt 0; then |
| 1340 | if test $failed -gt 0; then |
| 1341 | have_tcmalloc='no (some components failed test)' |
| 1342 | else |
| 1343 | TCMALLOC_LIBS=-ltcmalloc_minimal |
| 1344 | LIBS="$TCMALLOC_LIBS $LIBS" |
| 1345 | CFLAGS="$CFLAGS -fno-builtin-malloc -fno-builtin-calloc -fno-builtin-realloc -fno-builtin-free" |
| 1346 | AC_DEFINE([HAVE_TCMALLOC],[1],[Define if you have the tcmalloc memory allocation library]) |
| 1347 | have_tcmalloc='yes' |
| 1348 | fi |
| 1349 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1350 | AC_MSG_CHECKING([if tcmalloc memory allocation library is complete]) |
Cristy | 001b1da | 2019-09-11 08:38:23 -0400 | [diff] [blame] | 1351 | AC_MSG_RESULT([$have_tcmalloc]) |
| 1352 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1353 | AM_CONDITIONAL([HAVE_TCMALLOC],[test "$have_tcmalloc" = 'yes']) |
Cristy | 001b1da | 2019-09-11 08:38:23 -0400 | [diff] [blame] | 1354 | AC_SUBST([TCMALLOC_LIBS]) |
| 1355 | |
| 1356 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1357 | # Check for umem. |
| 1358 | # |
| 1359 | have_umem='no' |
| 1360 | UMEM_LIBS='' |
| 1361 | if test "$with_umem" != 'no'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1362 | AC_MSG_CHECKING([for UMEM support]) |
| 1363 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1364 | failed=0 |
| 1365 | passed=0 |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1366 | AC_CHECK_HEADER([umem.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 1367 | AC_CHECK_LIB([umem],[umem_alloc],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 1368 | |
| 1369 | AC_CHECK_LIB([umem],[umem_free],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 1370 | |
| 1371 | AC_MSG_CHECKING([if umem memory allocation library is complete]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1372 | if test $passed -gt 0; then |
| 1373 | if test $failed -gt 0; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1374 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1375 | have_umem='no (failed tests)' |
| 1376 | else |
| 1377 | UMEM_LIBS='-lumem' |
| 1378 | LIBS="$UMEM_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1379 | AC_DEFINE([HAVE_UMEM],[1],[Define if you have umem memory allocation library]) |
| 1380 | AC_MSG_RESULT([yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1381 | have_umem='yes' |
| 1382 | fi |
| 1383 | else |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1384 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1385 | fi |
| 1386 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1387 | AM_CONDITIONAL([HAVE_UMEM],[test "$have_umem" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1388 | AC_SUBST([UMEM_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1389 | |
| 1390 | # |
| 1391 | # Add support for ccmalloc memory debugging library if requested |
| 1392 | # |
| 1393 | have_ccmalloc='no' |
| 1394 | CCMALLOC_LIBS='' |
| 1395 | if test "$enable_ccmalloc" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1396 | AC_PATH_PROG([CCMALLOCDelegate],[ccmalloc],[]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1397 | if test -n "$CCMALLOCDelegate"; then |
| 1398 | eval `grep PREFIX= $CCMALLOCDelegate | sed -e 's/PREFIX/CCMALLOC_PREFIX/'` |
| 1399 | OLIBS="$LIBS" |
| 1400 | # Assume that gcc is used with ccmalloc. |
| 1401 | LIBS="$LIBS $CCMALLOC_PREFIX/lib/ccmalloc-gcc.o" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1402 | AC_CHECK_LIB([ccmalloc],[ccmalloc_malloc],[CCMALLOC_LIBS="$CCMALLOC_PREFIX/lib/ccmalloc-gcc.o -lccmalloc -ldl"],[,-ldl]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1403 | if test -n "$CCMALLOC_LIBS"; then |
| 1404 | LIBS="$OLIBS" |
| 1405 | LIBS="$LIBS $CCMALLOC_LIBS" |
| 1406 | have_ccmalloc='yes' |
| 1407 | else |
| 1408 | LIBS="$OLIBS" |
| 1409 | fi |
| 1410 | fi |
| 1411 | fi |
| 1412 | |
| 1413 | # |
cristy | 944e51f | 2013-04-16 18:45:02 +0000 | [diff] [blame] | 1414 | # Add support for 'huge pages' if requested |
| 1415 | # |
| 1416 | AS_IF([test "x$enable_hugepages" != "xno"],[ |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1417 | AC_DEFINE([HAVE_HUGEPAGES],[ 1],[ [Compile with hugepage support]]) |
cristy | 944e51f | 2013-04-16 18:45:02 +0000 | [diff] [blame] | 1418 | ]) |
| 1419 | |
| 1420 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1421 | # Add support for efence memory debugging library if requested |
| 1422 | # |
| 1423 | if test "$enable_efence" = 'yes'; then |
| 1424 | EFENCE_LIBS='-lefence' |
| 1425 | LIBS="$EFENCE_LIBS $LIBS" |
| 1426 | fi |
| 1427 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1428 | dnl =========================================================================== |
| 1429 | |
| 1430 | # |
| 1431 | # Check for BZLIB |
| 1432 | # |
| 1433 | |
| 1434 | AC_ARG_WITH([bzlib], |
| 1435 | [AC_HELP_STRING([--without-bzlib], |
| 1436 | [disable BZLIB support])], |
| 1437 | [with_bzlib=$withval], |
| 1438 | [with_bzlib='yes']) |
| 1439 | |
| 1440 | if test "$with_bzlib" != 'yes'; then |
| 1441 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-bzlib=$with_bzlib " |
| 1442 | fi |
| 1443 | |
| 1444 | have_bzlib='no' |
| 1445 | if test "$with_bzlib" != 'no'; then |
| 1446 | BZLIB_LIBS='' |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1447 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1448 | AC_MSG_CHECKING([for BZLIB]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1449 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1450 | failed=0 |
| 1451 | passed=0 |
| 1452 | found_libbz=0 |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1453 | AC_CHECK_HEADER([bzlib.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 1454 | AC_CHECK_LIB([bz2],[BZ2_bzDecompress],[found_libbz=`expr $found_libbz + 1`],[],[]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1455 | if test "$native_win32_build" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1456 | AC_CHECK_LIB([bz2],[_imp__BZ2_decompress],[found_libbz=`expr $found_libbz + 1`],[],[]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1457 | fi |
| 1458 | if test $found_libbz -gt 0; then |
| 1459 | passed=`expr $passed + 1` |
| 1460 | else |
| 1461 | failed=`expr $failed + 1` |
| 1462 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1463 | AC_MSG_CHECKING([if BZLIB package is complete]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1464 | if test $passed -gt 0; then |
| 1465 | if test $failed -gt 0; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1466 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1467 | have_bzlib='no (failed tests)' |
| 1468 | else |
| 1469 | BZLIB_LIBS='-lbz2' |
| 1470 | LIBS="$BZLIB_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1471 | AC_DEFINE([BZLIB_DELEGATE],[1],[Define if you have the bzip2 library]) |
| 1472 | AC_MSG_RESULT([yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1473 | have_bzlib='yes' |
| 1474 | fi |
| 1475 | else |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1476 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1477 | fi |
| 1478 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1479 | AM_CONDITIONAL([BZLIB_DELEGATE],[test "$have_bzlib" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1480 | AC_SUBST([BZLIB_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1481 | |
| 1482 | # |
| 1483 | # Find the X11 include and library directories. |
| 1484 | # |
| 1485 | IPC_LIBS='' |
| 1486 | X11_LIBS='' |
| 1487 | XEXT_LIBS='' |
| 1488 | XT_LIBS='' |
| 1489 | AC_PATH_XTRA |
| 1490 | if test "$no_x" != 'yes'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1491 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1492 | AC_MSG_CHECKING([for X11]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1493 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1494 | LDFLAGS="$LDFLAGS $X_LIBS" |
| 1495 | X11_LIBS="$X_PRE_LIBS -lX11 $X_EXTRA_LIBS" |
| 1496 | LIBS="$X11_LIBS $LIBS" |
| 1497 | CPPFLAGS="$CPPFLAGS $X_CFLAGS" |
| 1498 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1499 | AC_DEFINE([X11_DELEGATE],[1],[Define if you have X11 library])dnl |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1500 | |
| 1501 | # |
| 1502 | # Check for X11 shared memory extension |
| 1503 | # |
| 1504 | # shmctl is required to support the shared memory extension |
| 1505 | AC_CHECK_FUNC([shmctl],[have_shmctl='yes'],[]) |
| 1506 | if test "$have_shmctl" != 'yes'; then |
| 1507 | PERSIST_LIBS=$LIBS |
| 1508 | LIBS="$LIBS -lcygipc" |
| 1509 | AC_TRY_LINK_FUNC([shmctl],[have_shmctl='yes'; IPC_LIBS='-lcygipc'],[]) |
| 1510 | LIBS=$PERSIST_LIBS |
| 1511 | fi |
| 1512 | |
| 1513 | if test "$have_shmctl" = 'yes'; then |
| 1514 | AC_CHECK_LIB([Xext],[XShmAttach],[XEXT_LIBS='-lXext' ; AC_DEFINE(HAVE_SHARED_MEMORY,1,X11 server supports shared memory extension)],[],[]) |
| 1515 | fi |
| 1516 | |
| 1517 | # |
| 1518 | # Check for X11 shape extension |
| 1519 | # |
| 1520 | AC_CHECK_LIB([Xext],[XShapeCombineMask],[XEXT_LIBS='-lXext' ; AC_DEFINE(HAVE_SHAPE,1,X11 server supports shape extension)],[],[]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1521 | AC_CHECK_LIB([Xt],[XtSetEventDispatcher],[XT_LIBS='-lXt'],[],[]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1522 | LIBS="$XEXT_LIBS $XT_LIBS $LIBS" |
| 1523 | fi |
| 1524 | if test "$no_x" != 'yes'; then |
| 1525 | have_x='yes' |
| 1526 | else |
| 1527 | have_x='no' |
| 1528 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1529 | AM_CONDITIONAL([X11_DELEGATE],[test "$have_x" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1530 | AC_SUBST([X11_LIBS]) |
| 1531 | AC_SUBST([XEXT_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1532 | |
| 1533 | dnl =========================================================================== |
| 1534 | |
| 1535 | # |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1536 | # Check for ZIP |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1537 | # |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1538 | AC_ARG_WITH([zip], |
| 1539 | [AC_HELP_STRING([--without-zip], |
| 1540 | [disable ZIP support])], |
| 1541 | [with_zip=$withval], |
| 1542 | [with_zip='yes']) |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1543 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1544 | if test "$with_zip" != 'yes'; then |
| 1545 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-zip=$with_zip " |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1546 | fi |
| 1547 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1548 | have_zip='no' |
| 1549 | ZIP_CFLAGS="" |
| 1550 | ZIP_LIBS="" |
| 1551 | ZIP_PKG="" |
| 1552 | if test "x$with_zip" = "xyes"; then |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1553 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1554 | PKG_CHECK_MODULES([ZIP],[libzip >= 1.0.0],[have_zip=yes],[have_zip=no]) |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1555 | AC_MSG_RESULT([]) |
| 1556 | fi |
| 1557 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1558 | if test "$have_zip" = 'yes'; then |
| 1559 | AC_DEFINE([ZIP_DELEGATE],[1],[Define if you have ZIP library]) |
| 1560 | CFLAGS="$ZIP_CFLAGS $CFLAGS" |
| 1561 | LIBS="$ZIP_LIBS $LIBS" |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1562 | fi |
| 1563 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1564 | AM_CONDITIONAL([ZIP_DELEGATE],[test "$have_zip" = 'yes']) |
| 1565 | AC_SUBST([ZIP_CFLAGS]) |
| 1566 | AC_SUBST([ZIP_LIBS]) |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 1567 | |
| 1568 | dnl =========================================================================== |
| 1569 | |
| 1570 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1571 | # Check for ZLIB |
| 1572 | # |
| 1573 | AC_ARG_WITH([zlib], |
| 1574 | [AC_HELP_STRING([--without-zlib], |
| 1575 | [disable ZLIB support])], |
| 1576 | [with_zlib=$withval], |
| 1577 | [with_zlib='yes']) |
| 1578 | |
| 1579 | if test "$with_zlib" != 'yes'; then |
| 1580 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-zlib=$with_zlib " |
| 1581 | fi |
| 1582 | |
| 1583 | have_zlib='no' |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1584 | ZLIB_CFLAGS="" |
| 1585 | ZLIB_LIBS="" |
| 1586 | ZLIB_PKG="" |
| 1587 | if test "x$with_zlib" = "xyes"; then |
| 1588 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1589 | PKG_CHECK_MODULES([ZLIB],[zlib >= 1.0.0],[have_zlib=yes],[have_zlib=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1590 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1591 | fi |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1592 | |
| 1593 | if test "$have_zlib" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1594 | AC_DEFINE([ZLIB_DELEGATE],[1],[Define if you have ZLIB library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1595 | CFLAGS="$ZLIB_CFLAGS $CFLAGS" |
Cristy | b94e76e | 2017-06-22 19:18:20 -0400 | [diff] [blame] | 1596 | LIBS="$ZLIB_LIBS $LIBS" |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1597 | fi |
| 1598 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1599 | AM_CONDITIONAL([ZLIB_DELEGATE],[test "$have_zlib" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1600 | AC_SUBST([ZLIB_CFLAGS]) |
| 1601 | AC_SUBST([ZLIB_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1602 | |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1603 | dnl =========================================================================== |
| 1604 | |
Cristy | 08170e6 | 2018-10-14 10:33:46 -0400 | [diff] [blame] | 1605 | # |
| 1606 | # Check for ZSTD |
| 1607 | # |
| 1608 | AC_ARG_WITH([zstd], |
| 1609 | [AC_HELP_STRING([--without-zstd], |
| 1610 | [disable ZSTD support])], |
| 1611 | [with_zstd=$withval], |
| 1612 | [with_zstd='yes']) |
| 1613 | |
| 1614 | if test "$with_zstd" != 'yes'; then |
| 1615 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-zstd=$with_zstd " |
| 1616 | fi |
| 1617 | |
| 1618 | have_zstd='no' |
| 1619 | ZSTD_CFLAGS="" |
| 1620 | ZSTD_LIBS="" |
| 1621 | ZSTD_PKG="" |
| 1622 | if test "x$with_zstd" = "xyes"; then |
| 1623 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1624 | PKG_CHECK_MODULES([LIBZSTD],[libzstd >= 1.0.0],[have_zstd=yes],[have_zstd=no]) |
Cristy | 08170e6 | 2018-10-14 10:33:46 -0400 | [diff] [blame] | 1625 | AC_MSG_RESULT([]) |
| 1626 | fi |
| 1627 | |
| 1628 | if test "$have_zstd" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1629 | AC_DEFINE([ZSTD_DELEGATE],[1],[Define if you have ZSTD library]) |
Cristy | 08170e6 | 2018-10-14 10:33:46 -0400 | [diff] [blame] | 1630 | CFLAGS="$ZSTD_CFLAGS $CFLAGS" |
| 1631 | LIBS="$ZSTD_LIBS $LIBS" |
| 1632 | fi |
| 1633 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1634 | AM_CONDITIONAL([ZSTD_DELEGATE],[test "$have_zstd" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1635 | AC_SUBST([ZSTD_CFLAGS]) |
| 1636 | AC_SUBST([ZSTD_LIBS]) |
Cristy | 08170e6 | 2018-10-14 10:33:46 -0400 | [diff] [blame] | 1637 | |
| 1638 | dnl =========================================================================== |
| 1639 | |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1640 | # whether modules are built or not. |
Dirk Lemstra | eacaed7 | 2020-09-19 12:27:35 +0200 | [diff] [blame] | 1641 | if test "$build_modules" != 'no' || test "X$no_cl" != 'Xyes'; then |
| 1642 | with_ltdl='yes' |
| 1643 | else |
| 1644 | with_ltdl='no' |
| 1645 | fi |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1646 | have_ltdl='no' |
| 1647 | LTDL_LIBS='' |
Dirk Lemstra | eacaed7 | 2020-09-19 12:27:35 +0200 | [diff] [blame] | 1648 | if test "$with_ltdl" = 'yes'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1649 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1650 | AC_MSG_CHECKING([for libltdl]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1651 | AC_MSG_RESULT([]) |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1652 | failed=0 |
| 1653 | passed=0 |
cristy | af4cbf3 | 2012-10-16 23:47:41 +0000 | [diff] [blame] | 1654 | AC_CHECK_HEADER([ltdl.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1655 | AC_CHECK_LIB([ltdl],[lt_dlinit],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
cristy | af4cbf3 | 2012-10-16 23:47:41 +0000 | [diff] [blame] | 1656 | AC_MSG_CHECKING([if libltdl package is complete]) |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1657 | if test $passed -gt 0 ; then |
| 1658 | if test $failed -gt 0 ; then |
cristy | af4cbf3 | 2012-10-16 23:47:41 +0000 | [diff] [blame] | 1659 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1660 | have_ltdl='no (failed tests)' |
| 1661 | else |
| 1662 | LTDL_LIBS='-lltdl' |
| 1663 | LIBS="$LTDL_LIBS $LIBS" |
Cristy | 93b9048 | 2020-10-05 14:57:52 +0000 | [diff] [blame] | 1664 | AC_DEFINE([LTDL_DELEGATE],[1],[Define if using libltdl to support dynamically loadable modules and OpenCL]) |
David Seifert | 21ed292a | 2017-12-16 19:01:03 +0100 | [diff] [blame] | 1665 | AC_DEFINE_UNQUOTED([LTDL_MODULE_EXT],["${shrext_cmds}"],[Native module suffix]) |
cristy | af4cbf3 | 2012-10-16 23:47:41 +0000 | [diff] [blame] | 1666 | AC_MSG_RESULT([yes]) |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1667 | have_ltdl='yes' |
| 1668 | fi |
| 1669 | else |
cristy | af4cbf3 | 2012-10-16 23:47:41 +0000 | [diff] [blame] | 1670 | AC_MSG_RESULT([no]) |
| 1671 | fi |
| 1672 | if test "$have_ltdl" != 'yes' ; then |
Cristy | 89e8349 | 2017-11-12 08:09:05 -0500 | [diff] [blame] | 1673 | AC_MSG_FAILURE([libltdl is required for modules and OpenCL builds],[1]) |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1674 | fi |
| 1675 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1676 | AM_CONDITIONAL([WITH_LTDL],[test "$have_ltdl" != 'no']) |
cristy | 5eef09f | 2012-10-16 12:08:28 +0000 | [diff] [blame] | 1677 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1678 | # |
| 1679 | # If profiling, then check for -ldl and dlopen (required for Solaris & gcc) |
| 1680 | # |
| 1681 | LIB_DL='' |
| 1682 | if test "$enable_profiling" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1683 | AC_CHECK_LIB([dl],[dlopen],[LIB_DL='-ldl'],[],[]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1684 | LIBS="$LIB_DL $LIBS" |
| 1685 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1686 | AC_SUBST([LIB_DL]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1687 | |
| 1688 | dnl =========================================================================== |
| 1689 | |
| 1690 | # |
cristy | 5a3dc99 | 2014-12-05 19:50:04 +0000 | [diff] [blame] | 1691 | # Set Apple font directory. |
| 1692 | # |
| 1693 | AC_ARG_WITH([apple-font-dir], |
| 1694 | [AC_HELP_STRING([--with-apple-font-dir=DIR], |
| 1695 | [Apple font directory])], |
| 1696 | [with_apple_font_dir=$withval], |
| 1697 | [with_apple_font_dir='default']) |
| 1698 | |
| 1699 | if test "$with_apple_font_dir" != 'default'; then |
| 1700 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-apple-font-dir=$with_apple_font_dir " |
| 1701 | fi |
| 1702 | |
| 1703 | dnl =========================================================================== |
| 1704 | |
| 1705 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1706 | # Check for Autotrace delegate library. |
| 1707 | # |
| 1708 | AC_ARG_WITH([autotrace], |
| 1709 | [AC_HELP_STRING([--with-autotrace], |
| 1710 | [enable autotrace support])], |
| 1711 | [with_autotrace=$withval], |
| 1712 | [with_autotrace='no']) |
| 1713 | |
| 1714 | if test "$with_autotrace" != 'yes'; then |
| 1715 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-autotrace=$with_autotrace " |
| 1716 | fi |
| 1717 | |
| 1718 | have_autotrace='no' |
| 1719 | AUTOTRACE_CFLAGS="" |
| 1720 | AUTOTRACE_LIBS="" |
| 1721 | AUTOTRACE_PKG="" |
| 1722 | if test "x$with_autotrace" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1723 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1724 | PKG_CHECK_MODULES([AUTOTRACE],[autotrace >= 0.31.2],[have_autotrace=yes],[have_autotrace=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1725 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1726 | fi |
| 1727 | |
| 1728 | if test "$have_autotrace" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1729 | AC_DEFINE([AUTOTRACE_DELEGATE],[1],[Define if you have AUTOTRACE library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1730 | CFLAGS="$AUTOTRACE_CFLAGS $CFLAGS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1731 | fi |
| 1732 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1733 | AM_CONDITIONAL([AUTOTRACE_DELEGATE],[test "$have_autotrace" = 'yes']) |
| 1734 | AC_SUBST([AUTOTRACE_CFLAGS]) |
| 1735 | AC_SUBST([AUTOTRACE_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1736 | |
| 1737 | dnl =========================================================================== |
| 1738 | |
| 1739 | # |
| 1740 | # Check for Display Postscript delegate library. |
| 1741 | # |
| 1742 | AC_ARG_WITH([dps], |
| 1743 | [AC_HELP_STRING([--without-dps], |
| 1744 | [disable Display Postscript support])], |
| 1745 | [with_dps=$withval], |
| 1746 | [with_dps='yes']) |
| 1747 | |
| 1748 | if test "$with_dps" != 'yes'; then |
| 1749 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-dps=$with_dps " |
| 1750 | fi |
| 1751 | |
| 1752 | have_dps='no' |
| 1753 | DPS_LIBS='' |
| 1754 | if test "$with_dps" != 'no' && test "$with_x" != 'no'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1755 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1756 | AC_MSG_CHECKING([for DPS]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1757 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1758 | failed=0 |
| 1759 | passed=0 |
| 1760 | PERSIST_CPPFLAGS="$CPPFLAGS" |
| 1761 | CPPFLAGS="$CPPFLAGS -I${ac_x_includes}/X11" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1762 | AC_CHECK_HEADER([DPS/dpsXclient.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1763 | # DPS issues: |
| 1764 | # XFree86-4.x needs -lXt to provide XtMalloc for -ldps. |
| 1765 | # Cygwin doesn't deliver -lXt as a DLL, which prevents a DLL build. |
| 1766 | # Adobe DPS (as delivered on Solaris) doesn't require -lXt. |
| 1767 | # ImageMagick itself doesn't use -lXt. |
| 1768 | have_libdps='no' |
| 1769 | LIBDPS_XT='' |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1770 | AC_CHECK_LIB([dps],[DPSInitialize],[have_libdps='yes'],[have_libdps='no',]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1771 | if test "$have_libdps" != 'yes'; then |
| 1772 | # Unset cache variable so we can try again. |
| 1773 | unset ac_cv_lib_dps_DPSInitialize |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1774 | AC_CHECK_LIB([dps],[DPSInitialize],[have_libdps='yes'],[have_libdps='no',-lXt]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1775 | if test "$have_libdps" = 'yes'; then |
| 1776 | LIBDPS_XT='-lXt' |
| 1777 | fi |
| 1778 | fi |
| 1779 | if test "$have_libdps" = 'yes'; then |
| 1780 | passed=`expr $passed + 1` |
| 1781 | else |
| 1782 | failed=`expr $failed + 1` |
| 1783 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1784 | AC_CHECK_LIB([dpstk],[XDPSPixelsPerPoint],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`,-ldps $LIBDPS_XT]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1785 | AC_MSG_CHECKING([if DPS package is complete]) |
| 1786 | if test $passed -gt 0; then |
| 1787 | if test $failed -gt 0; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1788 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1789 | have_dps='no (failed tests)' |
| 1790 | CPPFLAGS="$PERSIST_CPPFLAGS" |
| 1791 | else |
| 1792 | DPS_LIBS="-ldpstk -ldps ${LIBDPS_XT}" |
| 1793 | LIBS="$DPS_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1794 | AC_DEFINE([DPS_DELEGATE],[1],[Define if you have Display Postscript]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1795 | AC_MSG_RESULT([yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1796 | have_dps='yes' |
| 1797 | fi |
| 1798 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1799 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1800 | CPPFLAGS=$PERSIST_CPPFLAGS |
| 1801 | fi |
| 1802 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1803 | AM_CONDITIONAL([DPS_DELEGATE],[test "$have_dps" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1804 | AC_SUBST([DPS_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1805 | |
| 1806 | dnl =========================================================================== |
| 1807 | |
| 1808 | # |
cristy | 430a731 | 2010-01-21 20:44:04 +0000 | [diff] [blame] | 1809 | # Set DejaVu font directory. |
| 1810 | # |
| 1811 | AC_ARG_WITH([dejavu-font-dir], |
| 1812 | [AC_HELP_STRING([--with-dejavu-font-dir=DIR], |
| 1813 | [DejaVu font directory])], |
| 1814 | [with_dejavu_font_dir=$withval], |
| 1815 | [with_dejavu_font_dir='default']) |
| 1816 | |
| 1817 | if test "$with_dejavu_font_dir" != 'default'; then |
| 1818 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-dejavu-font-dir=$with_dejavu_font_dir " |
| 1819 | fi |
| 1820 | |
| 1821 | dnl =========================================================================== |
| 1822 | |
| 1823 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1824 | # Check for FFTW delegate library. |
| 1825 | # |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 1826 | AC_ARG_WITH([fftw], |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1827 | [AC_HELP_STRING([--with-fftw], |
| 1828 | [enable FFTW support])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1829 | [with_fftw=$withval], |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1830 | [with_fftw='no']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1831 | |
| 1832 | if test "$with_fftw" != 'yes'; then |
| 1833 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-fftw=$with_fftw " |
| 1834 | fi |
| 1835 | |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 1836 | have_fftw='no' |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1837 | FFTW_CFLAGS="" |
| 1838 | FFTW_LIBS="" |
| 1839 | FFTW_PKG="" |
| 1840 | if test "x$with_fftw" = "xyes"; then |
| 1841 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1842 | PKG_CHECK_MODULES([fftw3],[fftw3 >= 3.0.0],[have_fftw=yes],[have_fftw=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1843 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1844 | fi |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1845 | |
| 1846 | if test "$have_fftw" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1847 | AC_DEFINE([FFTW_DELEGATE],[1],[Define if you have FFTW library]) |
cristy | b74ab6e | 2015-06-06 12:39:54 +0000 | [diff] [blame] | 1848 | FFTW_CFLAGS="$fftw3_CFLAGS" |
| 1849 | FFTW_LIBS="$fftw3_LIBS" |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1850 | CFLAGS="$fftw3_CFLAGS $CFLAGS" |
| 1851 | fi |
| 1852 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1853 | AM_CONDITIONAL([FFTW_DELEGATE],[test "$have_fftw" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1854 | AC_SUBST([FFTW_CFLAGS]) |
| 1855 | AC_SUBST([FFTW_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1856 | |
| 1857 | dnl =========================================================================== |
| 1858 | |
| 1859 | # |
Cristy | 6d2f14b | 2016-04-26 01:41:09 -0400 | [diff] [blame] | 1860 | # Check for FLIF delegate library. |
| 1861 | # |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1862 | AC_ARG_WITH([flif], |
Cristy | 6d2f14b | 2016-04-26 01:41:09 -0400 | [diff] [blame] | 1863 | [AC_HELP_STRING([--without-flif], |
| 1864 | [disable FLIF support])], |
| 1865 | [with_flif=$withval], |
| 1866 | [with_flif='yes']) |
| 1867 | |
| 1868 | if test "$with_flif" != 'yes'; then |
| 1869 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-flif=$with_flif " |
| 1870 | fi |
| 1871 | |
| 1872 | have_flif='no' |
| 1873 | FLIF_LIBS='' |
| 1874 | if test "$with_flif" != 'no'; then |
| 1875 | AC_MSG_RESULT([-------------------------------------------------------------]) |
| 1876 | AC_MSG_CHECKING([for FLIF]) |
| 1877 | AC_MSG_RESULT([]) |
| 1878 | failed=0 |
| 1879 | passed=0 |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1880 | AC_CHECK_HEADER([flif.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 1881 | AC_CHECK_LIB([flif],[flif_create_decoder],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
Cristy | 6d2f14b | 2016-04-26 01:41:09 -0400 | [diff] [blame] | 1882 | AC_MSG_CHECKING([if FLIF package is complete]) |
| 1883 | if test $passed -gt 0; then |
| 1884 | if test $failed -gt 0; then |
| 1885 | AC_MSG_RESULT([no -- some components failed test]) |
| 1886 | have_flif='no (failed tests)' |
| 1887 | else |
| 1888 | FLIF_LIBS='-lflif' |
| 1889 | LIBS="$FLIF_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1890 | AC_DEFINE([FLIF_DELEGATE],[1],[Define if you have FLIF library]) |
Cristy | 6d2f14b | 2016-04-26 01:41:09 -0400 | [diff] [blame] | 1891 | AC_MSG_RESULT([yes]) |
| 1892 | have_flif='yes' |
| 1893 | fi |
| 1894 | else |
| 1895 | AC_MSG_RESULT([no]) |
| 1896 | fi |
| 1897 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1898 | AM_CONDITIONAL([FLIF_DELEGATE],[test "$have_flif" = 'yes']) |
| 1899 | AC_SUBST([FLIF_LIBS]) |
Cristy | 6d2f14b | 2016-04-26 01:41:09 -0400 | [diff] [blame] | 1900 | |
| 1901 | dnl =========================================================================== |
| 1902 | |
| 1903 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1904 | # Check for FlashPIX delegate library. |
| 1905 | # |
| 1906 | AC_ARG_WITH([fpx], |
| 1907 | [AC_HELP_STRING([--without-fpx], |
| 1908 | [disable FlashPIX support])], |
| 1909 | [with_fpx=$withval], |
| 1910 | [with_fpx='yes']) |
| 1911 | |
| 1912 | if test "$with_fpx" != 'yes'; then |
| 1913 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-fpx=$with_fpx " |
| 1914 | fi |
| 1915 | |
| 1916 | have_fpx='no' |
| 1917 | FPX_LIBS='' |
| 1918 | if test "$with_fpx" != 'no'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1919 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1920 | AC_MSG_CHECKING([for FlashPIX]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1921 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1922 | failed=0 |
| 1923 | passed=0 |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1924 | AC_LANG_PUSH([C++]) |
| 1925 | AC_CHECK_HEADER([fpxlib.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 1926 | AC_CHECK_LIB([fpx],[FPX_OpenImageByFilename],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 1927 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1928 | AC_LANG_POP |
| 1929 | AC_MSG_CHECKING([if FlashPIX package is complete]) |
| 1930 | if test $passed -gt 0; then |
| 1931 | if test $failed -gt 0; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1932 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1933 | have_fpx='no (failed tests)' |
| 1934 | else |
| 1935 | FPX_LIBS='-lfpx' |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1936 | AC_DEFINE([FPX_DELEGATE],[1],[Define if you have FlashPIX library]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1937 | AC_MSG_RESULT([yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1938 | have_fpx='yes' |
| 1939 | PERLMAINCC="$CXX" |
| 1940 | fi |
| 1941 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 1942 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1943 | fi |
| 1944 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1945 | AM_CONDITIONAL([FPX_DELEGATE],[test "$have_fpx" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1946 | AC_SUBST([FPX_LIBS]) |
cristy | 853d990 | 2014-08-21 18:50:43 +0000 | [diff] [blame] | 1947 | |
| 1948 | dnl =========================================================================== |
| 1949 | |
| 1950 | # |
| 1951 | # Check for DJVU delegate library. |
| 1952 | # |
| 1953 | AC_ARG_WITH([djvu], |
| 1954 | [AC_HELP_STRING([--without-djvu], |
| 1955 | [disable DjVu support])], |
| 1956 | [with_djvu=$withval], |
| 1957 | [with_djvu='yes']) |
| 1958 | |
| 1959 | if test "$with_djvu" != 'yes'; then |
| 1960 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-djvu=$with_djvu " |
| 1961 | fi |
| 1962 | |
| 1963 | have_djvu='no' |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1964 | DJVU_CFLAGS="" |
| 1965 | DJVU_LIBS="" |
| 1966 | DJVU_PKG="" |
| 1967 | if test "x$with_djvu" = "xyes"; then |
| 1968 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1969 | PKG_CHECK_MODULES([ddjvuapi],[ddjvuapi >= 3.5.0],[have_djvu=yes],[have_djvu=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1970 | AC_MSG_RESULT([]) |
cristy | 853d990 | 2014-08-21 18:50:43 +0000 | [diff] [blame] | 1971 | fi |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1972 | |
| 1973 | if test "$have_djvu" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1974 | AC_DEFINE([DJVU_DELEGATE],[1],[Define if you have DJVU library]) |
cristy | c83c2cc | 2015-06-06 16:35:26 +0000 | [diff] [blame] | 1975 | DJVU_CFLAGS="$ddjvuapi_CFLAGS" |
| 1976 | DJVU_LIBS="$ddjvuapi_LIBS" |
| 1977 | CFLAGS="$ddjvuapi_CFLAGS $CFLAGS" |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 1978 | fi |
| 1979 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 1980 | AM_CONDITIONAL([DJVU_DELEGATE],[test "$have_djvu" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 1981 | AC_SUBST([DJVU_CFLAGS]) |
| 1982 | AC_SUBST([DJVU_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1983 | |
| 1984 | dnl =========================================================================== |
| 1985 | |
| 1986 | # |
| 1987 | # Check for fontconfig delegate library. |
| 1988 | # |
| 1989 | AC_ARG_WITH([fontconfig], |
| 1990 | [AC_HELP_STRING([--without-fontconfig], |
| 1991 | [disable fontconfig support])], |
| 1992 | [with_fontconfig=$withval], |
cristy | fc3d022 | 2012-02-07 15:05:57 +0000 | [diff] [blame] | 1993 | [with_fontconfig='yes']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 1994 | |
| 1995 | if test "$with_fontconfig" != 'yes'; then |
| 1996 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-fontconfig=$with_fontconfig " |
| 1997 | fi |
| 1998 | |
| 1999 | have_fontconfig='no' |
| 2000 | FONTCONFIG_CFLAGS="" |
| 2001 | FONTCONFIG_LIBS="" |
| 2002 | FONTCONFIG_PKG="" |
| 2003 | if test "x$with_fontconfig" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2004 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2005 | PKG_CHECK_MODULES([FONTCONFIG],[fontconfig >= 2.1.0],[have_fontconfig=yes],[have_fontconfig=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2006 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2007 | fi |
| 2008 | |
| 2009 | if test "$have_fontconfig" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2010 | AC_DEFINE([FONTCONFIG_DELEGATE],[1],[Define if you have FONTCONFIG library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2011 | CFLAGS="$FONTCONFIG_CFLAGS $CFLAGS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2012 | fi |
| 2013 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2014 | AM_CONDITIONAL([FONTCONFIG_DELEGATE],[test "$have_fontconfig" = 'yes']) |
| 2015 | AC_SUBST([FONTCONFIG_CFLAGS]) |
| 2016 | AC_SUBST([FONTCONFIG_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2017 | |
| 2018 | dnl =========================================================================== |
| 2019 | |
| 2020 | # |
cristy | 03f187e | 2013-01-24 00:22:19 +0000 | [diff] [blame] | 2021 | # Check for the Freetype delegate library. |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2022 | # |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2023 | AC_ARG_WITH([freetype], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2024 | [AC_HELP_STRING([--without-freetype], |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2025 | [disable Freetype support])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2026 | [with_freetype=$withval], |
| 2027 | [with_freetype='yes']) |
| 2028 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2029 | if test "$with_freetype" != 'yes'; then |
| 2030 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-freetype=$with_freetype " |
| 2031 | fi |
| 2032 | |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2033 | have_freetype='no' |
cristy | 03f187e | 2013-01-24 00:22:19 +0000 | [diff] [blame] | 2034 | FREETYPE_CFLAGS="" |
| 2035 | FREETYPE_LIBS="" |
| 2036 | FREETYPE_PKG="" |
| 2037 | if test "x$with_freetype" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2038 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2039 | PKG_CHECK_MODULES([FREETYPE],[freetype2],[have_freetype=yes],[have_freetype=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2040 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2041 | fi |
cristy | 03f187e | 2013-01-24 00:22:19 +0000 | [diff] [blame] | 2042 | |
| 2043 | if test "$have_freetype" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2044 | AC_DEFINE([FREETYPE_DELEGATE],[1],[Define if you have FREETYPE library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2045 | CFLAGS="$FREETYPE_CFLAGS $CFLAGS" |
Cristy | ed7fd17 | 2019-12-07 10:52:28 -0500 | [diff] [blame] | 2046 | MAGICKCORE_FREETYPE_DELEGATE=1 |
| 2047 | else |
| 2048 | MAGICKCORE_FREETYPE_DELEGATE=0 |
cristy | 03f187e | 2013-01-24 00:22:19 +0000 | [diff] [blame] | 2049 | fi |
| 2050 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2051 | AC_SUBST([FREETYPE_CFLAGS]) |
| 2052 | AC_SUBST([FREETYPE_LIBS]) |
Cristy | ed7fd17 | 2019-12-07 10:52:28 -0500 | [diff] [blame] | 2053 | AC_SUBST([MAGICKCORE_FREETYPE_DELEGATE]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2054 | |
| 2055 | dnl =========================================================================== |
| 2056 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2057 | # |
Cristy | 17f8c72 | 2016-01-31 09:42:56 -0500 | [diff] [blame] | 2058 | # Check for the raqm delegate library. |
| 2059 | # |
| 2060 | AC_ARG_WITH([raqm], |
| 2061 | [AC_HELP_STRING([--without-raqm], |
| 2062 | [disable Raqm support])], |
| 2063 | [with_raqm=$withval], |
| 2064 | [with_raqm='yes']) |
| 2065 | |
| 2066 | if test "$with_raqm" != 'yes'; then |
| 2067 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-raqm=$with_raqm " |
| 2068 | fi |
| 2069 | |
| 2070 | have_raqm='no' |
| 2071 | RAQM_CFLAGS="" |
| 2072 | RAQM_LIBS="" |
| 2073 | RAQM_PKG="" |
| 2074 | if test "x$with_raqm" = "xyes"; then |
| 2075 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2076 | PKG_CHECK_MODULES([RAQM],[raqm],[have_raqm=yes],[have_raqm=no]) |
Cristy | 17f8c72 | 2016-01-31 09:42:56 -0500 | [diff] [blame] | 2077 | AC_MSG_RESULT([]) |
| 2078 | fi |
| 2079 | |
| 2080 | if test "$have_raqm" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2081 | AC_DEFINE([RAQM_DELEGATE],[1],[Define if you have RAQM library]) |
Cristy | 17f8c72 | 2016-01-31 09:42:56 -0500 | [diff] [blame] | 2082 | CFLAGS="$RAQM_CFLAGS $CFLAGS" |
| 2083 | fi |
| 2084 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2085 | AM_CONDITIONAL([RAQM_DELEGATE],[test "$have_raqm" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2086 | AC_SUBST([RAQM_CFLAGS]) |
| 2087 | AC_SUBST([RAQM_LIBS]) |
Cristy | 17f8c72 | 2016-01-31 09:42:56 -0500 | [diff] [blame] | 2088 | |
| 2089 | dnl =========================================================================== |
| 2090 | |
| 2091 | # |
Cristy | cf715c7 | 2020-12-30 07:48:03 -0500 | [diff] [blame] | 2092 | # Enable Windows gdi32 libraries |
| 2093 | # |
| 2094 | AC_ARG_WITH([gdi32], |
| 2095 | AS_HELP_STRING([--without-gdi32], |
| 2096 | [disable Windows gdi32 support]), |
| 2097 | [with_gdi32=$withval], |
| 2098 | [with_gdi32='yes']) |
| 2099 | if test "$with_gdi32" != 'yes' ; then |
| 2100 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-gdi32=$with_gdi32 " |
| 2101 | fi |
| 2102 | |
| 2103 | # |
| 2104 | # Check for Windows gdi32 library. |
| 2105 | # |
| 2106 | have_gdi32='no' |
| 2107 | if test "$with_gdi32" != 'no'; then |
| 2108 | GDI32_LIBS='' |
| 2109 | AC_MSG_CHECKING([for Windows GDI32 support]) |
| 2110 | AC_MSG_RESULT() |
| 2111 | failed=0 |
| 2112 | passed=0 |
Cristy | cf715c7 | 2020-12-30 07:48:03 -0500 | [diff] [blame] | 2113 | AC_CHECK_HEADER([windows.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2114 | AC_CHECK_HEADER([winuser.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[#include <windows.h>]) |
| 2115 | AC_CHECK_HEADER([wingdi.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[#include <windows.h>]) |
Cristy | c459e8f | 2021-01-01 15:28:24 -0500 | [diff] [blame] | 2116 | if test "$cygwin_build" = yes -o "$native_win32_build" = yes; then |
Cristy | cf715c7 | 2020-12-30 07:48:03 -0500 | [diff] [blame] | 2117 | passed=`expr $passed + 1` |
Cristy | cf715c7 | 2020-12-30 07:48:03 -0500 | [diff] [blame] | 2118 | fi |
| 2119 | AC_MSG_CHECKING([if Windows GDI32 support is complete]) |
| 2120 | if test $passed -gt 0; then |
| 2121 | if test $failed -gt 0; then |
| 2122 | AC_MSG_RESULT([no -- some components failed test]) |
| 2123 | have_gdi32='no (failed tests)' |
| 2124 | else |
| 2125 | GDI32_LIBS='-lgdi32 -luser32' |
| 2126 | LIBS="$GDI32_LIBS $LIBS" |
| 2127 | AC_DEFINE([WINGDI32_DELEGATE],[1],[Define to use the Windows GDI32 library]) |
| 2128 | AC_MSG_RESULT([yes]) |
| 2129 | have_gdi32='yes' |
| 2130 | fi |
| 2131 | else |
| 2132 | AC_MSG_RESULT([no]) |
| 2133 | fi |
| 2134 | fi |
| 2135 | AM_CONDITIONAL([WINGDI32_DELEGATE], [test "$have_gdi32" = 'yes']) |
| 2136 | AC_SUBST([GDI32_LIBS]) |
| 2137 | |
| 2138 | |
| 2139 | dnl =========================================================================== |
| 2140 | |
| 2141 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2142 | # Check for Ghostscript library or framework. |
| 2143 | # |
| 2144 | # Test for iapi.h & test for gsapi_new_instance in -lgs |
| 2145 | # or -framework Ghostscript |
| 2146 | |
| 2147 | AC_ARG_WITH([gslib], |
cristy | 8d733f4 | 2013-03-04 11:27:54 +0000 | [diff] [blame] | 2148 | [AC_HELP_STRING([--with-gslib], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2149 | [enable Ghostscript library support])], |
| 2150 | [with_gslib=$withval], |
| 2151 | [with_gslib='no']) |
| 2152 | |
cristy | b7931f1 | 2009-09-25 10:22:21 +0000 | [diff] [blame] | 2153 | gslib_framework='no' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2154 | if test "$with_gslib" != 'yes'; then |
| 2155 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-gslib=$with_gslib " |
| 2156 | fi |
| 2157 | |
| 2158 | have_gslib='no' |
| 2159 | GS_LIBS='' |
| 2160 | if test "$with_gslib" != 'no'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2161 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2162 | AC_MSG_CHECKING([for Ghostscript]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2163 | AC_MSG_RESULT([]) |
cristy | b7931f1 | 2009-09-25 10:22:21 +0000 | [diff] [blame] | 2164 | framework=0 |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2165 | failed=0 |
| 2166 | passed=0 |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2167 | AC_CHECK_HEADER([ghostscript/iapi.h],[passed=`expr $passed + 1`], |
| 2168 | [failed=`expr $failed + 1`],[]) |
| 2169 | AC_CHECK_HEADER([ghostscript/ierrors.h],[passed=`expr $passed + 1`], |
| 2170 | [failed=`expr $failed + 1`],[]) |
| 2171 | AC_CHECK_FRAMEWORK([Ghostscript],[gsapi_new_instance],[framework=`expr $framework + 1`], |
| 2172 | AC_CHECK_LIB([gs],[gsapi_new_instance],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]),[]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2173 | AC_MSG_CHECKING([if Ghostscript package is complete]) |
| 2174 | if test $passed -gt 0; then |
| 2175 | if test $failed -gt 0; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2176 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2177 | have_gslib='no (failed tests)' |
| 2178 | else |
| 2179 | if test $framework -gt 0; then |
| 2180 | GS_LIBS='-framework Ghostscript' |
cristy | b7931f1 | 2009-09-25 10:22:21 +0000 | [diff] [blame] | 2181 | gslib_framework='yes' |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2182 | AC_MSG_RESULT([yes, using framework.]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2183 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2184 | AC_MSG_RESULT([yes, using library.]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2185 | GS_LIBS='-lgs' |
| 2186 | fi |
| 2187 | LIBS="$GS_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2188 | AC_DEFINE([GS_DELEGATE],[1],[Define if you have Ghostscript library or framework]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2189 | have_gslib='yes' |
| 2190 | fi |
| 2191 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2192 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2193 | fi |
| 2194 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2195 | AM_CONDITIONAL([GS_DELEGATE],[test "$have_gslib" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2196 | AC_SUBST([GS_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2197 | |
| 2198 | # Set default font search path |
| 2199 | AC_ARG_WITH([fontpath], |
| 2200 | [AC_HELP_STRING([--with-fontpath=DIR], |
| 2201 | [prepend to default font search path])], |
| 2202 | [with_fontpath=$withval], |
| 2203 | [with_fontpath='']) |
| 2204 | |
| 2205 | if test "$with_fontpath" != "yes" && test -z "$with_fontpath"; then |
| 2206 | with_fontpath='' |
| 2207 | else |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2208 | AC_DEFINE_UNQUOTED([MAGICK_FONT_PATH],["$with_fontpath"],[Define to prepend to default font search path.]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2209 | fi |
| 2210 | if test "$with_fontpath=" != ''; then |
| 2211 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-fontpath=$with_fontpath " |
| 2212 | fi |
| 2213 | |
| 2214 | # Set Ghostscript font directory |
| 2215 | AC_ARG_WITH([gs-font-dir], |
| 2216 | [AC_HELP_STRING([--with-gs-font-dir=DIR], |
| 2217 | [Ghostscript font directory])], |
| 2218 | [with_gs_font_dir=$withval], |
| 2219 | [with_gs_font_dir='default']) |
| 2220 | |
| 2221 | if test "$with_gs_font_dir" != 'default'; then |
| 2222 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-gs-font-dir=$with_gs_font_dir " |
| 2223 | fi |
| 2224 | |
| 2225 | dnl =========================================================================== |
| 2226 | |
| 2227 | # |
| 2228 | # Check for GVC delegate library. |
| 2229 | # |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2230 | AC_ARG_WITH([gvc], |
cristy | 24aeba9 | 2012-06-26 12:22:26 +0000 | [diff] [blame] | 2231 | [AC_HELP_STRING([--with-gvc], |
cristy | 8d733f4 | 2013-03-04 11:27:54 +0000 | [diff] [blame] | 2232 | [enable GVC support])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2233 | [with_gvc=$withval], |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 2234 | [with_gvc='yes']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2235 | |
| 2236 | if test "$with_gvc" != 'yes'; then |
| 2237 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-gvc=$with_gvc " |
| 2238 | fi |
| 2239 | |
| 2240 | GVC_PKG="" |
| 2241 | if test "x$with_gvc" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2242 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2243 | PKG_CHECK_MODULES([GVC],[libgvc >= 2.9.0],[have_gvc=yes],[have_gvc=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2244 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2245 | fi |
| 2246 | |
| 2247 | if test "$have_gvc" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2248 | AC_DEFINE([GVC_DELEGATE],[1],[Define if you have GVC library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2249 | CFLAGS="$GVC_CFLAGS $CFLAGS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2250 | fi |
| 2251 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2252 | AM_CONDITIONAL([GVC_DELEGATE],[test "$have_gvc" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2253 | AC_SUBST([GVC_CFLAGS]) |
| 2254 | AC_SUBST([GVC_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2255 | |
| 2256 | dnl =========================================================================== |
| 2257 | |
| 2258 | # |
Cristy | 9e7b981 | 2017-11-19 09:35:36 -0500 | [diff] [blame] | 2259 | # Check for the HEIC delegate library. |
| 2260 | # |
| 2261 | AC_ARG_WITH([heic], |
| 2262 | [AC_HELP_STRING([--without-heic], |
| 2263 | [disable HEIC support])], |
| 2264 | [with_heic=$withval], |
| 2265 | [with_heic='yes']) |
| 2266 | |
| 2267 | if test "$with_heic" != 'yes'; then |
| 2268 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-heic=$with_heic " |
| 2269 | fi |
| 2270 | |
| 2271 | have_heic='no' |
farindk | 4179457 | 2018-04-27 10:26:21 +0200 | [diff] [blame] | 2272 | HEIF_CFLAGS="" |
| 2273 | HEIF_LIBS="" |
| 2274 | HEIF_PKG="" |
Cristy | 9e7b981 | 2017-11-19 09:35:36 -0500 | [diff] [blame] | 2275 | if test "x$with_heic" = "xyes"; then |
| 2276 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2277 | PKG_CHECK_MODULES([HEIF],[libheif],[have_heic=yes],[have_heic=no]) |
Cristy | 9e7b981 | 2017-11-19 09:35:36 -0500 | [diff] [blame] | 2278 | AC_MSG_RESULT([]) |
| 2279 | fi |
| 2280 | |
| 2281 | if test "$have_heic" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2282 | AC_DEFINE([HEIC_DELEGATE],[1],[Define if you have libheif library]) |
farindk | 4179457 | 2018-04-27 10:26:21 +0200 | [diff] [blame] | 2283 | CFLAGS="$HEIF_CFLAGS $CFLAGS" |
Cristy | 9e7b981 | 2017-11-19 09:35:36 -0500 | [diff] [blame] | 2284 | fi |
| 2285 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2286 | AM_CONDITIONAL([HEIC_DELEGATE],[test "$have_heic" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2287 | AC_SUBST([HEIF_CFLAGS]) |
| 2288 | AC_SUBST([HEIF_LIBS]) |
Cristy | 9e7b981 | 2017-11-19 09:35:36 -0500 | [diff] [blame] | 2289 | |
| 2290 | dnl =========================================================================== |
| 2291 | |
| 2292 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2293 | # Check for JBIG delegate library. |
| 2294 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2295 | AC_ARG_WITH([jbig], |
| 2296 | [AC_HELP_STRING([--without-jbig], |
| 2297 | [disable JBIG support])], |
| 2298 | [with_jbig=$withval], |
| 2299 | [with_jbig='yes']) |
| 2300 | |
| 2301 | have_jbig='no' |
| 2302 | JBIG_LIBS='' |
| 2303 | if test "$with_jbig" != 'no'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2304 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2305 | AC_MSG_CHECKING([for JBIG]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2306 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2307 | failed=0 |
| 2308 | passed=0 |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2309 | AC_CHECK_HEADER([jbig.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2310 | AC_CHECK_LIB([jbig],[jbg_dec_init],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 2311 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2312 | AC_MSG_CHECKING([if JBIG package is complete]) |
| 2313 | if test $passed -gt 0; then |
| 2314 | if test $failed -gt 0; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2315 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2316 | have_jbig='no (failed tests)' |
| 2317 | else |
| 2318 | JBIG_LIBS='-ljbig' |
| 2319 | LIBS="$JBIG_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2320 | AC_DEFINE([JBIG_DELEGATE],[1],[Define if you have JBIG library]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2321 | AC_MSG_RESULT([yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2322 | have_jbig='yes' |
| 2323 | fi |
| 2324 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2325 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2326 | fi |
| 2327 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2328 | AM_CONDITIONAL([JBIG_DELEGATE],[test "$have_jbig" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2329 | AC_SUBST([JBIG_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2330 | |
| 2331 | dnl =========================================================================== |
| 2332 | |
| 2333 | # |
| 2334 | # Check for JPEG delegate library. |
| 2335 | # |
| 2336 | AC_ARG_WITH([jpeg], |
| 2337 | [AC_HELP_STRING([--without-jpeg], |
| 2338 | [disable JPEG support])], |
| 2339 | [with_jpeg=$withval], |
| 2340 | [with_jpeg='yes']) |
| 2341 | |
| 2342 | if test "$with_jpeg" != 'yes'; then |
| 2343 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-jpeg=$with_jpeg " |
| 2344 | fi |
| 2345 | |
| 2346 | have_jpeg='no' |
| 2347 | JPEG_LIBS='' |
| 2348 | if test "$with_jpeg" != 'no'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2349 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2350 | AC_MSG_CHECKING([for JPEG]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2351 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2352 | failed=0 |
| 2353 | passed=0 |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2354 | AC_CHECK_HEADER([jconfig.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2355 | AC_CHECK_HEADER([jerror.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2356 | AC_CHECK_HEADER([jmorecfg.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2357 | AC_CHECK_HEADER([jpeglib.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2358 | AC_CHECK_LIB([jpeg],[jpeg_read_header],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 2359 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2360 | AC_MSG_CHECKING([if JPEG package is complete]) |
| 2361 | if test $passed -gt 0; then |
| 2362 | if test $failed -gt 0; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2363 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2364 | have_jpeg='no (failed tests)' |
| 2365 | else |
| 2366 | JPEG_LIBS='-ljpeg' |
| 2367 | LIBS="$JPEG_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2368 | AC_DEFINE([JPEG_DELEGATE],[1],[Define if you have JPEG library]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2369 | AC_MSG_RESULT([yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2370 | have_jpeg='yes' |
| 2371 | fi |
| 2372 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2373 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2374 | fi |
| 2375 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2376 | AM_CONDITIONAL([JPEG_DELEGATE],[test "$have_jpeg" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2377 | AC_SUBST([JPEG_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2378 | |
| 2379 | dnl =========================================================================== |
| 2380 | |
| 2381 | # |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2382 | # Check for JPEG-XL delegate library. |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2383 | # |
| 2384 | AC_ARG_WITH([jxl], |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2385 | [AC_HELP_STRING([--with-jxl], |
| 2386 | [enable JPEG-XL support])], |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2387 | [with_jxl=$withval], |
Cristy | 5b7d1b7 | 2020-12-28 10:37:01 -0500 | [diff] [blame] | 2388 | [with_jxl='no']) |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2389 | |
| 2390 | if test "$with_jxl" != 'yes'; then |
| 2391 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-jxl=$with_jxl " |
| 2392 | fi |
Dirk Lemstra | 133411f | 2020-12-29 01:31:45 +0100 | [diff] [blame] | 2393 | if test "$enable_static" = 'yes'; then |
| 2394 | if test "$with_utilities" = 'yes'; then |
| 2395 | with_jxl='no' |
| 2396 | fi |
| 2397 | fi |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2398 | |
Cristy | b0314b2 | 2020-12-26 07:59:17 -0500 | [diff] [blame] | 2399 | # Check for the JPEG-XL library. |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2400 | have_jxl='no' |
| 2401 | JXL_LIBS='' |
| 2402 | if test "$with_jxl" != 'no'; then |
| 2403 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | b0314b2 | 2020-12-26 07:59:17 -0500 | [diff] [blame] | 2404 | AC_MSG_CHECKING([for jpeg-xl]) |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2405 | AC_MSG_RESULT([]) |
| 2406 | failed=0 |
| 2407 | passed=0 |
Cristy | b0314b2 | 2020-12-26 07:59:17 -0500 | [diff] [blame] | 2408 | AC_CHECK_HEADER([jxl/decode.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2409 | AC_CHECK_HEADER([jxl/encode.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
Dirk Lemstra | 133411f | 2020-12-29 01:31:45 +0100 | [diff] [blame] | 2410 | # This check should be changed once we have a .pc file for the JPEG-XL library. |
| 2411 | if test "$enable_static" != 'yes'; then |
| 2412 | AC_CHECK_LIB([jxl],[JxlDecoderCreate],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2413 | AC_CHECK_LIB([jxl],[JxlEncoderSetBasicInfo],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
Dirk Lemstra | 133411f | 2020-12-29 01:31:45 +0100 | [diff] [blame] | 2414 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2415 | |
Cristy | b0314b2 | 2020-12-26 07:59:17 -0500 | [diff] [blame] | 2416 | AC_MSG_CHECKING([if jpeg-xl package is complete]) |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2417 | if test $passed -gt 0; then |
| 2418 | if test $failed -gt 0; then |
| 2419 | AC_MSG_RESULT([no -- some components failed test]) |
| 2420 | have_jxl='no (failed tests)' |
| 2421 | else |
Cristy | b0314b2 | 2020-12-26 07:59:17 -0500 | [diff] [blame] | 2422 | JXL_LIBS='-ljxl' |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2423 | LIBS="$JXL_LIBS $LIBS" |
Cristy | b0314b2 | 2020-12-26 07:59:17 -0500 | [diff] [blame] | 2424 | AC_DEFINE([JXL_DELEGATE],[1],[Define if you have jpeg-xl library]) |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2425 | AC_MSG_RESULT([yes]) |
| 2426 | have_jxl='yes' |
| 2427 | fi |
| 2428 | else |
| 2429 | AC_MSG_RESULT([no]) |
| 2430 | fi |
| 2431 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2432 | AM_CONDITIONAL([JXL_DELEGATE],[test "$have_jxl" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2433 | AC_SUBST([JXL_LIBS]) |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 2434 | |
| 2435 | dnl =========================================================================== |
| 2436 | |
| 2437 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2438 | # Check for LCMS delegate library. |
| 2439 | # |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2440 | AC_ARG_WITH([lcms], |
cristy | 7120340 | 2010-06-18 13:12:03 +0000 | [diff] [blame] | 2441 | [ --without-lcms disable lcms (v1.1X) support], |
| 2442 | [with_lcms=$withval], |
| 2443 | [with_lcms='yes']) |
| 2444 | if test "$with_lcms" != 'yes' ; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2445 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-lcms=$with_lcms " |
| 2446 | fi |
| 2447 | |
cristy | 7120340 | 2010-06-18 13:12:03 +0000 | [diff] [blame] | 2448 | have_lcms='no' |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2449 | LCMS_CFLAGS="" |
| 2450 | LCMS_LIBS="" |
| 2451 | LCMS_PKG="" |
| 2452 | if test "x$with_lcms" = "xyes"; then |
| 2453 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2454 | PKG_CHECK_MODULES([LCMS2],[lcms2 >= 2.0.0],[have_lcms=yes],[have_lcms=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2455 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2456 | fi |
cristy | 7120340 | 2010-06-18 13:12:03 +0000 | [diff] [blame] | 2457 | |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2458 | if test "$have_lcms" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2459 | AC_DEFINE([LCMS_DELEGATE],[1],[Define if you have LCMS library]) |
cristy | b74ab6e | 2015-06-06 12:39:54 +0000 | [diff] [blame] | 2460 | LCMS_CFLAGS="$LCMS2_CFLAGS" |
| 2461 | LCMS_LIBS="$LCMS2_LIBS" |
cristy | b054e07 | 2015-06-05 20:35:43 +0000 | [diff] [blame] | 2462 | CFLAGS="$LCMS2_CFLAGS $CFLAGS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2463 | AC_CHECK_HEADER([lcms2/lcms2.h],[have_lcms_header='yes'],[]) |
cristy | d6ac47f | 2015-06-06 13:46:55 +0000 | [diff] [blame] | 2464 | if test "$have_lcms_header" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2465 | AC_DEFINE([HAVE_LCMS2_LCMS2_H],[1],[Define if you have the <lcms2/lcms2.h> header file.]) |
cristy | bc8ef1c | 2015-06-06 14:32:21 +0000 | [diff] [blame] | 2466 | else |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2467 | AC_DEFINE([HAVE_LCMS2_H],[1],[Define if you have the <lcms2.h> header file.]) |
cristy | d6ac47f | 2015-06-06 13:46:55 +0000 | [diff] [blame] | 2468 | fi |
cristy | d09bcf9 | 2010-03-25 03:04:45 +0000 | [diff] [blame] | 2469 | fi |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2470 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2471 | AM_CONDITIONAL([LCMS_DELEGATE],[test "$have_lcms" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2472 | AC_SUBST([LCMS_CFLAGS]) |
| 2473 | AC_SUBST([LCMS_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2474 | |
| 2475 | dnl =========================================================================== |
| 2476 | |
| 2477 | # |
cristy | 99db387 | 2014-01-01 15:11:34 +0000 | [diff] [blame] | 2478 | # Check for the OpenJP2 delegate library. |
| 2479 | # |
| 2480 | AC_ARG_WITH([openjp2], |
| 2481 | [AC_HELP_STRING([--without-openjp2], |
| 2482 | [disable OpenJP2 support])], |
| 2483 | [with_openjp2=$withval], |
| 2484 | [with_openjp2='yes']) |
| 2485 | |
| 2486 | if test "$with_openjp2" != 'yes'; then |
| 2487 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-openjp2=$with_openjp2 " |
| 2488 | fi |
| 2489 | |
| 2490 | have_openjp2='no' |
| 2491 | LIBOPENJP2_CFLAGS="" |
| 2492 | LIBOPENJP2_LIBS="" |
| 2493 | LIBOPENJP2_PKG="" |
Yoshihiro Yamazaki | ec98dde | 2020-03-24 03:46:01 +0900 | [diff] [blame] | 2494 | if test "$with_openjp2" != 'no'; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2495 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2496 | PKG_CHECK_MODULES([LIBOPENJP2],[libopenjp2 >= 2.1.0],[have_openjp2=yes],[have_openjp2=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2497 | AC_MSG_RESULT([]) |
cristy | 99db387 | 2014-01-01 15:11:34 +0000 | [diff] [blame] | 2498 | fi |
| 2499 | |
| 2500 | if test "$have_openjp2" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2501 | AC_DEFINE([LIBOPENJP2_DELEGATE],[1],[Define if you have OPENJP2 library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2502 | CFLAGS="$LIBOPENJP2_CFLAGS $CFLAGS" |
cristy | 99db387 | 2014-01-01 15:11:34 +0000 | [diff] [blame] | 2503 | fi |
| 2504 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2505 | AM_CONDITIONAL([LIBOPENJP2_DELEGATE],[test "$have_openjp2" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2506 | AC_SUBST([LIBOPENJP2_CFLAGS]) |
| 2507 | AC_SUBST([LIBOPENJP2_LIBS]) |
cristy | 99db387 | 2014-01-01 15:11:34 +0000 | [diff] [blame] | 2508 | |
| 2509 | |
| 2510 | dnl =========================================================================== |
| 2511 | |
| 2512 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2513 | # Check for the LQR (Liquid Rescale) delegate library. |
| 2514 | # |
| 2515 | AC_ARG_WITH([lqr], |
| 2516 | [AC_HELP_STRING([--without-lqr], |
cristy | ec50135 | 2010-03-13 18:43:34 +0000 | [diff] [blame] | 2517 | [disable Liquid Rescale support])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2518 | [with_lqr=$withval], |
| 2519 | [with_lqr='yes']) |
| 2520 | |
| 2521 | if test "$with_lqr" != 'yes'; then |
| 2522 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-lqr=$with_lqr " |
| 2523 | fi |
| 2524 | |
| 2525 | have_lqr='no' |
| 2526 | LQR_CFLAGS="" |
| 2527 | LQR_LIBS="" |
| 2528 | LQR_PKG="" |
| 2529 | if test "x$with_lqr" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2530 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2531 | PKG_CHECK_MODULES([LQR],[lqr-1 >= 0.1.0],[have_lqr=yes],[have_lqr=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2532 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2533 | fi |
| 2534 | |
| 2535 | if test "$have_lqr" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2536 | AC_DEFINE([LQR_DELEGATE],[1],[Define if you have LQR library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2537 | CFLAGS="$LQR_CFLAGS $CFLAGS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2538 | fi |
| 2539 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2540 | AM_CONDITIONAL([LQR_DELEGATE],[test "$have_lqr" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2541 | AC_SUBST([LQR_CFLAGS]) |
| 2542 | AC_SUBST([LQR_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2543 | |
| 2544 | dnl =========================================================================== |
| 2545 | |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2546 | # Disable LZMA (lzma library) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2547 | AC_ARG_WITH([lzma], |
glennrp | 3fc1c21 | 2013-01-10 01:52:32 +0000 | [diff] [blame] | 2548 | [ --without-lzma disable LZMA support], |
| 2549 | [with_lzma=$withval], |
| 2550 | [with_lzma='yes']) |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2551 | if test "$with_lzma" != 'yes' ; then |
cristy | fbb0ef0 | 2010-12-19 02:32:11 +0000 | [diff] [blame] | 2552 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-lzma=$with_lzma " |
| 2553 | fi |
| 2554 | |
cristy | 56bbc92 | 2011-11-14 13:18:39 +0000 | [diff] [blame] | 2555 | LZMA_PKG="" |
| 2556 | if test "x$with_lzma" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2557 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2558 | PKG_CHECK_MODULES([LZMA],[liblzma >= 2.9.0],[have_lzma=yes],[have_lzma=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2559 | AC_MSG_RESULT([]) |
Dirk Lemstra | db6f0b9 | 2020-09-19 13:32:08 +0200 | [diff] [blame] | 2560 | else |
| 2561 | have_lzma=no |
cristy | f805afb | 2011-10-03 17:17:37 +0000 | [diff] [blame] | 2562 | fi |
cristy | 56bbc92 | 2011-11-14 13:18:39 +0000 | [diff] [blame] | 2563 | |
| 2564 | if test "$have_lzma" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2565 | AC_DEFINE([LZMA_DELEGATE],[1],[Define if you have LZMA library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2566 | CFLAGS="$LZMA_CFLAGS $CFLAGS" |
cristy | 56bbc92 | 2011-11-14 13:18:39 +0000 | [diff] [blame] | 2567 | fi |
| 2568 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2569 | AM_CONDITIONAL([LZMA_DELEGATE],[test "$have_lzma" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2570 | AC_SUBST([LZMA_CFLAGS]) |
| 2571 | AC_SUBST([LZMA_LIBS]) |
cristy | fbb0ef0 | 2010-12-19 02:32:11 +0000 | [diff] [blame] | 2572 | |
| 2573 | dnl =========================================================================== |
| 2574 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2575 | # |
| 2576 | # Check for the OpenEXR delegate library. |
| 2577 | # |
| 2578 | AC_ARG_WITH([openexr], |
| 2579 | [AC_HELP_STRING([--without-openexr], |
| 2580 | [disable OpenEXR support])], |
| 2581 | [with_openexr=$withval], |
| 2582 | [with_openexr='yes']) |
| 2583 | |
| 2584 | if test "$with_openexr" != 'yes'; then |
| 2585 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-openexr=$with_openexr " |
| 2586 | fi |
| 2587 | |
| 2588 | have_openexr='no' |
| 2589 | OPENEXR_CFLAGS="" |
| 2590 | OPENEXR_LIBS="" |
| 2591 | OPENEXR_PKG="" |
| 2592 | if test "x$with_openexr" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2593 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2594 | PKG_CHECK_MODULES([OPENEXR],[OpenEXR >= 1.0.6],[have_openexr=yes],[have_openexr=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2595 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2596 | fi |
| 2597 | |
| 2598 | if test "$have_openexr" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2599 | AC_DEFINE([OPENEXR_DELEGATE],[1],[Define if you have OPENEXR library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2600 | CFLAGS="$OPENEXR_CFLAGS $CFLAGS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2601 | fi |
| 2602 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2603 | AM_CONDITIONAL([OPENEXR_DELEGATE],[test "$have_openexr" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2604 | AC_SUBST([OPENEXR_CFLAGS]) |
| 2605 | AC_SUBST([OPENEXR_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2606 | |
| 2607 | dnl =========================================================================== |
| 2608 | |
| 2609 | # |
cristy | 41cbe8a | 2011-10-27 01:35:18 +0000 | [diff] [blame] | 2610 | # Check for PANGO delegate library. |
| 2611 | # |
| 2612 | AC_ARG_WITH([pango], |
| 2613 | [AC_HELP_STRING([--without-pango], |
| 2614 | [disable PANGO support])], |
| 2615 | [with_pango=$withval], |
cristy | fc3d022 | 2012-02-07 15:05:57 +0000 | [diff] [blame] | 2616 | [with_pango='yes']) |
cristy | 41cbe8a | 2011-10-27 01:35:18 +0000 | [diff] [blame] | 2617 | |
| 2618 | if test "$with_pango" != 'yes'; then |
| 2619 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-pango=$with_pango " |
| 2620 | fi |
| 2621 | |
| 2622 | have_pango='no' |
cristy | a054b76 | 2012-03-26 23:16:00 +0000 | [diff] [blame] | 2623 | have_pangocairo='no' |
cristy | 41cbe8a | 2011-10-27 01:35:18 +0000 | [diff] [blame] | 2624 | PANGO_CFLAGS="" |
| 2625 | PANGO_LIBS="" |
| 2626 | PANGO_PKG="" |
| 2627 | if test "x$with_pango" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2628 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2629 | PKG_CHECK_MODULES([PANGO],[pangocairo >= 1.28.1],[have_pangocairo=yes],[have_pangocairo=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2630 | AC_MSG_RESULT([]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2631 | PKG_CHECK_MODULES([PANGO],[pango >= 1.28.1],[have_pango=yes],[have_pango=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2632 | AC_MSG_RESULT([]) |
cristy | 41cbe8a | 2011-10-27 01:35:18 +0000 | [diff] [blame] | 2633 | fi |
| 2634 | |
| 2635 | if test "$have_pango" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2636 | AC_DEFINE([PANGO_DELEGATE],[1],[Define if you have PANGO library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2637 | CFLAGS="$PANGO_CFLAGS $CFLAGS" |
cristy | 41cbe8a | 2011-10-27 01:35:18 +0000 | [diff] [blame] | 2638 | fi |
| 2639 | |
cristy | a054b76 | 2012-03-26 23:16:00 +0000 | [diff] [blame] | 2640 | if test "$have_pangocairo" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2641 | AC_DEFINE([PANGOCAIRO_DELEGATE],[1],[Define if you have PANGOCAIRO library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2642 | CFLAGS="$PANGOCAIRO_CFLAGS $CFLAGS" |
cristy | 41cbe8a | 2011-10-27 01:35:18 +0000 | [diff] [blame] | 2643 | fi |
| 2644 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2645 | AM_CONDITIONAL([PANGO_DELEGATE],[test "$have_pango" = 'yes']) |
| 2646 | AM_CONDITIONAL([PANGOCAIRO_DELEGATE],[test "$have_pangocairo" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2647 | AC_SUBST([PANGO_CFLAGS]) |
| 2648 | AC_SUBST([PANGO_LIBS]) |
cristy | 41cbe8a | 2011-10-27 01:35:18 +0000 | [diff] [blame] | 2649 | |
| 2650 | dnl =========================================================================== |
| 2651 | |
| 2652 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2653 | # Check for PNG delegate library. |
| 2654 | # |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2655 | AC_ARG_WITH([png], |
Cristy | 1245273 | 2020-10-02 16:23:46 +0000 | [diff] [blame] | 2656 | [AC_HELP_STRING([--without-png], [disable PNG support])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2657 | [with_png=$withval], |
| 2658 | [with_png='yes']) |
| 2659 | |
| 2660 | if test "$with_png" != 'yes'; then |
| 2661 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-png=$with_png " |
| 2662 | fi |
| 2663 | |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2664 | have_png='no' |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2665 | PNG_CFLAGS="" |
| 2666 | PNG_LIBS="" |
| 2667 | PNG_PKG="" |
| 2668 | if test "x$with_png" = "xyes"; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2669 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2670 | PKG_CHECK_MODULES([PNG],[libpng >= 1.0.0],[have_png=yes],[have_png=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2671 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2672 | fi |
cristy | 6487730 | 2011-08-23 19:10:31 +0000 | [diff] [blame] | 2673 | |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2674 | if test "$have_png" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2675 | AC_DEFINE([PNG_DELEGATE],[1],[Define if you have PNG library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2676 | CFLAGS="$PNG_CFLAGS $CFLAGS" |
| 2677 | fi |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2678 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2679 | AM_CONDITIONAL([PNG_DELEGATE],[test "$have_png" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2680 | AC_SUBST([PNG_CFLAGS]) |
| 2681 | AC_SUBST([PNG_LIBS]) |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2682 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2683 | dnl =========================================================================== |
| 2684 | |
| 2685 | # |
Cristy | cefed48 | 2017-07-14 07:56:27 -0400 | [diff] [blame] | 2686 | # Check for the Raw delegate library. |
| 2687 | # |
Cristy | 42ab1bc | 2017-07-18 17:59:43 -0400 | [diff] [blame] | 2688 | AC_ARG_WITH([raw], |
Cristy | cefed48 | 2017-07-14 07:56:27 -0400 | [diff] [blame] | 2689 | [AC_HELP_STRING([--without-raw], |
| 2690 | [disable Raw support])], |
| 2691 | [with_raw=$withval], |
| 2692 | [with_raw='yes']) |
| 2693 | |
| 2694 | if test "$with_raw" != 'yes'; then |
| 2695 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-libraw=$with_raw " |
| 2696 | fi |
| 2697 | |
| 2698 | have_raw='no' |
Cristy | 31c3c13 | 2017-07-14 18:49:05 -0400 | [diff] [blame] | 2699 | RAW_R_CFLAGS="" |
| 2700 | RAW_R_LIBS="" |
| 2701 | RAW_R_PKG="" |
Cristy | cefed48 | 2017-07-14 07:56:27 -0400 | [diff] [blame] | 2702 | if test "x$with_raw" = "xyes"; then |
| 2703 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2704 | PKG_CHECK_MODULES([RAW_R],[libraw_r >= 0.14.8],[have_raw=yes],[have_raw=no]) |
Cristy | cefed48 | 2017-07-14 07:56:27 -0400 | [diff] [blame] | 2705 | AC_MSG_RESULT([]) |
| 2706 | fi |
| 2707 | |
| 2708 | if test "$have_raw" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2709 | AC_DEFINE([RAW_R_DELEGATE],[1],[Define if you have LIBRAW library]) |
Cristy | 31c3c13 | 2017-07-14 18:49:05 -0400 | [diff] [blame] | 2710 | CFLAGS="$RAW_R_CFLAGS $CFLAGS" |
Cristy | cefed48 | 2017-07-14 07:56:27 -0400 | [diff] [blame] | 2711 | fi |
| 2712 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2713 | AM_CONDITIONAL([RAW_R_DELEGATE],[test "$have_raw" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2714 | AC_SUBST([RAW_R_CFLAGS]) |
| 2715 | AC_SUBST([RAW_R_LIBS]) |
Cristy | cefed48 | 2017-07-14 07:56:27 -0400 | [diff] [blame] | 2716 | |
| 2717 | dnl =========================================================================== |
| 2718 | |
| 2719 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2720 | # Check for RSVG delegate library. |
| 2721 | # |
| 2722 | AC_ARG_WITH([rsvg], |
cristy | 51633f5 | 2013-04-23 14:03:19 +0000 | [diff] [blame] | 2723 | [AC_HELP_STRING([--with-rsvg], |
cristy | 1164d5f | 2012-08-15 00:58:25 +0000 | [diff] [blame] | 2724 | [enable RSVG support])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2725 | [with_rsvg=$withval], |
cristy | 1164d5f | 2012-08-15 00:58:25 +0000 | [diff] [blame] | 2726 | [with_rsvg='no']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2727 | |
| 2728 | if test "$with_rsvg" != 'yes'; then |
| 2729 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-rsvg=$with_rsvg " |
| 2730 | fi |
| 2731 | |
| 2732 | have_rsvg='no' |
| 2733 | have_cairo='no' |
| 2734 | RSVG_CFLAGS="" |
| 2735 | RSVG_LIBS="" |
| 2736 | RSVG_PKG="" |
| 2737 | if test "x$with_rsvg" = "xyes"; then |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2738 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2739 | PKG_CHECK_MODULES([RSVG],[librsvg-2.0 >= 2.9.0],[have_rsvg=yes],[have_rsvg=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2740 | AC_MSG_RESULT([]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2741 | PKG_CHECK_MODULES([CAIRO_SVG],[cairo-svg],[have_cairo=yes],[have_cairo=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2742 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2743 | fi |
| 2744 | |
| 2745 | if test "$have_rsvg" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2746 | AC_DEFINE([RSVG_DELEGATE],[1],[Define if you have RSVG library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2747 | CFLAGS="$RSVG_CFLAGS $CFLAGS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2748 | fi |
| 2749 | |
| 2750 | if test "$have_cairo" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2751 | AC_DEFINE([CAIRO_DELEGATE],[1],[Define if you have CAIRO library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2752 | CFLAGS="$CAIRO_SVG_CFLAGS $CFLAGS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2753 | fi |
| 2754 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2755 | AM_CONDITIONAL([RSVG_DELEGATE],[test "$have_rsvg" = 'yes']) |
| 2756 | AM_CONDITIONAL([CAIRO_DELEGATE],[test "$have_cairo" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2757 | AC_SUBST([RSVG_CFLAGS]) |
| 2758 | AC_SUBST([RSVG_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2759 | |
| 2760 | dnl =========================================================================== |
| 2761 | |
| 2762 | # |
| 2763 | # Check for TIFF delegate library. |
| 2764 | # |
| 2765 | AC_ARG_WITH([tiff], |
| 2766 | [AC_HELP_STRING([--without-tiff], |
| 2767 | [disable TIFF support])], |
| 2768 | [with_tiff=$withval], |
| 2769 | [with_tiff='yes']) |
| 2770 | |
| 2771 | if test "$with_tiff" != 'yes'; then |
| 2772 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-tiff=$with_tiff " |
| 2773 | fi |
| 2774 | |
| 2775 | have_tiff='no' |
| 2776 | TIFF_LIBS='' |
| 2777 | if test "$with_tiff" != 'no'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2778 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2779 | AC_MSG_CHECKING([for TIFF]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2780 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2781 | failed=0 |
| 2782 | passed=0 |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2783 | AC_CHECK_HEADER([tiff.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2784 | AC_CHECK_HEADER([tiffio.h],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`]) |
| 2785 | AC_CHECK_LIB([tiff],[TIFFOpen],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 2786 | AC_CHECK_LIB([tiff],[TIFFClientOpen],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 2787 | AC_CHECK_LIB([tiff],[TIFFIsByteSwapped],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 2788 | AC_CHECK_LIB([tiff],[TIFFReadRGBATile],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
| 2789 | AC_CHECK_LIB([tiff],[TIFFReadRGBAStrip],[passed=`expr $passed + 1`],[failed=`expr $failed + 1`],[]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2790 | AC_MSG_CHECKING([if TIFF package is complete]) |
| 2791 | if test $passed -gt 0; then |
| 2792 | if test $failed -gt 0; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2793 | AC_MSG_RESULT([no -- some components failed test]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2794 | have_tiff='no (failed tests)' |
| 2795 | else |
| 2796 | TIFF_LIBS='-ltiff' |
| 2797 | LIBS="$TIFF_LIBS $LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2798 | AC_DEFINE([TIFF_DELEGATE],[1],[Define if you have TIFF library]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2799 | AC_MSG_RESULT([yes]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2800 | have_tiff='yes' |
| 2801 | AC_CHECK_HEADERS(tiffconf.h) |
| 2802 | AC_CHECK_FUNCS([TIFFIsCODECConfigured TIFFMergeFieldInfo \ |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2803 | TIFFIsBigEndian TIFFSetErrorHandlerExt TIFFSetTagExtender \ |
| 2804 | TIFFReadEXIFDirectory TIFFReadGPSDirectory \ |
| 2805 | TIFFSetWarningHandlerExt TIFFSwabArrayOfTriples]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2806 | fi |
| 2807 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 2808 | AC_MSG_RESULT([no]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2809 | fi |
| 2810 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2811 | AM_CONDITIONAL([TIFF_DELEGATE],[test "$have_tiff" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2812 | AC_SUBST([TIFF_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2813 | |
Cristy | ea6e8ae | 2019-09-30 07:21:16 -0400 | [diff] [blame] | 2814 | dnl =========================================================================== |
| 2815 | |
Cristy | fbca0d0 | 2017-09-27 16:52:52 -0400 | [diff] [blame] | 2816 | # |
| 2817 | # Set URW Base35 font directory. |
| 2818 | # |
| 2819 | AC_ARG_WITH([urw-base35-font-dir], |
| 2820 | [AC_HELP_STRING([--with-urw-base35-font-dir=DIR], |
| 2821 | [URW-base35 font directory])], |
| 2822 | [with_urw_base35_font_dir=$withval], |
| 2823 | [with_urw_base35_font_dir='default']) |
| 2824 | |
| 2825 | if test "$with_urw_base35_font_dir" != 'default'; then |
| 2826 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-urw-base35-font-dir=$with_urw_base35_font_dir " |
| 2827 | fi |
| 2828 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2829 | dnl =========================================================================== |
| 2830 | |
| 2831 | # |
Cristy | 692b678 | 2017-11-19 12:35:18 -0500 | [diff] [blame] | 2832 | # Check for the WEBP delegate library. |
cristy | b186075 | 2011-03-14 00:27:46 +0000 | [diff] [blame] | 2833 | # |
Cristy | 692b678 | 2017-11-19 12:35:18 -0500 | [diff] [blame] | 2834 | AC_ARG_WITH([webp], |
cristy | b186075 | 2011-03-14 00:27:46 +0000 | [diff] [blame] | 2835 | [AC_HELP_STRING([--without-webp], |
| 2836 | [disable WEBP support])], |
| 2837 | [with_webp=$withval], |
| 2838 | [with_webp='yes']) |
| 2839 | |
| 2840 | if test "$with_webp" != 'yes'; then |
| 2841 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-webp=$with_webp " |
| 2842 | fi |
| 2843 | |
| 2844 | have_webp='no' |
Cristy | 692b678 | 2017-11-19 12:35:18 -0500 | [diff] [blame] | 2845 | have_webpmux='no' |
| 2846 | WEBP_CFLAGS="" |
| 2847 | WEBP_LIBS="" |
| 2848 | WEBP_PKG="" |
| 2849 | WEBPMUX_CFLAGS="" |
| 2850 | WEBPMUX_LIBS="" |
| 2851 | WEBPMUX_PKG="" |
| 2852 | if test "x$with_webp" = "xyes"; then |
| 2853 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2854 | PKG_CHECK_MODULES([WEBP],[libwebp],[have_webp=yes],[have_webp=no]) |
| 2855 | PKG_CHECK_MODULES([WEBPMUX],[libwebpmux >= 0.5.0 libwebpdemux >= 0.5.0],[have_webpmux=yes],[have_webpmux=no]) |
Cristy | 692b678 | 2017-11-19 12:35:18 -0500 | [diff] [blame] | 2856 | AC_MSG_RESULT([]) |
cristy | b186075 | 2011-03-14 00:27:46 +0000 | [diff] [blame] | 2857 | fi |
cristy | b186075 | 2011-03-14 00:27:46 +0000 | [diff] [blame] | 2858 | |
Cristy | 692b678 | 2017-11-19 12:35:18 -0500 | [diff] [blame] | 2859 | if test "$have_webp" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2860 | AC_DEFINE([WEBP_DELEGATE],[1],[Define if you have WEBP library]) |
Cristy | 692b678 | 2017-11-19 12:35:18 -0500 | [diff] [blame] | 2861 | CFLAGS="$WEBP_CFLAGS $CFLAGS" |
| 2862 | fi |
| 2863 | |
| 2864 | if test "$have_webpmux" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2865 | AC_DEFINE([WEBPMUX_DELEGATE],[1],[Define if you have WEBPMUX library]) |
Cristy | 692b678 | 2017-11-19 12:35:18 -0500 | [diff] [blame] | 2866 | CFLAGS="$WEBPMUX_CFLAGS $CFLAGS" |
| 2867 | fi |
| 2868 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2869 | AM_CONDITIONAL([WEBP_DELEGATE],[test "$have_webp" = 'yes']) |
| 2870 | AM_CONDITIONAL([WEBPMUX_DELEGATE],[test "$have_webpmux" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2871 | AC_SUBST([WEBPMUX_CFLAGS]) |
| 2872 | AC_SUBST([WEBPMUX_LIBS]) |
| 2873 | AC_SUBST([WEBP_CFLAGS]) |
| 2874 | AC_SUBST([WEBP_LIBS]) |
Cristy | fbca0d0 | 2017-09-27 16:52:52 -0400 | [diff] [blame] | 2875 | |
cristy | b186075 | 2011-03-14 00:27:46 +0000 | [diff] [blame] | 2876 | dnl =========================================================================== |
| 2877 | |
| 2878 | # |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2879 | # Set Windows font directory. |
| 2880 | # |
cristy | 74554ef | 2011-10-27 12:56:11 +0000 | [diff] [blame] | 2881 | AC_ARG_WITH([windows-font-dir], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2882 | [AC_HELP_STRING([--with-windows-font-dir=DIR], |
cristy | 5a3dc99 | 2014-12-05 19:50:04 +0000 | [diff] [blame] | 2883 | [Windows font directory])], |
| 2884 | [with_windows_font_dir=$withval], |
| 2885 | [with_windows_font_dir='default']) |
| 2886 | |
| 2887 | if test "$with_windows_font_dir" != 'default'; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2888 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-windows-font-dir=$with_windows_font_dir " |
| 2889 | fi |
| 2890 | |
| 2891 | dnl =========================================================================== |
| 2892 | |
| 2893 | # |
| 2894 | # Check for WMF delegate library. |
| 2895 | # |
| 2896 | AC_ARG_WITH([wmf], |
cristy | d0a9a68 | 2012-02-11 00:21:53 +0000 | [diff] [blame] | 2897 | [AC_HELP_STRING([--with-wmf], |
| 2898 | [enable WMF support])], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2899 | [with_wmf=$withval], |
Cristy | 35ed1a5 | 2020-09-28 20:09:36 +0000 | [diff] [blame] | 2900 | [with_wmf=$build_modules]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2901 | |
| 2902 | if test "$with_wmf" != 'yes'; then |
| 2903 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-wmf=$with_wmf " |
| 2904 | fi |
| 2905 | |
| 2906 | have_wmf='no' |
cristy | ebc8f69 | 2015-06-16 10:36:30 +0000 | [diff] [blame] | 2907 | WMF_LIBS='' |
| 2908 | WMF_CFLAGS='' |
| 2909 | OLIBS="$LIBS" |
| 2910 | if test "$with_wmf" != 'no'; then |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2911 | AC_MSG_CHECKING([for WMF support]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2912 | AC_MSG_RESULT([]) |
cristy | 735e894 | 2010-04-02 20:32:57 +0000 | [diff] [blame] | 2913 | |
Cristy | d111aac | 2019-11-24 13:04:06 -0500 | [diff] [blame] | 2914 | have_libwmflite='no' |
cristy | ebc8f69 | 2015-06-16 10:36:30 +0000 | [diff] [blame] | 2915 | have_libwmf_ipa_h='no' |
| 2916 | |
| 2917 | AC_CHECK_HEADER([libwmf/ipa.h],[have_libwmf_ipa_h='yes'],[],[$FT2BUILD_H]) |
| 2918 | if test "$have_libwmf_ipa_h" = 'yes'; then |
Cristy | d111aac | 2019-11-24 13:04:06 -0500 | [diff] [blame] | 2919 | AC_CHECK_LIB([wmflite],[wmf_lite_create],[have_libwmflite='yes'],[],[]) |
| 2920 | if test "$have_libwmflite" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2921 | AC_DEFINE([WMF_DELEGATE],[1],[Define if you have WMF library]) |
Cristy | d111aac | 2019-11-24 13:04:06 -0500 | [diff] [blame] | 2922 | WMF_LIBS='-lwmflite' |
cristy | ebc8f69 | 2015-06-16 10:36:30 +0000 | [diff] [blame] | 2923 | LIBS="$WMF_LIBS $LIBS" |
| 2924 | have_wmf='yes' |
| 2925 | else |
| 2926 | AC_MSG_RESULT([no -- some components failed test]) |
| 2927 | have_wmf='no (failed tests)' |
Cristy | d111aac | 2019-11-24 13:04:06 -0500 | [diff] [blame] | 2928 | have_wmflite='no (failed tests)' |
cristy | ebc8f69 | 2015-06-16 10:36:30 +0000 | [diff] [blame] | 2929 | LIBS="$OLIBS" |
| 2930 | WMF_LIBS='' |
| 2931 | fi |
| 2932 | fi |
| 2933 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2934 | AC_MSG_CHECKING([if WMF package is complete]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2935 | if test "$have_wmf" = 'yes'; then |
cristy | ebc8f69 | 2015-06-16 10:36:30 +0000 | [diff] [blame] | 2936 | AC_MSG_RESULT([yes]) |
| 2937 | else |
| 2938 | AC_MSG_RESULT([no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2939 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2940 | AM_CONDITIONAL([WMF_DELEGATE],[test "$have_wmf" = 'yes']) |
cristy | ebc8f69 | 2015-06-16 10:36:30 +0000 | [diff] [blame] | 2941 | AC_SUBST([WMF_CFLAGS]) |
| 2942 | AC_SUBST([WMF_LIBS]) |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2943 | |
| 2944 | dnl =========================================================================== |
| 2945 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2946 | # |
| 2947 | # Check for XML delegate library. |
| 2948 | # |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2949 | AC_ARG_WITH([xml], |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2950 | [AC_HELP_STRING([--without-xml], |
| 2951 | [disable XML support])], |
| 2952 | [with_xml=$withval], |
cristy | fc3d022 | 2012-02-07 15:05:57 +0000 | [diff] [blame] | 2953 | [with_xml='yes']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2954 | |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2955 | if test "$with_xml" != 'yes' ; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2956 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-xml=$with_xml " |
| 2957 | fi |
| 2958 | |
cristy | 81beccd | 2011-10-03 18:17:24 +0000 | [diff] [blame] | 2959 | have_xml='no' |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2960 | XML_CFLAGS="" |
| 2961 | XML_LIBS="" |
| 2962 | XML_PKG="" |
| 2963 | if test "x$with_xml" = "xyes"; then |
| 2964 | AC_MSG_RESULT([-------------------------------------------------------------]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2965 | PKG_CHECK_MODULES([XML],[libxml-2.0 >= 2.0.0],[have_xml=yes],[have_xml=no]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2966 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2967 | fi |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2968 | |
| 2969 | if test "$have_xml" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2970 | AC_DEFINE([XML_DELEGATE],[1],[Define if you have XML library]) |
cristy | 32f75d4 | 2015-06-05 18:46:23 +0000 | [diff] [blame] | 2971 | CFLAGS="$XML_CFLAGS $CFLAGS" |
| 2972 | fi |
| 2973 | |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2974 | AM_CONDITIONAL([XML_DELEGATE],[test "$have_xml" = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 2975 | AC_SUBST([XML_CFLAGS]) |
| 2976 | AC_SUBST([XML_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2977 | |
| 2978 | dnl =========================================================================== |
| 2979 | |
Cristy | d2b6134 | 2019-05-05 12:07:47 -0400 | [diff] [blame] | 2980 | # Check for functions |
| 2981 | # |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 2982 | AC_CHECK_FUNCS([acosh _aligned_malloc aligned_malloc asinh atanh atoll atexit cabs carg cimag creal clock clock_getres clock_gettime ctime_r directio erf _exit execvp fchmod floor fork ftime ftruncate getc_unlocked getcwd getpid getexecname getdtablesize getpagesize getpwnam_r getrlimit getrusage gettimeofday gmtime_r isnan j0 j1 lltostr localtime_r lstat memmove memset mkdir mkstemp munmap nanosleep newlocale _NSGetExecutablePath pclose _pclose poll popen _popen posix_fadvise posix_fallocate posix_madvise posix_memalign posix_spawnp pow pread putenv pwrite qsort_r raise rand_r readlink realpath select seekdir sendfile setlocale socket sqrt setvbuf stat strcasestr strchr strrchr strcspn strdup strpbrk strspn strstr strtod strtod_l strtol strtoul symlink sysconf sigemptyset sigaction spawnvp strerror strlcat strlcpy strcasecmp strncasecmp telldir tempnam times ulltostr uselocale usleep utime vfprintf vfprintf_l vsprintf vsnprintf vsnprintf_l waitpid _wfopen _wstat]) |
Cristy | d2b6134 | 2019-05-05 12:07:47 -0400 | [diff] [blame] | 2983 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2984 | # Substitute compiler name to build/link PerlMagick |
| 2985 | # |
cristy | 86b6e55 | 2015-06-06 13:25:16 +0000 | [diff] [blame] | 2986 | AC_SUBST([PERLMAINCC]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 2987 | |
| 2988 | # |
| 2989 | # Configure install Paths |
| 2990 | # |
cristy | 7def36a | 2011-10-28 19:04:41 +0000 | [diff] [blame] | 2991 | |
cristy | 2a11bef | 2011-10-28 18:33:11 +0000 | [diff] [blame] | 2992 | # Path to ImageMagick header files |
cristy | bdabdd6 | 2013-03-04 17:43:36 +0000 | [diff] [blame] | 2993 | INCLUDE_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}" |
cristy | e52f12f | 2012-12-31 15:32:36 +0000 | [diff] [blame] | 2994 | INCLUDE_PATH="${INCLUDE_DIR}/${INCLUDE_RELATIVE_PATH}" |
| 2995 | DEFINE_INCLUDE_PATH="${INCLUDE_DIR}/${INCLUDE_RELATIVE_PATH}/" |
cristy | 2a11bef | 2011-10-28 18:33:11 +0000 | [diff] [blame] | 2996 | case "${build_os}" in |
| 2997 | mingw* ) |
| 2998 | DEFINE_INCLUDE_PATH=`$WinPathScript "$DEFINE_INCLUDE_PATH" 1` |
| 2999 | ;; |
| 3000 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3001 | AC_DEFINE_UNQUOTED([INCLUDE_PATH],["$DEFINE_INCLUDE_PATH"],[Directory where ImageMagick headers live.]) |
| 3002 | AC_SUBST([INCLUDE_PATH]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3003 | |
cristy | e52f12f | 2012-12-31 15:32:36 +0000 | [diff] [blame] | 3004 | # Path to ImageMagick header files (arch part) |
| 3005 | INCLUDEARCH_PATH="${INCLUDEARCH_DIR}/${INCLUDE_RELATIVE_PATH}" |
| 3006 | DEFINE_INCLUDEARCH_PATH="${INCLUDEARCH_DIR}/${INCLUDE_RELATIVE_PATH}/" |
| 3007 | case "${build_os}" in |
| 3008 | mingw* ) |
| 3009 | DEFINE_INCLUDEARCH_PATH=`$WinPathScript "$DEFINE_INCLUDEARCH_PATH" 1` |
| 3010 | ;; |
| 3011 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3012 | AC_DEFINE_UNQUOTED([INCLUDEARCH_PATH],["$DEFINE_INCLUDE_PATH"],[Directory where ImageMagick architecture headers live.]) |
| 3013 | AC_SUBST([INCLUDEARCH_PATH]) |
cristy | e52f12f | 2012-12-31 15:32:36 +0000 | [diff] [blame] | 3014 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3015 | # Subdirectory under lib to place ImageMagick lib files |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3016 | LIBRARY_RELATIVE_PATH="${PACKAGE_NAME}-${PACKAGE_BASE_VERSION}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3017 | AC_DEFINE_UNQUOTED([LIBRARY_RELATIVE_PATH],["$LIBRARY_RELATIVE_PATH"],[Subdirectory of lib where ImageMagick architecture dependent files are installed.]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3018 | |
| 3019 | # Path to ImageMagick bin directory |
| 3020 | EXECUTABLE_PATH="${BIN_DIR}" |
| 3021 | DEFINE_EXECUTABLE_PATH="${BIN_DIR}/" |
| 3022 | case "${build_os}" in |
| 3023 | mingw* ) |
| 3024 | DEFINE_EXECUTABLE_PATH=`$WinPathScript "$DEFINE_EXECUTABLE_PATH" 1` |
| 3025 | ;; |
| 3026 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3027 | AC_DEFINE_UNQUOTED([EXECUTABLE_PATH],["$DEFINE_EXECUTABLE_PATH"],[Directory where executables are installed.]) |
| 3028 | AC_SUBST([EXECUTABLE_PATH]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3029 | |
| 3030 | # Path to ImageMagick lib |
| 3031 | LIBRARY_PATH="${LIB_DIR}/${LIBRARY_RELATIVE_PATH}" |
| 3032 | DEFINE_LIBRARY_PATH="${LIB_DIR}/${LIBRARY_RELATIVE_PATH}/" |
| 3033 | case "${build_os}" in |
| 3034 | mingw* ) |
| 3035 | DEFINE_LIBRARY_PATH=`$WinPathScript "$DEFINE_LIBRARY_PATH" 1` |
| 3036 | ;; |
| 3037 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3038 | AC_DEFINE_UNQUOTED([LIBRARY_PATH],["$DEFINE_LIBRARY_PATH"],[Directory where architecture-dependent files live.]) |
| 3039 | AC_SUBST([LIBRARY_PATH]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3040 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3041 | # |
cristy | 8d0ff76 | 2013-03-10 20:33:28 +0000 | [diff] [blame] | 3042 | # path to local binaries |
| 3043 | if test "x$LIB_BIN_BASEDIRNAME" = "x"; then |
| 3044 | LIB_BIN_BASEDIRNAME="bin" |
| 3045 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3046 | AC_DEFINE_UNQUOTED([LIB_BIN_BASEDIRNAME],["$LIB_BIN_BASEDIRNAME"],[Binaries in libraries path base name (will be during install linked to bin)]) |
| 3047 | AC_SUBST([LIB_BIN_BASEDIRNAME]) |
cristy | 8d0ff76 | 2013-03-10 20:33:28 +0000 | [diff] [blame] | 3048 | |
| 3049 | if test "x$LIB_BIN_DIR" = "x"; then |
| 3050 | LIB_BIN_DIR=${LIB_BIN_BASEDIRNAME}-${MAGICK_ABI_SUFFIX} |
| 3051 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3052 | AC_SUBST([LIB_BIN_DIR]) |
cristy | 8d0ff76 | 2013-03-10 20:33:28 +0000 | [diff] [blame] | 3053 | |
| 3054 | LIB_BIN_DIR_RELATIVE_PATH=$LIB_BIN_DIR |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3055 | AC_SUBST([LIB_BIN_DIR_RELATIVE_PATH]) |
cristy | 8d0ff76 | 2013-03-10 20:33:28 +0000 | [diff] [blame] | 3056 | LIB_BIN_DIR_PATH="${LIBRARY_PATH}/${LIB_BIN_DIR_RELATIVE_PATH}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3057 | AC_SUBST([LIB_BIN_DIR_PATH]) |
cristy | 8d0ff76 | 2013-03-10 20:33:28 +0000 | [diff] [blame] | 3058 | |
| 3059 | # |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3060 | # path to modules lib |
| 3061 | if test "x$MODULES_BASEDIRNAME" = "x"; then |
| 3062 | MODULES_BASEDIRNAME="modules" |
| 3063 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3064 | AC_DEFINE_UNQUOTED([MODULES_BASEDIRNAME],["$MODULES_BASEDIRNAME"],[Module directory name without ABI part.]) |
| 3065 | AC_SUBST([MODULES_BASEDIRNAME]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3066 | |
| 3067 | if test "x$MODULES_DIRNAME" = "x"; then |
cristy | 7a26abd | 2012-12-03 00:18:59 +0000 | [diff] [blame] | 3068 | MODULES_DIRNAME=${MODULES_BASEDIRNAME}-${MAGICK_ABI_SUFFIX} |
cristy | 4bdbd34 | 2012-12-03 18:41:18 +0000 | [diff] [blame] | 3069 | else |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3070 | AC_DEFINE_UNQUOTED([MODULES_DIRNAME],["$MODULES_DIRNAME"],[Module directory dirname]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3071 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3072 | AC_SUBST([MODULES_DIRNAME]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3073 | |
cristy | 371d481 | 2012-12-01 19:48:10 +0000 | [diff] [blame] | 3074 | MODULES_RELATIVE_PATH="${MODULES_DIRNAME}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3075 | AC_SUBST([MODULES_RELATIVE_PATH]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3076 | MODULES_PATH="${LIBRARY_PATH}/${MODULES_RELATIVE_PATH}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3077 | AC_SUBST([MODULES_PATH]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3078 | |
| 3079 | # |
| 3080 | # path to coders lib |
| 3081 | if test "x$CODER_DIRNAME" = "x"; then |
| 3082 | CODER_DIRNAME="coders" |
| 3083 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3084 | AC_DEFINE_UNQUOTED([CODER_DIRNAME],["$CODER_DIRNAME"],[coders subdirectory.]) |
| 3085 | AC_SUBST([CODER_DIRNAME]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3086 | |
cristy | 371d481 | 2012-12-01 19:48:10 +0000 | [diff] [blame] | 3087 | CODER_RELATIVE_PATH="${CODER_DIRNAME}" |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3088 | CODER_PATH="${MODULES_PATH}/${CODER_DIRNAME}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3089 | AC_SUBST([CODER_PATH]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3090 | |
| 3091 | # |
| 3092 | # Subdirectory under lib to place ImageMagick filter module files |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3093 | # |
| 3094 | # path to coders lib |
| 3095 | if test "x$FILTER_DIRNAME" = "x"; then |
| 3096 | FILTER_DIRNAME="filters" |
| 3097 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3098 | AC_DEFINE_UNQUOTED([FILTER_DIRNAME],["$FILTER_DIRNAME"],[filter subdirectory.]) |
| 3099 | AC_SUBST([FILTER_DIRNAME]) |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3100 | |
cristy | 371d481 | 2012-12-01 19:48:10 +0000 | [diff] [blame] | 3101 | FILTER_RELATIVE_PATH="${FILTER_DIRNAME}" |
cristy | 01ff9f3 | 2012-12-01 18:15:29 +0000 | [diff] [blame] | 3102 | FILTER_PATH="${MODULES_PATH}/${FILTER_DIRNAME}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3103 | AC_SUBST([FILTER_PATH]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3104 | |
| 3105 | # |
| 3106 | # Path to ImageMagick documentation files |
Cristy | e35bdc6 | 2015-09-19 18:29:00 -0400 | [diff] [blame] | 3107 | DOCUMENTATION_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}" |
| 3108 | DOCUMENTATION_PATH="${DOC_DIR}/${DOCUMENTATION_RELATIVE_PATH}" |
| 3109 | DEFINE_DOCUMENTATION_PATH="${DOC_DIR}/${DOCUMENTATION_RELATIVE_PATH}/" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3110 | case "${build_os}" in |
| 3111 | mingw* ) |
| 3112 | DEFINE_DOCUMENTATION_PATH=`$WinPathScript "$DEFINE_DOCUMENTATION_PATH" 1` |
| 3113 | ;; |
| 3114 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3115 | AC_DEFINE_UNQUOTED([DOCUMENTATION_PATH],["$DEFINE_DOCUMENTATION_PATH"],[Directory where ImageMagick documents live.]) |
| 3116 | AC_SUBST([DOCUMENTATION_PATH]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3117 | |
cristy | dd17feb | 2014-03-05 02:06:32 +0000 | [diff] [blame] | 3118 | # |
| 3119 | # Enable/Disable documentation |
| 3120 | AC_ARG_ENABLE([docs], |
| 3121 | [AS_HELP_STRING([--disable-docs], |
| 3122 | [disable building of documentation])], |
cristy | 0227231 | 2014-03-07 00:55:25 +0000 | [diff] [blame] | 3123 | wantdocs=$enableval, wantdocs=yes) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3124 | AM_CONDITIONAL([INSTALL_DOC],[test "$wantdocs" = "yes"]) |
cristy | dd17feb | 2014-03-05 02:06:32 +0000 | [diff] [blame] | 3125 | |
cristy | 2a11bef | 2011-10-28 18:33:11 +0000 | [diff] [blame] | 3126 | # Subdirectory to place architecture-dependent configuration files |
cristy | bdabdd6 | 2013-03-04 17:43:36 +0000 | [diff] [blame] | 3127 | CONFIGURE_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3128 | AC_DEFINE_UNQUOTED([CONFIGURE_RELATIVE_PATH],["$CONFIGURE_RELATIVE_PATH"],[Subdirectory of lib where architecture-dependent configuration files live.]) |
cristy | 7def36a | 2011-10-28 19:04:41 +0000 | [diff] [blame] | 3129 | CONFIGURE_PATH="${SYSCONF_DIR}/${CONFIGURE_RELATIVE_PATH}/" |
cristy | 29b1f6f | 2011-03-27 14:02:38 +0000 | [diff] [blame] | 3130 | DEFINE_CONFIGURE_PATH="${SYSCONF_DIR}/${CONFIGURE_RELATIVE_PATH}/" |
| 3131 | case "${build_os}" in |
| 3132 | mingw* ) |
| 3133 | DEFINE_CONFIGURE_PATH=`$WinPathScript "$DEFINE_CONFIGURE_PATH" 1` |
| 3134 | ;; |
| 3135 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3136 | AC_DEFINE_UNQUOTED([CONFIGURE_PATH],["$DEFINE_CONFIGURE_PATH"],[Directory where architecture-dependent configuration files live.]) |
| 3137 | AC_SUBST([CONFIGURE_PATH]) |
cristy | 29b1f6f | 2011-03-27 14:02:38 +0000 | [diff] [blame] | 3138 | |
cristy | 2a11bef | 2011-10-28 18:33:11 +0000 | [diff] [blame] | 3139 | # Subdirectory to place architecture-independent configuration files |
cristy | bdabdd6 | 2013-03-04 17:43:36 +0000 | [diff] [blame] | 3140 | SHARE_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3141 | AC_DEFINE_UNQUOTED([SHARE_RELATIVE_PATH],["$SHARE_RELATIVE_PATH"],[Subdirectory of lib where architecture-independent configuration files live.]) |
cristy | 670aa3c | 2011-11-03 00:54:00 +0000 | [diff] [blame] | 3142 | SHARE_PATH="${DATA_DIR}/${SHARE_RELATIVE_PATH}" |
cristy | 4f82071 | 2011-04-01 12:35:43 +0000 | [diff] [blame] | 3143 | DEFINE_SHARE_PATH="${DATA_DIR}/${SHARE_RELATIVE_PATH}/" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3144 | case "${build_os}" in |
| 3145 | mingw* ) |
cristy | 4f82071 | 2011-04-01 12:35:43 +0000 | [diff] [blame] | 3146 | DEFINE_SHARE_PATH=`$WinPathScript "$DEFINE_SHARE_PATH" 1` |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3147 | ;; |
| 3148 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3149 | AC_DEFINE_UNQUOTED([SHARE_PATH],["$DEFINE_SHARE_PATH"],[Directory where architecture-independent configuration files live.]) |
| 3150 | AC_SUBST([SHARE_PATH]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3151 | |
cristy | 23c7e9a | 2012-12-04 15:47:57 +0000 | [diff] [blame] | 3152 | # |
| 3153 | # Subdirectory to place architecture-dependent configuration files. |
| 3154 | if test "x$SHAREARCH_BASEDIRNAME" = "x"; then |
| 3155 | SHAREARCH_BASEDIRNAME="config" |
| 3156 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3157 | AC_DEFINE_UNQUOTED([SHAREARCH_BASEDIRNAME],["$SHAREARCH_BASEDIRNAME"],[Sharearch directory name without ABI part.]) |
| 3158 | AC_SUBST([SHAREARCH_BASEDIRNAME]) |
cristy | 23c7e9a | 2012-12-04 15:47:57 +0000 | [diff] [blame] | 3159 | |
| 3160 | if test "x$SHAREARCH_DIRNAME" = "x"; then |
| 3161 | SHAREARCH_DIRNAME=${SHAREARCH_BASEDIRNAME}-${MAGICK_ABI_SUFFIX} |
| 3162 | else |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3163 | AC_DEFINE_UNQUOTED([SHAREARCH_DIRNAME],["$SHAREARCH_DIRNAME"],[Sharearch directory dirname]) |
cristy | 23c7e9a | 2012-12-04 15:47:57 +0000 | [diff] [blame] | 3164 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3165 | AC_SUBST([SHAREARCH_DIRNAME]) |
cristy | 23c7e9a | 2012-12-04 15:47:57 +0000 | [diff] [blame] | 3166 | |
| 3167 | SHAREARCH_RELATIVE_PATH="${SHAREARCH_DIRNAME}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3168 | AC_SUBST([SHAREARCH_RELATIVE_PATH]) |
cristy | 23c7e9a | 2012-12-04 15:47:57 +0000 | [diff] [blame] | 3169 | SHAREARCH_PATH="${LIBRARY_PATH}/${SHAREARCH_RELATIVE_PATH}" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3170 | AC_SUBST([SHAREARCH_PATH]) |
cristy | 670aa3c | 2011-11-03 00:54:00 +0000 | [diff] [blame] | 3171 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3172 | # |
| 3173 | # program_transform_name is formed for use in a Makefile, so create a |
| 3174 | # modified version for use in a shell script. |
| 3175 | configure_transform_name=`echo ${program_transform_name} | sed 's,\\$\\$,$,'` |
| 3176 | |
| 3177 | # Default delegate definitions |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3178 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3179 | AC_MSG_CHECKING([for ImageMagick delegate programs]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3180 | AC_MSG_RESULT([]) |
cristy | 212cd79 | 2014-12-12 00:51:03 +0000 | [diff] [blame] | 3181 | BPGDecodeDelegateDefault='bpgdec' |
| 3182 | BPGEncodeDelegateDefault='bpgenc' |
cristy | 3d7f806 | 2009-09-24 20:45:35 +0000 | [diff] [blame] | 3183 | BlenderDecodeDelegateDefault='blender' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3184 | BrowseDelegateDefault='xdg-open' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3185 | DNGDecodeDelegateDefault='ufraw-batch' |
Cristy | ab5fe29 | 2020-06-24 19:53:02 -0400 | [diff] [blame] | 3186 | DOCDecodeDelegateDefault='libreoffice' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3187 | GVCDecodeDelegateDefault='dot' |
| 3188 | DVIDecodeDelegateDefault='dvips' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3189 | EditorDelegateDefault='xterm' |
Cristy | 5974870 | 2016-05-12 21:35:47 -0400 | [diff] [blame] | 3190 | ConvertDelegateDefault=`echo magick | sed ${configure_transform_name}` |
| 3191 | DisplayDelegateDefault=`echo magick | sed ${configure_transform_name}` |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 3192 | Fig2devDelegateDefault='fig2dev' |
Cristy | 5974870 | 2016-05-12 21:35:47 -0400 | [diff] [blame] | 3193 | MogrifyDelegateDefault=`echo magick | sed ${configure_transform_name}` |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3194 | HPGLDecodeDelegateDefault='hp2xx' |
| 3195 | HTMLDecodeDelegateDefault='html2ps' |
| 3196 | ILBMDecodeDelegateDefault='ilbmtoppm' |
| 3197 | ILBMEncodeDelegateDefault='ppmtoilbm' |
cristy | 71f53d5 | 2013-04-27 13:33:59 +0000 | [diff] [blame] | 3198 | JXRDecodeDelegateDefault='JxrDecApp' |
| 3199 | JXREncodeDelegateDefault='JxrEncApp' |
Cristy | 3ef15c0 | 2017-01-02 07:41:13 -0500 | [diff] [blame] | 3200 | LEPDelegateDefault='lepton' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3201 | LPDelegateDefault='lp' |
| 3202 | LPRDelegateDefault='lpr' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3203 | LaunchDelegateDefault='gimp' |
cristy | 935c86e | 2010-06-05 23:50:07 +0000 | [diff] [blame] | 3204 | MrSIDDecodeDelegateDefault='mrsidgeodecode' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3205 | MVDelegateDefault='mv' |
| 3206 | PCLDelegateDefault='pcl6' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3207 | if test "$native_win32_build" = 'yes'; then |
| 3208 | PSDelegateDefault='gswin32c' |
cristy | b7931f1 | 2009-09-25 10:22:21 +0000 | [diff] [blame] | 3209 | elif test "$gslib_framework" = 'yes'; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3210 | PSDelegateDefault='gsc' |
| 3211 | else |
| 3212 | PSDelegateDefault='gs' |
| 3213 | fi |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3214 | RMDelegateDefault='rm' |
cristy | 5281e32 | 2012-02-09 21:12:45 +0000 | [diff] [blame] | 3215 | RSVGDecodeDelegateDefault='rsvg-convert' |
cristy | ec6934f | 2012-08-14 18:38:40 +0000 | [diff] [blame] | 3216 | SVGDecodeDelegateDefault='inkscape' |
Cristy | 6bb3534 | 2020-11-07 14:23:18 +0000 | [diff] [blame] | 3217 | TextEncodeDelegateDefault='tesseract' |
Cristy | 9e11348 | 2019-08-21 09:19:28 -0400 | [diff] [blame] | 3218 | TraceEncodeDelegateDefault='potrace' |
Cristy | 6e04083 | 2020-10-14 22:45:34 +0000 | [diff] [blame] | 3219 | VIDEODecodeDelegateDefault='ffmpeg' |
| 3220 | VIDEOEncodeDelegateDefault='ffmpeg' |
cristy | 86e8609 | 2013-08-04 17:43:57 +0000 | [diff] [blame] | 3221 | WebPDecodeDelegateDefault='dwebp' |
| 3222 | WebPEncodeDelegateDefault='cwebp' |
Cristy | dc553c1 | 2016-05-09 13:27:06 -0400 | [diff] [blame] | 3223 | WWWDecodeDelegateDefault='curl' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3224 | XPSDelegateDefault='gxps' |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3225 | |
| 3226 | # Search for delegates |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3227 | AC_PATH_PROG([BPGDecodeDelegate],["$BPGDecodeDelegateDefault"],["$BPGDecodeDelegateDefault"]) |
| 3228 | AC_PATH_PROG([BPGEncodeDelegate],["$BPGEncodeDelegateDefault"],["$BPGEncodeDelegateDefault"]) |
| 3229 | AC_PATH_PROG([BlenderDecodeDelegate],["$BlenderDecodeDelegateDefault"],["$BlenderDecodeDelegateDefault"]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3230 | AC_PATH_PROGS([BrowseDelegate],["$BrowseDelegateDefault" google-chrome firefox konqueror mozilla lynx],["$BrowseDelegateDefault"]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3231 | AC_PATH_PROG([DNGDecodeDelegate],["$DNGDecodeDelegateDefault"],["$DNGDecodeDelegateDefault"]) |
| 3232 | AC_PATH_PROG([DOCDecodeDelegate],["$DOCDecodeDelegateDefault"],["$DOCDecodeDelegateDefault"]) |
| 3233 | AC_PATH_PROG([DVIDecodeDelegate],["$DVIDecodeDelegateDefault"],["$DVIDecodeDelegateDefault"]) |
| 3234 | AC_PATH_PROG([ConvertDelegate],["$ConvertDelegateDefault"],["$ConvertDelegateDefault"]) |
| 3235 | AC_PATH_PROG([DisplayDelegate],["$DisplayDelegateDefault"],["$DisplayDelegateDefault"]) |
| 3236 | AC_PATH_PROG([EditorDelegate],["$EditorDelegateDefault"],["$EditorDelegateDefault"]) |
| 3237 | AC_PATH_PROG([GVCDecodeDelegate],["$GVCDecodeDelegateDefault"],["$GVCDecodeDelegateDefault"]) |
| 3238 | AC_PATH_PROG([HPGLDecodeDelegate],["$HPGLDecodeDelegateDefault"],["$HPGLDecodeDelegateDefault"]) |
| 3239 | AC_PATH_PROG([HTMLDecodeDelegate],["$HTMLDecodeDelegateDefault"],["$HTMLDecodeDelegateDefault"]) |
| 3240 | AC_PATH_PROG([ILBMDecodeDelegate],["$ILBMDecodeDelegateDefault"],["$ILBMDecodeDelegateDefault"]) |
| 3241 | AC_PATH_PROG([ILBMEncodeDelegate],["$ILBMEncodeDelegateDefault"],["$ILBMEncodeDelegateDefault"]) |
| 3242 | AC_PATH_PROG([JXRDecodeDelegate],["$JXRDecodeDelegateDefault"],["$JXRDecodeDelegateDefault"]) |
| 3243 | AC_PATH_PROG([JXREncodeDelegate],["$JXREncodeDelegateDefault"],["$JXREncodeDelegateDefault"]) |
| 3244 | AC_PATH_PROG([LEPDelegate],["$LEPDelegateDefault"],["$LEPDelegateDefault"]) |
| 3245 | AC_PATH_PROG([LPDelegate],["$LPDelegateDefault"],[no]) |
| 3246 | AC_PATH_PROG([LPRDelegate],["$LPRDelegateDefault"],["$LPRDelegateDefault"]) |
| 3247 | AC_PATH_PROG([LaunchDelegate],["$LaunchDelegateDefault"],["$LaunchDelegateDefault"]) |
| 3248 | AC_PATH_PROG([MogrifyDelegate],["$MogrifyDelegateDefault"],["$MogrifyDelegateDefault"]) |
| 3249 | AC_PATH_PROG([VIDEODecodeDelegate],["$VIDEODecodeDelegateDefault"],["$VIDEODecodeDelegateDefault"]) |
| 3250 | AC_PATH_PROG([VIDEOEncodeDelegate],["$VIDEOEncodeDelegateDefault"],["$VIDEOEncodeDelegateDefault"]) |
| 3251 | AC_PATH_PROG([MrSIDDecodeDelegate],["$MrSIDDecodeDelegateDefault"],["$MrSIDDecodeDelegateDefault"]) |
| 3252 | AC_PATH_PROG([MVDelegate],["$MVDelegateDefault"],["$MVDelegateDefault"]) |
| 3253 | AC_PATH_PROG([PCLDelegate],["$PCLDelegateDefault"],["$PCLDelegateDefault"]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3254 | AC_PATH_PROGS([PSDelegate],[gsx gsc "$PSDelegateDefault"],["$PSDelegateDefault"]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3255 | AC_PATH_PROG([RMDelegate],["$RMDelegateDefault"],["$RMDelegateDefault"]) |
| 3256 | AC_PATH_PROG([RSVGDecodeDelegate],["$RSVGDecodeDelegateDefault"],["$RSVGDecodeDelegateDefault"]) |
| 3257 | AC_PATH_PROG([SVGDecodeDelegate],["$SVGDecodeDelegateDefault"],["$SVGDecodeDelegateDefault"]) |
| 3258 | AC_PATH_PROG([TextEncodeDelegate],["$TextEncodeDelegateDefault"],["$TextEncodeDelegateDefault"]) |
| 3259 | AC_PATH_PROG([TraceEncodeDelegate],["$TraceEncodeDelegateDefault"],["$TraceEncodeDelegateDefault"]) |
| 3260 | AC_PATH_PROG([Fig2devDelegate],["$Fig2devDelegateDefault"],["$Fig2devDelegateDefault"]) |
| 3261 | AC_PATH_PROG([WebPDecodeDelegate],["$WebPDecodeDelegateDefault"],["$WebPDecodeDelegateDefault"]) |
| 3262 | AC_PATH_PROG([WebPEncodeDelegate],["$WebPEncodeDelegateDefault"],["$WebPEncodeDelegateDefault"]) |
| 3263 | AC_PATH_PROG([WWWDecodeDelegate],["$WWWDecodeDelegateDefault"],["$WWWDecodeDelegateDelegateDefault"]) |
| 3264 | AC_PATH_PROG([XPSDelegate],["$XPSDelegateDefault"],["$XPSDelegateDefault"]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3265 | |
| 3266 | # Prefer lpr to lp; lp needs options tacked on. |
| 3267 | if test "$LPRDelegate" != no; then |
| 3268 | PrintDelegate="$LPRDelegate" |
| 3269 | else |
| 3270 | PrintDelegate="$LPDelegate -c -s" |
| 3271 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3272 | AC_SUBST([PrintDelegate]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3273 | |
| 3274 | # Installed ImageMagick utiltity paths |
| 3275 | ConvertDelegate="${BIN_DIR}/${ConvertDelegateDefault}" |
| 3276 | DisplayDelegate="${BIN_DIR}/${DisplayDelegateDefault}" |
| 3277 | MogrifyDelegate="${BIN_DIR}/${MogrifyDelegateDefault}" |
| 3278 | |
| 3279 | # Set delegate booleans |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3280 | have_gs='no' ; if test "$PSDelegate" != "$PSDelegateDefault"; then have_gs='yes'; fi |
| 3281 | have_hp2xx='no' ; if test "$HPGLDecodeDelegate" != "$HPGLDecodeDelegateDefault" ; then have_hp2xx='yes'; fi |
| 3282 | have_ilbmtoppm='no' ; if test "$ILBMDecodeDelegate" != "$ILBMDecodeDelegateDefault" ; then have_ilbmtoppm='yes'; fi |
cristy | 935c86e | 2010-06-05 23:50:07 +0000 | [diff] [blame] | 3283 | have_mrsid='no'; if test "$MrSIDDecodeDelegate" != "$MrSIDDecodeDelegateDefault" ; then have_mrsid='yes'; fi |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3284 | have_pcl='no' ; if test "$PCLDelegate" != "$PCLDelegateDefault"; then have_pcl='yes'; fi |
| 3285 | have_ppmtoilbm='no' ; if test "$ILBMEncodeDelegate" != "$ILBMEncodeDelegateDefault" ; then have_ppmtoilbm='yes'; fi |
Cristy | 6e04083 | 2020-10-14 22:45:34 +0000 | [diff] [blame] | 3286 | have_video='no'; if test "$VIDEODecodeDelegate" != "$VIDEODecodeDelegateDefault" ; then have_video='yes'; fi |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3287 | have_xps='no' ; if test "$XPSDelegate" != "$XPSDelegateDefault"; then have_xps='yes'; fi |
| 3288 | |
| 3289 | # |
| 3290 | # Test for font directories |
| 3291 | # |
| 3292 | type_include_files='' |
| 3293 | |
Cristy | 6263d53 | 2016-05-01 18:39:52 -0400 | [diff] [blame] | 3294 | # Apple fonts. |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3295 | AC_MSG_CHECKING([for Apple fonts directory]) |
cristy | 5a3dc99 | 2014-12-05 19:50:04 +0000 | [diff] [blame] | 3296 | apple_font_dir='' |
| 3297 | if test "${with_apple_font_dir}" != 'default'; then |
| 3298 | apple_font_dir="${with_apple_font_dir}/" |
| 3299 | else |
| 3300 | for font_dir in '/Library/Fonts/'; do |
| 3301 | if test -f "${font_dir}Arial.ttf"; then |
| 3302 | apple_font_dir="${font_dir}" |
| 3303 | break 1 |
| 3304 | fi |
| 3305 | done |
| 3306 | fi |
| 3307 | if test "${apple_font_dir}x" != 'x'; then |
| 3308 | type_include_files="${type_include_files} "'<include file="type-apple.xml" />' |
| 3309 | AC_MSG_RESULT([$apple_font_dir]) |
| 3310 | else |
| 3311 | AC_MSG_RESULT([not found!]); |
| 3312 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3313 | AC_SUBST([apple_font_dir]) |
cristy | 5a3dc99 | 2014-12-05 19:50:04 +0000 | [diff] [blame] | 3314 | |
cristy | 430a731 | 2010-01-21 20:44:04 +0000 | [diff] [blame] | 3315 | # Dejavu fonts. |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3316 | AC_MSG_CHECKING([for Dejavu fonts directory]) |
cristy | 430a731 | 2010-01-21 20:44:04 +0000 | [diff] [blame] | 3317 | dejavu_font_dir='' |
| 3318 | if test "${with_dejavu_font_dir}" != 'default'; then |
| 3319 | dejavu_font_dir="${with_dejavu_font_dir}/" |
| 3320 | else |
| 3321 | for font_dir in "${prefix}/share/dejavu/fonts/" '/usr/share/fonts/dejavu/'; do |
| 3322 | if test -f "${font_dir}DejaVuSerif.ttf"; then |
| 3323 | dejavu_font_dir="${font_dir}" |
| 3324 | break 1 |
| 3325 | fi |
| 3326 | done |
| 3327 | fi |
| 3328 | if test "${dejavu_font_dir}x" != 'x'; then |
| 3329 | type_include_files="${type_include_files} "'<include file="type-dejavu.xml" />' |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3330 | AC_MSG_RESULT([$dejavu_font_dir]) |
cristy | 430a731 | 2010-01-21 20:44:04 +0000 | [diff] [blame] | 3331 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3332 | AC_MSG_RESULT([not found!]); |
cristy | 430a731 | 2010-01-21 20:44:04 +0000 | [diff] [blame] | 3333 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3334 | AC_SUBST([dejavu_font_dir]) |
cristy | 430a731 | 2010-01-21 20:44:04 +0000 | [diff] [blame] | 3335 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3336 | # Ghostscript |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3337 | AC_MSG_CHECKING([for Ghostscript fonts directory]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3338 | ghostscript_font_dir='' |
| 3339 | if test "${with_gs_font_dir}" != 'default'; then |
| 3340 | ghostscript_font_dir="${with_gs_font_dir}/" |
| 3341 | else |
| 3342 | if test "${native_win32_build}" = 'yes'; then |
| 3343 | # Native Windows Build |
| 3344 | for font_dir in "c:\\Program Files\\gs\\fonts\\" "c:\\Program Files \(x86\)\\gs\\fonts\\" "c:\\gs\\fonts\\"; do |
| 3345 | if test -f "${font_dir}a010013l.pfb"; then |
| 3346 | ghostscript_font_dir="$font_dir" |
| 3347 | break 1 |
| 3348 | fi |
| 3349 | done |
| 3350 | if test "${PSDelegate}" != 'gswin32c'; then |
| 3351 | ghostscript_font_dir=`echo "${PSDelegate}" | sed -e 's:/gs/.*:/gs:;s:^/::;s/./&:/;s:/:\\\\:g'`"\\fonts\\" |
| 3352 | fi |
| 3353 | else |
| 3354 | # Linux / Mac OS X / Unix Build |
| 3355 | for font_dir in "${prefix}/share/ghostscript/fonts/" '/usr/share/fonts/default/Type1/' '/usr/share/ghostscript/fonts/' '/usr/share/fonts/ghostscript/' '/usr/share/fonts/type1/gsfonts/' '/opt/local/share/ghostscript/fonts/' '/sw/share/ghostscript/fonts/' '/System/Library/Frameworks/Ghostscript.framework/Resources/fonts/'; do |
| 3356 | if test -f "${font_dir}a010013l.pfb"; then |
| 3357 | ghostscript_font_dir="${font_dir}" |
| 3358 | break 1 |
| 3359 | fi |
| 3360 | done |
| 3361 | if test "${ghostscript_font_dir}x" = 'x'; then |
| 3362 | if test "$PSDelegate" != 'gs'; then |
| 3363 | ghostscript_font_dir=`echo "$PSDelegate" | sed -e 's:/bin/gs:/share/ghostscript/fonts:'`"/" |
| 3364 | fi |
| 3365 | fi |
| 3366 | fi |
| 3367 | fi |
| 3368 | if test "${ghostscript_font_dir}x" != 'x'; then |
| 3369 | type_include_files="${type_include_files} "'<include file="type-ghostscript.xml" />' |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3370 | AC_MSG_RESULT([$ghostscript_font_dir]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3371 | else |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3372 | AC_MSG_RESULT([not found!]); |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3373 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3374 | AC_SUBST([ghostscript_font_dir]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3375 | case "${build_os}" in |
| 3376 | mingw* ) |
| 3377 | PSDelegate=`$WinPathScript "$PSDelegate" 1` |
| 3378 | ;; |
| 3379 | esac |
| 3380 | |
Cristy | fbca0d0 | 2017-09-27 16:52:52 -0400 | [diff] [blame] | 3381 | # URW-base35 fonts. |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3382 | AC_MSG_CHECKING([for URW-base35 fonts directory]) |
Cristy | fbca0d0 | 2017-09-27 16:52:52 -0400 | [diff] [blame] | 3383 | urw_base35_font_dir='' |
| 3384 | if test "${with_urw_base35_font_dir}" != 'default'; then |
| 3385 | urw_base35_font_dir="${with_urw_base35_font_dir}/" |
Cristy | fbca0d0 | 2017-09-27 16:52:52 -0400 | [diff] [blame] | 3386 | fi |
| 3387 | if test "${urw_base35_font_dir}x" != 'x'; then |
| 3388 | type_include_files="${type_include_files} "'<include file="type-urw-base35.xml" />' |
| 3389 | AC_MSG_RESULT([$urw_base35_font_dir]) |
| 3390 | else |
| 3391 | AC_MSG_RESULT([not found!]); |
| 3392 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3393 | AC_SUBST([urw_base35_font_dir]) |
Cristy | fbca0d0 | 2017-09-27 16:52:52 -0400 | [diff] [blame] | 3394 | |
cristy | 5a3dc99 | 2014-12-05 19:50:04 +0000 | [diff] [blame] | 3395 | # Windows fonts. |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3396 | AC_MSG_CHECKING([for Windows fonts directory]) |
cristy | 5a3dc99 | 2014-12-05 19:50:04 +0000 | [diff] [blame] | 3397 | windows_font_dir='' |
| 3398 | if test "${with_windows_font_dir}" != 'default'; then |
| 3399 | windows_font_dir="${with_windows_font_dir}/" |
| 3400 | else |
Cristy | 6fa1876 | 2018-12-16 14:48:50 -0500 | [diff] [blame] | 3401 | for font_dir in '/usr/X11R6/lib/X11/fonts/truetype/' '/usr/X11R7/lib/X11/fonts/truetype/' '/usr/share/fonts/msttcore/' '/usr/share/fonts/microsoft/' '/usr/share/fonts/truetype/msttcorefonts/'; do |
cristy | 5a3dc99 | 2014-12-05 19:50:04 +0000 | [diff] [blame] | 3402 | if test -f "${font_dir}arial.ttf"; then |
| 3403 | windows_font_dir="${font_dir}" |
| 3404 | break 1 |
| 3405 | fi |
| 3406 | done |
| 3407 | fi |
| 3408 | if test "${windows_font_dir}x" != 'x'; then |
| 3409 | type_include_files="${type_include_files} "'<include file="type-windows.xml" />' |
| 3410 | AC_MSG_RESULT([$windows_font_dir]) |
| 3411 | else |
| 3412 | AC_MSG_RESULT([not found!]); |
| 3413 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3414 | AC_SUBST([windows_font_dir]) |
cristy | 5a3dc99 | 2014-12-05 19:50:04 +0000 | [diff] [blame] | 3415 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3416 | AC_SUBST([type_include_files]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3417 | |
| 3418 | # |
| 3419 | # Handle case where user doesn't want frozen paths |
| 3420 | # |
| 3421 | if test "$with_frozenpaths" != 'yes'; then |
| 3422 | # Re-set delegate definitions to default (no paths) |
Cristy | 06c41ab | 2016-04-30 10:23:22 -0400 | [diff] [blame] | 3423 | BPGDecodeDelegate="$BPGDecodeDelegateDefault" |
| 3424 | BPGEncodeDelegate="$BPGEncodeDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3425 | BlenderDecodeDelegate="$BlenderDecodeDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3426 | BrowseDelegate="$BrowseDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3427 | ConvertDelegate="$ConvertDelegateDefault" |
cristy | 71f53d5 | 2013-04-27 13:33:59 +0000 | [diff] [blame] | 3428 | DisplayDelegate="$DisplayDelegateDefault" |
| 3429 | DNGDecodeDelegate="$DNGDecodeDelegateDefault" |
cristy | 66f238e | 2014-05-16 12:21:48 +0000 | [diff] [blame] | 3430 | DOCDecodeDelegate="$DOCDecodeDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3431 | DVIDecodeDelegate="$DVIDecodeDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3432 | EditorDelegate="$EditorDelegateDefault" |
cristy | 71f53d5 | 2013-04-27 13:33:59 +0000 | [diff] [blame] | 3433 | GVCDecodeDelegate="$GVCDecodeDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3434 | HPGLDecodeDelegate="$HPGLDecodeDelegateDefault" |
| 3435 | HTMLDecodeDelegate="$HTMLDecodeDelegateDefault" |
| 3436 | ILBMDecodeDelegate="$ILBMDecodeDelegateDefault" |
| 3437 | ILBMEncodeDelegate="$ILBMEncodeDelegateDefault" |
cristy | 71f53d5 | 2013-04-27 13:33:59 +0000 | [diff] [blame] | 3438 | JXRDecodeDelegate="$JXRDecodeDelegateDefault" |
| 3439 | JXREncodeDelegate="$JXREncodeDelegateDefault" |
Cristy | 3ef15c0 | 2017-01-02 07:41:13 -0500 | [diff] [blame] | 3440 | LEPDelegate="$LEPDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3441 | LPDelegate="$LPDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3442 | LaunchDelegate="$LaunchDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3443 | MogrifyDelegate="$MogrifyDelegateDefault" |
cristy | 935c86e | 2010-06-05 23:50:07 +0000 | [diff] [blame] | 3444 | MrSIDDecodeDelegate="$MrSIDDecodeDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3445 | PCLDelegate="$PCLDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3446 | PSDelegate="$PSDelegateDefault" |
cristy | 4689cf0 | 2010-02-17 21:15:45 +0000 | [diff] [blame] | 3447 | RSVGDecodeDelegate="$RSVGDecodeDelegateDefault" |
cristy | ec6934f | 2012-08-14 18:38:40 +0000 | [diff] [blame] | 3448 | SVGDecodeDelegate="$SVGDecodeDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3449 | ShowImageDelegate="$ShowImageDelegateDefault" |
Cristy | 6bb3534 | 2020-11-07 14:23:18 +0000 | [diff] [blame] | 3450 | TextEncodeDelegate="$TextEncodeDelegateDefault" |
Cristy | 9e11348 | 2019-08-21 09:19:28 -0400 | [diff] [blame] | 3451 | TraceEncodeDelegate="$TraceEncodeDelegateDefault" |
Cristy | b7c02fa | 2020-08-09 17:20:25 -0400 | [diff] [blame] | 3452 | Fig2devDelegate="$Fig2devDelegateDefault" |
Cristy | 6e04083 | 2020-10-14 22:45:34 +0000 | [diff] [blame] | 3453 | VIDEODecodeDelegate="$VIDEODecodeDelegateDefault" |
| 3454 | VIDEOEncodeDelegate="$VIDEOEncodeDelegateDefault" |
cristy | 86e8609 | 2013-08-04 17:43:57 +0000 | [diff] [blame] | 3455 | WebPDecodeDelegate="$WebPDecodeDelegateDefault" |
| 3456 | WebPEncodeDelegate="$WebPEncodeDelegateDefault" |
Cristy | dc553c1 | 2016-05-09 13:27:06 -0400 | [diff] [blame] | 3457 | WWWDecodeDelegate="$WWWDecodeDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3458 | XPSDelegate="$XPSDelegateDefault" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3459 | fi |
| 3460 | |
| 3461 | # Delegate substitutions |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3462 | AC_SUBST([BPGDecodeDelegate]) |
| 3463 | AC_SUBST([BPGEncodeDelegate]) |
| 3464 | AC_SUBST([BlenderDecodeDelegate]) |
| 3465 | AC_SUBST([BrowseDelegate]) |
| 3466 | AC_SUBST([ConvertDelegate]) |
| 3467 | AC_SUBST([GVCDecodeDelegate]) |
| 3468 | AC_SUBST([DVIDecodeDelegate]) |
| 3469 | AC_SUBST([EditorDelegate]) |
| 3470 | AC_SUBST([Fig2devDelegate]) |
| 3471 | AC_SUBST([HPGLDecodeDelegate]) |
| 3472 | AC_SUBST([HTMLDecodeDelegate]) |
| 3473 | AC_SUBST([ILBMDecodeDelegate]) |
| 3474 | AC_SUBST([ILBMEncodeDelegate]) |
| 3475 | AC_SUBST([JXRDecodeDelegate]) |
| 3476 | AC_SUBST([JXREncodeDelegate]) |
| 3477 | AC_SUBST([LaunchDelegate]) |
| 3478 | AC_SUBST([LEPDelegate]) |
| 3479 | AC_SUBST([LPDelegate]) |
Cristy | 6e04083 | 2020-10-14 22:45:34 +0000 | [diff] [blame] | 3480 | AC_SUBST([VIDEODecodeDelegate]) |
| 3481 | AC_SUBST([VIDEOEncodeDelegate]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3482 | AC_SUBST([MogrifyDelegate]) |
| 3483 | AC_SUBST([MrSIDDecodeDelegate]) |
| 3484 | AC_SUBST([PCLDelegate]) |
| 3485 | AC_SUBST([PSDelegate]) |
| 3486 | AC_SUBST([ShowImageDelegate]) |
Cristy | 6bb3534 | 2020-11-07 14:23:18 +0000 | [diff] [blame] | 3487 | AC_SUBST([TextEncodeDelegate]) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3488 | AC_SUBST([TraceEncodeDelegate]) |
| 3489 | AC_SUBST([WebPDecodeDelegate]) |
| 3490 | AC_SUBST([WebPEncodeDelegate]) |
| 3491 | AC_SUBST([WWWDecodeDelegate]) |
| 3492 | AC_SUBST([XPSDelegate]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3493 | |
| 3494 | # |
| 3495 | # RPM support. |
| 3496 | # |
| 3497 | RPM='' |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3498 | AC_CHECK_PROGS([TAR],[gnutar gtar tar]) |
| 3499 | AC_CHECK_PROGS([PERL],[perl]) |
| 3500 | AC_CHECK_PROGS([RPM],[rpmbuild rpm]) |
| 3501 | AM_MISSING_PROG([ACLOCAL],[aclocal],[$missing_dir]) |
| 3502 | AM_MISSING_PROG([AUTOCONF],[autoconf],[$missing_dir]) |
| 3503 | AM_MISSING_PROG([AUTOMAKE],[automake],[$missing_dir]) |
| 3504 | AM_MISSING_PROG([AUTOHEADER],[autoheader],[$missing_dir]) |
| 3505 | AC_SUBST([RPM]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3506 | AM_CONDITIONAL([RPM_DELEGATE],[test "x$RPM" != "x"]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3507 | |
| 3508 | # |
| 3509 | # 7ZIP support (http://p7zip.sourceforge.net/) |
| 3510 | # |
| 3511 | P7ZIP='' |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3512 | AC_CHECK_PROGS([P7ZIP],[7za]) |
| 3513 | AC_SUBST([P7ZIP]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3514 | AM_CONDITIONAL([P7ZIP_DELEGATE],[test "x$P7ZIP" != "x"]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3515 | |
| 3516 | # |
| 3517 | # ZIP support (http://www.info-zip.org/Zip.html) |
| 3518 | # |
| 3519 | ZIP='' |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3520 | AC_CHECK_PROGS([ZIP],[zip]) |
| 3521 | AC_SUBST([ZIP]) |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3522 | AM_CONDITIONAL([ZIP_DELEGATE],[test "x$ZIP" != "x"]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3523 | |
| 3524 | # |
| 3525 | # GhostPCL related configuration. |
| 3526 | # |
| 3527 | PCLColorDevice=ppmraw |
cristy | 8bc8408 | 2011-09-07 13:57:00 +0000 | [diff] [blame] | 3528 | PCLCMYKDevice=pamcmyk32 |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3529 | PCLMonoDevice=pbmraw |
| 3530 | if test -z "$PCLVersion"; then |
| 3531 | PCLVersion='unknown' |
| 3532 | fi |
| 3533 | if test $have_pcl = 'yes'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3534 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3535 | AC_MSG_CHECKING([for PCL]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3536 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3537 | # PCLColorDevice |
| 3538 | AC_MSG_CHECKING([for pcl color device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3539 | if $PCLDelegate -dBATCH -sDEVICE=$PCLColorDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3540 | : |
| 3541 | else |
| 3542 | PCLColorDevice=ppmraw |
| 3543 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3544 | AC_MSG_RESULT([$PCLColorDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3545 | |
| 3546 | # PCLCMYKDevice |
| 3547 | AC_MSG_CHECKING([for pcl CMYK device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3548 | if $PCLDelegate -dBATCH -sDEVICE=$PCLColorDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3549 | : |
| 3550 | else |
| 3551 | PCLCMYKDevice=$PCLColorDevice |
| 3552 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3553 | AC_MSG_RESULT([$PCLCMYKDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3554 | |
| 3555 | # PCLMonoDevice |
| 3556 | AC_MSG_CHECKING([for pcl mono device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3557 | if $PCLDelegate -dBATCH -sDEVICE=$PCLMonoDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3558 | : |
| 3559 | else |
| 3560 | PCLMonoDevice=$PCLColorDevice |
| 3561 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3562 | AC_MSG_RESULT([$PCLMonoDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3563 | fi |
| 3564 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3565 | AC_SUBST([PCLMonoDevice]) |
| 3566 | AC_SUBST([PCLColorDevice]) |
| 3567 | AC_SUBST([PCLCMYKDevice]) |
| 3568 | AC_SUBST([PCLVersion]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3569 | |
| 3570 | # |
| 3571 | # GhostXPS related configuration. |
| 3572 | # |
| 3573 | XPSColorDevice=ppmraw |
| 3574 | XPSCMYKDevice=bmpsep8 |
| 3575 | XPSMonoDevice=pbmraw |
| 3576 | if test -z "$XPSVersion"; then |
| 3577 | XPSVersion='unknown' |
| 3578 | fi |
| 3579 | if test $have_xps = 'yes'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3580 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3581 | AC_MSG_CHECKING([for XPS]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3582 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3583 | # XPSColorDevice |
| 3584 | AC_MSG_CHECKING([for xps color device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3585 | if $XPSDelegate -dBATCH -sDEVICE=$XPSColorDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3586 | : |
| 3587 | else |
| 3588 | XPSColorDevice=ppmraw |
| 3589 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3590 | AC_MSG_RESULT([$XPSColorDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3591 | |
| 3592 | # XPSCMYKDevice |
| 3593 | AC_MSG_CHECKING([for xps CMYK device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3594 | if $XPSDelegate -dBATCH -sDEVICE=$XPSColorDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3595 | : |
| 3596 | else |
| 3597 | XPSCMYKDevice=$XPSColorDevice |
| 3598 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3599 | AC_MSG_RESULT([$XPSCMYKDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3600 | |
| 3601 | # XPSMonoDevice |
| 3602 | AC_MSG_CHECKING([for xps mono device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3603 | if $XPSDelegate -dBATCH -sDEVICE=$XPSMonoDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3604 | : |
| 3605 | else |
| 3606 | XPSMonoDevice=$XPSColorDevice |
| 3607 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3608 | AC_MSG_RESULT([$XPSMonoDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3609 | fi |
| 3610 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3611 | AC_SUBST([XPSMonoDevice]) |
| 3612 | AC_SUBST([XPSColorDevice]) |
| 3613 | AC_SUBST([XPSCMYKDevice]) |
| 3614 | AC_SUBST([XPSVersion]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3615 | |
| 3616 | # |
| 3617 | # Ghostscript related configuration. |
| 3618 | # |
cristy | a97426c | 2011-02-04 01:41:27 +0000 | [diff] [blame] | 3619 | GSAlphaDevice=pngalpha |
Cristy | 13f5e9a | 2019-11-29 12:24:16 -0500 | [diff] [blame] | 3620 | GSColorDevice=png16m |
cristy | 63970c5 | 2015-06-06 16:09:04 +0000 | [diff] [blame] | 3621 | GSCMYKDevice=pamcmyk32 |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3622 | GSMonoDevice=pbmraw |
| 3623 | GSPDFDevice=pdfwrite |
cristy | b096ea5 | 2013-10-26 20:56:38 +0000 | [diff] [blame] | 3624 | GSPSDevice=ps2write |
cristy | a5b91e7 | 2015-01-07 15:39:36 +0000 | [diff] [blame] | 3625 | GSEPSDevice=eps2write |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3626 | GSVersion='unknown' |
| 3627 | if test $have_gs = 'yes'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3628 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3629 | AC_MSG_CHECKING([for Ghostscript]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3630 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3631 | AC_MSG_CHECKING([for Ghostscript version]) |
| 3632 | if GSVersion=`$PSDelegate --version`; then |
| 3633 | : |
| 3634 | else |
| 3635 | GSVersion=`$PSDelegate --help | sed -e '1q' | awk '{ print $3 }'` |
| 3636 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3637 | AC_MSG_RESULT([$GSVersion]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3638 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3639 | # GSColorDevice |
| 3640 | AC_MSG_CHECKING([for gs color device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3641 | if $PSDelegate -q -dBATCH -sDEVICE=$GSColorDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3642 | : |
| 3643 | else |
cristy | 63970c5 | 2015-06-06 16:09:04 +0000 | [diff] [blame] | 3644 | GSColorDevice=ppmraw |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3645 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3646 | AC_MSG_RESULT([$GSColorDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3647 | |
cristy | 63970c5 | 2015-06-06 16:09:04 +0000 | [diff] [blame] | 3648 | # GSAlphaDevice |
| 3649 | AC_MSG_CHECKING([for gs alpha device]) |
| 3650 | if $PSDelegate -q -dBATCH -sDEVICE=$GSAlphaDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
| 3651 | : |
| 3652 | else |
| 3653 | GSAlphaDevice=$GSColorDevice |
| 3654 | fi |
| 3655 | AC_MSG_RESULT([$GSAlphaDevice]) |
| 3656 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3657 | # GSCMYKDevice |
| 3658 | AC_MSG_CHECKING([for gs CMYK device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3659 | if $PSDelegate -q -dBATCH -sDEVICE=$GSCMYKDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3660 | : |
| 3661 | else |
cristy | 63970c5 | 2015-06-06 16:09:04 +0000 | [diff] [blame] | 3662 | GSCMYKDevice=pam |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3663 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3664 | AC_MSG_RESULT([$GSCMYKDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3665 | |
| 3666 | # GSMonoDevice |
| 3667 | AC_MSG_CHECKING([for gs mono device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3668 | if $PSDelegate -q -dBATCH -sDEVICE=$GSMonoDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3669 | : |
| 3670 | else |
| 3671 | GSMonoDevice=$GSColorDevice |
| 3672 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3673 | AC_MSG_RESULT([$GSMonoDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3674 | |
| 3675 | # GSPDFDevice |
| 3676 | AC_MSG_CHECKING([for gs PDF writing device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3677 | if $PSDelegate -q -dBATCH -sDEVICE=$GSPDFDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3678 | : |
| 3679 | else |
| 3680 | GSPDFDevice=nodevice |
| 3681 | fi |
cristy | 63970c5 | 2015-06-06 16:09:04 +0000 | [diff] [blame] | 3682 | AC_MSG_RESULT([$GSPDFDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3683 | |
| 3684 | # GSPSDevice |
| 3685 | AC_MSG_CHECKING([for gs PS writing device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3686 | if $PSDelegate -q -dBATCH -sDEVICE=$GSPSDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3687 | : |
| 3688 | else |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 3689 | GSPSDevice=pswrite |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3690 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3691 | AC_MSG_RESULT([$GSPSDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3692 | |
| 3693 | # GSEPSDevice |
| 3694 | AC_MSG_CHECKING([for gs EPS writing device]) |
cristy | 86e31f3 | 2015-06-06 15:47:32 +0000 | [diff] [blame] | 3695 | if $PSDelegate -q -dBATCH -sDEVICE=$GSEPSDevice -sOutputFile=/dev/null < /dev/null 1>&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD; then |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3696 | : |
| 3697 | else |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 3698 | GSEPSDevice=epswrite |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3699 | fi |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3700 | AC_MSG_RESULT([$GSEPSDevice]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3701 | fi |
| 3702 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3703 | AC_SUBST([GSAlphaDevice]) |
| 3704 | AC_SUBST([GSCMYKDevice]) |
| 3705 | AC_SUBST([GSColorDevice]) |
| 3706 | AC_SUBST([GSEPSDevice]) |
| 3707 | AC_SUBST([GSMonoDevice]) |
| 3708 | AC_SUBST([GSPDFDevice]) |
| 3709 | AC_SUBST([GSPSDevice]) |
| 3710 | AC_SUBST([GSVersion]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3711 | |
| 3712 | # |
| 3713 | # PerlMagick-related configuration |
| 3714 | # |
| 3715 | |
| 3716 | # Look for PERL if PerlMagick requested |
| 3717 | # If name/path of desired PERL interpreter is specified, look for that one first |
| 3718 | have_perl='no' |
| 3719 | if test "$with_perl" != 'no'; then |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3720 | AC_MSG_RESULT([-------------------------------------------------------------]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3721 | AC_MSG_CHECKING([for Perl]) |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3722 | AC_MSG_RESULT([]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3723 | if test "$with_perl" != 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3724 | AC_CACHE_CHECK([for perl],[ac_cv_path_PERL],[ac_cv_path_PERL="$with_perl"]); |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3725 | PERL=$ac_cv_path_PERL |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3726 | AC_SUBST([PERL])dnl |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3727 | have_perl="$ac_cv_path_PERL" |
| 3728 | else |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3729 | AC_PATH_PROGS([PERL],[perl perl5],[])dnl |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3730 | if test "$ac_cv_path_PERL"; then |
| 3731 | have_perl="$ac_cv_path_PERL" |
| 3732 | fi |
| 3733 | fi |
| 3734 | fi |
| 3735 | |
cristy | 949301e | 2010-01-06 01:38:40 +0000 | [diff] [blame] | 3736 | if test "$with_perl" != 'yes' ; then |
| 3737 | DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-perl=$with_perl " |
| 3738 | fi |
| 3739 | |
| 3740 | PERL_SUPPORTS_DESTDIR='no' |
| 3741 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3742 | with_perl_static='no' |
| 3743 | with_perl_dynamic='no' |
| 3744 | if test "$have_perl" != 'no'; then |
| 3745 | if test "$with_perl" != 'no' && test "$libtool_build_shared_libs" = 'no'; then |
| 3746 | with_perl_static='yes' |
| 3747 | fi |
| 3748 | if test "$with_perl" != 'no' && test "$libtool_build_shared_libs" = 'yes'; then |
| 3749 | with_perl_dynamic='yes' |
| 3750 | fi |
| 3751 | # Is PERL's MakeMaker new enough to support DESTDIR? |
cristy | 964cb7f | 2010-04-25 23:18:00 +0000 | [diff] [blame] | 3752 | AX_PROG_PERL_VERSION(5.8.1,[PERL_SUPPORTS_DESTDIR='yes'],[PERL_SUPPORTS_DESTDIR='no']) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3753 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3754 | AM_CONDITIONAL([WITH_PERL],[test "$have_perl" != 'no']) |
| 3755 | AM_CONDITIONAL([WITH_PERL_STATIC],[test $with_perl_static = 'yes']) |
| 3756 | AM_CONDITIONAL([WITH_PERL_DYNAMIC],[test $with_perl_dynamic = 'yes']) |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3757 | AC_SUBST([PERL_SUPPORTS_DESTDIR]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3758 | |
| 3759 | # Determine path to pick up MagickCore library from for use with building PerlMagick |
| 3760 | MAGICKCORE_PATH="${LIB_DIR}" |
| 3761 | if test $with_perl_static = 'yes'; then |
| 3762 | # Find out where libtool hides its uninstalled libraries (as libtool_objdir) |
| 3763 | libtool_objdir=$objdir |
| 3764 | |
| 3765 | # Linker search path to library, followed by -lMagickCore |
cristy | 4c08aed | 2011-07-01 19:47:50 +0000 | [diff] [blame] | 3766 | MAGICKCORE_PATH="${builddir}/MagickCore/${libtool_objdir}" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3767 | fi |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3768 | AC_SUBST([MAGICKCORE_PATH]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3769 | |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3770 | # Create a simple string containing format names for all delegate libraries. |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3771 | MAGICK_DELEGATES='' |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3772 | if test "$have_autotrace" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3773 | MAGICK_DELEGATES="$MAGICK_DELEGATES autotrace" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3774 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3775 | if test "$have_bzlib" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3776 | MAGICK_DELEGATES="$MAGICK_DELEGATES bzlib" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3777 | fi |
| 3778 | if test "$have_dps" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3779 | MAGICK_DELEGATES="$MAGICK_DELEGATES dps" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3780 | fi |
| 3781 | if test "$have_djvu" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3782 | MAGICK_DELEGATES="$MAGICK_DELEGATES djvu" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3783 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3784 | if test "$have_fftw" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3785 | MAGICK_DELEGATES="$MAGICK_DELEGATES fftw" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3786 | fi |
Cristy | 6d2f14b | 2016-04-26 01:41:09 -0400 | [diff] [blame] | 3787 | if test "$have_flif" = 'yes' ; then |
| 3788 | MAGICK_DELEGATES="$MAGICK_DELEGATES flif" |
| 3789 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3790 | if test "$have_fpx" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3791 | MAGICK_DELEGATES="$MAGICK_DELEGATES fpx" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3792 | fi |
| 3793 | if test "$have_fontconfig" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3794 | MAGICK_DELEGATES="$MAGICK_DELEGATES fontconfig" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3795 | fi |
| 3796 | if test "$have_freetype" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3797 | MAGICK_DELEGATES="$MAGICK_DELEGATES freetype" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3798 | fi |
| 3799 | if test "$have_gslib" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3800 | MAGICK_DELEGATES="$MAGICK_DELEGATES gslib" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3801 | fi |
Cristy | 9e7b981 | 2017-11-19 09:35:36 -0500 | [diff] [blame] | 3802 | if test "$have_heic" = 'yes' ; then |
| 3803 | MAGICK_DELEGATES="$MAGICK_DELEGATES heic" |
| 3804 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3805 | if test "$have_jbig" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3806 | MAGICK_DELEGATES="$MAGICK_DELEGATES jbig" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3807 | fi |
| 3808 | if test "$have_png$have_jpeg" = 'yesyes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3809 | MAGICK_DELEGATES="$MAGICK_DELEGATES jng" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3810 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3811 | if test "$have_jpeg" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3812 | MAGICK_DELEGATES="$MAGICK_DELEGATES jpeg" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3813 | fi |
Cristy | b316fbb | 2019-10-05 10:51:15 -0400 | [diff] [blame] | 3814 | if test "$have_jxl" = 'yes' ; then |
| 3815 | MAGICK_DELEGATES="$MAGICK_DELEGATES jxl" |
| 3816 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3817 | if test "$have_lcms" = 'yes' || test "$have_lcms2" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3818 | MAGICK_DELEGATES="$MAGICK_DELEGATES lcms" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3819 | fi |
| 3820 | if test "$have_lqr" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3821 | MAGICK_DELEGATES="$MAGICK_DELEGATES lqr" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3822 | fi |
| 3823 | if test "$have_lzma" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3824 | MAGICK_DELEGATES="$MAGICK_DELEGATES lzma" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3825 | fi |
| 3826 | if test "$have_openexr" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3827 | MAGICK_DELEGATES="$MAGICK_DELEGATES openexr" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3828 | fi |
cristy | 99db387 | 2014-01-01 15:11:34 +0000 | [diff] [blame] | 3829 | if test "$have_openjp2" = 'yes' ; then |
| 3830 | MAGICK_DELEGATES="$MAGICK_DELEGATES openjp2" |
cristy | 3fe0945 | 2014-01-01 12:29:14 +0000 | [diff] [blame] | 3831 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3832 | if test "$have_pango" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3833 | MAGICK_DELEGATES="$MAGICK_DELEGATES pango" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3834 | fi |
| 3835 | if test "$have_png" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3836 | MAGICK_DELEGATES="$MAGICK_DELEGATES png" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3837 | fi |
| 3838 | have_ps='no' |
| 3839 | if test "$have_dps" = 'yes' || \ |
| 3840 | test "$have_gs" = 'yes' || \ |
| 3841 | test "${native_win32_build}" = 'yes' ; then |
| 3842 | have_ps='yes' |
| 3843 | fi |
| 3844 | if test "$have_ps" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3845 | MAGICK_DELEGATES="$MAGICK_DELEGATES ps" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3846 | fi |
Cristy | 5572ef6 | 2016-02-06 16:10:00 -0500 | [diff] [blame] | 3847 | if test "$have_raqm" = 'yes' ; then |
| 3848 | MAGICK_DELEGATES="$MAGICK_DELEGATES raqm" |
| 3849 | fi |
Cristy | ea6e8ae | 2019-09-30 07:21:16 -0400 | [diff] [blame] | 3850 | if test "$have_raw" = 'yes' ; then |
| 3851 | MAGICK_DELEGATES="$MAGICK_DELEGATES raw" |
| 3852 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3853 | if test "$have_ra_ppm" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3854 | MAGICK_DELEGATES="$MAGICK_DELEGATES rad" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3855 | fi |
| 3856 | if test "$have_rsvg" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3857 | MAGICK_DELEGATES="$MAGICK_DELEGATES rsvg" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3858 | fi |
| 3859 | if test "$have_tiff" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3860 | MAGICK_DELEGATES="$MAGICK_DELEGATES tiff" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3861 | fi |
| 3862 | if test "$have_ttf" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3863 | MAGICK_DELEGATES="$MAGICK_DELEGATES ttf" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3864 | fi |
Cristy | 6e04083 | 2020-10-14 22:45:34 +0000 | [diff] [blame] | 3865 | if test "$have_video" = 'yes' ; then |
| 3866 | MAGICK_DELEGATES="$MAGICK_DELEGATES video" |
| 3867 | fi |
cristy | 3b640ed | 2013-07-29 00:27:59 +0000 | [diff] [blame] | 3868 | if test "$have_webp" = 'yes' ; then |
| 3869 | MAGICK_DELEGATES="$MAGICK_DELEGATES webp" |
| 3870 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3871 | if test "$have_wmf" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3872 | MAGICK_DELEGATES="$MAGICK_DELEGATES wmf" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3873 | fi |
| 3874 | if test "$have_x" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3875 | MAGICK_DELEGATES="$MAGICK_DELEGATES x" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3876 | fi |
| 3877 | if test "$have_xml" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3878 | MAGICK_DELEGATES="$MAGICK_DELEGATES xml" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3879 | fi |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3880 | if test "$have_zip" = 'yes' ; then |
| 3881 | MAGICK_DELEGATES="$MAGICK_DELEGATES zip" |
Christopher Chianelli | 7a1a92c | 2020-08-02 10:16:01 -0400 | [diff] [blame] | 3882 | fi |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3883 | if test "$have_zlib" = 'yes' ; then |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3884 | MAGICK_DELEGATES="$MAGICK_DELEGATES zlib" |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3885 | fi |
Cristy | 08170e6 | 2018-10-14 10:33:46 -0400 | [diff] [blame] | 3886 | if test "$have_zstd" = 'yes' ; then |
| 3887 | MAGICK_DELEGATES="$MAGICK_DELEGATES zstd" |
| 3888 | fi |
cristy | ead532a | 2015-06-05 00:49:30 +0000 | [diff] [blame] | 3889 | |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3890 | # Remove extraneous spaces from output variables (asthetic) |
cristy | 422d550 | 2012-12-22 22:20:57 +0000 | [diff] [blame] | 3891 | MAGICK_DELEGATES=`echo $MAGICK_DELEGATES | sed -e 's/ */ /g'` |
cristy | 2a3eb39 | 2012-12-17 13:39:20 +0000 | [diff] [blame] | 3892 | MAGICK_FEATURES=`echo $MAGICK_FEATURES | sed -e 's/ */ /g'` |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3893 | AC_SUBST([MAGICK_DELEGATES]) |
| 3894 | AC_SUBST([MAGICK_FEATURES]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3895 | |
| 3896 | # |
| 3897 | # Handle special compiler flags |
| 3898 | # |
| 3899 | |
| 3900 | # Add '-p' if prof source profiling support enabled |
| 3901 | if test "$enable_prof" = 'yes'; then |
| 3902 | CFLAGS="-p $CFLAGS" |
| 3903 | CXXFLAGS="-p $CXXFLAGS" |
| 3904 | LDFLAGS="-p $LDFLAGS" |
| 3905 | fi |
| 3906 | |
| 3907 | # Add '-pg' if gprof source profiling support enabled |
| 3908 | if test "$enable_gprof" = 'yes'; then |
| 3909 | CFLAGS="-pg $CFLAGS" |
| 3910 | CXXFLAGS="-pg $CXXFLAGS" |
| 3911 | LDFLAGS="-pg $LDFLAGS" |
| 3912 | fi |
| 3913 | |
| 3914 | # Add '-ftest-coverage -fprofile-arcs' if gcov source profiling support enabled |
| 3915 | # This is a gcc-specific feature |
| 3916 | if test "$enable_gcov" = 'yes'; then |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3917 | AC_CHECK_LIB([gcov],[_gcov_init],[],[]) |
| 3918 | AC_CHECK_LIB([gcov],[__gcov_init],[],[]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3919 | case "$target_os" in |
| 3920 | darwin*) |
| 3921 | OSX_GCOV_LDFLAG="-Wl,-single_module" |
| 3922 | ;; |
| 3923 | *) |
| 3924 | OSX_GCOV_LDFLAG="" |
| 3925 | ;; |
| 3926 | esac |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3927 | AC_SUBST([OSX_GCOV_LDFLAG]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3928 | CFLAGS="-ftest-coverage -fprofile-arcs $CFLAGS" |
| 3929 | CXXFLAGS="-ftest-coverage -fprofile-arcs $CXXFLAGS" |
| 3930 | LDFLAGS="-ftest-coverage -fprofile-arcs $LDFLAGS" |
| 3931 | fi |
| 3932 | |
| 3933 | # |
| 3934 | # Build library dependency list for libMagickCore |
| 3935 | # |
| 3936 | |
cristy | c672209 | 2012-10-14 00:19:31 +0000 | [diff] [blame] | 3937 | if test "$build_modules" != 'no'; then |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3938 | MAGICK_DEP_LIBS="$USER_LIBS $LCMS_LIBS $FREETYPE_LIBS $RAQM_LIBS $LQR_LIBS $FFTW_LIBS $XML_LIBS $FLIF_LIBS $FONTCONFIG_LIBS $XEXT_LIBS $IPC_LIBS $X11_LIBS $XT_LIBS $BZLIB_LIBS $ZLIB_LIBS $ZIP_LIBS $ZSTD_LIBS $LTDL_LIBS $GDI32_LIBS $MATH_LIBS $CL_LIBS $UMEM_LIBS $JEMALLOC_LIBS $THREAD_LIBS $TCMALLOC_LIBS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3939 | else |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 3940 | MAGICK_DEP_LIBS="$USER_LIBS $JBIG_LIBS $LCMS_LIBS $TIFF_LIBS $FREETYPE_LIBS $RAQM_LIBS $JPEG_LIBS $JXL_LIBS $GS_LIBS $LQR_LIBS $PNG_LIBS $AUTOTRACE_LIBS $DJVU_LIBS $FFTW_LIBS $FLIF_LIBS $FPX_LIBS $FONTCONFIG_LIBS $HEIF_LIBS $WEBPMUX_LIBS $WEBP_LIBS $WMF_LIBS $DPS_LIBS $XEXT_LIBS $XT_LIBS $IPC_LIBS $X11_LIBS $LZMA_LIBS $BZLIB_LIBS $OPENEXR_LIBS $LIBOPENJP2_LIBS $PANGO_LIBS $RAW_R_LIBS $RSVG_LIBS $XML_LIBS $GVC_LIBS $ZLIB_LIBS $ZIP_LIBS $ZSTD_LIBS $LTDL_LIBS $GDI32_LIBS $MATH_LIBS $CL_LIBS $UMEM_LIBS $JEMALLOC_LIBS $THREAD_LIBS $TCMALLOC_LIBS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3941 | fi |
Cristy | 56d66f2 | 2018-10-22 19:15:12 -0400 | [diff] [blame] | 3942 | MAGICK_EXTRA_DEP_LIBS="$GOMP_LIBS" |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3943 | AC_SUBST([MAGICK_DEP_LIBS]) |
| 3944 | AC_SUBST([MAGICK_EXTRA_DEP_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3945 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3946 | # Pass only user-provided LIBS as "global" libraries |
| 3947 | LIBS=$USER_LIBS |
| 3948 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3949 | #AC_SUBST([CPPFLAGS]) |
| 3950 | AC_SUBST([X_CFLAGS]) |
| 3951 | #AC_SUBST([LDFLAGS]) |
| 3952 | #AC_SUBST([X_PRE_LIBS]) |
| 3953 | #AC_SUBST([X_LIBS]) |
| 3954 | #AC_SUBST([X_EXTRA_LIBS]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3955 | |
| 3956 | MAGICK_CFLAGS=$CFLAGS |
| 3957 | MAGICK_CXXFLAGS="$CXXFLAGS" |
| 3958 | MAGICK_CPPFLAGS=`echo $MAGICK_CPPFLAGS | sed -e 's/ */ /g'` |
| 3959 | MAGICK_PCFLAGS=`echo $MAGICK_PCFLAGS | sed -e 's/ */ /g'` |
| 3960 | MAGICK_LDFLAGS="-L$LIB_DIR $LDFLAGS" |
Carsten Teibes | 93d248a | 2018-10-29 21:00:15 +0100 | [diff] [blame] | 3961 | MAGICK_LIBS="$MAGICK_DEP_LIBS $MAGICK_EXTRA_DEP_LIBS" |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3962 | |
Cristy | c1bfec2 | 2020-10-04 15:40:32 +0000 | [diff] [blame] | 3963 | AC_SUBST([MAGICK_CFLAGS]) |
| 3964 | AC_SUBST([MAGICK_CXXFLAGS]) |
| 3965 | AC_SUBST([MAGICK_CPPFLAGS]) |
| 3966 | AC_SUBST([MAGICK_PCFLAGS]) |
| 3967 | AC_SUBST([MAGICK_LDFLAGS]) |
| 3968 | AC_SUBST([MAGICK_LIBS]) |
cristy | 154f9fa | 2012-12-05 19:30:42 +0000 | [diff] [blame] | 3969 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3970 | # Set configured scripts to executable. |
| 3971 | AC_CONFIG_COMMANDS([default],[],[]) |
cristy | 2bd4b6e | 2012-07-22 15:29:11 +0000 | [diff] [blame] | 3972 | AC_CONFIG_COMMANDS([magick.sh.in],[chmod +x magick.sh]) |
cristy | 4c08aed | 2011-07-01 19:47:50 +0000 | [diff] [blame] | 3973 | AC_CONFIG_COMMANDS([MagickCore-config.in],[chmod +x MagickCore/MagickCore-config]) |
cristy | 4c08aed | 2011-07-01 19:47:50 +0000 | [diff] [blame] | 3974 | AC_CONFIG_COMMANDS([MagickWand-config.in],[chmod +x MagickWand/MagickWand-config]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3975 | AC_CONFIG_COMMANDS([Magick++-config.in],[chmod +x Magick++/bin/Magick++-config]) |
| 3976 | AC_CONFIG_COMMANDS([PerlMagick/check.sh.in],[chmod +x PerlMagick/check.sh]) |
| 3977 | |
cristy | ad38abe | 2012-12-23 23:03:21 +0000 | [diff] [blame] | 3978 | AC_MSG_RESULT([-------------------------------------------------------------]) |
| 3979 | AC_MSG_RESULT([Update ImageMagick configuration]) |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3980 | |
| 3981 | rm -f magick-version |
| 3982 | |
cristy | 430a731 | 2010-01-21 20:44:04 +0000 | [diff] [blame] | 3983 | result_dejavu_font_dir='none' |
| 3984 | if test "${dejavu_font_dir}x" != 'x'; then |
| 3985 | result_dejavu_font_dir=$dejavu_font_dir |
| 3986 | fi |
| 3987 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3988 | result_ghostscript_font_dir='none' |
| 3989 | if test "${ghostscript_font_dir}x" != 'x'; then |
| 3990 | result_ghostscript_font_dir=$ghostscript_font_dir |
| 3991 | fi |
| 3992 | |
Cristy | c575106 | 2018-02-24 15:15:12 -0500 | [diff] [blame] | 3993 | result_urw_base35_font_dir='none' |
| 3994 | if test "${urw_base35_font_dir}x" != 'x'; then |
| 3995 | result_urw_base35_font_dir=$urw_base35_font_dir |
| 3996 | fi |
| 3997 | |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 3998 | result_windows_font_dir='none' |
| 3999 | if test "${windows_font_dir}x" != 'x'; then |
| 4000 | result_windows_font_dir=${windows_font_dir} |
| 4001 | fi |
| 4002 | |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4003 | # ============================================================================== |
| 4004 | # Generate build environment |
| 4005 | # ============================================================================== |
| 4006 | AC_CONFIG_FILES([\ |
| 4007 | common.shi \ |
| 4008 | config/configure.xml \ |
| 4009 | config/delegates.xml \ |
| 4010 | config/ImageMagick.rdf \ |
| 4011 | config/MagickCore.dox \ |
| 4012 | config/MagickWand.dox \ |
| 4013 | config/Magick++.dox \ |
| 4014 | config/type-apple.xml \ |
| 4015 | config/type-dejavu.xml \ |
| 4016 | config/type-ghostscript.xml \ |
Cristy | 9283d5b | 2017-09-27 17:40:11 -0400 | [diff] [blame] | 4017 | config/type-urw-base35.xml \ |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4018 | config/type-windows.xml \ |
| 4019 | config/type.xml \ |
| 4020 | ImageMagick.spec \ |
| 4021 | Magick++/bin/Magick++-config \ |
| 4022 | MagickCore/ImageMagick.pc \ |
| 4023 | Magick++/lib/Magick++.pc \ |
| 4024 | MagickCore/MagickCore-config \ |
| 4025 | MagickCore/MagickCore.pc \ |
| 4026 | MagickCore/version.h \ |
| 4027 | Makefile \ |
| 4028 | magick.sh \ |
| 4029 | PerlMagick/check.sh \ |
| 4030 | PerlMagick/default/Magick.pm \ |
| 4031 | PerlMagick/Makefile.PL \ |
| 4032 | PerlMagick/default/Makefile.PL \ |
| 4033 | PerlMagick/quantum/Makefile.PL \ |
| 4034 | PerlMagick/quantum/quantum.pm \ |
| 4035 | PerlMagick/quantum/quantum.xs \ |
| 4036 | PerlMagick/quantum/typemap \ |
| 4037 | utilities/animate.1 \ |
| 4038 | utilities/compare.1 \ |
| 4039 | utilities/composite.1 \ |
| 4040 | utilities/conjure.1 \ |
| 4041 | utilities/convert.1 \ |
| 4042 | utilities/display.1 \ |
| 4043 | utilities/identify.1 \ |
| 4044 | utilities/ImageMagick.1 \ |
| 4045 | utilities/import.1 \ |
Cristy | 540ea6e | 2016-04-01 12:06:50 -0400 | [diff] [blame] | 4046 | utilities/magick.1 \ |
| 4047 | utilities/magick-script.1 \ |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4048 | utilities/mogrify.1 \ |
| 4049 | utilities/montage.1 \ |
| 4050 | utilities/stream.1 \ |
| 4051 | MagickWand/MagickWand-config \ |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 4052 | MagickWand/MagickWand.pc]) |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4053 | AC_OUTPUT |
| 4054 | |
| 4055 | # ============================================================================== |
| 4056 | # ImageMagick Configuration |
| 4057 | # ============================================================================== |
| 4058 | AC_MSG_NOTICE([ |
| 4059 | ============================================================================== |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 4060 | ${PACKAGE_NAME} ${PACKAGE_VERSION} is configured as follows. Please verify that this |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4061 | configuration matches your expectations. |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 4062 | |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4063 | Host system type: $host |
| 4064 | Build system type: $build |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 4065 | |
Dirk Lemstra | db34c40 | 2020-09-19 13:29:11 +0200 | [diff] [blame] | 4066 | Option Value |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4067 | ------------------------------------------------------------------------------ |
| 4068 | Shared libraries --enable-shared=$enable_shared $libtool_build_shared_libs |
| 4069 | Static libraries --enable-static=$enable_static $libtool_build_static_libs |
| 4070 | Build utilities --with-utilities=$with_utilities $with_utilities |
| 4071 | Module support --with-modules=$build_modules $build_modules |
| 4072 | GNU ld --with-gnu-ld=$with_gnu_ld $lt_cv_prog_gnu_ld |
| 4073 | Quantum depth --with-quantum-depth=$with_quantum_depth $with_quantum_depth |
| 4074 | High Dynamic Range Imagery |
| 4075 | --enable-hdri=$enable_hdri $enable_hdri |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 4076 | |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4077 | Install documentation: $wantdocs |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 4078 | |
Cristy | 0b5b968 | 2019-09-13 14:54:28 -0400 | [diff] [blame] | 4079 | Memory allocation library: |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4080 | JEMalloc --with-jemalloc=$with_jemalloc $have_jemalloc |
| 4081 | TCMalloc --with-tcmalloc=$with_tcmalloc $have_tcmalloc |
| 4082 | UMem --with-umem=$with_umem $have_umem |
| 4083 | |
Cristy | 0b5b968 | 2019-09-13 14:54:28 -0400 | [diff] [blame] | 4084 | Delegate library configuration: |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4085 | BZLIB --with-bzlib=$with_bzlib $have_bzlib |
| 4086 | Autotrace --with-autotrace=$with_autotrace $have_autotrace |
| 4087 | DJVU --with-djvu=$with_djvu $have_djvu |
| 4088 | DPS --with-dps=$with_dps $have_dps |
| 4089 | FFTW --with-fftw=$with_fftw $have_fftw |
Cristy | 6d2f14b | 2016-04-26 01:41:09 -0400 | [diff] [blame] | 4090 | FLIF --with-flif=$with_flif $have_flif |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4091 | FlashPIX --with-fpx=$with_fpx $have_fpx |
cristy | bc8ef1c | 2015-06-06 14:32:21 +0000 | [diff] [blame] | 4092 | FontConfig --with-fontconfig=$with_fontconfig $have_fontconfig |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4093 | FreeType --with-freetype=$with_freetype $have_freetype |
| 4094 | Ghostscript lib --with-gslib=$with_gslib $have_gslib |
| 4095 | Graphviz --with-gvc=$with_gvc $have_gvc |
Dirk Lemstra | db34c40 | 2020-09-19 13:29:11 +0200 | [diff] [blame] | 4096 | HEIC --with-heic=$with_heic $have_heic |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4097 | JBIG --with-jbig=$with_jbig $have_jbig |
| 4098 | JPEG v1 --with-jpeg=$with_jpeg $have_jpeg |
Dirk Lemstra | db34c40 | 2020-09-19 13:29:11 +0200 | [diff] [blame] | 4099 | JPEG XL --with-jxl=$with_jxl $have_jxl |
cristy | d6ac47f | 2015-06-06 13:46:55 +0000 | [diff] [blame] | 4100 | LCMS --with-lcms=$with_lcms $have_lcms |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4101 | LQR --with-lqr=$with_lqr $have_lqr |
| 4102 | LTDL --with-ltdl=$with_ltdl $have_ltdl |
| 4103 | LZMA --with-lzma=$with_lzma $have_lzma |
| 4104 | Magick++ --with-magick-plus-plus=$with_magick_plus_plus $have_magick_plus_plus |
| 4105 | OpenEXR --with-openexr=$with_openexr $have_openexr |
Cristy | 428ba72 | 2015-11-08 15:49:24 -0500 | [diff] [blame] | 4106 | OpenJP2 --with-openjp2=$with_openjp2 $have_openjp2 |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4107 | PANGO --with-pango=$with_pango $have_pango |
| 4108 | PERL --with-perl=$with_perl $have_perl |
| 4109 | PNG --with-png=$with_png $have_png |
Cristy | 5572ef6 | 2016-02-06 16:10:00 -0500 | [diff] [blame] | 4110 | RAQM --with-raqm=$with_raqm $have_raqm |
Dirk Lemstra | db34c40 | 2020-09-19 13:29:11 +0200 | [diff] [blame] | 4111 | RAW --with-raw=$with_raw $have_raw |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4112 | RSVG --with-rsvg=$with_rsvg $have_rsvg |
| 4113 | TIFF --with-tiff=$with_tiff $have_tiff |
| 4114 | WEBP --with-webp=$with_webp $have_webp |
| 4115 | WMF --with-wmf=$with_wmf $have_wmf |
| 4116 | X11 --with-x=$with_x $have_x |
| 4117 | XML --with-xml=$with_xml $have_xml |
Elliott Hughes | 5d41fba | 2021-04-12 16:36:42 -0700 | [diff] [blame] | 4118 | ZIP --with-zip=$with_zip $have_zip |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4119 | ZLIB --with-zlib=$with_zlib $have_zlib |
Cristy | 08170e6 | 2018-10-14 10:33:46 -0400 | [diff] [blame] | 4120 | ZSTD --with-zstd=$with_zstd $have_zstd |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 4121 | |
Cristy | 0b5b968 | 2019-09-13 14:54:28 -0400 | [diff] [blame] | 4122 | Delegate program configuration: |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4123 | GhostPCL None $PCLDelegate ($PCLVersion) |
| 4124 | GhostXPS None $XPSDelegate ($XPSVersion) |
| 4125 | Ghostscript None $PSDelegate ($GSVersion) |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 4126 | |
Cristy | 0b5b968 | 2019-09-13 14:54:28 -0400 | [diff] [blame] | 4127 | Font configuration: |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4128 | Apple fonts --with-apple-font-dir=$with_apple_font_dir $result_apple_font_dir |
| 4129 | Dejavu fonts --with-dejavu-font-dir=$with_dejavu_font_dir $result_dejavu_font_dir |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4130 | Ghostscript fonts --with-gs-font-dir=$with_gs_font_dir $result_ghostscript_font_dir |
| 4131 | URW-base35 fonts --with-urw-base35-font-dir=$with_urw_base35_font_dir $result_urw_base35_font_dir |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4132 | Windows fonts --with-windows-font-dir=$with_windows_font_dir $result_windows_font_dir |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 4133 | |
Cristy | 0b5b968 | 2019-09-13 14:54:28 -0400 | [diff] [blame] | 4134 | X11 configuration: |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4135 | X_CFLAGS = $X_CFLAGS |
| 4136 | X_PRE_LIBS = $X_PRE_LIBS |
| 4137 | X_LIBS = $X_LIBS |
| 4138 | X_EXTRA_LIBS = $X_EXTRA_LIBS |
cristy | 1530816 | 2015-01-09 23:43:12 +0000 | [diff] [blame] | 4139 | |
Cristy | 90ceb26 | 2019-09-11 13:22:38 -0400 | [diff] [blame] | 4140 | Options used to compile and link: |
| 4141 | PREFIX = $PREFIX_DIR |
| 4142 | EXEC-PREFIX = $EXEC_PREFIX_DIR |
| 4143 | VERSION = $PACKAGE_VERSION |
| 4144 | CC = $CC |
| 4145 | CFLAGS = $CFLAGS |
| 4146 | CPPFLAGS = $CPPFLAGS |
| 4147 | PCFLAGS = $PCFLAGS |
| 4148 | DEFS = $DEFS |
| 4149 | LDFLAGS = $LDFLAGS |
| 4150 | LIBS = $MAGICK_DEP_LIBS |
| 4151 | CXX = $CXX |
| 4152 | CXXFLAGS = $CXXFLAGS |
| 4153 | FEATURES = $MAGICK_FEATURES |
| 4154 | DELEGATES = $MAGICK_DELEGATES |
cristy | 9af1cbf | 2014-12-28 22:03:09 +0000 | [diff] [blame] | 4155 | ============================================================================== |
cristy | 3ed852e | 2009-09-05 21:47:34 +0000 | [diff] [blame] | 4156 | ]) |