Martchus
485b123124
The upstream commit
641bec0e30
changed how static libraries are built and named.
30 lines
888 B
Bash
30 lines
888 B
Bash
pkgname=mingw-w64-cmake-static
|
|
pkgver=1
|
|
pkgrel=4
|
|
arch=('any')
|
|
pkgdesc='CMake wrapper for MinGW (mingw-w64, static)'
|
|
depends=('mingw-w64-cmake')
|
|
license=("GPL")
|
|
url='https://github.com/martchus/pkgbuilds'
|
|
source=(mingw-cmake-static.sh
|
|
toolchain-mingw-static.cmake)
|
|
sha256sums=('SKIP' 'SKIP')
|
|
_architectures="i686-w64-mingw32 x86_64-w64-mingw32"
|
|
|
|
build() {
|
|
for _arch in ${_architectures}; do
|
|
sed "s|@TRIPLE@|${_arch}|g;s|@PROCESSOR@|${_arch::-12}|g" toolchain-mingw-static.cmake > toolchain-${_arch}-static.cmake
|
|
sed "s|@TRIPLE@|${_arch}|g" mingw-cmake-static.sh > ${_arch}-cmake-static
|
|
done
|
|
}
|
|
|
|
package() {
|
|
install -d "${pkgdir}"/usr/bin
|
|
install -d "${pkgdir}"/usr/share/mingw
|
|
for _arch in ${_architectures}; do
|
|
install -m 644 toolchain-${_arch}-static.cmake "${pkgdir}"/usr/share/mingw/
|
|
install -m 755 ${_arch}-cmake-static "${pkgdir}"/usr/bin/
|
|
done
|
|
}
|
|
|