]> git.pld-linux.org Git - packages/crossmingw32-libpng.git/blob - crossmingw32-libpng.spec
- updated to 1.2.25
[packages/crossmingw32-libpng.git] / crossmingw32-libpng.spec
1 %define         realname        libpng
2 Summary:        PNG library - Mingw32 cross version
3 Summary(pl.UTF-8):      Biblioteka PNG - wersja skrośna dla Mingw32
4 Name:           crossmingw32-%{realname}
5 Version:        1.2.25
6 Release:        1
7 License:        distributable
8 Group:          Development/Libraries
9 Source0:        http://dl.sourceforge.net/libpng/%{realname}-%{version}.tar.lzma
10 # Source0-md5:  f340daef5a039ec6d25bddc9b3b91a52
11 Patch0:         %{realname}-pngminus.patch
12 Patch1:         %{realname}-opt.patch
13 Patch2:         %{realname}-revert.patch
14 Patch3:         %{realname}-norpath.patch
15 Patch4:         %{realname}-apng.patch
16 Patch5:         %{name}-shared.patch
17 URL:            http://www.libpng.org/pub/png/libpng.html
18 BuildRequires:  crossmingw32-gcc
19 BuildRequires:  crossmingw32-zlib
20 BuildRequires:  lzma >= 1:4.42
21 Requires:       crossmingw32-zlib
22 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
24 %define         no_install_post_strip   1
25
26 %define         target                  i386-mingw32
27 %define         target_platform         i386-pc-mingw32
28
29 %define         _sysprefix              /usr
30 %define         _prefix                 %{_sysprefix}/%{target}
31 %define         _libdir                 %{_prefix}/lib
32 %define         _pkgconfigdir           %{_prefix}/lib/pkgconfig
33 %define         _dlldir                 /usr/share/wine/windows/system
34 %define         __cc                    %{target}-gcc
35 %define         __cxx                   %{target}-g++
36
37 %ifarch alpha sparc sparc64 sparcv9
38 %define         optflags        -O2
39 %endif
40
41 %description
42 The PNG library is a collection of routines used to create and
43 manipulate PNG format graphics files. The PNG format was designed as a
44 replacement for GIF, with many improvements and extensions.
45
46 This package contains the cross version for Win32.
47
48 %description -l pl.UTF-8
49 Biblioteki PNG są kolekcją form używanych do tworzenia i manipulowania
50 plikami w formacie graficznym PNG. Format ten został stworzony jako
51 zamiennik dla formatu GIF, z wieloma rozszerzeniami i nowościami.
52
53 Ten pakiet zawiera wersję skrośną dla Win32.
54
55 %package static
56 Summary:        Static libpng library (cross mingw32 version)
57 Summary(pl.UTF-8):      Statyczna biblioteka libpng (wersja skrośna mingw32)
58 Group:          Development/Libraries
59 Requires:       %{name} = %{version}-%{release}
60
61 %description static
62 Static libpng library (cross mingw32 version).
63
64 %description static -l pl.UTF-8
65 Statyczna biblioteka libpng (wersja skrośna mingw32).
66
67 %package dll
68 Summary:        libpng - DLL library for Windows
69 Summary(pl.UTF-8):      libpng - biblioteka DLL dla Windows
70 Group:          Applications/Emulators
71 Requires:       crossmingw32-zlib-dll
72 Requires:       wine
73
74 %description dll
75 libpng - DLL library for Windows.
76
77 %description dll -l pl.UTF-8
78 libpng - biblioteka DLL dla Windows.
79
80 %prep
81 %setup -q -n %{realname}-%{version} -c -T
82 lzma -dc %{SOURCE0} | tar xf - -C ..
83 %patch0 -p1
84 %patch1 -p1
85 %patch2 -p1
86 %patch3 -p1
87 %patch4 -p0
88 %patch5 -p1
89
90 %build
91 %configure \
92         --target=%{target} \
93         --host=%{target} \
94         --with-pkgconfigdir=%{_pkgconfigdir}
95
96 %{__make}
97
98 %install
99 rm -rf $RPM_BUILD_ROOT
100
101 %{__make} install \
102         DESTDIR=$RPM_BUILD_ROOT
103
104 install -d $RPM_BUILD_ROOT%{_dlldir}
105 mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir}
106
107 %if 0%{!?debug:1}
108 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll
109 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
110 %endif
111
112 rm -rf $RPM_BUILD_ROOT%{_datadir}/man
113
114 %clean
115 rm -rf $RPM_BUILD_ROOT
116
117 %files
118 %defattr(644,root,root,755)
119 %{_libdir}/libpng.dll.a
120 %{_libdir}/libpng12.dll.a
121 %{_libdir}/libpng.la
122 %{_libdir}/libpng12.la
123 %dir %{_includedir}/libpng12
124 %{_includedir}/libpng12/*
125 %{_pkgconfigdir}/*.pc
126
127 %files static
128 %defattr(644,root,root,755)
129 %{_libdir}/libpng.a
130 %{_libdir}/libpng12.a
131
132 %files dll
133 %defattr(644,root,root,755)
134 %{_dlldir}/libpng-*.dll
135 %{_dlldir}/libpng12-*.dll
This page took 0.050774 seconds and 4 git commands to generate.