diff options
author | Chris Severance | 2015-08-13 04:43:45 -0400 |
---|---|---|
committer | Chris Severance | 2015-08-13 04:43:45 -0400 |
commit | a392ac8d453435b48d6ede7c0e5726d9a2a0773f (patch) | |
tree | 052e8d7e16391889b19fc493c1b1507e5573b25b | |
download | aur-a392ac8d453435b48d6ede7c0e5726d9a2a0773f.tar.gz |
Upstream switches from svn to git
-rw-r--r-- | .SRCINFO | 75 | ||||
-rw-r--r-- | PKGBUILD | 142 | ||||
-rw-r--r-- | libpng_mmx_patch_x86_64.patch | 11 |
3 files changed, 228 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..644f4d9263f4 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,75 @@ +pkgbase = imagemagick-git + pkgdesc = An image viewing/manipulation program + pkgver = 7.0.0.0.r10071.g3de10e8 + pkgrel = 1 + url = https://www.imagemagick.org/ + arch = i686 + arch = x86_64 + license = custom + makedepends = libltdl + makedepends = lcms2 + makedepends = libxt + makedepends = fontconfig + makedepends = libxext + makedepends = ghostscript + makedepends = openexr + makedepends = libwmf + makedepends = librsvg + makedepends = libxml2 + makedepends = liblqr + makedepends = openjpeg2 + makedepends = opencl-headers + makedepends = libcl + makedepends = libwebp + makedepends = git + source = imagemagick-git::git+http://git.imagemagick.org/repos/ImageMagick.git + source = libpng_mmx_patch_x86_64.patch + source = perlmagick.rpath.patch::https://projects.archlinux.org/togit/packages.git/plain/trunk/perlmagick.rpath.patch?h=packages/imagemagick + sha256sums = SKIP + sha256sums = 4f3ab23349fd3958a88eb09a7107e08c2c6f3953287907103ec48cfa83575e87 + sha256sums = 17218bbecc17f3c7a86935a09d5a47e46113a1fc28f7d91c2fe495019cc36088 + +pkgname = imagemagick-git + pkgdesc = An image viewing/manipulation program + depends = libltdl + depends = lcms2 + depends = libxt + depends = fontconfig + depends = libxext + depends = liblqr + depends = libcl + depends = perl>= + depends = perl< + optdepends = imagemagick-doc: for additional information + optdepends = ghostscript: for Ghostscript support + optdepends = openexr: for OpenEXR support + optdepends = openjpeg2: for JP2 support + optdepends = libwmf: for WMF support + optdepends = librsvg: for SVG support + optdepends = libxml2: for XML support + optdepends = libpng: for PNG support + optdepends = libwebp: for WEBP support + provides = imagemagick=7.0.0.0 + conflicts = imagemagick + options = !docs + options = libtool + options = !emptydirs + backup = etc/ImageMagick-7/coder + backup = etc/ImageMagick-7/colors + backup = etc/ImageMagick-7/delegates + backup = etc/ImageMagick-7/log + backup = etc/ImageMagick-7/magic + backup = etc/ImageMagick-7/mime + backup = etc/ImageMagick-7/policy + backup = etc/ImageMagick-7/thresholds + backup = etc/ImageMagick-7/type + backup = etc/ImageMagick-7/type-dejavu + backup = etc/ImageMagick-7/type-ghostscript + backup = etc/ImageMagick-7/type-windows + +pkgname = imagemagick-git-doc + pkgdesc = The ImageMagick documentation (utilities manuals and libraries API) + depends = imagemagick + provides = imagemagick-doc + conflicts = imagemagick-doc + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..3d5bed28a426 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,142 @@ +# Maintainer: Chris Severance aur.severach aATt spamgourmet dott com +# Contributor: Limao Luo <luolimao+AUR@gmail.com> +# Contributor: Stefan Husmann <stefan-husmann@t-online.de> +# From core package +# Contributor: Eric BĂ©langer <eric@archlinux.org> + +# TODO: How to get rid of the relinking during make install + +set -u +_pkgname='imagemagick' +pkgbase="${_pkgname}-git" +_srcdir="${pkgbase}" +pkgname=("${pkgbase}" "${pkgbase}-doc") +pkgver=7.0.0.0.r10071.g3de10e8 +pkgrel=1 +pkgdesc='An image viewing/manipulation program' +arch=('i686' 'x86_64') +url='https://www.imagemagick.org/' +license=('custom') +makedepends=('libltdl' 'lcms2' 'libxt' 'fontconfig' 'libxext' 'ghostscript' + 'openexr' 'libwmf' 'librsvg' 'libxml2' 'liblqr' 'openjpeg2' + 'opencl-headers' 'libcl' 'libwebp' 'git') +#source=("ftp://ftp.sunet.se/pub/multimedia/graphics/ImageMagick/ImageMagick-${pkgver%.*}-${pkgver##*.}".tar.xz{,.asc}) +#source=("${pkgname}::svn+https://subversion.imagemagick.org/subversion/ImageMagick/trunk/") # svn was shut down August 10, 2015 +_archlink="@@@::https://projects.archlinux.org/togit/packages.git/plain/trunk/@@@?h=packages/${_pkgname}" +source=("${pkgname}::git+http://git.imagemagick.org/repos/ImageMagick.git" + 'libpng_mmx_patch_x86_64.patch' + "${_archlink//@@@/perlmagick.rpath.patch}") +sha256sums=('SKIP' + '4f3ab23349fd3958a88eb09a7107e08c2c6f3953287907103ec48cfa83575e87' + '17218bbecc17f3c7a86935a09d5a47e46113a1fc28f7d91c2fe495019cc36088') +#validpgpkeys=('D8272EF51DA223E4D05B466989AB63D48277377A') + +pkgver() { + set -u + cd "${_srcdir}/" + #echo $(grep -o -m1 '[0-9.-]\+' "${pkgname}/ChangeLog" | sed -n '2p' | tr '-' '.').$(svnversion "${SRCDEST}/${pkgname}/" | tr -d 'a-zA-z') + local _version="$(grep -o -m1 '[0-9]\+\.[0-9]\+\.[0-9\.-]\+' 'ChangeLog')" + #_version="${_version//-/.}.$(svnversion | tr -d 'a-zA-z')" + printf '%s.r%s.g%s' "${_version//-/.}" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" + set +u +} + +prepare() { + set -u + cd "${_srcdir}/" + #[ "${CARCH}" = 'x86_64' ] && patch -p1 -i "${srcdir}/libpng_mmx_patch_x86_64.patch" + sed -i -e '/AC_PATH_XTRA/d' 'configure.ac' + autoreconf --force --install + patch -p0 -i "${srcdir}/perlmagick.rpath.patch" + local _EXTRAOPTS='' + case "${CARCH}" in + 'i686') _EXTRAOPTS='--with-gcc-arch=i686';; + 'x86_64') _EXTRAOPTS='--with-gcc-arch=x86-64';; + esac + #./configure --prefix='/usr' --sysconfdir='/etc' --with-modules --disable-static --enable-openmp --with-x --with-wmf --with-openexr --with-xml --with-gslib --with-gs-font-dir='/usr/share/fonts/Type1' --with-perl --with-perl-options='INSTALLDIRS=vendor' --without-gvc --with-djvu --without-autotrace --with-jp2 --with-jbig --without-fpx --without-dps --without-fftw + ./configure --prefix='/usr' --sysconfdir='/etc' --with-modules \ + --enable-hdri --with-wmf --with-openexr --with-xml --with-lcms2 \ + --with-webp --with-gslib --with-gs-font-dir='/usr/share/fonts/Type1' \ + --with-perl --with-perl-options='INSTALLDIRS=vendor' --with-lqr --with-rsvg \ + --enable-opencl --with-openjp2 --without-gvc --without-djvu --without-autotrace \ + --without-jbig --without-fpx --without-dps --without-fftw ${_EXTRAOPTS} + sed -i -e 's: -mtune=x86-64 : :g' 'Makefile' # This works even though the screen still shows the flags + set +u +} + +build() { + set -u + cd "${_srcdir}/" + make -s -j $(nproc) + set +u +} + +check() { + cd "${_srcdir}/" + #make -s -j $(nproc) check +} + +package_imagemagick-git() { + set -u + pkgdesc='An image viewing/manipulation program' + depends=('libltdl' 'lcms2' 'libxt' 'fontconfig' 'libxext' 'liblqr' 'libcl') + optdepends=('imagemagick-doc: for additional information' + 'ghostscript: for Ghostscript support' + 'openexr: for OpenEXR support' + 'openjpeg2: for JP2 support' + 'libwmf: for WMF support' + 'librsvg: for SVG support' + 'libxml2: for XML support' + 'libpng: for PNG support' + 'libwebp: for WEBP support') + backup=("etc/ImageMagick-${pkgver%%.*}"/{coder,colors,delegates,log,magic,mime,policy,thresholds,type{,-dejavu,-ghostscript,-windows}}) + #options=('libtool' '!emptydirs' '!makeflags') + options=('!docs' 'libtool' '!emptydirs') + provides=("${_pkgname}=${pkgver%.r*}") + conflicts=("${_pkgname}") + + cd "${_srcdir}/" + make -s -j $(nproc) DESTDIR="${pkgdir}" install + #install -d "${pkgdir}/usr/share/licenses/${_pkgname}/" + install -Dpm644 'LICENSE' 'NOTICE' -t "${pkgdir}/usr/share/licenses/${_pkgname}/" + #Cleaning. Why are we deleting a file that says DO NOT DELETE? + #rm -f "${pkgdir}/usr/lib"/*.la + #rm -rf "${pkgdir}/usr/share/doc/" # same as option !docs + + # This looks dangerous. Upgrading perl will remove ImageMagick + if ! :; then + # template start; name=perl-binary-module-dependency; version=1; + if [ ! -z "$(find "${pkgdir}/usr/lib/perl5/" -name '*.so')" ]; then + local _perlver_min="$(perl -e '$v = $^V->{version}; print $v->[0].".".($v->[1]);')" + local _perlver_max="$(perl -e '$v = $^V->{version}; print $v->[0].".".($v->[1]+1);')" + depends+=("perl>=${_perlver_min}" "perl<${_perlver_max}") + fi + # template end; + fi + set +u +} + +package_imagemagick-git-doc() { + set -u + pkgdesc='The ImageMagick documentation (utilities manuals and libraries API)' + provides=("${_pkgname}-doc") + conflicts=("${_pkgname}-doc") + depends=("${_pkgname}") + + cd "${_srcdir}/" + make -s DESTDIR="${pkgdir}" install-data-html + install -Dpm644 'LICENSE' 'NOTICE' -t "${pkgdir}/usr/share/licenses/${_pkgname}-doc/" + set +u + # Ensure there are no forbidden paths. Place at the end of package() and comment out as you find or need exceptions. (git-aurcheck) + ! test -d "${pkgdir}/bin" || { echo "Line ${LINENO} Forbidden: /bin"; false; } + ! test -d "${pkgdir}/sbin" || { echo "Line ${LINENO} Forbidden: /sbin"; false; } + ! test -d "${pkgdir}/lib" || { echo "Line ${LINENO} Forbidden: /lib"; false; } + ! test -d "${pkgdir}/share" || { echo "Line ${LINENO} Forbidden: /share"; false; } + ! test -d "${pkgdir}/usr/sbin" || { echo "Line ${LINENO} Forbidden: /usr/sbin"; false; } + ! test -d "${pkgdir}/usr/local" || { echo "Line ${LINENO} Forbidden: /usr/local"; false; } + #! grep -lr "/sbin" "${pkgdir}" || { echo "Line ${LINENO} Forbidden: /sbin"; false; } + ! grep -lr "/usr/tmp" "${pkgdir}" || { echo "Line ${LINENO} Forbidden: /usr/tmp"; false; } + #! grep -lr "/usr/local" "${pkgdir}" || { echo "Line ${LINENO} Forbidden: /usr/local"; false; } + ! pcre2grep -Ilr "(?<!/usr)/bin" "${pkgdir}" || { echo "Line ${LINENO} Forbidden: /bin"; false; } +} +set +u diff --git a/libpng_mmx_patch_x86_64.patch b/libpng_mmx_patch_x86_64.patch new file mode 100644 index 000000000000..addfd5637e8f --- /dev/null +++ b/libpng_mmx_patch_x86_64.patch @@ -0,0 +1,11 @@ +--- a/coders/png.c 2012-12-10 18:19:07.149721232 -0500 ++++ b/coders/png.c 2012-12-10 18:24:17.442782178 -0500 +@@ -631,6 +631,8 @@ + #define PNG_UINT_31_MAX (png_uint_32) 0x7fffffffL + #endif + ++#undef PNG_ASSEMBLER_CODE_SUPPORTED ++ + /* + Constant strings for known chunk types. If you need to add a chunk, + add a string holding the name here. To make the code more |