]>
Commit | Line | Data |
---|---|---|
deef52dc JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_with bootstrap | |
4 | # | |
c8829b2a | 5 | %define snap 20110625 |
1eadea1c | 6 | %define snaph 2245 |
f3138d6c | 7 | %define rel 5 |
65b73f48 | 8 | Summary: H264 encoder library |
23647862 | 9 | Summary(pl.UTF-8): Biblioteka kodująca H264 |
65b73f48 | 10 | Name: libx264 |
bb560be3 | 11 | Version: 0.1.3 |
4663db6e | 12 | Release: 1.%{snap}_%{snaph}.%{rel} |
76f3f357 | 13 | License: GPL v2+ |
65b73f48 | 14 | Group: Libraries |
deef52dc | 15 | # still no releases, use snapshots |
aedfa898 | 16 | Source0: ftp://ftp.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-%{snap}-%{snaph}.tar.bz2 |
c8829b2a | 17 | # Source0-md5: 6463c144cd10c26d721fac212a747910 |
2741dce2 | 18 | Patch0: %{name}-alpha.patch |
deef52dc | 19 | Patch1: altivec-no-vand.patch |
d6b08ec3 | 20 | Patch2: %{name}-gpac.patch |
8723c613 | 21 | Patch3: %{name}-ffmpeg.patch |
f33b600a | 22 | URL: http://www.videolan.org/developers/x264.html |
bad36153 KK |
23 | BuildRequires: pkgconfig |
24 | %ifarch %{ix86} %{x8664} | |
f33b600a | 25 | BuildRequires: yasm >= 0.6.0 |
aedfa898 | 26 | %endif |
deef52dc JB |
27 | %if %{without bootstrap} |
28 | # which version exactly??? | |
29 | # for full x264 CLI utility functionality it wants: | |
30 | # libswscale >= 0.9.0 (in pkgconfig file) | |
31 | # libav{format,codec,util} from ffmpeg >= r21854 | |
8723c613 | 32 | BuildRequires: ffmpeg-devel >= 0.7.1 |
8bab7e00 | 33 | BuildRequires: ffmpegsource-devel >= 2.15 |
deef52dc | 34 | # gpac >= 2007-06-21 |
d6b08ec3 JB |
35 | BuildRequires: gpac-devel >= 0.4.5-2 |
36 | Requires: gpac >= 0.4.5-2 | |
deef52dc | 37 | %endif |
65b73f48 JB |
38 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
39 | ||
7cf55bee PS |
40 | # encoder/macroblock.c breaks strict-aliasing rules |
41 | %define specflags -fno-strict-aliasing | |
42 | ||
65b73f48 JB |
43 | %description |
44 | libx264 library for encoding H264 video format. | |
45 | ||
3d6bd83a | 46 | %description -l pl.UTF-8 |
65b73f48 JB |
47 | Biblioteka libx264 do kodowania w formacie obrazu H264. |
48 | ||
49 | %package devel | |
50 | Summary: Header files for x264 library | |
23647862 | 51 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki x264 |
65b73f48 JB |
52 | Group: Development/Libraries |
53 | Requires: %{name} = %{version}-%{release} | |
54 | ||
55 | %description devel | |
56 | Header files for x264 library. | |
57 | ||
3d6bd83a JR |
58 | %description devel -l pl.UTF-8 |
59 | Pliki nagłówkowe biblioteki x264. | |
65b73f48 JB |
60 | |
61 | %package static | |
62 | Summary: Static x264 library | |
23647862 | 63 | Summary(pl.UTF-8): Statyczna biblioteka x264 |
65b73f48 JB |
64 | Group: Development/Libraries |
65 | Requires: %{name}-devel = %{version}-%{release} | |
66 | ||
67 | %description static | |
68 | Static x264 library. | |
69 | ||
3d6bd83a | 70 | %description static -l pl.UTF-8 |
65b73f48 JB |
71 | Statyczna biblioteka x264. |
72 | ||
deef52dc JB |
73 | %package -n x264 |
74 | Summary: x264 CLI decoder | |
75 | Summary(pl.UTF-8): Dekoder x264 działający z linii poleceń | |
76 | Group: Applications/Multimedia | |
77 | Requires: %{name} = %{version}-%{release} | |
78 | ||
79 | %description -n x264 | |
80 | x264 CLI decoder. | |
81 | ||
82 | %description -n x264 -l pl.UTF-8 | |
83 | Dekoder x264 działający z linii poleceń. | |
84 | ||
65b73f48 | 85 | %prep |
aedfa898 | 86 | %setup -q -n x264-snapshot-%{snap}-%{snaph} |
2741dce2 | 87 | %patch0 -p1 |
deef52dc | 88 | %if "%{pld_release}" == "ac" |
3b7e662c | 89 | %patch1 -p1 |
deef52dc | 90 | %endif |
d6b08ec3 | 91 | %patch2 -p1 |
8723c613 | 92 | %patch3 -p1 |
65b73f48 JB |
93 | |
94 | %build | |
704304fd | 95 | CC="%{__cc}" \ |
7cf55bee | 96 | ./configure \ |
219e4f34 PS |
97 | --prefix=%{_prefix} \ |
98 | --exec-prefix=%{_prefix} \ | |
99 | --bindir=%{_bindir} \ | |
100 | --includedir=%{_includedir} \ | |
101 | --libdir=%{_libdir} \ | |
7cf55bee | 102 | --extra-cflags="%{rpmcflags}" \ |
bad36153 | 103 | --enable-pic \ |
c8829b2a JB |
104 | --enable-shared \ |
105 | --enable-static | |
7cf55bee | 106 | |
65b73f48 JB |
107 | %{__make} |
108 | ||
109 | %install | |
110 | rm -rf $RPM_BUILD_ROOT | |
111 | ||
112 | %{__make} install \ | |
113 | DESTDIR=$RPM_BUILD_ROOT | |
114 | ||
115 | %clean | |
116 | rm -rf $RPM_BUILD_ROOT | |
117 | ||
118 | %post -p /sbin/ldconfig | |
119 | %postun -p /sbin/ldconfig | |
120 | ||
121 | %files | |
122 | %defattr(644,root,root,755) | |
247a0e4f | 123 | %doc AUTHORS |
c8829b2a | 124 | %attr(755,root,root) %{_libdir}/libx264.so.115 |
65b73f48 JB |
125 | |
126 | %files devel | |
127 | %defattr(644,root,root,755) | |
128 | %attr(755,root,root) %{_libdir}/libx264.so | |
65b73f48 | 129 | %{_includedir}/x264.h |
ac54585f | 130 | %{_includedir}/x264_config.h |
247a0e4f | 131 | %{_pkgconfigdir}/x264.pc |
65b73f48 JB |
132 | |
133 | %files static | |
134 | %defattr(644,root,root,755) | |
135 | %{_libdir}/libx264.a | |
deef52dc JB |
136 | |
137 | %files -n x264 | |
138 | %defattr(644,root,root,755) | |
139 | %attr(755,root,root) %{_bindir}/x264 |