Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
docs
zlib
CMakeLists.txt
FindPthreads.cmake
License.txt
Makefile.in
README
README.MacOS
README.win
README_OLD.win
buffers.c
cfileio.c
cfitsio.pc.in
cfitsio_mac.sit.hqx
cfortran.h
checksum.c
config.guess
config.sub
configure
configure.in
cookbook.c
cookbook.f
drvrfile.c
drvrgsiftp.c
drvrgsiftp.h
drvrmem.c
drvrnet.c
drvrsmem.c
drvrsmem.h
editcol.c
edithdu.c
eval.l
eval.y
eval_defs.h
eval_f.c
eval_l.c
eval_tab.h
eval_y.c
f77.inc
f77_wrap.h
f77_wrap1.c
f77_wrap2.c
f77_wrap3.c
f77_wrap4.c
fits_hcompress.c
fits_hdecompress.c
fitscopy.c
fitscore.c
fitsio.h
fitsio2.h
fpack.c
fpack.h
fpackutil.c
funpack.c
getcol.c
getcolb.c
getcold.c
getcole.c
getcoli.c
getcolj.c
getcolk.c
getcoll.c
getcols.c
getcolsb.c
getcolui.c
getcoluj.c
getcoluk.c
getkey.c
group.c
group.h
grparser.c
grparser.h
histo.c
imcompress.c
imcopy.c
install-sh
iraffits.c
iter_a.c
iter_a.f
iter_a.fit
iter_b.c
iter_b.f
iter_b.fit
iter_c.c
iter_c.f
iter_c.fit
iter_image.c
iter_var.c
longnam.h
makefile.bc
makefile.vcc
makepc.bat
modkey.c
pliocomp.c
putcol.c
putcolb.c
putcold.c
putcole.c
putcoli.c
putcolj.c
putcolk.c
putcoll.c
putcols.c
putcolsb.c
putcolu.c
putcolui.c
putcoluj.c
putcoluk.c
putkey.c
quantize.c
region.c
region.h
ricecomp.c
sample.tpl
scalnull.c
simplerng.c
simplerng.h
smem.c
speed.c
swapproc.c
testf77.f
testf77.out
testf77.std
testprog.c
testprog.out
testprog.std
testprog.tpt
vmsieee.c
wcssub.c
wcsutil.c
winDumpExts.mak
windumpexts.c

README

                   CFITSIO Interface Library

CFITSIO is a library of ANSI C routines for reading and writing FITS
format data files.  A set of Fortran-callable wrapper routines are also
included for the convenience of Fortran programmers.  This README file
gives a brief summary of how to build and test CFITSIO, but the CFITSIO
User's Guide, found in the files cfitsio.doc (plain text), cfitsio.tex
(LaTeX source file), cfitsio.ps, or cfitsio.pdf should be
referenced for the latest and most complete information.

BUILDING CFITSIO
----------------

The CFITSIO code is contained in about 40 *.c source files and several *.h
header files.  The CFITSIO library is built on Unix systems by typing:

 >  ./configure [--prefix=/target/installation/path]
 >  make          (or  'make shared')
 >  make install  (this step is optional)

