--- R-hdf5.spec	2007-07-05 10:58:15.000000000 -0400
+++ R-hdf5.spec.new	2009-10-29 14:35:19.000000000 -0400
@@ -3,7 +3,7 @@
 
 Name: R-%{packname}
 Version: 1.6.6
-Release: 1%{?dist}
+Release: 2%{?dist}
 Source0: ftp://cran.r-project.org/pub/R/contrib/main/%{packname}_%{version}.tar.gz
 License: GPL
 URL: http://cran.r-project.org/contrib
@@ -11,6 +11,7 @@
 Summary: Interface to the NCSA HDF5 library
 BuildRequires: R-devel, tetex-latex, hdf5-devel, zlib-devel
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+Requires: R-core
 
 %description
 R package:
@@ -34,16 +35,19 @@
 rm -rf $RPM_BUILD_ROOT
 
 %post
-cat %{_libdir}/R/library/*/CONTENTS > %{_libdir}/R/doc/html/search/index.txt
+/usr/lib/rpm/R-make-search-index.sh
 
 %postun
-cat %{_libdir}/R/library/*/CONTENTS > %{_libdir}/R/doc/html/search/index.txt
+/usr/lib/rpm/R-make-search-index.sh
 
 %files
 %doc DESCRIPTION
 %{_libdir}/R/library/%{packname}
 
 %changelog
+* Thu Oct 29 2009 Aaron Knister <aaronk@umbc.edu> 1.6.6-2
+- Fixed issue with postscripts redirecting output to a directory that doesn't exist
+
 * Thu Jul  5 2007 Tom "spot" Callaway <tcallawa@redhat.com> 1.6.6-1
 - bump to 1.6.6
 
