%{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}} Name: ast Version: 7.3.4 Release: 1%{?dist} Summary: A Library for Handling World Coordinate Systems in Astronomy Group: System Environment/Libraries # proj.c proj.h wcsmath.h wcstrig.c wcstrig.h are LGPLv2+ License: GPLv2+ and LGPLv2+ URL: http://starlink.jach.hawaii.edu/starlink/AST Source0: http://www.starlink.ac.uk/download/ast/ast-%{version}.tar.gz # Fix up library linkages Patch0: ast-libs.patch BuildRequires: gcc-gfortran %description The AST library provides a comprehensive range of facilities for attaching world coordinate systems to astronomical data, for retrieving and interpreting that information and for generating graphical output based on it. It's main selling points are: * Ease of use. * Facilities for generating plots of generalized non-linear, potentially discontinuous 2-D or 3-D coordinate systems, with detailed control of the appearance of the plot. * Facilities for converting transparently between different coordinate systems, including a wide range of celestial, spectral and time coordinate systems. * Facilities for searching a general collection of connected coordinate systems for a coordinate system with any given set of characteristics. * Allows code for handling WCS information to be written in a general way without regard to the specific nature of the coordinate systems being handled (i.e. whether they represent sky positions, spectral positions, focal plane positions, pixel positions, etc). * Flexible system for saving and retrieving WCS information, including (but not limited to) a range of different popular FITS descriptions. * Written in C but has interfaces for C, Fortran, Java (via JNI), Perl, and UNIX shell. * Extensive documentation. %package devel Summary: Development files for %{name} Group: Development/Libraries Requires: %{name} = %{version}-%{release} %description devel The %{name}-devel package contains libraries and header files for developing applications that use %{name}. Applications should make use of the ast_link command for setting the libraries to link to, e.g.: cc prog.c `ast_link` -o prog %package doc Summary: Documentation for %{name} Group: Documentation %description doc C and Fortran programming documentation for %{name}. %prep %setup -q %patch0 -p1 -b .libs sed -i -e '1i#!/bin/bash' ast_link* # Fix FSF address sed -i -e 's/675 Mass Ave, Cambridge, MA 02139/51 Franklin Street, Fifth Floor, Boston, MA 02110-1301/' COPYING.LIB proj.* wcstrig.* %build # Do not conflict with libast (bug #978262) %configure --disable-static --libdir=%{_libdir}/%{name} make %{?_smp_mflags} %install make install DESTDIR=$RPM_BUILD_ROOT find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';' # Setup ld.so.conf.d mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d echo %{_libdir}/%{name} > $RPM_BUILD_ROOT%{_sysconfdir}/ld.so.conf.d/%{name}_%{_arch}.conf # Docs are installed to the wrong location, don't need source mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir} mv $RPM_BUILD_ROOT%{_prefix}/docs/*.pdf $RPM_BUILD_ROOT%{_pkgdocdir}/ rm -r $RPM_BUILD_ROOT%{_prefix}/docs rm -r $RPM_BUILD_ROOT%{_datadir}/ast rm -r $RPM_BUILD_ROOT%{_prefix}/{help,manifests,news} # This references an uninstalled library rm $RPM_BUILD_ROOT%{_bindir}/ast_link_adam # These reference other libraries rm $RPM_BUILD_ROOT%{_libdir}/%{name}/libast_{drama,ems,pgplot{,3d}}.so* %check make check %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %doc COPYING.LIB LICENCE %config(noreplace) %{_sysconfdir}/ld.so.conf.d/%{name}_%{_arch}.conf %dir %{_libdir}/%{name} %{_libdir}/%{name}/*.so.* %files devel %{_bindir}/ast_link %{_includedir}/* %{_libdir}/%{name}/*.so %files doc %{_pkgdocdir}/ %changelog * Fri Mar 7 2014 Orion Poplawski 7.3.4-1 - Update to 7.3.4 * Tue Jan 7 2014 Orion Poplawski 7.3.3-1 - Update to 7.3.3 * Thu Sep 26 2013 Orion Poplawski 7.3.2-1 - Update to 7.3.2 - Drop path patch applied upstream * Tue Aug 13 2013 Orion Poplawski 7.3.1-1 - Update to 7.3.1-1 - Add patch to fix conftest paths * Sun Aug 11 2013 Orion Poplawski 6.0.1-6 - Do not conflict with libast (bug #978262) * Wed Feb 13 2013 Fedora Release Engineering - 6.0.1-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild * Wed Jul 18 2012 Fedora Release Engineering - 6.0.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild * Thu Jan 12 2012 Orion Poplawski 6.0.1-2 - Update source to new tarball and URL - Drop FSF address fixes applied upstream * Mon Nov 28 2011 Orion Poplawski 6.0.1-1 - Update to 6.0-1 - Fixup some lib linkages - Fix license tag - Fix FSF license - Fixup doc install - Drop BuildRoot, clean, defattr * Fri Oct 14 2011 Orion Poplawski 5.7.2-1 - Update to 5.7-2 - Truncate description - Move documentation to subpackage * Wed Apr 27 2011 Orion Poplawski 5.6-1 - Initial package