]> git.pld-linux.org Git - packages/libx264.git/blame - libx264.spec
explicitly pass bash completions directory
[packages/libx264.git] / libx264.spec
CommitLineData
deef52dc
JB
1#
2# Conditional build:
be9a44e2 3%bcond_with bootstrap # no ffmpeg/gpac support in x264 utility
c010e225 4%bcond_without asm # disable asm
e391f7cc 5%bcond_without lsmash # lsmash for MP4 (preferred over gpac)
c010e225 6
4bc51f18 7%ifnarch %{ix86} %{x8664} aarch64
c010e225
ER
8%undefine with_asm
9%endif
460a5dbe 10
03f2214c 11%define gitref 12426f5f4906e34d483a07da0debb6d56c6f8434
c0b37d51 12%define rel 2
03f2214c
JB
13%define snap 20240220
14%define api_ver 164
65b73f48 15Summary: H264 encoder library
23647862 16Summary(pl.UTF-8): Biblioteka kodująca H264
65b73f48 17Name: libx264
03f2214c
JB
18Version: 0.%{api_ver}
19Release: 0.%{snap}.%{rel}
76f3f357 20License: GPL v2+
65b73f48 21Group: Libraries
deef52dc 22# still no releases, use snapshots
03f2214c 23# previously available at https://download.videolan.org/videolan/x264/snapshots/
e391f7cc 24# for further changes see: https://code.videolan.org/videolan/x264/
03f2214c
JB
25Source0: https://code.videolan.org/videolan/x264/-/archive/%{gitref}/x264-%{gitref}.tar.bz2
26# Source0-md5: b46bb3b0521e2d5fdefeed345bd42f94
2741dce2 27Patch0: %{name}-alpha.patch
03f2214c
JB
28Patch1: %{name}-gpac.patch
29Patch2: x32.patch
f33b600a 30URL: http://www.videolan.org/developers/x264.html
019accbe 31%ifarch %{ix86} %{x8664}
e3dd7f14 32%{?with_asm:BuildRequires: nasm >= 2.13}
019accbe 33%endif
bad36153 34BuildRequires: pkgconfig
03f2214c 35BuildRequires: rpmbuild(macros) >= 1.673
deef52dc
JB
36%if %{without bootstrap}
37# which version exactly???
38# for full x264 CLI utility functionality it wants:
39# libswscale >= 0.9.0 (in pkgconfig file)
40# libav{format,codec,util} from ffmpeg >= r21854
8723c613 41BuildRequires: ffmpeg-devel >= 0.7.1
e391f7cc 42BuildRequires: ffms2-devel >= 2.21
deef52dc 43# gpac >= 2007-06-21
03f2214c 44%{!?with_lsmash:BuildRequires: gpac-devel >= 0.8.0}
e391f7cc 45%{?with_lsmash:BuildRequires: l-smash-devel >= 1.5}
deef52dc 46%endif
65b73f48
JB
47BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48
7cf55bee
PS
49# encoder/macroblock.c breaks strict-aliasing rules
50%define specflags -fno-strict-aliasing
51
65b73f48
JB
52%description
53libx264 library for encoding H264 video format.
54
3d6bd83a 55%description -l pl.UTF-8
65b73f48
JB
56Biblioteka libx264 do kodowania w formacie obrazu H264.
57
58%package devel
59Summary: Header files for x264 library
23647862 60Summary(pl.UTF-8): Pliki nagłówkowe biblioteki x264
65b73f48
JB
61Group: Development/Libraries
62Requires: %{name} = %{version}-%{release}
63
64%description devel
65Header files for x264 library.
66
3d6bd83a
JR
67%description devel -l pl.UTF-8
68Pliki nagłówkowe biblioteki x264.
65b73f48
JB
69
70%package static
71Summary: Static x264 library
23647862 72Summary(pl.UTF-8): Statyczna biblioteka x264
65b73f48
JB
73Group: Development/Libraries
74Requires: %{name}-devel = %{version}-%{release}
75
76%description static
77Static x264 library.
78
3d6bd83a 79%description static -l pl.UTF-8
65b73f48
JB
80Statyczna biblioteka x264.
81
deef52dc
JB
82%package -n x264
83Summary: x264 CLI decoder
84Summary(pl.UTF-8): Dekoder x264 działający z linii poleceń
85Group: Applications/Multimedia
86Requires: %{name} = %{version}-%{release}
c6f8df1a 87%if %{without bootstrap}
e391f7cc
JB
88Requires: ffms2 >= 2.21
89%if %{with lsmash}
90Requires: l-smash >= 1.5
91%else
03f2214c 92Requires: gpac >= 0.8.0
c6f8df1a 93%endif
e391f7cc 94%endif
deef52dc
JB
95
96%description -n x264
97x264 CLI decoder.
98
99%description -n x264 -l pl.UTF-8
100Dekoder x264 działający z linii poleceń.
101
65b73f48 102%prep
03f2214c 103%setup -q -n x264-%{gitref}
2741dce2 104%patch0 -p1
3b7e662c 105%patch1 -p1
d6b08ec3 106%patch2 -p1
65b73f48
JB
107
108%build
704304fd 109CC="%{__cc}" \
7cf55bee 110./configure \
b841a03e 111 --host=%{_target_platform} \
219e4f34
PS
112 --prefix=%{_prefix} \
113 --exec-prefix=%{_prefix} \
114 --bindir=%{_bindir} \
115 --includedir=%{_includedir} \
116 --libdir=%{_libdir} \
7cf55bee 117 --extra-cflags="%{rpmcflags}" \
640c0aaf 118 --bashcompletionsdir="%{bash_compdir}" \
c010e225 119 %{!?with_asm:--disable-asm} \
bad36153 120 --enable-pic \
c8829b2a
JB
121 --enable-shared \
122 --enable-static
7cf55bee 123
65b73f48
JB
124%{__make}
125
126%install
127rm -rf $RPM_BUILD_ROOT
128
129%{__make} install \
130 DESTDIR=$RPM_BUILD_ROOT
131
132%clean
133rm -rf $RPM_BUILD_ROOT
134
135%post -p /sbin/ldconfig
136%postun -p /sbin/ldconfig
137
138%files
139%defattr(644,root,root,755)
247a0e4f 140%doc AUTHORS
03f2214c 141%attr(755,root,root) %{_libdir}/libx264.so.%{api_ver}
65b73f48
JB
142
143%files devel
144%defattr(644,root,root,755)
145%attr(755,root,root) %{_libdir}/libx264.so
65b73f48 146%{_includedir}/x264.h
ac54585f 147%{_includedir}/x264_config.h
247a0e4f 148%{_pkgconfigdir}/x264.pc
65b73f48
JB
149
150%files static
151%defattr(644,root,root,755)
152%{_libdir}/libx264.a
deef52dc
JB
153
154%files -n x264
155%defattr(644,root,root,755)
156%attr(755,root,root) %{_bindir}/x264
03f2214c 157%{bash_compdir}/x264
This page took 0.178213 seconds and 4 git commands to generate.