pkgname=libjpeg-turbo pkgver=3.0.4 pkgrel=1 pkgdesc="libjpeg derivative with accelerated baseline JPEG compression and decompression" arch=('x86_64') url="https://libjpeg-turbo.org/" license=('GPL' 'custom') makedepends=('nasm') provides=('libjpeg=8.0.2' 'libjpeg6') replaces=('libjpeg' 'libjpeg6') conflicts=('libjpeg' 'libjpeg6') options=('!libtool') source=("https://github.com/libjpeg-turbo/libjpeg-turbo/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.gz") sha1sums=('130ee52021d700d8074898b7565dd25ae61b292d') build() { cmake -B build -S ${pkgname}-${pkgver} \ -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_DEFAULT_LIBDIR=lib \ -DWITH_JPEG8=TRUE cmake --build build } package() { DESTDIR=${pkgdir} cmake --install build # provide jpegint.h as it is required by various software install -m644 ${pkgname}-${pkgver}/jpegint.h ${pkgdir}/usr/include/ install -Dm644 ${pkgname}-${pkgver}/LICENSE.md ${pkgdir}/usr/share/licenses/libjpeg-turbo/LICENSE.md install -Dm644 ${pkgname}-${pkgver}/README.md ${pkgdir}/usr/share/licenses/libjpeg-turbo/README.md }