Cfitsio version 3.210 - How to Download and Install on Mac OS X
Saturday the 7th of November, 2009

    cfitsio  most recent diff


    version 3.210

      View the most recent changes for the cfitsio port at: cfitsio.darwinports.com/diff
      Scroll down toward the bottom of the page to get installation instructions for cfitsio.
      The raw portfile for cfitsio 3.210 is located here:
      http://cfitsio.darwinports.com/dports/science/cfitsio/Portfile
      Find related portfiles with the unique DarwinPorts.com search feature.
      Check for any related Fink projects here: pdb.finkproject.org/pdb/package.php/cfitsio


      The cfitsio Portfile 58723 2009-10-03 15:30:57Z ram macports.org $

      PortSystem 1.0

      Name: cfitsio
      Version: 3.210
      Category: science
      Platform: darwin
      Maintainers: ram openmaintainer

      Description: C access to FITS data files with optional Fortran wrappers
      Long Description: CFITSIO is a library of C and Fortran subroutines for reading and writing data files in FITS (Flexible Image Transport System) data format. CFITSIO simplifies the task of writing software that deals with FITS files by providing an easy to use set of high-level routines that insulate the programmer from the internal complexities of the FITS file format. At the same time, CFITSIO provides many advanced features that have made it the most widely used FITS file programming interface in the astronomical community.

      Homepage: http://heasarc.gsfc.nasa.gov/fitsio/
      Master Sites: http://heasarc.gsfc.nasa.gov/FTP/software/fitsio/c/
      distname ${name}[strsed ${version} {g/\.//}]
      worksrcdir ${name}
      #dist_subdir ${name}/${version}

      Checksums: md5 30f7e968983f6f46162f12368b68c42a sha1 d815840e32a4667547cef09bf5874520f06472c4 rmd160 d9d0654e6ab05b6fa5857dc0d020500a8ee27fe5

      Patch Files: patch-configure.diff

      # turn off FORTRAN compiler wrappers by removing FORTRAN from the path
      configure.fc ${prefix}/bin/no-possible-compiler
      configure.cflags -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64

      build.target all shared

      post-patch {
      reinplace "s| MPORTS_PREFIX |${prefix}|" ${worksrcpath}/configure
      }

      post-destroot {
      system "ranlib ${destroot}${prefix}/lib/libcfitsio.a"
      set docdir ${destroot}${prefix}/share/doc/${name}-${version}
      xinstall -m 755 -d ${docdir}
      eval xinstall -m 644 ${worksrcpath}/README [glob ${worksrcpath}/*.txt] [glob ${worksrcpath}/*.ps] [glob ${worksrcpath}/*.doc] [glob ${worksrcpath}/*.tex] ${docdir}
      }

      Variant: gcc42 description {create Fortran wrappers using gcc42} conflicts gcc43 gcc44 g95 g77 {
      depends_lib-append port:gcc42
      configure.fc ${prefix}/bin/gfortran-mp-4.2
      }

      Variant: gcc43 description {create Fortran wrappers using gcc43} conflicts gcc42 gcc44 g95 g77 {
      depends_lib-append port:gcc43
      configure.fc ${prefix}/bin/gfortran-mp-4.3
      }

      Variant: gcc44 description {create Fortran wrappers using gcc43} conflicts gcc42 gcc43 g95 g77 {
      depends_lib-append port:gcc44
      configure.fc ${prefix}/bin/gfortran-mp-4.4
      }

      Variant: g95 description {create Fortran wrappers using f95} conflicts gcc42 gcc43 gcc44 g77 {
      depends_lib-append port:g95
      configure.fc ${prefix}/bin/g95
      }

      Variant: g77 description {create Fortran wrappers using g77} conflicts gcc42 gcc43 gcc44 g95 {
      depends_lib-append port:gcc34
      configure.fc ${prefix}/bin/g77-dp-3.4
      }

      livecheck.type regex
      livecheck.url ${master_sites}
      livecheck.regex {cfitsio(\d+).tar.gz}
      livecheck.version [strsed ${version} {g/\.//}]

    If you haven't already installed Darwin Ports, you can find easy instructions for doing so at the main Darwin Ports page.

    Once Darwin Ports has been installed, in a terminal window and while online, type the following and hit return:


      %  cd /opt/local/bin/portslocation/dports/cfitsio
      % sudo port install cfitsio
      Password:
    You will then be prompted for your root password, which you should enter. You may have to wait for a few minutes while the software is retrieved from the network and installed for you. Y ou should see something that looks similar to:

      ---> Fetching cfitsio
      ---> Verifying checksum for cfitsio
      ---> Extracting cfitsio
      ---> Configuring cfitsio
      ---> Building cfitsio with target all
      ---> Staging cfitsio into destroot
      ---> Installing cfitsio
    - Make sure that you do not close the terminal window while Darwin Ports is working. Once the software has been installed, you can find further information about using cfitsio with these commands:
      %  man cfitsio
      % apropos cfitsio
      % which cfitsio
      % locate cfitsio

     Where to find more information:

    Darwin Ports



    Lightbox this page.