PKGBUILDs/libfilezilla/mingw-w64/PKGBUILD

64 lines
2.4 KiB
Bash
Raw Normal View History

2016-06-01 00:22:52 +02:00
# 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.
_name=libfilezilla
pkgname=mingw-w64-libfilezilla
2019-07-23 17:42:42 +02:00
pkgver=0.17.1
2016-06-01 00:22:52 +02:00
pkgrel=1
pkgdesc='Small and modern C++ library, offering some basic functionality to build high-performing, platform-independent programs (mingw-w64)'
2016-06-01 00:22:52 +02:00
arch=('any')
url='https://filezilla-project.org/'
2016-06-01 00:22:52 +02:00
license=('GPL')
2019-07-23 17:42:42 +02:00
depends=('mingw-w64-crt' 'mingw-w64-nettle' 'mingw-w64-gnutls')
2016-06-01 00:22:52 +02:00
makedepends=('mingw-w64-configure')
options=(staticlibs !strip !buildflags !makeflags)
2016-06-01 00:22:52 +02:00
install=
2019-07-23 17:42:42 +02:00
source=("https://download.filezilla-project.org/libfilezilla/libfilezilla-$pkgver.tar.bz2"
'remove-version.patch::https://svn.filezilla-project.org/filezilla/libfilezilla/trunk/lib/Makefile.am?view=patch&r1=9357&r2=9356&pathrev=9357'
'remove-version-2.patch::https://svn.filezilla-project.org/filezilla/libfilezilla/trunk/lib/Makefile.am?view=patch&r1=9358&r2=9357&pathrev=9358'
'fix-rc.patch::https://svn.filezilla-project.org/filezilla/libfilezilla/trunk/lib/Makefile.am?view=patch&r1=9359&r2=9358&pathrev=9359')
md5sums=('7cecda7c08f141223076487490374cb5'
'214c4efa3b967ec32abd207eef32e270'
'9a413b5b4f1cf341eca233614c626674'
'e89893486d31c6475743e12517f5b505')
2016-06-01 00:22:52 +02:00
_architectures="i686-w64-mingw32 x86_64-w64-mingw32"
prepare() {
cd "${srcdir}/${_name}-${pkgver}"
2019-07-23 17:42:42 +02:00
msg2 'Patching sources'
patch -p2 -i "$srcdir/remove-version.patch"
patch -p2 -i "$srcdir/remove-version-2.patch"
patch -p2 -i "$srcdir/fix-rc.patch"
#rm lib/libfilezilla/version.hpp
msg2 'Running autoreconf -i'
2016-06-01 00:22:52 +02:00
autoreconf -i
}
build() {
2019-07-23 17:42:42 +02:00
#export CXXFLAGS='-O0'
2016-06-01 00:22:52 +02:00
for _arch in ${_architectures}; do
mkdir -p "${srcdir}/${_name}-${pkgver}/build-${_arch}" && cd "${srcdir}/${_name}-${pkgver}/build-${_arch}"
2016-07-29 18:08:04 +02:00
${_arch}-configure --disable-shared
# shared build doesn't work because 'fz::simple_event<fz::timer_event_type, unsigned long long>::type()'
2019-07-23 17:42:42 +02:00
# is not exported correctly
2016-06-01 00:22:52 +02:00
make
done
}
package() {
for _arch in ${_architectures}; do
cd "${srcdir}/${_name}-${pkgver}/build-${_arch}"
make DESTDIR="${pkgdir}" install
find "${pkgdir}/usr/${_arch}" -name '*.exe' -exec ${_arch}-strip --strip-all {} \;
find "${pkgdir}/usr/${_arch}" -name '*.dll' -exec ${_arch}-strip --strip-unneeded {} \;
find "${pkgdir}/usr/${_arch}" -name '*.a' -exec ${_arch}-strip -g {} \;
2016-06-01 00:22:52 +02:00
done
}