diff --git a/cfitsio-sparc64.patch b/cfitsio-sparc64.patch new file mode 100644 index 0000000..f8b9025 --- /dev/null +++ b/cfitsio-sparc64.patch @@ -0,0 +1,24 @@ +diff -uNr cfitsio-orig/fitsio2.h cfitsio/fitsio2.h +--- cfitsio-orig/fitsio2.h 2008-12-02 15:28:35.000000000 -0600 ++++ cfitsio/fitsio2.h 2009-06-13 12:41:37.000000000 -0500 +@@ -54,7 +54,7 @@ + #define BYTESWAPPED TRUE + #define LONGSIZE 64 + +-#elif defined(__sparcv9) ++#elif defined(__sparcv9) || (defined(__sparc__) && defined(__arch64__)) + /* SUN Solaris7 in 64-bit mode */ + #define BYTESWAPPED FALSE + #define MACHINE NATIVE +diff -uNr cfitsio-orig/fitsio.h cfitsio/fitsio.h +--- cfitsio-orig/fitsio.h 2009-01-05 11:20:41.000000000 -0600 ++++ cfitsio/fitsio.h 2009-06-13 12:49:45.000000000 -0500 +@@ -80,7 +80,7 @@ + || defined(__x86_64__) \ + */ + #if (defined(__alpha) && ( defined(__unix__) || defined(__NetBSD__) )) \ +- || defined(__sparcv9) \ ++ || defined(__sparcv9) || (defined(__sparc__) && defined(__arch64__)) \ + || defined(__powerpc64__) || defined(__64BIT__) \ + || (defined(_MIPS_SZLONG) && _MIPS_SZLONG == 64) \ + || defined( _MSC_VER)|| defined(__BORLANDC__) diff --git a/cfitsio.spec b/cfitsio.spec index c2388e7..e0f034e 100644 --- a/cfitsio.spec +++ b/cfitsio.spec @@ -1,13 +1,14 @@ Name: cfitsio Version: 3.130 -Release: 4%{?dist} +Release: 5%{?dist} Summary: Library for manipulating FITS data files Group: Development/Libraries License: GPLv2+ URL: http://heasarc.gsfc.nasa.gov/docs/software/fitsio/fitsio.html Source0: ftp://heasarc.gsfc.nasa.gov/software/fitsio/c/cfitsio3130.tar.gz -Patch: cfitsio.patch +Patch0: cfitsio.patch +Patch1: cfitsio-sparc64.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: gcc-gfortran @@ -42,7 +43,8 @@ Static cfitsio library; avoid use if possible. %prep %setup -q -n cfitsio -%patch -p1 +%patch0 -p1 +%patch1 -p1 %build FC=f95 @@ -98,6 +100,9 @@ rm -rf %{buildroot} %{_libdir}/libcfitsio.a %changelog +* Sat Jun 13 2009 Dennis Gilmore - 3.130-5 +- patch for 64 bit sparc linux + * Tue Mar 10 2009 Matthew Truch - 3.130-4 - Set correct version in pkgconfig .pc file.