diff --git a/config/policy.xml b/config/policy.xml
index 2ed14de..808fcf6 100644
--- a/config/policy.xml
+++ b/config/policy.xml
@@ -57,26 +57,43 @@
-->
-
-
-
-
+
+
+
+
-
-
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/configure.ac b/configure.ac
index 7963576..570d04f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -208,9 +208,9 @@ AC_SUBST([SBIN_DIR])
eval "eval LIBEXEC_DIR=$libexecdir"
AC_SUBST([LIBEXEC_DIR])
eval "eval DATA_DIR=$datadir"
-AC_SUBST([DATA_DIR])
-eval "eval DOC_DIR=$datadir/doc"
-AC_SUBST([DOC_DIR])
+AC_SUBST(DATA_DIR)
+eval "eval DOC_DIR=$docdir"
+AC_SUBST(DOC_DIR)
eval "eval SYSCONF_DIR=$sysconfdir"
AC_SUBST([SYSCONF_DIR])
eval "eval SHAREDSTATE_DIR=$sharedstatedir"
@@ -805,7 +805,10 @@ MAGICK_ABI_SUFFIX="Q${QUANTUM_DEPTH}"
if test "$enable_hdri" = 'yes'; then
MAGICK_ABI_SUFFIX="Q${QUANTUM_DEPTH}${MAGICK_HDRI}"
fi
-AC_SUBST([MAGICK_ABI_SUFFIX])
+
+AC_SUBST(MAGICK_ABI_SUFFIX)
+MAGICK_ABI_SUFFIX_LC=`echo "$MAGICK_ABI_SUFFIX" | sed 's/./\L&/g'`
+AC_SUBST(MAGICK_ABI_SUFFIX_LC)
# Set pixel cache threshold
AC_ARG_WITH([cache],
@@ -3048,9 +3051,8 @@ AC_SUBST([FILTER_PATH])
#
# Path to ImageMagick documentation files
-DOCUMENTATION_RELATIVE_PATH="${PACKAGE_NAME}-${MAGICK_MAJOR_VERSION}"
-DOCUMENTATION_PATH="${DOC_DIR}/${DOCUMENTATION_RELATIVE_PATH}"
-DEFINE_DOCUMENTATION_PATH="${DOC_DIR}/${DOCUMENTATION_RELATIVE_PATH}/"
+DOCUMENTATION_PATH="${DOC_DIR}"
+DEFINE_DOCUMENTATION_PATH="${DOC_DIR}"
case "${build_os}" in
mingw* )
DEFINE_DOCUMENTATION_PATH=`$WinPathScript "$DEFINE_DOCUMENTATION_PATH" 1`
@@ -3059,6 +3061,18 @@ esac
AC_DEFINE_UNQUOTED([DOCUMENTATION_PATH],["$DEFINE_DOCUMENTATION_PATH"],[Directory where ImageMagick documents live.])
AC_SUBST([DOCUMENTATION_PATH])
+
+#
+# Add distribution specific string for documentation
+AC_ARG_WITH([extra-doc-dir],
+ [AC_HELP_STRING([--with-extra-doc-dir=""],
+ [extra documentation dir could be overriden by distribution, for instance by " (you may install the imagemagick-doc package)"])],
+ [extra_doc_dir="$withval"],
+ [extra_doc_dir=""])
+AC_DEFINE_UNQUOTED(EXTRA_DOC_DIR,"$EXTRA_DOC_DIR",[Extra documentation dir could be overriden by distribution, for instance by " (you may install th imagemagick-doc package)"])
+AC_SUBST(EXTRA_DOC_DIR,$extra_doc_dir)
+
+
#
# Enable/Disable documentation
AC_ARG_ENABLE([docs],
diff --git a/debian/patches/series b/debian/patches/series
deleted file mode 100644
index 45288fa..0000000
--- a/debian/patches/series
+++ /dev/null
@@ -1,24 +0,0 @@
-0001-Fix-br-tag.patch
-0002-Fix-api-Image-.html.patch
-0003-Fix-www-api-mophologie.html.patch
-0004-Fix-www-command-line-options.html.patch
-0005-Use-modern-idiom-for-autoconf.patch
-0006-Allow-distribution-to-custumize-the-html-pointer-to-.patch
-0007-Improve-policy-in-order-to-be-safer.patch
-0008-Fix-remaining-error-in-html-files.patch
-0009-Improve-man-page-to-use-version-information-and-quan.patch
-0010-Fix-changelog-tag-mismatch.patch
-0011-Fix-html-error-in-api-Image-.html.patch
-0012-Fix-www-escape.html.patch
-0013-Fix-www-magick-script.html.patch
-0014-Fix-www-support.html.patch
-0015-Fix-instead-of-lt-and-input-form.patch
-0016-Fix-another-errors-in-html-files.patch
-0017-Fix-index.html.patch
-0018-Fix-end-tags.patch
-0019-Fix-a-few-html-error.patch
-0020-Fix-a-typo-in-manpage.patch
-0021-Finalize-fixing-error-in-html.patch
-0022-FIx-error-in-new-upstream-html.patch
-0001-https-github.com-ImageMagick-ImageMagick6-issues-145.patch
-0023-disable-ghostscript-formats.patch
diff --git a/debian/source/format b/debian/source/format
index 163aaf8..89ae9db 100644
--- a/debian/source/format
+++ b/debian/source/format
@@ -1 +1 @@
-3.0 (quilt)
+3.0 (native)
diff --git a/index.html b/index.html
index ca08420..4c61371 100644
--- a/index.html
+++ b/index.html
@@ -67,8 +67,8 @@
-
@@ -136,7 +136,7 @@ Use ImageMagickDelineate image features
- Canny edge detection, Hough lines. |
+ Canny edge detection, Hough lines. |
Discrete Fourier transform |
@@ -204,7 +204,7 @@ Use ImageMagickNoise and color reduction
- Kuwahara Filter, mean-shift. |
+ Kuwahara Filter, mean-shift. |
Perceptual hash |
@@ -265,7 +265,7 @@ Use ImageMagick<\/script>')