libpng: Move libpng-compat package into own build file.

Fixes #10521.
This commit is contained in:
Stefan Schantl 2014-04-22 20:36:06 +02:00
parent aab9fcba44
commit 98456149ee
2 changed files with 62 additions and 35 deletions

View File

@ -0,0 +1,61 @@
###############################################################################
# IPFire.org - An Open Source Firewall Solution #
# Copyright (C) - IPFire Development Team <info@ipfire.org> #
###############################################################################
name = compat-libpng
version = 1.5.18
release = 1
thisapp = libpng-%{version}
groups = System/Libraries
url = http://www.libpng.org/pub/png/
license = zlib
summary = A library of functions for manipulating PNG image format files.
description
The libpng package contains a library of functions for creating and
manipulating PNG (Portable Network Graphics) image format files.
PNG is a bit-mapped graphics format similar to the GIF format. PNG
was created to replace the GIF format, since GIF uses a patented
data compression algorithm.
end
source_dl += http://downloads.sourceforge.net/project/libpng/libpng15/%{version}/
source_dl += http://downloads.sourceforge.net/project/libpng/history/libpng15/%{version}/
sources = %{thisapp}.tar.xz
build
requires
pkg-config
zlib-devel
end
install
# Install just the library and no headers.
mkdir -pv %{BUILDROOT}%{libdir}
install -m 755 .libs/libpng15.so.15.18.0 %{BUILDROOT}%{libdir}
ln -svf libpng15.so.15.18.0 %{BUILDROOT}%{libdir}/libpng15.so.15
end
end
packages
package %{name}
provides
libpng = %{thisver}
end
obsoletes
libpng-compat
end
conflicts
libpng <= %{thisver}
end
end
package %{name}-debuginfo
template DEBUGINFO
end
end

View File

@ -5,9 +5,7 @@
name = libpng
version = 1.6.10
release = 1
compat_ver = 1.5.17
release = 2
groups = System/Libraries
url = http://www.libpng.org/pub/png/
@ -25,35 +23,11 @@ end
source_dl = http://downloads.sourceforge.net/project/libpng/libpng16/%{version}/
source_dl += http://downloads.sourceforge.net/project/libpng/history/libpng16/%{version}/
# Source URL for comat package.
source_dl += http://downloads.sourceforge.net/project/libpng/libpng15/%{compat_ver}/
source_dl += http://downloads.sourceforge.net/project/libpng/history/libpng15/%{compat_ver}/
sources = %{thisapp}.tar.xz
# File for compat package.
sources += %{name}-%{compat_ver}.tar.xz
build
requires
pkg-config
zlib-devel
end
# Build compat package.
build_cmds
cd %{DIR_SRC}/%{name}-%{compat_ver}
./configure %{configure_options}
make %{PARALLELISMFLAGS}
end
# Install compat package.
install_cmds
cd %{DIR_SRC}/%{name}-%{compat_ver}
install -m 755 .libs/libpng15.so.15.17.0 %{BUILDROOT}%{libdir}
ln -svf libpng15.so.15.17.0 %{BUILDROOT}%{libdir}/libpng15.so.15
end
end
packages
@ -65,14 +39,6 @@ packages
requires = zlib-devel
end
package %{name}-compat
summary = Compat libraries of %{thisapp}.
files
%{libdir}/%{name}15.so*
end
end
package %{name}-debuginfo
template DEBUGINFO
end