61 lines
2.2 KiB
Bash
61 lines
2.2 KiB
Bash
# Maintainer: Martchus <martchus@gmx.net>
|
|
|
|
# All my PKGBUILDs are managed at https://github.com/Martchus/PKGBUILDs where
|
|
# you also find the URL of a binary repository.
|
|
|
|
pkgname=mingw-w64-freetype2-bootstrap
|
|
pkgver=2.6.4
|
|
pkgrel=1
|
|
pkgdesc="TrueType font rendering library (mingw-w64 bootstrap)"
|
|
arch=('any')
|
|
url="http://www.freetype.org/"
|
|
license=('GPL')
|
|
# adding harfbuzz for improved OpenType features auto-hinting
|
|
# introduces a cycle dep to harfbuzz depending on freetype wanted by upstream
|
|
depends=(mingw-w64-crt mingw-w64-zlib mingw-w64-bzip2)
|
|
makedepends=(mingw-w64-gcc mingw-w64-configure)
|
|
provides=(mingw-w64-freetype ${pkgname%-bootstrap})
|
|
conflicts=(mingw-w64-freetype ${pkgname%-bootstrap})
|
|
source=(http://download.savannah.gnu.org/releases/freetype/freetype-${pkgver}.tar.bz2{,.sig}
|
|
0001-Enable-table-validation-modules.patch
|
|
0002-Enable-subpixel-rendering.patch
|
|
0003-Make-subpixel-hinting-mode-configurable.patch)
|
|
options=(!strip !buildflags !libtool staticlibs)
|
|
sha1sums=('5eaa8c949b4841eeabba44d2c582ff6859e5c4b9'
|
|
'SKIP'
|
|
'045b1b6a56151ab46a8300e6fd09f24294258e97'
|
|
'afd6f9504516fa02e57890dde820f488e0df36bb'
|
|
'2a1d6e734001e196c7a7790c78165d9b9fe49f7f')
|
|
validpgpkeys=('58E0C111E39F5408C5D3EC76C1A60EACE707FDA5')
|
|
|
|
_architectures="i686-w64-mingw32 x86_64-w64-mingw32"
|
|
|
|
prepare() {
|
|
cd "${srcdir}/freetype-${pkgver}"
|
|
patch -Np1 -i "${srcdir}/0001-Enable-table-validation-modules.patch"
|
|
patch -Np1 -i "${srcdir}/0002-Enable-subpixel-rendering.patch"
|
|
|
|
# Provide a way to set the default subpixel hinting mode
|
|
# at runtime, without depending on the application to do so.
|
|
patch -Np1 -i "${srcdir}/0003-Make-subpixel-hinting-mode-configurable.patch"
|
|
}
|
|
|
|
build() {
|
|
for _arch in ${_architectures}; do
|
|
mkdir -p "${srcdir}/freetype-${pkgver}/build-${_arch}"
|
|
cd "${srcdir}/freetype-${pkgver}/build-${_arch}"
|
|
${_arch}-configure --with-zlib=/usr/${_arch} --without-png
|
|
make
|
|
done
|
|
}
|
|
|
|
package() {
|
|
for _arch in ${_architectures}; do
|
|
cd "${srcdir}/freetype-${pkgver}/build-${_arch}"
|
|
make DESTDIR="${pkgdir}" install
|
|
rm -rf "${pkgdir}/usr/${_arch}/share/"
|
|
${_arch}-strip -g "${pkgdir}/usr/${_arch}/lib/"*.a
|
|
${_arch}-strip --strip-unneeded "$pkgdir"/usr/${_arch}/bin/*.dll
|
|
done
|
|
}
|