]> git.pld-linux.org Git - packages/libvpx.git/blob - libvpx.spec
requires yasm >= 0.8
[packages/libvpx.git] / libvpx.spec
1 #
2 # Conditional build:
3 %bcond_without  asm     # x86 assembler
4
5 Summary:        VP8, a high-quality video codec
6 Summary(pl.UTF-8):      VP8 - kodek obrazu wysokiej jakości
7 Name:           libvpx
8 Version:        1.0.0
9 Release:        1
10 License:        BSD
11 Group:          Libraries
12 # Source0Download: http://code.google.com/p/webm/downloads/list
13 Source0:        https://webm.googlecode.com/files/%{name}-v%{version}.tar.bz2
14 # Source0-md5:  d987b5140412edd37d2c6b10c29ad484
15 URL:            http://www.webmproject.org/
16 BuildRequires:  /usr/bin/php
17 BuildRequires:  doxygen
18 BuildRequires:  php-common >= 4:5.0.0
19 BuildRequires:  php-pcre
20 BuildRequires:  sed >= 4.0
21 %ifarch %{ix86} %{x8664}
22 %{?with_asm:BuildRequires:      yasm >= 0.8}
23 %endif
24 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
26 %description
27 VP8, a high-quality video codec.
28
29 %description -l pl.UTF-8
30 VP8 - kodek obrazu wysokiej jakości.
31
32 %package devel
33 Summary:        Header files for libvpx
34 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki libvpx
35 Group:          Development/Libraries
36 Requires:       %{name} = %{version}-%{release}
37
38 %description devel
39 Header files for libvpx library.
40
41 %description devel -l pl.UTF-8
42 Pliki nagłówkowe biblioteki libvpx.
43
44 %package static
45 Summary:        Static libvpx library
46 Summary(pl.UTF-8):      Statyczna biblioteka libvpx
47 Group:          Development/Libraries
48 Requires:       %{name}-devel = %{version}-%{release}
49
50 %description static
51 Static libvpx library.
52
53 %description static -l pl.UTF-8
54 Statyczna biblioteka libvpx.
55
56 %prep
57 %setup -q -n %{name}-v%{version}
58
59 %build
60 install -d obj
61 cd obj
62 # not autoconf configure
63 CFLAGS="%{rpmcflags} %{rpmcppflags}" \
64 ../configure \
65 %if %{with asm}
66         --as=yasm \
67 %ifarch %{x8664}
68         --target=x86_64-linux-gcc \
69 %endif
70 %ifarch %{ix86}
71         --target=x86-linux-gcc \
72 %endif
73 %else
74         --target=generic-gnu \
75 %endif
76         --enable-shared \
77         --disable-optimizations \
78         --enable-vp8 \
79         --enable-postproc \
80         --enable-runtime-cpu-detect
81
82 %{__make} verbose=true target=libs \
83         HAVE_GNU_STRIP=no \
84         CC="%{__cc}" \
85         LDFLAGS="%{rpmldflags}"
86
87 %{__make} verbose=true target=examples \
88         CC="%{__cc}" \
89         LDFLAGS="%{rpmldflags} -L."
90 %{__make} verbose=true target=docs
91
92 %install
93 rm -rf $RPM_BUILD_ROOT
94 install -d $RPM_BUILD_ROOT{%{_bindir},%{_includedir}/vpx,%{_libdir}}
95
96 %{__make} -C obj verbose=true install \
97         LIBSUBDIR=%{_lib} \
98         DIST_DIR=$RPM_BUILD_ROOT%{_prefix}
99
100 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libvpx.so.1.0
101
102 # adjust prefix and libdir
103 %{__sed} -i -e 's,^prefix=.*,prefix=%{_prefix},;s,^libdir=.*,libdir=%{_libdir},' $RPM_BUILD_ROOT%{_pkgconfigdir}/vpx.pc
104
105 %clean
106 rm -rf $RPM_BUILD_ROOT
107
108 %post   -p /sbin/ldconfig
109 %postun -p /sbin/ldconfig
110
111 %files
112 %defattr(644,root,root,755)
113 %doc AUTHORS CHANGELOG LICENSE PATENTS README
114 %attr(755,root,root) %{_bindir}/vp8_scalable_patterns
115 %attr(755,root,root) %{_bindir}/vpxdec
116 %attr(755,root,root) %{_bindir}/vpxenc
117 %attr(755,root,root) %{_libdir}/libvpx.so.*.*.*
118 %attr(755,root,root) %ghost %{_libdir}/libvpx.so.1
119
120 %files devel
121 %defattr(644,root,root,755)
122 %doc vp8_api1_migration.txt
123 %attr(755,root,root) %{_libdir}/libvpx.so
124 %{_includedir}/vpx
125 %{_pkgconfigdir}/vpx.pc
126
127 %files static
128 %defattr(644,root,root,755)
129 %{_libdir}/libvpx.a
This page took 0.063772 seconds and 4 git commands to generate.