1 # NOTE: there is intel SSE optimization available but with no runtime detection;
2 # it's enabled based on compiler flags (-msse*, either explicit or implied by -march=)
5 %bcond_without tests # don't perform "make check"
6 %bcond_without default_libpng # don't use this libpng as default system libpng
9 Summary(de.UTF-8): PNG-Library
10 Summary(es.UTF-8): Biblioteca PNG
11 Summary(fr.UTF-8): Librarie PNG
12 Summary(pl.UTF-8): Biblioteka PNG
13 Summary(pt_BR.UTF-8): Biblioteca PNG
14 Summary(tr.UTF-8): PNG kitaplığı
19 License: distributable
21 Source0: http://downloads.sourceforge.net/libpng/%{name}-%{version}.tar.xz
22 # Source0-md5: 015e8e15db1eecde5f2eb9eb5b6e59e9
23 Patch0: http://downloads.sourceforge.net/libpng-apng/%{name}-%{version}-apng.patch.gz
24 # Patch0-md5: f02073fd96816b184c79b297775e37dc
25 Patch1: %{name}-pngminus.patch
26 Patch2: %{name}-drop-Llibdir.patch
27 URL: http://www.libpng.org/pub/png/libpng.html
28 BuildRequires: rpmbuild(macros) >= 1.213
29 BuildRequires: tar >= 1:1.22
30 BuildRequires: xz >= 1:4.999.7
31 BuildRequires: zlib-devel >= 1.2.9
32 Provides: libpng(APNG) = 0.10
33 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36 The PNG library is a collection of routines used to create and
37 manipulate PNG format graphics files. The PNG format was designed as a
38 replacement for GIF, with many improvements and extensions.
40 %description -l de.UTF-8
41 Die PNG-Library ist eine Sammlung von Routinen zum Erstellen und
42 Bearbeiten von Grafiken im PNG-Format. Das PNG-Format wurde als Ersatz
43 für GIF entwickelt und enthält viele Verbesserungen und Erweiterungen.
45 %description -l es.UTF-8
46 Esta biblioteca es una colección de rutinas para crear y manipular
47 archivos gráficos en el formato PNG. Este formato fue proyectado para
50 %description -l fr.UTF-8
51 La librairie PNG est un ensemble de routines utilisées pour créer et
52 manipuler des fichiers graphiques au format PNG. Le format PNG a été
53 élaboré pour remplacer le GIF, avec de nombreuses améliorations et
56 %description -l pl.UTF-8
57 Biblioteki PNG są kolekcją form używanych do tworzenia i manipulowania
58 plikami w formacie graficznym PNG. Format ten został stworzony jako
59 zamiennik dla formatu GIF, z wieloma rozszerzeniami i nowościami.
61 %description -l pt_BR.UTF-8
62 Esta biblioteca é uma coleção de rotinas para criar e manipular
63 arquivos gráficos no formato PNG. Este formato foi projetado para
64 substituir o formato GIF, com extensões e melhorias.
66 %description -l tr.UTF-8
67 PNG kitaplığı, PNG formatındaki resim dosyalarını işlemeye yönelik
68 yordamları içerir. PNG, GIF formatının yerini almak üzere tasarlanmış
72 Summary: Header files for libpng
73 Summary(de.UTF-8): libpng Headers
74 Summary(es.UTF-8): Archivos de inclusión y bibliotecas estáticas
75 Summary(fr.UTF-8): en-têtes et bibliothèques statiques
76 Summary(pl.UTF-8): Pliki nagłówkowe libpng
77 Summary(pt_BR.UTF-8): Arquivos de inclusão e bibliotecas estáticas
78 Summary(tr.UTF-8): başlık dosyaları ve statik kitaplıklar
79 Group: Development/Libraries
80 Requires: %{name} = %{epoch}:%{version}-%{release}
82 Provides: libpng(APNG)-devel = 0.10
83 Conflicts: libpng < 1.0.15
86 The header files are only needed for development of programs using the
89 %description devel -l de.UTF-8
90 Die Header-Dateien werden nur zur Entwicklung von Programmen mit der
93 %description devel -l es.UTF-8
94 Archivos de inclusión y bibliotecas estáticas que son necesarios
95 solamente para el desarrollo de programas que usan la biblioteca PNG.
97 %description devel -l fr.UTF-8
98 Fichiers d'en-tete et les librairies qui sont requis seulement pour le
99 développement avec la librairie PNG.
101 %description devel -l pl.UTF-8
102 W pakiecie tym znajdują się pliki nagłówkowe, przeznaczone dla
103 programistów używających bibliotek PNG.
105 %description devel -l pt_BR.UTF-8
106 Arquivos de inclusão e bibliotecas estáticas que são necessários
107 somente para o desenvolvimento de programas que usam a biblioteca PNG.
109 %description devel -l tr.UTF-8
110 PNG kitaplığını kullanan programlar geliştirmek için gereken
111 kitaplıklar ve başlık dosyaları.
114 Summary: Static PNG library
115 Summary(de.UTF-8): Statisch PNG Library
116 Summary(pl.UTF-8): Biblioteka statyczna PNG
117 Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com libpng
118 Group: Development/Libraries
119 Requires: %{name}-devel = %{epoch}:%{version}-%{release}
120 Provides: libpng(APNG)-static = 0.10
125 %description static -l de.UTF-8
126 Statisch PNG Library.
128 %description static -l pl.UTF-8
129 Biblioteka statyczna PNG.
131 %description static -l pt_BR.UTF-8
132 Bibliotecas estáticas para desenvolvimento com libpng.
135 Summary: libpng utility programs
136 Summary(pl.UTF-8): Narzędzia do plików PNG
137 Group: Applications/Graphics
138 Requires: %{name} = %{epoch}:%{version}-%{release}
141 This package contains utility programs to convert PNG files to and
144 %description progs -l pl.UTF-8
145 Narzędzia do konwersji plików PNG z lub do plików PNM.
155 %ifarch %{arm} aarch64
156 --enable-arm-neon=check \
158 %ifarch mipsel mips64el
159 --enable-mips-msa=check \
162 --enable-powerpc-vsx=check
167 %{__make} -C contrib/pngminus \
170 OPT_FLAGS="%{rpmcppflags} %{rpmcflags}"
172 %{?with_tests:%{__make} -j1 check}
175 rm -rf $RPM_BUILD_ROOT
176 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
179 DESTDIR=$RPM_BUILD_ROOT
181 install contrib/pngminus/{png2pnm,pnm2png} $RPM_BUILD_ROOT%{_bindir}
182 install example.c $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
184 %if %{without default_libpng}
185 %{__rm} $RPM_BUILD_ROOT%{_bindir}/{libpng-config,pn?2pn?} \
186 $RPM_BUILD_ROOT%{_libdir}/libpng.{so,la,a} \
187 $RPM_BUILD_ROOT%{_includedir}/png*.h \
188 $RPM_BUILD_ROOT%{_pkgconfigdir}/libpng.pc \
189 $RPM_BUILD_ROOT%{_mandir}/man[35]/*png*
193 rm -rf $RPM_BUILD_ROOT
195 %post -p /sbin/ldconfig
196 %postun -p /sbin/ldconfig
199 %defattr(644,root,root,755)
200 %doc ANNOUNCE CHANGES LICENSE README TODO
201 %attr(755,root,root) %{_libdir}/libpng16.so.*.*.*
202 %attr(755,root,root) %ghost %{_libdir}/libpng16.so.16
205 %defattr(644,root,root,755)
206 %doc libpng-manual.txt
207 %attr(755,root,root) %{_bindir}/libpng16-config
208 %attr(755,root,root) %{_libdir}/libpng16.so
209 %{_libdir}/libpng16.la
210 %{_includedir}/libpng16
211 %{_pkgconfigdir}/libpng16.pc
212 %{_examplesdir}/%{name}-%{version}
213 %if %{with default_libpng}
214 %attr(755,root,root) %{_bindir}/libpng-config
215 %attr(755,root,root) %{_libdir}/libpng.so
217 %{_pkgconfigdir}/libpng.pc
218 %{_includedir}/png*.h
219 %{_mandir}/man3/libpng.3*
220 %{_mandir}/man3/libpngpf.3*
221 %{_mandir}/man5/png.5*
225 %defattr(644,root,root,755)
226 %{_libdir}/libpng16.a
227 %if %{with default_libpng}
231 %if %{with default_libpng}
233 %defattr(644,root,root,755)
234 %attr(755,root,root) %{_bindir}/png2pnm
235 %attr(755,root,root) %{_bindir}/pngfix
236 %attr(755,root,root) %{_bindir}/png-fix-itxt
237 %attr(755,root,root) %{_bindir}/pnm2png