rpms/libpng10/devel libpng-1.0.20-pngconf.patch, NONE, 1.1 libpng-1.0.20-soname.patch, NONE, 1.1 libpng10.spec, 1.2, 1.3 libpng-1.0.20-rhconf.patch, 1.1, NONE

Paul Howarth (pghmcfc) fedora-extras-commits at redhat.com
Wed Aug 2 07:18:24 UTC 2006


Author: pghmcfc

Update of /cvs/extras/rpms/libpng10/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv29966/devel

Modified Files:
	libpng10.spec 
Added Files:
	libpng-1.0.20-pngconf.patch libpng-1.0.20-soname.patch 
Removed Files:
	libpng-1.0.20-rhconf.patch 
Log Message:
auto-import libpng10-1.0.20-3 on branch devel from libpng10-1.0.20-3.src.rpm

libpng-1.0.20-pngconf.patch:

--- NEW FILE libpng-1.0.20-pngconf.patch ---
--- libpng-1.0.20/configure.ac	2006-08-01 14:37:36.000000000 +0100
+++ libpng-1.0.20/configure.ac	2006-08-01 14:38:43.000000000 +0100
@@ -60,7 +60,8 @@
 
 AC_MSG_CHECKING([if assembler code in pnggccrd.c can be compiled])
 AC_TRY_COMPILE(
-  [#include "pnggccrd.c"],
+  [#define PNG_CONFIGURE_LIBPNG
+   #include "pnggccrd.c"],
   [return 0;],
   LIBPNG_DEFINES=,
   LIBPNG_DEFINES=-DPNG_CONFIGURE_LIBPNG\ -DPNG_NO_ASSEMBLER_CODE)
--- libpng-1.0.20/configure	2006-08-01 14:44:04.000000000 +0100
+++ libpng-1.0.20/configure	2006-08-01 14:44:51.000000000 +0100
@@ -20149,6 +20149,7 @@
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
+#define PNG_CONFIGURE_LIBPNG
 #include "pnggccrd.c"
 int
 main ()
--- libpng-1.0.20/pngconf.h	2006-08-01 14:39:27.000000000 +0100
+++ libpng-1.0.20/pngconf.h	2006-08-01 14:43:34.000000000 +0100
@@ -29,6 +29,26 @@
 #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 command line by libpng's configure script.
+   
+   For all defines from config.h, not having them set is not a problem.
+   However, the configure script 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 wether 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
 
 /*

libpng-1.0.20-soname.patch:

--- NEW FILE libpng-1.0.20-soname.patch ---
--- libpng-1.0.20/ltmain.sh	2006-08-01 15:46:17.000000000 +0100
+++ libpng-1.0.20/ltmain.sh	2006-08-01 15:46:52.000000000 +0100
@@ -3270,7 +3270,7 @@
 	esac
 
 	case $revision in
-	0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
+	0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]|[0-9].[0-9][0-9]) ;;
 	*)
 	  $echo "$modename: REVISION \`$revision' must be a nonnegative integer" 1>&2
 	  $echo "$modename: \`$vinfo' is not valid version information" 1>&2
--- libpng-1.0.20/Makefile.am	2006-06-27 21:20:58.000000000 +0100
+++ libpng-1.0.20/Makefile.am	2006-08-01 16:03:14.000000000 +0100
@@ -45,7 +45,7 @@
 	-version-number 0:@PNGLIB_MINOR@:0
 # -rpath is needed as automake doesn't know the directory
 libpng_la_LDFLAGS = -rpath '$(libdir)' -no-undefined -export-dynamic \
-	-version-number 3:@PNGLIB_MINOR@:0
+	-version-number 2:1:0. at PNGLIB_MINOR@
 
 if HAVE_LD_VERSION_SCRIPT
   # Versioned symbols and restricted exports
--- libpng-1.0.20/Makefile.in	2006-06-27 21:21:15.000000000 +0100
+++ libpng-1.0.20/Makefile.in	2006-08-01 16:04:16.000000000 +0100
@@ -291,7 +291,7 @@
 	0:@PNGLIB_MINOR@:0 $(am__append_1) $(am__append_2)
 # -rpath is needed as automake doesn't know the directory
 libpng_la_LDFLAGS = -rpath '$(libdir)' -no-undefined -export-dynamic \
-	-version-number 3:@PNGLIB_MINOR@:0
+	-version-number 2:1:0. at PNGLIB_MINOR@
 
 @HAVE_LD_VERSION_SCRIPT_FALSE at libpng10_la_DEPENDENCIES = libpng.sym
 @HAVE_LD_VERSION_SCRIPT_TRUE at libpng10_la_DEPENDENCIES = libpng.vers


Index: libpng10.spec
===================================================================
RCS file: /cvs/extras/rpms/libpng10/devel/libpng10.spec,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- libpng10.spec	20 Jul 2006 14:56:37 -0000	1.2
+++ libpng10.spec	2 Aug 2006 07:18:24 -0000	1.3
@@ -1,12 +1,13 @@
 Summary:	Old version of libpng, needed to run old binaries
 Name:		libpng10
 Version:	1.0.20
-Release:	2%{?dist}
+Release:	3%{?dist}
 License:	zlib License
 Group:		System Environment/Libraries
 URL:		http://www.libpng.org/pub/png/libpng.html
 Source:		ftp://ftp.simplesystems.org/pub/libpng/png/src/libpng-%{version}.tar.bz2
-Patch0:		libpng-1.0.20-rhconf.patch
+Patch0:		libpng-1.0.20-soname.patch
+Patch1:		libpng-1.0.20-pngconf.patch
 Buildroot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:	zlib-devel
 Conflicts:	libpng < 2:1.2.0
@@ -34,16 +35,19 @@
 
 %prep
 %setup -q -n libpng-%{version}
-%{__ln_s} scripts/makefile.linux Makefile
-%patch0 -p1 -b .rhconf
+%patch0 -p1 -b .soname
+%patch1 -p1 -b .pngconf
 
 %build
-# Appears to break if %{?_smp_mflags} is used
-%{__make} RPM_OPT_FLAGS="%{optflags}" LIBPATH=%{_libdir}
+%configure \
+	--disable-static \
+	--disable-dependency-tracking \
+	--without-binconfigs
+%{__make} %{?_smp_mflags}
 
 %install
 %{__rm} -rf %{buildroot}
-%{__make} DESTDIR=%{buildroot} LIBPATH=%{_libdir} install
+%{__make} DESTDIR=%{buildroot} install
 
 # Install docs
 # This is done manually so that the docs, which are all in the same directory,
@@ -60,6 +64,25 @@
 %{__install} -p -m 644 example.c libpng.txt \
 	%{buildroot}%{_docdir}/%{name}-%{version}/
 
+# Unpackaged files
+%{__rm} -f \
+	%{buildroot}%{_bindir}/libpng-config \
+	%{buildroot}%{_includedir}/png.h \
+	%{buildroot}%{_includedir}/pngconf.h \
+	%{buildroot}%{_libdir}/libpng.a \
+	%{buildroot}%{_libdir}/libpng.la \
+	%{buildroot}%{_libdir}/libpng.so \
+	%{buildroot}%{_libdir}/libpng10.la \
+	%{buildroot}%{_libdir}/libpng10.so.* \
+	%{buildroot}%{_libdir}/pkgconfig/libpng.pc \
+	%{buildroot}%{_mandir}/man3/libpng.3 \
+	%{buildroot}%{_mandir}/man3/libpngpf.3 \
+	%{buildroot}%{_mandir}/man5/png.5
+
+# Fix devel link
+%{__rm} -f %{buildroot}%{_libdir}/libpng10.so
+%{__ln_s} libpng.so.2 %{buildroot}%{_libdir}/libpng10.so
+
 %clean
 %{__rm} -rf %{buildroot}
 
@@ -85,6 +108,10 @@
 %{_libdir}/pkgconfig/libpng10.pc
 
 %changelog
+* Tue Aug  1 2006 Paul Howarth <paul at city-fan.org> 1.0.20-3
+- reenable %%{_smp_mflags}
+- use patched configure script rather than old Makefiles
+
 * Thu Jul 20 2006 Paul Howarth <paul at city-fan.org> 1.0.20-2
 - don't use %%{_smp_mflags}
 


--- libpng-1.0.20-rhconf.patch DELETED ---




More information about the fedora-extras-commits mailing list