2015-04-22 18:36:40 +02:00
|
|
|
_name=c++utilities
|
2015-04-29 21:34:23 +02:00
|
|
|
pkgname=mingw-w64-c++utilities
|
2015-04-22 18:36:40 +02:00
|
|
|
pkgver=1.0.4
|
|
|
|
pkgrel=1
|
|
|
|
arch=('any')
|
2015-04-29 21:34:23 +02:00
|
|
|
pkgdesc="Common C++ classes and routines used by my applications such
|
|
|
|
as argument parser, IO and conversion utilities (mingw-w64)."
|
2015-04-22 18:36:40 +02:00
|
|
|
license=('GPL')
|
|
|
|
depends=('mingw-w64-crt' 'mingw-w64-qt5-base')
|
|
|
|
makedepends=('mingw-w64-gcc')
|
2015-04-29 21:34:23 +02:00
|
|
|
url="https://github.com/Martchus/cpp-utilities"
|
|
|
|
source=("c++utilities-${pkgver}.tar.gz::https://github.com/Martchus/cpp-utilities/archive/v${pkgver}.tar.gz")
|
|
|
|
sha256sums=('4e94aff9225d8873f752995c1bcc5f15')
|
2015-04-22 18:36:40 +02:00
|
|
|
options=('staticlibs' '!strip')
|
|
|
|
_architectures="i686-w64-mingw32 x86_64-w64-mingw32"
|
2015-04-29 21:34:23 +02:00
|
|
|
|
2015-04-22 18:36:40 +02:00
|
|
|
# head end
|
2015-04-29 21:34:23 +02:00
|
|
|
|
2015-04-22 18:36:40 +02:00
|
|
|
build() {
|
|
|
|
cd $srcdir/$_name
|
2015-04-29 21:34:23 +02:00
|
|
|
# build for each architecture
|
2015-04-22 18:36:40 +02:00
|
|
|
for _arch in ${_architectures}; do
|
|
|
|
mkdir -p build-${_arch} && pushd build-${_arch}
|
|
|
|
INSTALL_ROOT=$pkgdir/usr/ ${_arch}-qmake-qt5 -r ../${_name}.pro
|
|
|
|
make
|
|
|
|
popd
|
|
|
|
done
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
|
|
|
cd $srcdir/$_name
|
|
|
|
for _arch in ${_architectures}; do
|
|
|
|
# bin stuff
|
|
|
|
pushd build-${_arch}
|
|
|
|
${_arch}-strip --strip-unneeded ./release/${_name}.dll
|
|
|
|
${_arch}-strip --strip-unneeded ./release/lib${_name}.dll.a
|
|
|
|
install -m755 -D ./release/${_name}.dll $pkgdir/usr/${_arch}/bin/${_name}.dll
|
|
|
|
install -m755 -D ./release/lib${_name}.dll.a $pkgdir/usr/${_arch}/lib/lib${_name}.dll.a
|
|
|
|
popd
|
|
|
|
# include files
|
|
|
|
for dir in application chrono conversion io math misc
|
|
|
|
do
|
|
|
|
mkdir -p $pkgdir/usr/${_arch}/include/${_name}/$dir
|
|
|
|
install -m644 -D ./$dir/*.h $pkgdir/usr/${_arch}/include/${_name}/$dir
|
|
|
|
done
|
|
|
|
done
|
|
|
|
}
|