--- libspooles.spec.orig 2010-02-22 12:57:57.000000000 +0100 +++ libspooles.spec 2010-02-22 12:56:04.000000000 +0100 @@ -1,83 +1,70 @@ -Name: libspooles -Version: 2.2 -Release: 2%{?dist} -Summary: A sparse matrix library +Name: libspooles +Version: 2.2 +Release: 2%{?dist} +Summary: Sparse matrix library # SPOOLES: Public Domain # SPOOLES: iohb: BSD style -License: BSD and Public Domain -URL: http://www.netlib.org/linalg/spooles/spooles.2.2.html -Group: Applications/Engineering -Source0: http://netlib.bell-labs.com/netlib/linalg/spooles/spooles.2.2.tgz -Patch0: patch-spooles-shared -Patch1: patch-spooles-I2Ohash-from-debian +License: BSD and Public Domain +URL: http://www.netlib.org/linalg/spooles/spooles.2.2.html +Group: Applications/Engineering +Source0: http://netlib.bell-labs.com/netlib/linalg/spooles/spooles.2.2.tgz +Patch0: patch-spooles-shared +Patch1: patch-spooles-I2Ohash-from-debian BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) %description -SPOOLES is a library for solving sparse real and complex linear systems -of equations, written in the C language using object oriented design. +SPOOLES is a library for solving sparse real and complex linear +systems of equations, written in the C language using object oriented +design. %prep %setup -c -q - %patch0 -p1 %patch1 -p1 %package devel Summary: Header files for the SPOOLES library -Group: Applications/Engineering +Group: Applications/Engineering %description devel -spooles-devel provides the header file for the SPOOLES library. +%{name}-devel provides the header file for the SPOOLES library. %build -cd ${RPM_BUILD_DIR}/%{name}-%{version} export CFLAGS="$RPM_OPT_FLAGS" - make -f makeRPM all %{?_smp_mflags} %install -cd ${RPM_BUILD_DIR}/%{name}-%{version} -rm -rf $RPM_BUILD_ROOT/* -mkdir -p $RPM_BUILD_ROOT/%{_libdir} -cp -P libspooles* $RPM_BUILD_ROOT/%{_libdir} -chmod 755 $RPM_BUILD_ROOT/%{_libdir}/libspooles.so.%{version} - +rm -rf $RPM_BUILD_ROOT +install -D -m 0755 libspooles.so.%{version} $RPM_BUILD_ROOT/%{_libdir}/libspooles.so.%{version} +ln -s libspooles.so.%{version} $RPM_BUILD_ROOT/%{_libdir}/libspooles.so # header files: use same convention as debian spooles package: # all headers under /usr/include/spooles - -mkdir -p $RPM_BUILD_ROOT/%{_includedir}/spooles -for headerfile in `find . -name \*.h -print`; do - dir="$RPM_BUILD_ROOT/%{_includedir}/spooles/`dirname $headerfile`" - mkdir -p $dir - cp $headerfile $dir - chmod 644 $RPM_BUILD_ROOT/%{_includedir}/spooles/$headerfile -done +for file in $(find . -name \*.h -print); do + install -D -m 0644 $file $RPM_BUILD_ROOT/%{_includedir}/spooles/$file +done %clean -rm -Rf $RPM_BUILD_ROOT +rm -rf $RPM_BUILD_ROOT %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files -%defattr(-,root,root) -%{_libdir}/libspooles.so +%defattr(-,root,root,-) +%doc spooles.2.2.html %{_libdir}/libspooles.so.2.2 -%doc spooles.2.2.html - %files devel -%defattr(-,root,root) -%{_includedir}/spooles/ +%defattr(-,root,root,-) +%{_includedir}/spooles +%{_libdir}/libspooles.so %changelog -* Sun Feb 21 2010 Manfred Spraul: -- %post and %postun added -- 2.2-2 +* Sun Feb 21 2010 Manfred Spraul - 2.2-2 +- %%post and %%postun added -* Sat Feb 20 2010 Manfred Spraul: +* Sat Feb 20 2010 Manfred Spraul - 2.2-1 - renamed to libspooles - serial and parallel functions included - MPI functions not included -- 2.2-1