# Modeled after the Arch AUR astc-encoder PKGBUILD by Daniel Bermond # Adapted for RPM/Fedora packaging conventions %global soname libastcenc Name: astc-encoder Version: 5.3.0 Release: 2%{?dist} Summary: A tool for compressing and decompressing images using the ASTC texture compression standard License: Apache-2.0 URL: https://github.com/ARM-software/astc-encoder Source0: %{url}/archive/refs/tags/%{version}.tar.gz#/%{name}-%{version}.tar.gz ExclusiveArch: x86_64 BuildRequires: cmake BuildRequires: gcc-c++ BuildRequires: make BuildRequires: python3 %description The Arm ASTC Encoder (astcenc) is a command-line tool for compressing and decompressing images using the Adaptive Scalable Texture Compression (ASTC) data format. The ASTC compressed data format, developed by Arm and AMD, has been adopted as an official extension to the OpenGL, OpenGL ES, and Vulkan graphics APIs. %package devel Summary: Development files for %{name} Requires: %{name}%{?_isa} = %{version}-%{release} %description devel Development headers for the ASTC Encoder shared library. %prep %autosetup -n astc-encoder-%{version} %build %cmake \ -DASTCENC_ISA_AVX2:BOOL=ON \ -DASTCENC_ISA_SSE2:BOOL=ON \ -DASTCENC_ISA_SSE41:BOOL=ON \ -DASTCENC_SHAREDLIB:BOOL=ON \ -DASTCENC_WERROR:BOOL=OFF \ -DCMAKE_INSTALL_LIBDIR=%{_libdir} %cmake_build %install %cmake_install install -D -p -m 0644 Source/astcenc.h %{buildroot}%{_includedir}/astcenc.h ln -s astcenc-sse2 %{buildroot}%{_bindir}/astcenc ln -s libastcenc-sse2-shared.so %{buildroot}%{_libdir}/libastcenc.so %files %license LICENSE.txt %doc README.md Docs/ %{_bindir}/astcenc-avx2 %{_bindir}/astcenc-sse2 %{_bindir}/astcenc-sse4.1 %{_bindir}/astcenc %{_libdir}/libastcenc-avx2-shared.so %{_libdir}/libastcenc-sse2-shared.so %{_libdir}/libastcenc-sse4.1-shared.so %{_libdir}/libastcenc.so %files devel %{_includedir}/astcenc.h %changelog * Wed Feb 11 2026 O3DE Packaging - 5.3.0-1 - Initial RPM package, modeled after Arch AUR PKGBUILD - Enable AVX2, SSE2, and SSE4.1 ISA backends - Build shared libraries