]>
Commit | Line | Data |
---|---|---|
13d93324 | 1 | # NOTE: try to switch to ac/am/lt build on 1.2.x->1.4.x upgrade |
cf8258c6 | 2 | # TODO: update apng.patch when possible |
714c2522 | 3 | Summary: PNG library |
c09c3034 ER |
4 | Summary(de.UTF-8): PNG-Library |
5 | Summary(es.UTF-8): Biblioteca PNG | |
6 | Summary(fr.UTF-8): Librarie PNG | |
7 | Summary(pl.UTF-8): Biblioteka PNG | |
8 | Summary(pt_BR.UTF-8): Biblioteca PNG | |
9 | Summary(tr.UTF-8): PNG kitaplığı | |
714c2522 | 10 | Name: libpng |
cf8258c6 | 11 | Version: 1.2.41 |
580fd6fc | 12 | Release: 1 |
62e09fb4 | 13 | Epoch: 2 |
1b0fd02b | 14 | License: distributable |
714c2522 | 15 | Group: Libraries |
589651e6 | 16 | Source0: http://dl.sourceforge.net/libpng/%{name}-%{version}.tar.xz |
cf8258c6 | 17 | # Source0-md5: 5aca52d472cb53035a7424f5ce3650ef |
e65334f7 | 18 | Patch0: %{name}-pngminus.patch |
44788aa3 | 19 | Patch1: %{name}-opt.patch |
45020d74 | 20 | Patch2: %{name}-norpath.patch |
610263cf AG |
21 | Patch3: %{name}-export_old.patch |
22 | Patch4: %{name}-revert.patch | |
2da42a2c ER |
23 | # http://littlesvr.ca/apng/ |
24 | Patch5: %{name}-apng.patch | |
bd250172 | 25 | URL: http://www.libpng.org/pub/png/libpng.html |
c4b2207e | 26 | BuildRequires: rpmbuild(macros) >= 1.213 |
df9cfb27 | 27 | BuildRequires: xz >= 1:4.999.7 |
a65a9a74 | 28 | BuildRequires: zlib-devel |
c4b2207e | 29 | %ifarch %{x8664} ia64 ppc64 s390x sparc64 |
bdcad10b JB |
30 | Provides: libpng.so.3()(64bit) |
31 | %else | |
d5026e25 | 32 | Provides: libpng.so.3 |
bdcad10b | 33 | %endif |
2da42a2c | 34 | Provides: libpng(APNG) = 0.10 |
7f0d4dbb | 35 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
6b867543 | 36 | |
37 | %description | |
72f15a65 | 38 | The PNG library is a collection of routines used to create and |
39 | manipulate PNG format graphics files. The PNG format was designed as a | |
40 | replacement for GIF, with many improvements and extensions. | |
6b867543 | 41 | |
2bdf363b | 42 | %description -l de.UTF-8 |
72f15a65 | 43 | Die PNG-Library ist eine Sammlung von Routinen zum Erstellen und |
44 | Bearbeiten von Grafiken im PNG-Format. Das PNG-Format wurde als Ersatz | |
2bdf363b | 45 | für GIF entwickelt und enthält viele Verbesserungen und Erweiterungen. |
fe532919 | 46 | |
2bdf363b JR |
47 | %description -l es.UTF-8 |
48 | Esta biblioteca es una colección de rutinas para crear y manipular | |
49 | archivos gráficos en el formato PNG. Este formato fue proyectado para | |
0fc3dbd2 | 50 | substituir el |
51 | ||
2bdf363b JR |
52 | %description -l fr.UTF-8 |
53 | La librairie PNG est un ensemble de routines utilisées pour créer et | |
54 | manipuler des fichiers graphiques au format PNG. Le format PNG a été | |
55 | élaboré pour remplacer le GIF, avec de nombreuses améliorations et | |
fe532919 | 56 | extensions. |
57 | ||
2bdf363b JR |
58 | %description -l pl.UTF-8 |
59 | Biblioteki PNG są kolekcją form używanych do tworzenia i manipulowania | |
60 | plikami w formacie graficznym PNG. Format ten został stworzony jako | |
61 | zamiennik dla formatu GIF, z wieloma rozszerzeniami i nowościami. | |
4ef53418 | 62 | |
2bdf363b JR |
63 | %description -l pt_BR.UTF-8 |
64 | Esta biblioteca é uma coleção de rotinas para criar e manipular | |
65 | arquivos gráficos no formato PNG. Este formato foi projetado para | |
66 | substituir o formato GIF, com extensões e melhorias. | |
0fc3dbd2 | 67 | |
2bdf363b JR |
68 | %description -l tr.UTF-8 |
69 | PNG kitaplığı, PNG formatındaki resim dosyalarını işlemeye yönelik | |
70 | yordamları içerir. PNG, GIF formatının yerini almak üzere tasarlanmış | |
71 | bir resim formatıdır. | |
fe532919 | 72 | |
6b867543 | 73 | %package devel |
4ef53418 | 74 | Summary: Header files for libpng |
c09c3034 ER |
75 | Summary(de.UTF-8): libpng Headers |
76 | Summary(es.UTF-8): Archivos de inclusión y bibliotecas estáticas | |
77 | Summary(fr.UTF-8): en-têtes et bibliothèques statiques | |
78 | Summary(pl.UTF-8): Pliki nagłówkowe libpng | |
79 | Summary(pt_BR.UTF-8): Arquivos de inclusão e bibliotecas estáticas | |
80 | Summary(tr.UTF-8): başlık dosyaları ve statik kitaplıklar | |
714c2522 | 81 | Group: Development/Libraries |
6fc2747d | 82 | Requires: %{name} = %{epoch}:%{version}-%{release} |
9b72b791 | 83 | Requires: zlib-devel |
2da42a2c | 84 | Provides: libpng(APNG)-devel = 0.10 |
2cfb55ca | 85 | Conflicts: libpng < 1.0.15 |
6b867543 | 86 | |
87 | %description devel | |
4ef53418 JB |
88 | The header files are only needed for development of programs using the |
89 | PNG library. | |
6b867543 | 90 | |
2bdf363b | 91 | %description devel -l de.UTF-8 |
4ef53418 | 92 | Die Header-Dateien werden nur zur Entwicklung von Programmen mit der |
2bdf363b | 93 | PNG-Library benötigt. |
6b867543 | 94 | |
2bdf363b JR |
95 | %description devel -l es.UTF-8 |
96 | Archivos de inclusión y bibliotecas estáticas que son necesarios | |
0fc3dbd2 | 97 | solamente para el desarrollo de programas que usan la biblioteca PNG. |
98 | ||
2bdf363b | 99 | %description devel -l fr.UTF-8 |
72f15a65 | 100 | Fichiers d'en-tete et les librairies qui sont requis seulement pour le |
2bdf363b | 101 | développement avec la librairie PNG. |
6b867543 | 102 | |
2bdf363b JR |
103 | %description devel -l pl.UTF-8 |
104 | W pakiecie tym znajdują się pliki nagłówkowe, przeznaczone dla | |
105 | programistów używających bibliotek PNG. | |
0fc3dbd2 | 106 | |
2bdf363b JR |
107 | %description devel -l pt_BR.UTF-8 |
108 | Arquivos de inclusão e bibliotecas estáticas que são necessários | |
0fc3dbd2 | 109 | somente para o desenvolvimento de programas que usam a biblioteca PNG. |
110 | ||
2bdf363b JR |
111 | %description devel -l tr.UTF-8 |
112 | PNG kitaplığını kullanan programlar geliştirmek için gereken | |
113 | kitaplıklar ve başlık dosyaları. | |
6b867543 | 114 | |
c381bb48 | 115 | %package static |
4ef53418 | 116 | Summary: Static PNG libraries |
c09c3034 ER |
117 | Summary(de.UTF-8): Statischen PNG Libraries |
118 | Summary(pl.UTF-8): Biblioteki statyczne PNG | |
119 | Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com libpng | |
714c2522 | 120 | Group: Development/Libraries |
6fc2747d | 121 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
2da42a2c | 122 | Provides: libpng(APNG)-static = 0.10 |
6b867543 | 123 | |
124 | %description static | |
4ef53418 JB |
125 | Static PNG libraries. |
126 | ||
2bdf363b | 127 | %description static -l de.UTF-8 |
4ef53418 | 128 | Statischen PNG Libraries. |
6b867543 | 129 | |
2bdf363b | 130 | %description static -l pl.UTF-8 |
4ef53418 | 131 | Biblioteki statyczne PNG. |
6b867543 | 132 | |
2bdf363b JR |
133 | %description static -l pt_BR.UTF-8 |
134 | Bibliotecas estáticas para desenvolvimento com libpng. | |
0fc3dbd2 | 135 | |
0f88fd3d | 136 | %package progs |
137 | Summary: libpng utility programs | |
c09c3034 | 138 | Summary(pl.UTF-8): Narzędzia do plików PNG |
0f88fd3d | 139 | Group: Applications/Graphics |
3591ed11 | 140 | Requires: %{name} = %{epoch}:%{version}-%{release} |
0f88fd3d | 141 | |
142 | %description progs | |
d6af8901 JB |
143 | This package contains utility programs to convert PNG files to and |
144 | from PNM files. | |
0f88fd3d | 145 | |
2bdf363b JR |
146 | %description progs -l pl.UTF-8 |
147 | Narzędzia do konwersji plików PNG z lub do plików PNM. | |
c381bb48 | 148 | |
6b867543 | 149 | %prep |
be9d35ce | 150 | %setup -q -c -T |
df9cfb27 | 151 | xzcat -dc %{SOURCE0} | tar xf - -C .. |
133d32e3 | 152 | %patch0 -p1 |
0f88fd3d | 153 | %patch1 -p1 |
4ef53418 | 154 | %patch2 -p1 |
fd2c7e5b | 155 | %patch3 -p1 |
c42ebfd2 | 156 | %patch4 -p1 |
870010ec | 157 | %patch5 -p0 |
0f88fd3d | 158 | |
b6e14c4c | 159 | %ifarch %{ix86} |
88cd7cec | 160 | ln -sf scripts/makefile.gcmmx ./Makefile |
b6e14c4c AF |
161 | %else |
162 | ln -sf scripts/makefile.linux ./Makefile | |
163 | %endif | |
6b867543 | 164 | |
165 | %build | |
e75b4e8f | 166 | %{__make} \ |
88882d70 | 167 | prefix=%{_prefix} \ |
2dabdc19 | 168 | LIBPATH=%{_libdir} \ |
24540946 | 169 | CC="%{__cc}" \ |
3fe537bd | 170 | %ifarch %{x8664} sparc sparcv9 sparc64 |
b6a18c3b JB |
171 | OPT_FLAGS="%{rpmcflags} -DPNG_NO_MMX_CODE" |
172 | %else | |
e75b4e8f | 173 | OPT_FLAGS="%{rpmcflags}" |
b6a18c3b | 174 | %endif |
0b50ec85 | 175 | |
e75b4e8f | 176 | %{__make} -C contrib/pngminus -f makefile.std \ |
2dabdc19 | 177 | LIBPATH=%{_libdir} \ |
24540946 | 178 | CC="%{__cc}" \ |
e75b4e8f | 179 | OPT_FLAGS="%{rpmcflags}" |
6b867543 | 180 | |
181 | %install | |
182 | rm -rf $RPM_BUILD_ROOT | |
d5026e25 | 183 | install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir},%{_mandir}/man{3,5}} \ |
184 | $RPM_BUILD_ROOT{%{_pkgconfigdir},%{_examplesdir}/%{name}-%{version}} | |
6b867543 | 185 | |
e75b4e8f | 186 | %{__make} install \ |
83a00d5e JB |
187 | DESTDIR=$RPM_BUILD_ROOT \ |
188 | prefix=%{_prefix} \ | |
2dabdc19 | 189 | LIBPATH=%{_libdir} \ |
83a00d5e | 190 | MANPATH=%{_mandir} |
6b867543 | 191 | |
0f88fd3d | 192 | install contrib/pngminus/{png2pnm,pnm2png} $RPM_BUILD_ROOT%{_bindir} |
d5026e25 | 193 | install example.c $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} |
6b867543 | 194 | |
83a00d5e JB |
195 | %clean |
196 | rm -rf $RPM_BUILD_ROOT | |
332660b0 | 197 | |
198 | %post -p /sbin/ldconfig | |
6b867543 | 199 | %postun -p /sbin/ldconfig |
200 | ||
201 | %files | |
e987a93d | 202 | %defattr(644,root,root,755) |
a3f859a9 | 203 | %doc ANNOUNCE CHANGES KNOWNBUG README LICENSE |
fa2428a4 JB |
204 | %attr(755,root,root) %{_libdir}/libpng12.so.*.*.* |
205 | %attr(755,root,root) %{_libdir}/libpng.so.*.*.* | |
206 | %attr(755,root,root) %ghost %{_libdir}/libpng12.so.0 | |
2a3ff70c JB |
207 | # alternative soname (symlink in PLD, so must be packaged) |
208 | %attr(755,root,root) %{_libdir}/libpng.so.3 | |
6b867543 | 209 | |
210 | %files devel | |
969c9518 | 211 | %defattr(644,root,root,755) |
a65a9a74 | 212 | %doc *.txt |
fa2428a4 JB |
213 | %attr(755,root,root) %{_bindir}/libpng12-config |
214 | %attr(755,root,root) %{_bindir}/libpng-config | |
215 | %attr(755,root,root) %{_libdir}/libpng12.so | |
216 | %attr(755,root,root) %{_libdir}/libpng.so | |
217 | %{_pkgconfigdir}/libpng12.pc | |
218 | %{_pkgconfigdir}/libpng.pc | |
219 | %{_includedir}/libpng12 | |
220 | %{_includedir}/libpng | |
221 | %{_includedir}/png*.h | |
2e406028 | 222 | %{_mandir}/man?/* |
d5026e25 | 223 | %{_examplesdir}/%{name}-%{version} |
6b867543 | 224 | |
225 | %files static | |
e987a93d | 226 | %defattr(644,root,root,755) |
fa2428a4 JB |
227 | %{_libdir}/libpng12.a |
228 | %{_libdir}/libpng.a | |
0f88fd3d | 229 | |
230 | %files progs | |
231 | %defattr(644,root,root,755) | |
83a00d5e | 232 | %attr(755,root,root) %{_bindir}/p* |