1 | Name: libvpx |
---|
2 | Version: 1.1.0 |
---|
3 | Release: 1%{?_dist_release} |
---|
4 | Summary: The VP8 Codec SDK |
---|
5 | Summary(ja): VP8 コーデックソフトウェア開発キット |
---|
6 | |
---|
7 | Group: System Environment/Libraries |
---|
8 | License: BSD |
---|
9 | URL: http://www.webmproject.org/tools/vp8-sdk/ |
---|
10 | Source0: http://webm.googlecode.com/files/%{name}-v%{version}.tar.bz2 |
---|
11 | Source2: libvpx.ver |
---|
12 | |
---|
13 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root |
---|
14 | %ifarch %{ix86} x86_64 |
---|
15 | BuildRequires: yasm |
---|
16 | %endif |
---|
17 | |
---|
18 | Vendor: Project Vine |
---|
19 | Distribution: Vine Linux |
---|
20 | Packager: daisuke |
---|
21 | |
---|
22 | %description |
---|
23 | The WebM VP8 Codec SDK allows you to integrate your applications with |
---|
24 | the VP8 video codec, a high quality, royalty free, open source codec |
---|
25 | deployed on millions of computers and devices worldwide. |
---|
26 | |
---|
27 | %description -l ja |
---|
28 | WebM VP8 コーデック SDK は、VP8 ビデオコーデックをアプリケーションに |
---|
29 | 統合するための開発きっとです。VP8ビデオコーデックは高品質でロイヤリティ |
---|
30 | フリーかつオープンソースのコーデックで、世界中の多くのコンピュータや |
---|
31 | デバイスで利用されています。 |
---|
32 | |
---|
33 | %package devel |
---|
34 | Summary: Development files for %{name} |
---|
35 | Summary(ja): %{name} の開発ファイル |
---|
36 | Group: Development/Libraries |
---|
37 | Requires: %{name} = %{version}-%{release} |
---|
38 | |
---|
39 | %description devel |
---|
40 | The %{name}-devel package contains development files for |
---|
41 | %{name}. |
---|
42 | |
---|
43 | %description devel -l ja |
---|
44 | %{name}-devel パッケージは %{name} の開発用ファイルを含んでいます。 |
---|
45 | |
---|
46 | %package utils |
---|
47 | Summary: example programs for %{name} |
---|
48 | Summary(ja): %{name} のサンプルプログラム |
---|
49 | Group: Applications/Multimedia |
---|
50 | Requires: %{name} = %{version}-%{release} |
---|
51 | |
---|
52 | %description utils |
---|
53 | The %{name}-utils package contains example programs that |
---|
54 | use %{name}. |
---|
55 | |
---|
56 | %description utils -l ja |
---|
57 | %{name}-utils パッケージは、%{name} を使用したサンプル |
---|
58 | アプリケーションを含んでいます。 |
---|
59 | |
---|
60 | |
---|
61 | %prep |
---|
62 | %setup -q -n %{name}-v%{version} |
---|
63 | |
---|
64 | %build |
---|
65 | |
---|
66 | %ifarch %{ix86} |
---|
67 | %global vpxtarget x86-linux-gcc |
---|
68 | %else |
---|
69 | %ifarch x86_64 |
---|
70 | %global vpxtarget x86_64-linux-gcc |
---|
71 | %else |
---|
72 | %global vpxtarget generic-gnu |
---|
73 | %endif |
---|
74 | %endif |
---|
75 | |
---|
76 | %if "%{vpxtarget}" == "generic-gnu" |
---|
77 | %global generic_target 1 |
---|
78 | %else |
---|
79 | %global generic_target 0 |
---|
80 | %endif |
---|
81 | |
---|
82 | ./configure \ |
---|
83 | --target=%{vpxtarget} \ |
---|
84 | --enable-pic \ |
---|
85 | %if ! %{generic_target} |
---|
86 | --enable-shared \ |
---|
87 | %endif |
---|
88 | --prefix=%{_prefix} \ |
---|
89 | --libdir=%{_libdir} \ |
---|
90 | --disable-install-docs \ |
---|
91 | --disable-install-srcs |
---|
92 | |
---|
93 | # fix up optflags |
---|
94 | sed -i "s|-O3|%{optflags}|g" libs-%{vpxtarget}.mk |
---|
95 | sed -i "s|-O3|%{optflags}|g" examples-%{vpxtarget}.mk |
---|
96 | sed -i "s|-O3|%{optflags}|g" docs-%{vpxtarget}.mk |
---|
97 | |
---|
98 | %{__make} %{?_smp_mflags} verbose=true target=libs |
---|
99 | |
---|
100 | %if %{generic_target} |
---|
101 | mkdir -p tmp |
---|
102 | pushd tmp |
---|
103 | ar x ../libvpx_g.a |
---|
104 | popd |
---|
105 | gcc -shared -fPIC -pthread -lm \ |
---|
106 | -Wl,--no-undefined \ |
---|
107 | -Wl,-soname,libvpx.so.0 \ |
---|
108 | -Wl,--version-script,%{SOURCE2} \ |
---|
109 | -Wl,-z,noexecstack \ |
---|
110 | -o libvpx.so.%{version} tmp/*.o |
---|
111 | rm -rf tmp |
---|
112 | %endif |
---|
113 | |
---|
114 | ln -sf libvpx.so.%{version} libvpx.so |
---|
115 | |
---|
116 | mv libvpx.a libvpx.a.tmp |
---|
117 | mv libvpx_g.a libvpx_g.a.tmp |
---|
118 | |
---|
119 | make %{?_smp_mflags} verbose=true target=examples |
---|
120 | |
---|
121 | mv libvpx.a.tmp libvpx.a |
---|
122 | mv libvpx_g.a.tmp libvpx_g.a |
---|
123 | |
---|
124 | %install |
---|
125 | %{__rm} -rf $RPM_BUILD_ROOT |
---|
126 | %{__make} DIST_DIR=$RPM_BUILD_ROOT%{_prefix} dist |
---|
127 | |
---|
128 | %if %{generic_target} |
---|
129 | install -p libvpx.so.%{version} %{buildroot}%{_libdir} |
---|
130 | pushd %{buildroot}%{_libdir} |
---|
131 | ln -sf libvpx.so.%{version} libvpx.so |
---|
132 | ln -sf libvpx.so.%{version} libvpx.so.1 |
---|
133 | ln -sf libvpx.so.%{version} libvpx.so.1.1 |
---|
134 | popd |
---|
135 | %endif |
---|
136 | |
---|
137 | pushd %{buildroot} |
---|
138 | # Rename a few examples |
---|
139 | mv usr/bin/postproc usr/bin/vp8_postproc |
---|
140 | mv usr/bin/simple_decoder usr/bin/vp8_simple_decoder |
---|
141 | mv usr/bin/simple_encoder usr/bin/vp8_simple_encoder |
---|
142 | mv usr/bin/twopass_encoder usr/bin/vp8_twopass_encoder |
---|
143 | # Fix the binary permissions |
---|
144 | chmod 755 usr/bin/* |
---|
145 | popd |
---|
146 | |
---|
147 | rm -f $RPM_BUILD_ROOT%{_prefix}/md5sums.txt |
---|
148 | rm -f $RPM_BUILD_ROOT%{_libdir}/lib*.a |
---|
149 | rm -f $RPM_BUILD_ROOT%{_prefix}/{CHANGELOG,README} |
---|
150 | rm -rf $RPM_BUILD_ROOT%{_prefix}/build |
---|
151 | |
---|
152 | |
---|
153 | %clean |
---|
154 | rm -rf $RPM_BUILD_ROOT |
---|
155 | |
---|
156 | |
---|
157 | %post -p /sbin/ldconfig |
---|
158 | |
---|
159 | %postun -p /sbin/ldconfig |
---|
160 | |
---|
161 | |
---|
162 | %files |
---|
163 | %defattr(-,root,root,-) |
---|
164 | %doc AUTHORS LICENSE README CHANGELOG |
---|
165 | %{_libdir}/*.so.* |
---|
166 | |
---|
167 | %files devel |
---|
168 | %defattr(-,root,root,-) |
---|
169 | %{_libdir}/*.so |
---|
170 | %{_libdir}/pkgconfig/*.pc |
---|
171 | %{_includedir}/vpx/*.h |
---|
172 | |
---|
173 | %files utils |
---|
174 | %defattr(-,root,root,-) |
---|
175 | %{_bindir}/* |
---|
176 | |
---|
177 | |
---|
178 | %changelog |
---|
179 | * Mon Oct 08 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.1.0-1 |
---|
180 | - new upstream release |
---|
181 | - remove Patch0 (libvpx-0.9.0-no-explicit-dep-on-static-lib.patch) |
---|
182 | - remove Source1 (libvpx.pc) |
---|
183 | |
---|
184 | * Sun Oct 16 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.9.6-1 |
---|
185 | - new upstream release |
---|
186 | |
---|
187 | * Mon Dec 27 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 0.9.5-1 |
---|
188 | - new upstream release |
---|
189 | |
---|
190 | * Sun Sep 26 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 0.9.1-2 |
---|
191 | - rebuild with rpm-4.8.1 for pkg-config file |
---|
192 | |
---|
193 | * Sun Jul 11 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 0.9.1-1 |
---|
194 | - new upstream release |
---|
195 | |
---|
196 | * Mon May 24 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 0.9.0-1 |
---|
197 | - initial build for Vine Linux |
---|