packages: libharu/libharu.spec, libharu/libharu-libdir.patch (NEW), libharu...

qboosh qboosh at pld-linux.org
Sun Nov 20 09:49:57 CET 2011


Author: qboosh                       Date: Sun Nov 20 08:49:57 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- new Source URL, updated to 2.2.1 (note: new soname)
- removed obsolete destdir patch (upstream switched to autotools, resolving such problems)
- added libdir patch to kill unnecessary -L/usr/lib and unify libpng linking
- added -static; .la file is needed to specify library dependencies

---- Files affected:
packages/libharu:
   libharu.spec (1.3 -> 1.4) , libharu-libdir.patch (NONE -> 1.1)  (NEW), libharu-destdir.patch (1.1 -> NONE)  (REMOVED)

---- Diffs:

================================================================
Index: packages/libharu/libharu.spec
diff -u packages/libharu/libharu.spec:1.3 packages/libharu/libharu.spec:1.4
--- packages/libharu/libharu.spec:1.3	Thu Jan 28 20:55:52 2010
+++ packages/libharu/libharu.spec	Sun Nov 20 09:49:51 2011
@@ -1,21 +1,19 @@
 # $Revision$, $Date$
-#
-# Conditional build:
-%bcond_without	apidocs		# do not build and package API docs
-#
-%define ver	%(echo %{version} | tr . _)
-Summary:	library for generating PDF documents
-Summary(pl.UTF-8):	biblioteka do generowania dokumentów PDF
+Summary:	Library for generating PDF documents
+Summary(pl.UTF-8):	Biblioteka do generowania dokumentów PDF
 Name:		libharu
-Version:	2.0.8
-Release:	3
-License:	distributable
+Version:	2.2.1
+Release:	1
+License:	MIT-like
 Group:		Libraries
-Source0:	http://dl.sourceforge.net/libharu/%{name}_%{ver}.tgz
-# Source0-md5:	4b9714fd89b4134b0b9c93f857add327
-Patch0:		%{name}-destdir.patch
+Source0:	http://libharu.org/files/%{name}-%{version}.tar.bz2
+# Source0-md5:	4febd7e677b1c5d54db59a608b84e79f
+Patch0:		%{name}-libdir.patch
 URL:		http://libharu.org/
+BuildRequires:	autoconf >= 2.60
+BuildRequires:	automake
 BuildRequires:	libpng-devel
+BuildRequires:	libtool
 BuildRequires:	zlib-devel
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -48,39 +46,49 @@
 - wsparcie dla czcionek i kodowań znaków CJK.
 
 %package devel
-Summary:	Header files for haru library
-Summary(pl.UTF-8):	Pliki nagłówkowe biblioteki haru
+Summary:	Header files for Haru PDF library
+Summary(pl.UTF-8):	Pliki nagłówkowe biblioteki Haru PDF
 Group:		Development/Libraries
 Requires:	%{name} = %{version}-%{release}
 
 %description devel
-Header files for haru library.
+Header files for Haru PDF library.
 
 %description devel -l pl.UTF-8
-Pliki nagłówkowe biblioteki haru.
+Pliki nagłówkowe biblioteki Haru PDF.
+
+%package static
+Summary:	Static Haru PDF library
+Summary(pl.UTF-8):	Statyczna biblioteka Haru PDF
+Group:		Development/Libraries
+Requires:	%{name}-devel = %{version}-%{release}
+
+%description static
+Static Haru PDF library.
+
+%description static -l pl.UTF-8
+Statyczna biblioteka Haru PDF.
 
 %prep
 %setup -q
 %patch0 -p1
 
 %build
-./configure \
-	--shared \
-	--prefix=%{_prefix} \
-	--cflags="%{rpmcflags}"
-%{__make} \
-	CC="%{__cc}"
+%{__libtoolize}
+%{__aclocal}
+%{__autoconf}
+%{__autoheader}
+%{__automake}
+%configure
+
+%{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
 
 %{__make} install \
-	PREFIX=%{_prefix} \
-	LIBDIR=%{_libdir} \
 	DESTDIR=$RPM_BUILD_ROOT
 
-install include/* $RPM_BUILD_ROOT%{_includedir}
-
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -89,13 +97,18 @@
 
 %files
 %defattr(644,root,root,755)
-%doc README TODO
-%attr(755,root,root) %{_libdir}/lib*.so.*.*.*
+%doc README
+%attr(755,root,root) %{_libdir}/libhpdf-%{version}.so
 
 %files devel
 %defattr(644,root,root,755)
-%{_libdir}/lib*.so
-%{_includedir}/*
+%attr(755,root,root) %{_libdir}/libhpdf.so
+%{_libdir}/libhpdf.la
+%{_includedir}/hpdf*.h
+
+%files static
+%defattr(644,root,root,755)
+%{_libdir}/libhpdf.a
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -103,6 +116,12 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.4  2011/11/20 08:49:51  qboosh
+- new Source URL, updated to 2.2.1 (note: new soname)
+- removed obsolete destdir patch (upstream switched to autotools, resolving such problems)
+- added libdir patch to kill unnecessary -L/usr/lib and unify libpng linking
+- added -static; .la file is needed to specify library dependencies
+
 Revision 1.3  2010/01/28 19:55:52  arekm
 - release 3
 

================================================================
Index: packages/libharu/libharu-libdir.patch
diff -u /dev/null packages/libharu/libharu-libdir.patch:1.1
--- /dev/null	Sun Nov 20 09:49:57 2011
+++ packages/libharu/libharu-libdir.patch	Sun Nov 20 09:49:51 2011
@@ -0,0 +1,29 @@
+--- libharu-2.2.1/configure.in.orig	2010-11-22 10:59:56.000000000 +0100
++++ libharu-2.2.1/configure.in	2011-11-20 07:14:34.760591648 +0100
+@@ -240,7 +240,6 @@
+   fi
+ 
+   AC_MSG_RESULT([$ZLIB_DIR])
+-  LDFLAGS="$LDFLAGS -L$ZLIB_DIR/$LIBDIR"
+   CFLAGS="$CFLAGS -I$ZLIB_DIR/include"
+   LIBS="$LIBS -lz"
+ 
+@@ -291,13 +290,15 @@
+   fi
+ 
+   AC_MSG_RESULT([$LIBPNG_DIR])
+-  LDFLAGS="$LDFLAGS -L$LIBPNG_DIR/$LIBDIR"
+   CFLAGS="$CFLAGS -I$LIBPNG_DIR/include"
+-  LIBS="$LIBS -lpng"
+ 
+-  AC_CHECK_LIB([png], [png_init_io], [], [
++  AC_CHECK_LIB([png14], [png_init_io], [LIBS="$LIBS -lpng14"], [
++  AC_CHECK_LIB([png12], [png_init_io], [LIBS="$LIBS -lpng12"], [
++  AC_CHECK_LIB([png], [png_init_io], [LIBS="$LIBS -lpng"], [
+     AC_MSG_ERROR([png_init_io() is missing, check config.log for more details])
+   ])
++  ])
++  ])
+ fi
+ dnl }}}
+ 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/libharu/libharu.spec?r1=1.3&r2=1.4&f=u



More information about the pld-cvs-commit mailing list