ImageMagick.spec \
Magick++/bin/Magick++-config \
MagickCore/ImageMagick.pc \
- Magick++/lib/ImageMagick++.pc \
Magick++/lib/Magick++.pc \
MagickCore/MagickCore-config \
MagickCore/MagickCore.pc \
MagickCore/version.h \
Makefile \
magick.sh \
- PerlMagick/Magick.pm \
- PerlMagick/Makefile.PL \
PerlMagick/check.sh \
+ PerlMagick/default/Magick.pm \
+ PerlMagick/Makefile.PL \
+ PerlMagick/default/Makefile.PL \
+ PerlMagick/quantum/Makefile.PL \
+ PerlMagick/quantum/quantum.pm \
+ PerlMagick/quantum/quantum.xs \
+ PerlMagick/quantum/typemap \
utilities/animate.1 \
utilities/compare.1 \
utilities/composite.1 \
AC_SUBST(MAGICK_TARGET_OS)
AC_DEFINE_UNQUOTED(MAGICK_TARGET_OS,$MAGICK_TARGET_OS,[Target Host OS])
+
+# Substitute versioning
+AC_SUBST([MAGICK_MAJOR_VERSION],[magick_major_version])
+AC_SUBST([MAGICK_MINOR_VERSION],[magick_minor_version])
+AC_SUBST([MAGICK_MICRO_VERSION],[magick_micro_version])
+AC_SUBST([MAGICK_PATCHLEVEL_VERSION],[magick_patchlevel_version])
+AC_SUBST([MAGICK_VERSION],[magick_version])
+AC_SUBST([MAGICK_SVN_REVISION],[magick_svn_revision])
+
# Substitute library versioning
AC_SUBST(MAGICK_LIBRARY_CURRENT)dnl
AC_SUBST(MAGICK_LIBRARY_REVISION)dnl
[`expr $MAGICK_LIBRARY_CURRENT - $MAGICK_LIBRARY_AGE`])
AC_SUBST([MAGICK_LIBRARY_VERSION_INFO],
[$MAGICK_LIBRARY_CURRENT:$MAGICK_LIBRARY_REVISION:$MAGICK_LIBRARY_AGE])
-AC_SUBST([MAGICK_SVN_REVISION],[magick_svn_revision])
AC_SUBST(PACKAGE_NAME)dnl
AC_SUBST(PACKAGE_VERSION)dnl
AC_PROG_INSTALL
AC_PROG_MAKE_SET
AC_PROG_LN_S
+AC_PROG_SED
AC_PROG_AWK
AM_WITH_DMALLOC
AX_C___ATTRIBUTE__
AX_GCC_ARCHFLAG([no])
PKG_PROG_PKG_CONFIG
-# Check for linker script support
+# Check for linker script support
gl_LD_VERSION_SCRIPT
#
dnl Platform-specific stuff
case "$host" in
-*darwin* | *-macos10*)
- dnl OS X universal binary support, requires --disable-dependency-tracking
- AC_ARG_ENABLE([osx-universal-binary],
+ *darwin* | *-macos10*)
+ dnl Disable FORTIFY_SOURCE to fix a bug in LVVM / OpenMP support
+ CFLAGS="${CFLAGS} -D_FORTIFY_SOURCE=0"
+ dnl OS X universal binary support, requires --disable-dependency-tracking
+ AC_ARG_ENABLE([osx-universal-binary],
AC_HELP_STRING([--enable-osx-universal-binary],
[build universal binary on OS X [[default=no]]]),
[build_osxuniversal="${enableval}"], [build_osxuniversal=no])
- if test "${build_osxuniversal}" != no ; then
- if test "$enable_dependency_tracking" != no ; then
- AC_MSG_ERROR([--enable-osx-universal-binary requires --disable-dependency-tracking.
+ if test "${build_osxuniversal}" != no ; then
+ if test "$enable_dependency_tracking" != no ; then
+ AC_MSG_ERROR([--enable-osx-universal-binary requires --disable-dependency-tracking.
Please re-run configure with these options:
--disable-dependency-tracking --enable-osx-universal-binary
])
- fi
- CFLAGS="$CFLAGS -isysroot /Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386"
- CXXFLAGS="$CXXFLAGS -isysroot /Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386"
- LDFLAGS="$LDFLAGS -Wl,-syslibroot,/Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386"
+ fi
+ CFLAGS="$CFLAGS -isysroot /Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386"
+ CXXFLAGS="$CXXFLAGS -isysroot /Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386"
+ LDFLAGS="$LDFLAGS -Wl,-syslibroot,/Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386"
fi
;;
esac
eval "eval SHAREARCH_DIR=$sharearch_dir"
AC_SUBST(SHAREARCH_DIR)
+# Path to the pkgconfig folder
+AC_ARG_WITH([pkgconfigdir], AS_HELP_STRING([--with-pkgconfigdir=DIR],
+ [Path to the pkgconfig directory @<:@LIBDIR/pkgconfig@:>@]),
+ [pkgconfigdir="$withval"], [pkgconfigdir='${libdir}/pkgconfig'])
+AC_SUBST([pkgconfigdir])
+
#
# Enable support for threads
AC_ARG_WITH([threads],
QUANTUM_DEPTH="$with_quantum_depth"
AC_DEFINE_UNQUOTED(QUANTUM_DEPTH_OBSOLETE_IN_H,$QUANTUM_DEPTH,[Number of bits in a pixel Quantum (8/16/32/64)])
AC_SUBST(QUANTUM_DEPTH)dnl
-MAGICKCORE_PCFLAGS="$MAGICKCORE_PCFLAGS -DMAGICKCORE_QUANTUM_DEPTH=$QUANTUM_DEPTH"
+MAGICK_PCFLAGS="$MAGICK_PCFLAGS -DMAGICKCORE_QUANTUM_DEPTH=$QUANTUM_DEPTH"
CFLAGS="$CFLAGS -DMAGICKCORE_QUANTUM_DEPTH=$QUANTUM_DEPTH"
CPPFLAGS="$CPPFLAGS -DMAGICKCORE_QUANTUM_DEPTH=$QUANTUM_DEPTH"
AC_HEADER_DIRENT
# Check additional headers
-AC_CHECK_HEADERS(arm/limits.h complex.h errno.h fcntl.h limits.h linux/unistd.h locale.h machine/param.h mach-o/dyld.h netdb.h OS.h process.h sun_prefetch.h stdarg.h sys/ipc.h sys/mman.h sys/resource.h sys/socket.h sys/syslimits.h sys/time.h sys/timeb.h sys/times.h sys/wait.h wchar.h xlocale.h)
+AC_CHECK_HEADERS(arm/limits.h arpa/inet.h complex.h errno.h fcntl.h limits.h linux/unistd.h locale.h machine/param.h mach-o/dyld.h netinet/in.h OS.h process.h sun_prefetch.h stdarg.h sys/ipc.h sys/mman.h sys/resource.h sys/socket.h sys/syslimits.h sys/time.h sys/timeb.h sys/times.h sys/wait.h wchar.h xlocale.h)
########
#
# Assume that delegate headers reside under same directory as ImageMagick
# installation prefix.
-MAGICK_CPPFLAGS="-I$INCLUDE_DIR/ImageMagick $MAGICK_CPPFLAGS"
+MAGICK_CPPFLAGS="-I$INCLUDE_DIR/${PACKAGE_NAME}-$MAGICK_MAJOR_VERSION $MAGICK_CPPFLAGS"
#
# Find the X11 RGB database
dnl ===========================================================================
#
-# Check for freetype delegate library.
+# Check for the Freetype delegate library.
#
AC_ARG_WITH([freetype],
[AC_HELP_STRING([--without-freetype],
[with_freetype=$withval],
[with_freetype='yes'])
-
if test "$with_freetype" != 'yes'; then
DISTCHECK_CONFIG_FLAGS="${DISTCHECK_CONFIG_FLAGS} --with-freetype=$with_freetype "
fi
have_freetype='no'
-FREETYPE_LIBS=''
-if test "$with_freetype" != 'no'; then
+FREETYPE_CFLAGS=""
+FREETYPE_LIBS=""
+FREETYPE_PKG=""
+if test "x$with_freetype" = "xyes"; then
AC_MSG_RESULT([-------------------------------------------------------------])
- AC_MSG_CHECKING(for FreeType 2.0 )
- AC_MSG_RESULT()
- failed=0
- passed=0
- PERSIST_LDFLAGS="$LDFLAGS"
- PERSIST_CPPFLAGS="$CPPFLAGS"
- freetype_config=''
- # Allow the user to specify the location of freetype.
- if test "$with_freetype" != 'yes'; then
- if test -x "${with_freetype}/bin/freetype-config"; then
- freetype_config="${with_freetype}/bin/freetype-config"
- elif test -x "${with_freetype}"; then
- freetype_config=${with_freetype}
- fi
- fi
- if test -z "$freetype_config"; then
- AC_PATH_PROG(freetype_config,freetype-config,)dnl
- fi
- if test -n "$freetype_config"; then
- freetype_prefix=`${freetype_config} --prefix`
- freetype_exec_prefix=`${freetype_config} --exec-prefix`
- LDFLAGS="$LDFLAGS -L${freetype_exec_prefix}/lib"
- CPPFLAGS="$CPPFLAGS -I${freetype_prefix}/include/freetype2"
- fi
-
-dnl First see if there is a library
- if test "$FREETYPE_LIBS" = ''; then
- AC_CHECK_LIB(freetype,FT_Init_FreeType,FREETYPE_LIBS='-lfreetype',,)
- if test "$FREETYPE_LIBS" != ''; then
- passed=`expr $passed + 1`
- else
- failed=`expr $failed + 1`
- LDFLAGS="$PERSIST_LDFLAGS"
- fi
- fi
-
-dnl Now test for the headers
- AC_CHECK_HEADER([ft2build.h],[FT2BUILD_H='#include <ft2build.h>'],[ft2build=''],[])
- AC_CHECK_HEADER(freetype/freetype.h,[have_freetype_h='yes'],[have_freetype_h='no'],[$FT2BUILD_H])
- if test "$have_freetype_h" = 'yes'; then
- passed=`expr $passed + 1`
- else
- failed=`expr $failed + 1`
- CPPFLAGS="$PERSIST_CPPFLAGS"
- fi
+ PKG_CHECK_MODULES(FREETYPE,[freetype2], have_freetype=yes, have_freetype=no)
+ AC_MSG_RESULT([])
+fi
- AC_MSG_CHECKING(if FreeType package is complete)
- if test $passed -gt 0; then
- if test $failed -gt 0; then
- FREETYPE_LIBS=''
- AC_MSG_RESULT(no -- some components failed test)
- have_freetype='no (failed tests)'
- else
- LIBS="$FREETYPE_LIBS $LIBS"
- AC_DEFINE(FREETYPE_DELEGATE,1,Define if you have FreeType (TrueType font) library)
- if test "$ac_cv_header_ft2build_h" = 'yes'; then
- AC_DEFINE([HAVE_FT2BUILD_H],[1],[Define to 1 if you have the <ft2build.h> header file.])
- fi
- AC_MSG_RESULT(yes)
- have_freetype='yes'
- fi
- else
- AC_MSG_RESULT(no)
- fi
+if test "$have_freetype" = 'yes'; then
+ AC_DEFINE(FREETYPE_DELEGATE,1,Define if you have FREETYPE library)
+ CFLAGS="$FREETYPE_CFLAGS $CFLAGS"
fi
+
AM_CONDITIONAL(FREETYPE_DELEGATE, test "$have_freetype" = 'yes')
+AC_SUBST(FREETYPE_CFLAGS)
AC_SUBST(FREETYPE_LIBS)
dnl ===========================================================================
# or -framework Ghostscript
AC_ARG_WITH([gslib],
- [AC_HELP_STRING([--without-gslib],
+ [AC_HELP_STRING([--with-gslib],
[enable Ghostscript library support])],
[with_gslib=$withval],
[with_gslib='no'])
#
AC_ARG_WITH(gvc,
[AC_HELP_STRING([--with-gvc],
- [disable GVC support])],
+ [enable GVC support])],
[with_gvc=$withval],
[with_gvc='no'])
failed=0
passed=0
AC_CHECK_HEADER(webp/decode.h,passed=`expr $passed + 1`,failed=`expr $failed + 1`,)
- AC_CHECK_LIB(webp,WebPDecodeRGB,passed=`expr $passed + 1`,failed=`expr $failed + 1`,)
+ AC_CHECK_LIB(webp,WebPPictureInit,passed=`expr $passed + 1`,failed=`expr $failed + 1`,)
AC_MSG_CHECKING([if WEBP package is complete])
if test $passed -gt 0; then
if test $failed -gt 0; then
#
# Path to ImageMagick header files
-INCLUDE_RELATIVE_PATH="ImageMagick"
+INCLUDE_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}"
INCLUDE_PATH="${INCLUDE_DIR}/${INCLUDE_RELATIVE_PATH}"
DEFINE_INCLUDE_PATH="${INCLUDE_DIR}/${INCLUDE_RELATIVE_PATH}/"
case "${build_os}" in
AC_DEFINE_UNQUOTED(LIBRARY_PATH,"$DEFINE_LIBRARY_PATH",[Directory where architecture-dependent files live.])
AC_SUBST(LIBRARY_PATH)
+#
+# path to local binaries
+if test "x$LIB_BIN_BASEDIRNAME" = "x"; then
+ LIB_BIN_BASEDIRNAME="bin"
+fi
+AC_DEFINE_UNQUOTED(LIB_BIN_BASEDIRNAME,"$LIB_BIN_BASEDIRNAME",[Binaries in libraries path base name (will be during install linked to bin)])
+AC_SUBST(LIB_BIN_BASEDIRNAME)
+
+if test "x$LIB_BIN_DIR" = "x"; then
+ LIB_BIN_DIR=${LIB_BIN_BASEDIRNAME}-${MAGICK_ABI_SUFFIX}
+fi
+AC_SUBST(LIB_BIN_DIR)
+
+LIB_BIN_DIR_RELATIVE_PATH=$LIB_BIN_DIR
+AC_SUBST(LIB_BIN_DIR_RELATIVE_PATH)
+LIB_BIN_DIR_PATH="${LIBRARY_PATH}/${LIB_BIN_DIR_RELATIVE_PATH}"
+AC_SUBST(LIB_BIN_DIR_PATH)
+
#
# path to modules lib
if test "x$MODULES_BASEDIRNAME" = "x"; then
#
# Path to ImageMagick documentation files
-DOCUMENTATION_RELATIVE_PATH="${PACKAGE_NAME}-${PACKAGE_VERSION}"
+DOCUMENTATION_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}"
DOCUMENTATION_PATH="${DOC_DIR}/${DOCUMENTATION_RELATIVE_PATH}"
DEFINE_DOCUMENTATION_PATH="${DOC_DIR}/${DOCUMENTATION_RELATIVE_PATH}/"
case "${build_os}" in
AC_SUBST(DOCUMENTATION_PATH)
# Subdirectory to place architecture-dependent configuration files
-CONFIGURE_RELATIVE_PATH="${PACKAGE_NAME}"
+CONFIGURE_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}"
AC_DEFINE_UNQUOTED(CONFIGURE_RELATIVE_PATH,"$CONFIGURE_RELATIVE_PATH",[Subdirectory of lib where architecture-dependent configuration files live.])
CONFIGURE_PATH="${SYSCONF_DIR}/${CONFIGURE_RELATIVE_PATH}/"
DEFINE_CONFIGURE_PATH="${SYSCONF_DIR}/${CONFIGURE_RELATIVE_PATH}/"
AC_SUBST(CONFIGURE_PATH)
# Subdirectory to place architecture-independent configuration files
-SHARE_RELATIVE_PATH="${LIBRARY_RELATIVE_PATH}"
+SHARE_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}"
AC_DEFINE_UNQUOTED(SHARE_RELATIVE_PATH,"$SHARE_RELATIVE_PATH",[Subdirectory of lib where architecture-independent configuration files live.])
SHARE_PATH="${DATA_DIR}/${SHARE_RELATIVE_PATH}"
DEFINE_SHARE_PATH="${DATA_DIR}/${SHARE_RELATIVE_PATH}/"