# Contributor: Russ Webber # Maintainer: Russ Webber pkgname=assimp pkgver=5.2.5 pkgrel=1 pkgdesc="Open Asset Import Library imports and exports 3D model formats." url="http://www.assimp.org/" arch="all" license="BSD-3-Clause" makedepends=" cmake samurai zlib-dev " subpackages="$pkgname-dev $pkgname-libs" source="https://github.com/assimp/assimp/archive/v$pkgver/assimp-v$pkgver.tar.gz version.patch " case "$CARCH" in s390x) # a few tests fail options="$options !check" ;; esac prepare() { default_prepare # tests report correct values, but comparison fails case $CARCH in x86) sed -i \ -e "/AssimpAPITest_aiMatrix3x3/d" \ -e "/AssimpAPITest_aiMatrix4x4/d" \ -e "/utFastAtof/d" \ test/CMakeLists.txt ;; esac } build() { cmake -B build -G Ninja \ -DCMAKE_BUILD_TYPE=MinSizeRel \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib \ -DBUILD_SHARED_LIBS=True \ -DASSIMP_IGNORE_GIT_HASH=ON \ -DASSIMP_BUILD_ASSIMP_TOOLS=ON \ -DASSIMP_BUILD_TESTS="$(want_check && echo ON || echo OFF)" \ -DASSIMP_WARNINGS_AS_ERRORS=OFF \ -DASSIMP_BUILD_MINIZIP=True # use vendored fork of minizip cmake --build build } check() { ./build/bin/unit } package() { DESTDIR="$pkgdir" cmake --install build rm -vf "$pkgdir"/usr/lib/libIrrXML.a } sha512sums=" ac0dc4243f9d1ff077966f0037187b4374075ac97e75e1a3cd6bdc1caf5f8e4d40953d9a8a316480969c09524d87daa9d3ed75e6ac6f037dd5b1c5f25fce3afb assimp-v5.2.5.tar.gz 758e0f83ba5de7b3894c16e79fe1c596f0ba3abb730631e35b0201b560bd15b2e5f4d001a2d11b757dd1b44f241d2cf57ad7d1a45e4be434fcaabdeda4e7d89e version.patch "