Christoph Reiter b38b2b78f4 Remove all cygwin CHOST changes
Since #5448 CHOST defaults to cygwin now, so this
is no longer needed.
2025-06-27 07:42:37 +02:00

54 lines
1.3 KiB
Bash

# Maintainer: Alexey Pavlov <alexpux@gmail.com>
pkgname=('libyaml' 'libyaml-devel')
pkgver=0.2.5
pkgrel=2
pkgdesc="YAML 1.1 library"
arch=('i686' 'x86_64')
url="https://pyyaml.org/wiki/LibYAML"
msys2_references=(
"cpe: cpe:/a:pyyaml:libyaml"
)
license=('spdx:MIT')
makedepends=('autotools' 'gcc')
source=(https://pyyaml.org/download/libyaml/yaml-${pkgver}.tar.gz
'yaml-0.1.7-fix-undefined.patch')
sha256sums=('c642ae9b75fee120b2d96c712538bd2cf283228d2337df2cf2988e3c02678ef4'
'fba2535decf076c0a6b260db01e163e665c5fc92fe7edaa90246d31810082387')
prepare() {
cd "${srcdir}/yaml-${pkgver}"
patch -p1 -i ${srcdir}/yaml-0.1.7-fix-undefined.patch
autoreconf -fiv
}
build() {
cd "${srcdir}/yaml-${pkgver}"
./configure \
--build=${CHOST} \
--prefix=/usr
make
make DESTDIR="$srcdir/dest" install
install -m644 -D LICENSE ${srcdir}/dest/usr/share/licenses/${pkgname}/LICENSE
}
package_libyaml() {
groups=('libraries')
install -dm755 ${pkgdir}/usr/bin
install -m755 -t ${pkgdir}/usr/bin ${srcdir}/dest/usr/bin/*.dll
cp -rf ${srcdir}/dest/usr/share ${pkgdir}/usr/
}
package_libyaml-devel() {
groups=('development')
depends=("libyaml=${pkgver}")
install -dm755 ${pkgdir}/usr
cp -rf ${srcdir}/dest/usr/include ${pkgdir}/usr/
cp -rf ${srcdir}/dest/usr/lib ${pkgdir}/usr/
}