]> git.pld-linux.org Git - packages/crossmingw32-libwebp.git/blob - crossmingw32-libwebp.spec
do not provide pkgconfig deps in system namespace
[packages/crossmingw32-libwebp.git] / crossmingw32-libwebp.spec
1 Summary:        WebP image codec libraries - cross MinGW32 version
2 Summary(pl.UTF-8):      Biblioteki do kodeka obrazów WebP - wersja skrośna MinGW32
3 Name:           crossmingw32-libwebp
4 Version:        0.3.0
5 Release:        2
6 License:        BSD
7 Group:          Development/Libraries
8 #Source0Download: http://code.google.com/p/webp/downloads/list
9 Source0:        http://webp.googlecode.com/files/libwebp-%{version}.tar.gz
10 # Source0-md5:  4183f4f51ada98976f14e7bd51f30938
11 URL:            https://developers.google.com/speed/webp/
12 BuildRequires:  autoconf >= 2.50
13 BuildRequires:  automake
14 BuildRequires:  crossmingw32-gcc
15 BuildRequires:  libtool
16 BuildRequires:  rpmbuild(macros) >= 1.197
17 BuildRequires:  sed >= 4.0
18 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
19
20 %define         no_install_post_strip   1
21
22 %define         target                  i386-mingw32
23 %define         target_platform         i386-pc-mingw32
24
25 %define         _sysprefix              /usr
26 %define         _prefix                 %{_sysprefix}/%{target}
27 %define         _libdir                 %{_prefix}/lib
28 %define         _pkgconfigdir           %{_prefix}/lib/pkgconfig
29 %define         _dlldir                 /usr/share/wine/windows/system
30 %define         __cc                    %{target}-gcc
31 %define         __cxx                   %{target}-g++
32 %define         __pkgconfig_provides    %{nil}
33
34 %ifnarch %{ix86}
35 # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc
36 %define         optflags        -O2
37 %endif
38 # -z options are invalid for mingw linker, most of -f options are Linux-specific
39 %define         filterout_ld    -Wl,-z,.*
40 %define         filterout_c     -f[-a-z0-9=]*
41
42 %description
43 WebP image codec libraries.
44
45 This package contains the cross version for Win32.
46
47 %description -l pl.UTF-8
48 Biblioteki kodeka obrazów WebP.
49
50 Ten pakiet zawiera wersję skrośną dla Win32.
51
52 %package static
53 Summary:        Static WebP libraries (cross MinGW32 version)
54 Summary(pl.UTF-8):      Statyczne biblioteki WebP (wersja skrośna MinGW32)
55 Group:          Development/Libraries
56 Requires:       %{name} = %{version}-%{release}
57
58 %description static
59 Static WebP libraries (cross MinGW32 version).
60
61 %description static -l pl.UTF-8
62 Statyczne biblioteki WebP (wersja skrośna MinGW32).
63
64 %package dll
65 Summary:        DLL WebP libraries for Windows
66 Summary(pl.UTF-8):      Biblioteki DLL WebP dla Windows
67 Group:          Applications/Emulators
68 Requires:       wine
69
70 %description dll
71 DLL WebP libraries for Windows.
72
73 %description dll -l pl.UTF-8
74 Biblioteki DLL WebP dla Windows.
75
76 %prep
77 %setup -q -n libwebp-%{version}
78
79 sed -i -e 's/libwebp_la_LDFLAGS.*/& -no-undefined/' src/Makefile.am
80
81 %build
82 %{__libtoolize}
83 %{__aclocal} -I m4
84 %{__autoconf}
85 %{__autoheader}
86 %{__automake}
87 %configure \
88         --target=%{target} \
89         --host=%{target} \
90         --disable-silent-rules \
91         --enable-libwebpdemux \
92         --enable-libwebpmux
93
94 # -C src to get just the library, no utils
95 %{__make} -C src
96
97 %install
98 rm -rf $RPM_BUILD_ROOT
99
100 %{__make} -C src install \
101         DESTDIR=$RPM_BUILD_ROOT
102
103 install -d $RPM_BUILD_ROOT%{_dlldir}
104 mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir}
105
106 %if 0%{!?debug:1}
107 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll
108 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
109 %endif
110
111 %clean
112 rm -rf $RPM_BUILD_ROOT
113
114 %files
115 %defattr(644,root,root,755)
116 %doc AUTHORS COPYING ChangeLog NEWS PATENTS README
117 %{_libdir}/libwebp.dll.a
118 %{_libdir}/libwebp.la
119 %{_libdir}/libwebpdemux.dll.a
120 %{_libdir}/libwebpdemux.la
121 %{_libdir}/libwebpmux.dll.a
122 %{_libdir}/libwebpmux.la
123 %{_includedir}/webp
124 %{_pkgconfigdir}/libwebp.pc
125 %{_pkgconfigdir}/libwebpdemux.pc
126 %{_pkgconfigdir}/libwebpmux.pc
127
128 %files static
129 %defattr(644,root,root,755)
130 %{_libdir}/libwebp.a
131 %{_libdir}/libwebpdemux.a
132 %{_libdir}/libwebpmux.a
133
134 %files dll
135 %defattr(644,root,root,755)
136 %{_dlldir}/libwebp-4.dll
137 %{_dlldir}/libwebpmux-0.dll
138 %{_dlldir}/libwebpdemux-0.dll
This page took 0.084602 seconds and 3 git commands to generate.