epel9
Sérgio Basto 10 years ago
parent f537fd3411
commit b02d2898b6

@ -1,20 +1,21 @@
%global libname libimagequant %global libname libimagequant
Name: pngquant Name: pngquant
Version: 2.3.4 Version: 2.4.0.1
Release: 1%{?dist} Release: 1%{?dist}
Summary: PNG quantization tool for reducing image file size Summary: PNG quantization tool for reducing image file size
%{?el5:Group: Applications/Multimedia} %{?el5:Group: Applications/Multimedia}
License: BSD with advertising License: BSD with advertising
URL: http://%{name}.org URL: http://%{name}.org
Source0: https://github.com/pornel/pngquant/archive/%{name}-%{version}.tar.gz Source0: http://github.srcurl.net/pornel/%{name}/%{version}/%{name}-%{version}.tar.gz
#Source0: https://github.com/pornel/%{name}/archive/%{name}-%{version}.tar.gz
Patch0: %{name}-2.3.2_fix-Makefile.patch Patch0: %{name}-2.4.0_fix-Makefile.patch
%{?el5:BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)} %{?el5:BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)}
BuildRequires: libpng-devel%{?_isa} >= 1.2.46-1 BuildRequires: libpng-devel%{?_isa} >= 1.2.46-1
BuildRequires: zlib-devel%{?_isa} >= 1.2.3-1 BuildRequires: zlib-devel%{?_isa} >= 1.2.3-1
BuildRequires: gcc%{?_isa} >= 4.2-1 BuildRequires: gcc%{?_isa} >= 4.2-1
@ -32,8 +33,8 @@ their 24/32-bit version. %{name} uses the median cut algorithm.
%package -n %{libname} %package -n %{libname}
Summary: Small, portable C lib for HQ conversion of RGBA to 8-bit indexed-color Summary: Small, portable C lib for HQ conversion of RGBA to 8-bit indexed-color
%{?el5:Group: System Environment/Libraries} %{?el5:Group: System Environment/Libraries}
%description -n %{libname} %description -n %{libname}
%{libname} converts 24/32-bit RGBA PNG images to 8-bit palette with alpha %{libname} converts 24/32-bit RGBA PNG images to 8-bit palette with alpha
@ -44,10 +45,10 @@ their 24/32-bit version. %{libname} uses the median cut algorithm.
%package -n %{libname}-devel %package -n %{libname}-devel
Summary: Development files for %{libname} Summary: Development files for %{libname}
%{?el5:Group: Development/Libraries} %{?el5:Group: Development/Libraries}
Requires: %{libname} = %{version}-%{release} Requires: %{libname} = %{version}-%{release}
%description -n %{libname}-devel %description -n %{libname}-devel
This package contains files for development with %{libname}. This package contains files for development with %{libname}.
@ -77,23 +78,23 @@ make %{?_smp_mflags} PREFIX=%{_prefix}
%{?el5:rm -rf %{buildroot}} %{?el5:rm -rf %{buildroot}}
mkdir -p %{buildroot}%{_includedir}/imagequant \ mkdir -p %{buildroot}%{_includedir}/imagequant \
%{buildroot}%{_bindir} \ %{buildroot}%{_bindir} \
%{buildroot}%{_libdir} \ %{buildroot}%{_libdir} \
%{buildroot}%{_mandir}/man1 %{buildroot}%{_mandir}/man1
make install DESTDIR=%{buildroot} PREFIX=%{_prefix} make install DESTDIR=%{buildroot} PREFIX=%{_prefix}
# install libimagequant # install libimagequant
install -pm 0755 lib/%{libname}.so.0 \ install -pm 0755 lib/%{libname}.so.0 \
%{buildroot}%{_libdir} %{buildroot}%{_libdir}
ln -fs %{_libdir}/%{libname}.so.0 \ ln -fs %{_libdir}/%{libname}.so.0 \
%{buildroot}%{_libdir}/%{libname}.so %{buildroot}%{_libdir}/%{libname}.so
install -pm 0644 lib/*.h \ install -pm 0644 lib/*.h \
%{buildroot}%{_includedir}/imagequant %{buildroot}%{_includedir}/imagequant
# install man-page for %%{name} # install man-page for %%{name}
install -pm 0644 %{name}.1 \ install -pm 0644 %{name}.1 \
%{buildroot}/%{_mandir}/man1/%{name}.1 %{buildroot}/%{_mandir}/man1/%{name}.1
mkdir -p %{buildroot}/%{_bindir} mkdir -p %{buildroot}/%{_bindir}
make install PREFIX=%{_prefix} DESTDIR=%{buildroot} make install PREFIX=%{_prefix} DESTDIR=%{buildroot}

Loading…
Cancel
Save