## ## 1 minutes 16 seconds ## First build devel-only @finalbuild=0 ## Second build ffmpeg ## Final build full s264 @finalbuild=1 ## %global commit a8b68ebfaa68621b5ac8907610d3335971839d52 %global gittag 0.164 %global shortcommit %(c=%{commit}; echo ${c:0:7}) %global finalbuild 1 Name: x264 #define X264_BUILD 164 in x264.h Version: 0.164 Release: 1.%{shortcommit}%{?dist} Summary: x264 - H264/AVC video streams encoder Group: Applications/System License: MIT license URL: https://code.videolan.org %undefine _disable_source_fetch Source0: https://code.videolan.org/videolan/x264/-/archive/%{commit}/x264-%{shortcommit}.tar.gz Packager: %packager #BuildRequires: liblsmash %global configure "--disable-cli" %if %{finalbuild} BuildRequires: ffmpeg-devel BuildRequires: l-smash-devel BuildRequires: x264-devel BuildRequires: ffms2-devel BuildRequires: avisynthplus %global configure "--system-libx264" %endif BuildRequires: nasm >= 2.13 %define debug_package %nil Provides: libx264 = %{version} Provides: libx264-devel = %{version} %description x264 is a free library for encoding H264/AVC video streams, written from scratch. This package contains the frontend. ################################################################################################################## %package devel Summary: Development files for the x264 library Group: Development/Libraries Requires: %{name}-libs = %{version} %description devel x264 is a free library for encoding H264/AVC video streams, written from scratch. This package contains the development files. %package libs Summary: Library for encoding H264/AVC video streams Group: Development/Libraries %description libs x264 is a free library for encoding H264/AVC video streams, written from scratch. ################################################################################################################## %prep %setup -q -n x264-%{commit} %build ./configure --prefix=%{_prefix} --bindir=%{_bindir} --libdir=%{_libdir} --enable-shared %{configure} make %{?_smp_mflags} %install [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT make DESTDIR=$RPM_BUILD_ROOT install %post ldconfig %clean [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT %if %{finalbuild} %files %{_bindir}/x264 %endif %files libs %doc AUTHORS COPYING %{_libdir}/libx264.so.164 %files devel %{_includedir}/x264.h %{_includedir}/x264_config.h %{_libdir}/libx264.so %{_libdir}/pkgconfig/x264.pc