at the operating system prompt.  The configure command customizes the
Makefile for the particular system, then the `make' command compiles the
source files and builds the library.  Type `./configure' and not simply
`configure' to ensure that the configure script in the current directory
is run and not some other system-wide configure script.  The optional
'prefix' argument to configure gives the path to the directory where
the CFITSIO library and include files should be installed via the later
'make install' command. For example,

   > ./configure --prefix=/usr1/local

will cause the 'make install' command to copy the CFITSIO libcfitsio file 
to /usr1/local/lib and the necessary include files to /usr1/local/include
(assuming of course that the  process has permission to write to these 
directories).

On VAX/VMS and ALPHA/VMS systems the make.com command file may be used
to build the cfitsio.olb object library using the default G-floating
point option for double variables.  The make\_dfloat.com and make\_ieee.com
files may be used instead to build the library with the other floating
point options.

A precompiled DLL version of CFITSIO is available for IBM-PC users of
the Borland or Microsoft Visual C++ compilers in the files
cfitsiodll_xxxx_borland.zip and cfitsiodll_xxxx_vcc.zip, where 'xxxx'
represents the current release number.  These zip archives also
contains other files and instructions on how to use the CFITSIO DLL
library. The CFITSIO library may also be built from the source code
using the makefile.bc or makefile.vcc  files.  Finally, the makepc.bat
file gives an example of  building CFITSIO with the Borland C++ v4.5
compiler using simpler DOS commands.

When building on Mac OS-X, users should follow the Unix instructions,
above. Previous MacOS versions of the cfitsio library can be built by
(1) un binhex and unstuff cfitsio_mac.sit.hqx, (2) put CFitsioPPC.mcp
in the cfitsio directory, and (3) load CFitsioPPC.mcp into CodeWarrior
Pro 5 and make.  This builds the cfitsio library for PPC.  There are
also targets for both the test program and the speed test program.

To use the MacOS port you can add Cfitsio PPC.lib to your Codewarrior
Pro 5 project.  Note that this only has been tested for the PPC and
probably won't work
 on 68k macs.

TESTING CFITSIO
---------------

The CFITSIO library should be tested by building and running
the testprog.c program that is included with the release. 
On Unix systems, type:
-
    % make testprog
    % testprog > testprog.lis
    % diff testprog.lis testprog.out
    % cmp testprog.fit testprog.std
-
 On VMS systems,
(assuming cc is the name of the C compiler command), type:
-
    $ cc testprog.c
    $ link testprog, cfitsio/lib
    $ run testprog
-
The testprog program should produce a FITS file called `testprog.fit'
that is identical to the testprog.std FITS file included in this
release.  The diagnostic messages (which were piped to the file
testprog.lis in the Unix example) should be identical to the listing
contained in the file testprog.out.  The 'diff' and 'cmp' commands
shown above should not report any differences in the files.

USING CFITSIO
-------------

The CFITSIO User's Guide, contained in the files cfitsio.doc (plain
text file) and cfitsio.ps (postscript file), provides detailed
documentation about how to build and use the CFITSIO library.
It contains a description of every user-callable routine in the
CFITSIO interface.

The cookbook.c file provides some sample routines for performing common
operations on various types of FITS files.  Programmers are urged to
examine these routines for recommended programming practices when using
CFITSIO.  Users are free to copy or modify these routines for their own
purposes.

SUPPORTED PLATFORMS
-------------------

CFITSIO has currently been tested on the following platforms (not up-to-date):

   Operating System          Compiler
   ----------------          --------
  OPERATING SYSTEM           COMPILER
   Sun OS                     gcc and cc (3.0.1)
   Sun Solaris                gcc and cc
   Silicon Graphics IRIX      gcc and cc
   Silicon Graphics IRIX64    MIPS
   Dec Alpha OSF/1            gcc and cc
   DECstation  Ultrix         gcc
   Dec Alpha OpenVMS          cc 
   DEC VAX/VMS                gcc and cc
   HP-UX                      gcc
   IBM AIX                    gcc
   Linux                      gcc
   MkLinux                    DR3
   Windows 95/98/NT           Borland C++ V4.5
   Windows 95/98/NT/ME/XP     Microsoft/Compaq Visual C++ v5.0, v6.0
   Windows 95/98/NT           Cygwin gcc
   OS/2                       gcc + EMX
   Mac OS 7.1 or greater      Metrowerks 10.+
   Mac OS-X 10.1 or greater   cc (gcc)

CFITSIO will probably run on most other Unix platforms without
modification.  Cray supercomputers computers are
currently not supported.

Reports of any success or failure to run CFITSIO on other platforms
would be appreciated.  Any problem reports or suggestions for
improvements are also welcome and should be sent to the HEASARC.

-------------------------------------------------------------------------
William D. Pence
HEASARC, NASA/GSFC