Summary: MXTOOLS - IRAF Package of Image Matching and Image Coordinates Tasks Name: iraf-mxtools Version: 2001DEC27 Release: 6.el5.uson License: Freely redistributable/modifiable if attributed, no warranty Group: Applications/Scientific Packager: Fernando Avila Castro Distribution: Area de Astronomia, USON Source0: mxtools.tar.Z Source1: mxtools-bin.redhat.tar.Z Url: http://iraf.noao.edu/iraf/web/extern.html BuildRoot: %{_tmppath}/mxtools-root Provides: iraf-mxtools Requires: iraf %description MXTOOLS is an IRAF package providing tools for image matching and image coordinate manipulation. %prep # set up dirs mkdir -p $RPM_BUILD_DIR/iraf/mxtools # unpack the main sources cd $RPM_BUILD_DIR/iraf/mxtools tar xvvzf $RPM_SOURCE_DIR/mxtools.tar.Z # unpack the binaries mkdir -p $RPM_BUILD_DIR/iraf/mxtools/bin.redhat cd $RPM_BUILD_DIR/iraf/mxtools/bin.redhat tar xvvzf $RPM_SOURCE_DIR/mxtools-bin.redhat.tar.Z %build # nuke unnecessary files and strip static libs cd $RPM_BUILD_DIR/iraf find . -path "*bin.sunos/*" -exec rm -rf {} \; find . -path "*bin.freebsd/*" -exec rm -rf {} \; find . -path "*bin.suse/*" -exec rm -rf {} \; find . -path "*bin.linux/*" -exec rm -rf {} \; find . -name "*OBJS.arc*" -exec rm {} \; find . -name ".nfs*" -exec rm {} \; %install rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT/iraf cd $RPM_BUILD_DIR/iraf mv * $RPM_BUILD_ROOT/iraf/. # diddle with extern.pkg mkdir -p $RPM_BUILD_ROOT/iraf/iraf/unix/hlib cd $RPM_BUILD_ROOT/iraf/iraf/unix/hlib # make specific entries for each external package and then slap them # all together with the post(un)install scripts. echo 'reset mxtools = /iraf/mxtools/' > MXTOOLS.extern.pkg echo 'task mxtools.pkg = mxtools$mxtools.cl' >> MXTOOLS.extern.pkg echo '' >> MXTOOLS.extern.pkg echo ' ,mxtools$lib/helpdb.mip\' > MXTOOLS.helpdb.mip %clean rm -rf $RPM_BUILD_ROOT rm -rf $RPM_BUILD_DIR/iraf %post cp /iraf/iraf/unix/hlib/extern.pkg /iraf/iraf/unix/hlib/extern.pkg.irafsave cat /iraf/iraf/unix/hlib/*.extern.pkg > /iraf/iraf/unix/hlib/extern.pkg echo 'reset helpdb = "lib$helpdb.mip\' >> /iraf/iraf/unix/hlib/extern.pkg cat /iraf/iraf/unix/hlib/*.helpdb.mip >> /iraf/iraf/unix/hlib/extern.pkg echo ' "' >> /iraf/iraf/unix/hlib/extern.pkg echo 'keep' >> /iraf/iraf/unix/hlib/extern.pkg %postun cp /iraf/iraf/unix/hlib/extern.pkg /iraf/iraf/unix/hlib/extern.pkg.irafsave cat /iraf/iraf/unix/hlib/*.extern.pkg > /iraf/iraf/unix/hlib/extern.pkg echo 'reset helpdb = "lib$helpdb.mip\' >> /iraf/iraf/unix/hlib/extern.pkg cat /iraf/iraf/unix/hlib/*.helpdb.mip >> /iraf/iraf/unix/hlib/extern.pkg echo ' "' >> /iraf/iraf/unix/hlib/extern.pkg echo 'keep' >> /iraf/iraf/unix/hlib/extern.pkg %files %defattr(-,root,root) /iraf/mxtools /iraf/iraf/unix/hlib/* %changelog * Wed Apr 18 2007 - rebuild for rhel 5 * Sun Aug 15 2004 - build under FC 2 * Fri Jan 16 2004 - build under FC 1 * Mon Feb 04 2002 - first crack at making rpm