# $Id$ PNAME="gd" PVER="2.2.5" PBUILD="r1" PCAT="media-libs" DESCRIPTION="GD is an open source code library for the dynamic creation of images by programmers." HOMEPAGE="http://www.libgd.org/" DEPEND=">= virtual/libjpeg >= media-libs/libpng-1.5 >= media-libs/freetype-2.6 >= media-libs/fontconfig-2.8 >= x11-libs/libX11-1.6 >= x11-libs/libXau-1 >= x11-libs/libxcb-1.12 >= x11-libs/libXdmcp-1 >= x11-libs/libXpm-3 >= sys-libs/zlib-1.2.5" if mqueryfeature "check" then # make check needs fonts installed SDEPEND+=" >= media-fonts/font-misc-misc-1" fi SRCFILE="lib${PNAME}-${PVER}.tar.xz" SRCDIR="${BUILDDIR}/lib${PNAME}-${PVER}" sminclude mbuild SRC_URI=( https://github.com/libgd/libgd/releases/download/${PNAME}-${PVER}/${SRCFILE} mirror://${PNAME}/${SRCFILE} ) UP2DATE="updatecmd https://github.com/libgd/libgd/releases | highesttarball xz" src_check() { cd ${SRCDIR} # not dying here, one check fails [[ ${ARCH} = i?86 ]] || FREETYPE_PROPERTIES='truetype:interpreter-version=35' \ mmake -j1 -k check || if [[ $(grep "fontconfig/basic.*Could not set character size" tests/test-suite.log) ]]; then true; else die; fi } src_compile() { cd ${SRCDIR} mconfigure --disable-rpath --with-jpeg --with-png --with-xpm --with-freetype || die mmake || die }