From 569c83b55de78fac4f23079707c6798e19faaea7 Mon Sep 17 00:00:00 2001 From: CentOS Buildsys Date: Mar 17 2013 13:47:28 +0000 Subject: import libpng12-1.2.50-3.el7.src.rpm --- diff --git a/.libpng12.metadata b/.libpng12.metadata new file mode 100644 index 0000000..4c7b1fc --- /dev/null +++ b/.libpng12.metadata @@ -0,0 +1 @@ +c4d1881a376836a45688446624fd5d834ea118f0 SOURCES/libpng-1.2.50.tar.bz2 diff --git a/README.md b/README.md deleted file mode 100644 index 0e7897f..0000000 --- a/README.md +++ /dev/null @@ -1,5 +0,0 @@ -The master branch has no content - -Look at the c7 branch if you are working with CentOS-7, or the c4/c5/c6 branch for CentOS-4, 5 or 6 - -If you find this file in a distro specific branch, it means that no content has been checked in yet diff --git a/SOURCES/libpng12-multilib.patch b/SOURCES/libpng12-multilib.patch new file mode 100644 index 0000000..be079f7 --- /dev/null +++ b/SOURCES/libpng12-multilib.patch @@ -0,0 +1,35 @@ +Use pkg-config to report libpng12 version and installation directories. + + +diff -Naur libpng-1.2.49.orig/scripts/libpng-config.in libpng-1.2.49/scripts/libpng-config.in +--- libpng-1.2.49.orig/scripts/libpng-config.in 2012-03-29 00:46:55.000000000 -0400 ++++ libpng-1.2.49/scripts/libpng-config.in 2012-08-01 15:03:50.564507346 -0400 +@@ -11,11 +11,11 @@ + + # Modeled after libxml-config. + +-version="@PNGLIB_VERSION@" +-prefix="@prefix@" +-exec_prefix="@exec_prefix@" +-libdir="@libdir@" +-includedir="@includedir@/libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@" ++version=`pkg-config --modversion libpng12` ++prefix=`pkg-config --variable prefix libpng12` ++exec_prefix=`pkg-config --variable exec_prefix libpng12` ++libdir=`pkg-config --variable libdir libpng12` ++includedir=`pkg-config --variable includedir libpng12` + libs="-lpng@PNGLIB_MAJOR@@PNGLIB_MINOR@" + all_libs="-lpng@PNGLIB_MAJOR@@PNGLIB_MINOR@ @LIBS@" + I_opts="-I${includedir}" +diff -Naur libpng-1.2.49.orig/scripts/libpng.pc-configure.in libpng-1.2.49/scripts/libpng.pc-configure.in +--- libpng-1.2.49.orig/scripts/libpng.pc-configure.in 2012-03-29 00:46:55.000000000 -0400 ++++ libpng-1.2.49/scripts/libpng.pc-configure.in 2012-08-01 15:04:37.817786337 -0400 +@@ -3,7 +3,7 @@ + libdir=@libdir@ + includedir=@includedir@/libpng@PNGLIB_MAJOR@@PNGLIB_MINOR@ + +-Name: libpng ++Name: libpng12 + Description: Loads and saves PNG files + Version: @PNGLIB_VERSION@ + Libs: -L${libdir} -lpng@PNGLIB_MAJOR@@PNGLIB_MINOR@ diff --git a/SOURCES/libpng12-pngconf.patch b/SOURCES/libpng12-pngconf.patch new file mode 100644 index 0000000..dbaadcb --- /dev/null +++ b/SOURCES/libpng12-pngconf.patch @@ -0,0 +1,42 @@ +diff -Naur libpng-1.2.29.orig/configure.ac libpng-1.2.29/configure.ac +--- libpng-1.2.29.orig/configure.ac 2008-05-08 07:58:11.000000000 -0400 ++++ libpng-1.2.29/configure.ac 2008-05-31 20:21:12.000000000 -0400 +@@ -63,7 +63,8 @@ + AC_MSG_CHECKING( + [if assembler code in pnggccrd.c can be compiled without PNG_NO_MMX_CODE]) + AC_TRY_COMPILE( +- [#include "$srcdir/pnggccrd.c"], ++ [#define PNG_CONFIGURE_LIBPNG ++ #include "$srcdir/pnggccrd.c"], + [return 0;], + AC_MSG_RESULT(yes) + LIBPNG_NO_MMX="", +diff -Naur libpng-1.2.29.orig/pngconf.h libpng-1.2.29/pngconf.h +--- libpng-1.2.29.orig/pngconf.h 2008-05-08 07:58:03.000000000 -0400 ++++ libpng-1.2.29/pngconf.h 2008-05-31 20:21:12.000000000 -0400 +@@ -35,6 +35,25 @@ + #ifdef HAVE_CONFIG_H + #include "config.h" + #endif ++#else ++/* pngconf.h is part of the exported API. When a libpng-using application ++ includes us, PNG_CONFIGURE_LIBPNG is of course not defined as we do not have ++ libpng's config.h available in this case. This means that we do not have the ++ defines added to config.h and the commandline by libpng's ./configure . ++ ++ For all defines from config.h not having them set is not a problem, however ++ ./configure also adds -DPNG_NO_ASSEMBLER_CODE to the CFLAGS when compiling ++ on a platform on which the MMX and SSE asm code in libpng is not supported. ++ ++ We do need this define as this define is used to determine whether or not ++ to define PNG_ASSEMBLER_CODE_SUPPORTED and other assembler related defines ++ and prototypes. PNG_ASSEMBLER_CODE_SUPPORTED in turn is used by applications ++ (ImageMagick for example) to determine whether or not they can use the asm ++ functions. Thus we need to define PNG_NO_ASSEMBLER_CODE here on platforms ++ on which the MMX and SSE asm code in libpng is not supported: */ ++#ifndef __i386__ /* change this if MMX/SSE become supported on x86_64! */ ++#define PNG_NO_ASSEMBLER_CODE ++#endif + #endif + + /* diff --git a/SPECS/libpng12.spec b/SPECS/libpng12.spec new file mode 100644 index 0000000..9921d2c --- /dev/null +++ b/SPECS/libpng12.spec @@ -0,0 +1,88 @@ +Summary: Old version of libpng, needed to run old binaries +Name: libpng12 +Version: 1.2.50 +Release: 3%{?dist} +License: zlib +Group: System Environment/Libraries +URL: http://www.libpng.org/pub/png/ + +# Obsolete old temporary packaging of libpng 1.2 +Obsoletes: libpng-compat <= 2:1.5.10 + +# Note: non-current tarballs get moved to the history/ subdirectory, +# so look there if you fail to retrieve the version you want +Source: ftp://ftp.simplesystems.org/pub/png/src/libpng-%{version}.tar.bz2 + +Patch0: libpng12-multilib.patch +Patch1: libpng12-pngconf.patch + +BuildRequires: zlib-devel, pkgconfig + +%description +The libpng12 package provides libpng 1.2, an older version of the libpng +library for manipulating PNG (Portable Network Graphics) image format files. +This version should be used only if you are unable to use the current +version of libpng. + +%package devel +Summary: Development files for libpng 1.2 +Group: Development/Libraries +Requires: %{name}%{?_isa} = %{version}-%{release} +Requires: zlib-devel%{?_isa} pkgconfig%{?_isa} +Conflicts: libpng-devel + +%description devel +The libpng12-devel package contains header files and documentation necessary +for developing programs using libpng12. + +%prep +%setup -q -n libpng-%{version} + +%patch0 -p1 +%patch1 -p1 + +%build +%configure +make %{?_smp_mflags} + +%install +make DESTDIR=$RPM_BUILD_ROOT install + +# We don't ship .la files. +rm -rf $RPM_BUILD_ROOT%{_libdir}/libpng.la +rm -rf $RPM_BUILD_ROOT%{_libdir}/libpng12.la +# We're not providing any static libraries, either. +rm -rf $RPM_BUILD_ROOT%{_libdir}/*.a +# Also drop man5 files, because these are in the base libpng package, +# which we don't want to conflict with. +rm -rf $RPM_BUILD_ROOT%{_mandir}/man5/* + +%post -p /sbin/ldconfig + +%postun -p /sbin/ldconfig + +%files +%doc *.txt example.c README TODO CHANGES LICENSE +%{_libdir}/libpng*.so.* + +%files devel +%{_bindir}/* +%{_includedir}/* +%{_libdir}/libpng*.so +%{_libdir}/pkgconfig/* +%{_mandir}/man3/* + +%changelog +* Thu Feb 14 2013 Fedora Release Engineering - 1.2.50-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Wed Aug 22 2012 Tom Lane 1.2.50-2 +- Remove unnecessary use of epoch +Related: #850628 + +* Fri Aug 3 2012 Tom Lane 1.2.50-1 +- Update to 1.2.50 (just on general principles) +- Add Obsoletes: libpng-compat + +* Wed Aug 1 2012 Tom Lane 1.2.49-1 +- Created from libpng