Import Debian changes 3.470-ok1

cfitsio (3.470-ok1) yangtze; urgency=medium

  * Build for openKylin.
This commit is contained in:
openKylinBot 2022-04-25 22:03:04 +08:00
parent f590880010
commit 44971d932d
34 changed files with 2727 additions and 0 deletions

11
debian/README.examples vendored Normal file
View File

@ -0,0 +1,11 @@
To compile some of the example programs included here, copy the example
C program to your directory, and then compile it. For say the cookbook
program, after copying:
$ gcc cookbook.c -o cookbook -lcfitsio
Some documentation on the example C files can be found in the libcfitsio-doc
package.
Gopal Narayanan <gopal@debian.org>

5
debian/changelog vendored Normal file
View File

@ -0,0 +1,5 @@
cfitsio (3.470-ok1) yangtze; urgency=medium
* Build for openKylin.
-- openKylinBot <openKylinBot@openkylin.com> Mon, 25 Apr 2022 22:03:04 +0800

5
debian/clean vendored Normal file
View File

@ -0,0 +1,5 @@
docs/*.aux
docs/*.dvi
docs/*.log
docs/*.pdf
docs/*.toc

1
debian/compat vendored Normal file
View File

@ -0,0 +1 @@
10

80
debian/control vendored Normal file
View File

@ -0,0 +1,80 @@
Source: cfitsio
Section: devel
Priority: optional
Maintainer: Debian Astronomy Maintainers <debian-astro-maintainers@lists.alioth.debian.org>
Uploaders: Aurelien Jarno <aurel32@debian.org>
Build-Depends: debhelper (>= 10)
Build-Depends-Arch: gfortran, cfortran, zlib1g-dev, libbz2-dev, libcurl4-gnutls-dev
Build-Depends-Indep: hevea, latex2html, texlive
Standards-Version: 4.3.0
Homepage: https://heasarc.gsfc.nasa.gov/fitsio/fitsio.html
Vcs-Browser: https://salsa.debian.org/debian-astro-team/cfitsio
Vcs-Git: https://salsa.debian.org/debian-astro-team/cfitsio.git
XS-Testsuite: autopkgtest
Package: libcfitsio8
Architecture: any
Section: libs
Multi-Arch: same
Pre-Depends: ${misc:Pre-Depends}
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: shared library for I/O with FITS format data files
FITS (Flexible Image Transport System) is a data format most used in
astronomy. 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 package contains what you need to run programs that use this
library.
Package: libcfitsio-dev
Section: libdevel
Architecture: any
Multi-Arch: same
Depends: libcfitsio8 (= ${binary:Version}), ${misc:Depends}
Replaces: libcfitsio3-dev (<< 3.340-0)
Breaks: libcfitsio3-dev (<< 3.340-0)
Recommends: libcfitsio-doc
Description: library for I/O with FITS format data files (development files)
FITS (Flexible Image Transport System) is a data format most used in
astronomy. 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 package contains what you need for compiling sources that
use this library in your own code.
Package: libcfitsio-bin
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: CFITSIO based utilities
FITS (Flexible Image Transport System) is a data format most used in
astronomy. 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 package contains utility programs, based on CFITSIO, namely
fitscopy, fpack and funpack.
Package: libcfitsio-doc
Architecture: all
Section: doc
Multi-Arch: foreign
Depends: ${misc:Depends}
Suggests: libcfitsio-dev
Replaces: libcfitsio3-doc (<< 3.340-0)
Breaks: libcfitsio3-doc (<< 3.340-0)
Description: documentation for CFITSIO
FITS (Flexible Image Transport System) is a data format most used in
astronomy. 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 package contains the CFITSIO User's Guide and QuickStart Guide
in html, postscript and text formats, and contains documentation on
how to use the library in your programs. It also contains example
source files that demonstrate the use of CFITSIO.

122
debian/copyright vendored Normal file
View File

@ -0,0 +1,122 @@
This package was debianized by Gopal Narayanan <Gopal Narayanan
<gopal@debian.org> on Thu, 2 Nov 2000 10:12:15 -0500.
It was downloaded from https://heasarc.gsfc.nasa.gov/docs/software/fitsio/
Upstream Author: Dr. William Pence <pence@tetra.gsfc.nasa.gov>
Copyright for most of CFITSIO:
Copyright (Unpublished--all rights reserved under the copyright laws of
the United States), U.S. Government as represented by the Administrator
of the National Aeronautics and Space Administration. No copyright is
claimed in the United States under Title 17, U.S. Code.
Copyright for part of fits_hcompress.c and fits_hdecompress.c:
Copyright (c) 1993 Association of Universities for Research in Astronomy.
Copyright files present in the sources, but not used:
Copyright (C) 1995-2010 Mark Adler
Copyright (C) 1995-2010 Jean-loup Gailly
Copyright (C) 1990-2003 Burkhard Burow
License:
Permission to freely use, copy, modify, and distribute this software
and its documentation without fee is hereby granted, provided that this
copyright notice and disclaimer of warranty appears in all copies.
DISCLAIMER:
THE SOFTWARE IS PROVIDED 'AS IS' WITHOUT ANY WARRANTY OF ANY KIND,
EITHER EXPRESSED, IMPLIED, OR STATUTORY, INCLUDING, BUT NOT LIMITED TO,
ANY WARRANTY THAT THE SOFTWARE WILL CONFORM TO SPECIFICATIONS, ANY
IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
PURPOSE, AND FREEDOM FROM INFRINGEMENT, AND ANY WARRANTY THAT THE
DOCUMENTATION WILL CONFORM TO THE SOFTWARE, OR ANY WARRANTY THAT THE
SOFTWARE WILL BE ERROR FREE. IN NO EVENT SHALL NASA BE LIABLE FOR ANY
DAMAGES, INCLUDING, BUT NOT LIMITED TO, DIRECT, INDIRECT, SPECIAL OR
CONSEQUENTIAL DAMAGES, ARISING OUT OF, RESULTING FROM, OR IN ANY WAY
CONNECTED WITH THIS SOFTWARE, WHETHER OR NOT BASED UPON WARRANTY,
CONTRACT, TORT , OR OTHERWISE, WHETHER OR NOT INJURY WAS SUSTAINED BY
PERSONS OR PROPERTY OR OTHERWISE, AND WHETHER OR NOT LOSS WAS SUSTAINED
FROM, OR AROSE OUT OF THE RESULTS OF, OR USE OF, THE SOFTWARE OR
SERVICES PROVIDED HEREUNDER."
License of files present in the sources, but not used:
The files adler32.c, crc32.c, inffast.c, inftrees.c, trees.c, zutil.c
deflate.c, infback.c, inflate.c, uncompr.c contain source code that
originally came from gzip-1.2.4, copyright (C) 1992-1993 by Jean-loup
Gailly. This gzip code is distributed under the GNU General Public.
On Debian systems, the complete text of the GNU General Public
License, version 2, can be found in /usr/share/common-licenses/GPL-2.
The file cfortran.h is distributed either under the LGPL license as
stated in the email below:
Date: Tue, 22 Oct 2002 12:48:00 -0400
From: Burkhard D Steinmacher-burow <steinmac@us.ibm.com>
To: Kevin B. McCarty <kmccarty@Princeton.EDU>
Subject: Re: CFortran licensing question
Kevin,
[Just noticed that I didn't send this yesterady.]
I have no time right now to read through licenses.
IIRC, library GPL is fairly unrestrictive, so I'll choose that. So.....
You may consider this e-mail as a notice that as an alternative to any
other cfortran licenses,
I hereby relase all versions and all parts of cfortran under the
the Library GPL license.
From among these licenses, the user is free to choose
the license or licenses under which cfortran is used.
Contact me if you'd like to be able to choose another license.
Burkhard
steinmac@us.ibm.com, (914)945-3756, Fax 3684, Tieline 862
or the following license:
THIS PACKAGE, I.E. CFORTRAN.H, THIS DOCUMENT, AND THE CFORTRAN.H EXAMPLE
PROGRAMS ARE PROPERTY OF THE AUTHOR WHO RESERVES ALL RIGHTS. THIS PACKAGE AND
THE CODE IT PRODUCES MAY BE FREELY DISTRIBUTED WITHOUT FEES, SUBJECT TO THE
FOLLOWING RESTRICTIONS:
- YOU MUST ACCOMPANY ANY COPIES OR DISTRIBUTION WITH THIS (UNALTERED) NOTICE.
- YOU MAY NOT RECEIVE MONEY FOR THE DISTRIBUTION OR FOR ITS MEDIA
(E.G. TAPE, DISK, COMPUTER, PAPER.)
- YOU MAY NOT PREVENT OTHERS FROM COPYING IT FREELY.
- YOU MAY NOT DISTRIBUTE MODIFIED VERSIONS WITHOUT CLEARLY DOCUMENTING YOUR
CHANGES AND NOTIFYING THE AUTHOR.
- YOU MAY NOT MISREPRESENTED THE ORIGIN OF THIS SOFTWARE, EITHER BY EXPLICIT
CLAIM OR BY OMISSION.
THE INTENT OF THE ABOVE TERMS IS TO ENSURE THAT THE CFORTRAN.H PACKAGE NOT BE
USED FOR PROFIT MAKING ACTIVITIES UNLESS SOME ROYALTY ARRANGEMENT IS ENTERED
INTO WITH ITS AUTHOR.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER
EXPRESSED OR IMPLIED. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
SOFTWARE IS WITH YOU. SHOULD THE SOFTWARE PROVE DEFECTIVE, YOU ASSUME THE COST
OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. THE AUTHOR IS NOT RESPONSIBLE
FOR ANY SUPPORT OR SERVICE OF THE CFORTRAN.H PACKAGE.
Burkhard Burow
burow@desy.de
On Debian systems, the complete text of the GNU Library General Public
License can be found in `/usr/share/common-licenses/LGPL-2'.

50
debian/fitscopy.1 vendored Normal file
View File

@ -0,0 +1,50 @@
.TH fitscopy "1" "April 2014" "CFITSIO version 3.370" "User Commands"
.SH NAME
fitscopy \- copy FITS files with optional filtering
.SH SYNOPSIS
.B fitscopy \fIinputfile\fR \fIoutputfile\fR
.SH DESCRIPTION
Copy an input file to an output file, optionally filtering the file in the
process. This seemingly simple program can apply powerful filters which
transform the input file as it is being copied. Filters may be used to
extract a subimage from a larger image, select rows from a table, filter a
table with a GTI time extension or a SAO region file, create or delete
columns in a table, create an image by binning (histogramming) 2 table
columns, and convert IRAF format *.imh or raw binary data files into FITS
images.
.SH EXAMPLES
.TP
simple file copy
.B fitscopy in.fit out.fit
.TP
stdin to stdout
.B fitscopy \- \-
.TP
copy a subimage
.B fitscopy in.fit[11:50,21:60] out.fit
.TP
IRAF image to FITS
.B fitscopy iniraf.imh out.fit
.TP
raw array to FITS
.B fitscopy in.dat[i512,512] out.fit
.TP
copy rows with pi>35
.B fitscopy in.fit[events][pi>35] out.fit
.TP
bin an image
.B fitscopy in.fit[events][bin X,Y] out.fit
.TP
new x column
.B fitscopy in.fit[events][col x=.9*y] out.fit
.TP
time filter
.B fitscopy in.fit[events][gtifilter()] out.fit
.TP
spatial filter
.B fitscopy in.fit[2][regfilter("pow.reg")] out.fit
.PP
Note that it may be necessary to enclose the input file name
in single quote characters on the Unix command line.
.SH "SEE ALSO"
\fBfpack\fP(1), \fBfunpack\fP(1).

126
debian/fpack.1 vendored Normal file
View File

@ -0,0 +1,126 @@
.TH fpack "1" "April 2014" "CFITSIO version 3.370" "User Commands"
.SH NAME
fpack \- FITS image compression program
.SH SYNOPSIS
.B funpack
[\fIOPTION\fR]... \fIFILE\fR...
.SH DESCRIPTION
.PP
.B fpack
is a utility program for optimally compressing images in the FITS data format.
This programs is analogous to the GZIP utility program except that it is
optimized for FITS format images and offer a wider choice of compression
options.
.SH OPTIONS
.PP
Flags must be separate and appear before filenames. Use '\-' to read from stdin.
.PP
The compression parameters specified on the \fBfpack\fR command line may
be overridden by compression directive keywords in the header of each HDU
of the input file(s).
.TP
\fB\-r\fR
Rice compression (default).
.TP
\fB\-h\fR
Hcompress compression.
.TP
\fB\-g\fR
or \fB\-g1\fR GZIP_1 (per\-tile) compression.
.TP
\fB\-g2\fR
GZIP_2 (per\-tile) compression (with byte shuffling).
.TP
\fB\-p\fR
PLIO compression (only for positive 8 or 16\-bit integer images).
.TP
\fB\-d\fR
Tile the image without compression (debugging mode).
.TP
\fB\-w\fR
Compress the whole image as a single large tile.
.TP
\fB\-t\fR \fIaxes\fR
Comma separated list of tile dimensions (default is row by row).
.TP
\fB\-q\fR \fIlevel\fR
Quantized level spacing when converting floating point images to
scaled integers. (+value relative to sigma of background noise;
\fB\-value\fR is absolute). Default q value of 4 gives a compression ratio
of about 6 with very high fidelity (only 0.26% increase in noise).
Using q values of 2, or 1 will give compression ratios of
about 8, or 10, respectively (with 1.0% or 4.1% noise increase).
The scaled quantized values are randomly dithered using a seed
value determined from the system clock at run time.
Use \fB\-q0\fR instead of \fB\-q\fR to suppress random dithering.
Use \fB\-qz\fR instead of \fB\-q\fR to not dither zero\-valued pixels.
Use \fB\-qt\fR or \fB\-qzt\fR to compute random dithering seed from first tile checksum.
Use \fB\-qN\fR or \fB\-qzN\fR, (N in range 1 to 10000) to use a specific dithering seed.
Floating\-point images can be losslessly compressed by selecting
the GZIP algorithm and specifying \fB\-q\fR 0, but this is slower and often
produces much less compression than the default quantization method.
.TP
\fB\-i2f\fR
Convert integer images to floating point, then quantize and compress
using the specified q level. When used appropriately, this lossy
compression method can give much better compression than the normal
lossless compression methods without significant loss of information.
The \fB\-n3ratio\fR and \fB\-n3min\fR flags control the minimum noise thresholds;
Images below these thresholds will be losslessly compressed.
.TP
\fB\-n3ratio\fR
Minimum ratio of background noise sigma divided by q. Default = 2.0.
.TP
\fB\-n3min\fR
Minimum background noise sigma. Default = 6. The \fB\-i2f\fR flag will be ignored
if the noise level in the image does not exceed both thresholds.
.TP
\fB\-s\fR \fIscale\fR
Scale factor for lossy Hcompress (default = 0 = lossless)
(+values relative to RMS noise; \fB\-value\fR is absolute)
.TP
\fB\-n\fR \fInoise\fR
Rescale scaled\-integer images to reduce noise and improve compression.
.TP
\fB\-v\fR
Verbose mode; list each file as it is processed.
.TP
\fB\-T\fR
Show compression algorithm comparison test statistics; files unchanged.
.TP
\fB\-R\fR \fIfile\fR
Write the comparison test report (above) to a text file.
.TP
\fB\-table\fR
Compress FITS binary tables using prototype method, as well as compress
any image HDUs. This option is intended for experimental use.
.TP
\fB\-tableonly\fR
Compress only FITS binary tables using prototype method; do not compress
any image HDUs. This option is intended for experimental use.
.TP
\fB\-F\fR
Overwrite input file by output file with same name.
.TP
\fB\-D\fR
Delete input file after writing output.
.TP
\fB\-Y\fR
Suppress prompts to confirm \fB\-F\fR or \fB\-D\fR options.
.TP
\fB\-S\fR
Output compressed FITS files to STDOUT.
.TP
\fB\-L\fR
List contents; files unchanged.
.TP
\fB\-C\fR
Don't update FITS checksum keywords.
.TP
\fB\-H\fR
Show this message.
.TP
\fB\-V\fR
Show version number.
.SH "SEE ALSO"
\fBfunpack\fP(1), \fBfitscopy\fP(1).

50
debian/funpack.1 vendored Normal file
View File

@ -0,0 +1,50 @@
.TH funpack "1" "April 2014" "CFITSIO version 3.370" "User Commands"
.SH NAME
funpack \- FITS image decompression program
.SH SYNOPSIS
.B funpack
[\fIOPTION\fR]... \fIFILE\fR...
.SH DESCRIPTION
.PP
.B funpack
is an utility to restore a compressed FITS image file back to its original state.
.SH OPTIONS
.PP
Flags must be separate and appear before filenames. Use '\-' to read from stdin.
.TP
\fB\-E\fR \fIHDUlist\fR Unpack only the list of HDU names or numbers in the file.
.TP
\fB\-P\fR \fIpre\fR
Prepend \fIpre\fR to create new output filenames.
.TP
\fB\-O\fR \fIname\fR
Specify full output file name.
.TP
\fB\-Z\fR
Recompress the output file with host GZIP program.
.TP
\fB\-F\fR
Overwrite input file by output file with same name.
.TP
\fB\-D\fR
Delete input file after writing output.
.TP
\fB\-S\fR
Output uncompressed file to STDOUT file stream.
.TP
\fB\-L\fR
List contents, files unchanged.
.TP
\fB\-C\fR
Don't update FITS checksum keywords.
.TP
\fB\-v\fR
Verbose mode; list each file as it is processed.
.TP
\fB\-H\fR
Show this message.
.TP
\fB\-V\fR
Show version number.
.SH "SEE ALSO"
\fBfpack\fP(1), \fBfitscopy\fP(1).

55
debian/imcopy.1 vendored Normal file
View File

@ -0,0 +1,55 @@
.TH imcopy "1" "April 2014" "CFITSIO version 3.370" "User Commands"
.SH NAME
imcopy \- copies FITS images.
.SH SYNOPSIS
.B imcopy
\fI\,inputImage outputImage\/\fR[\fI\,compress\/\fR]
.SH DESCRIPTION
Copy an input image to an output image, optionally compressing
or uncompressing the image in the process. If the [compress]
qualifier is appended to the output file name then the input image
will be compressed using the tile\-compressed format. In this format,
the image is divided into rectangular tiles and each tile of pixels
is compressed and stored in a variable\-length row of a binary table.
If the [compress] qualifier is omitted, and the input image is
in tile\-compressed format, then the output image will be uncompressed.
.PP
If an extension name or number is appended to the input file name,
enclosed in square brackets, then only that single extension will be
copied to the output file. Otherwise, every extension in the input file
will be processed in turn and copied to the output file.
.PP
The full syntax of the compression qualifier is:
.IP
[compress ALGORITHM TDIM1,TDIM2,...; NOISE_BITS]
.PP
where the allowed ALGORITHM values are Rice, GZIP, PLIO,
and TDIMn is the size of the compression tile in each dimension,
and NOISE_BITS = 1, 2, 3, or 4 and controls the amount of noise
suppression when compressing floating point images.
.PP
Note that it may be necessary to enclose the file names
in single quote characters on the Unix command line.
.SH EXAMPLES
1) imcopy image.fit 'cimage.fit[compress]'
.IP
This compresses the input image using the default parameters, i.e.,
using the Rice compression algorithm and using row by row tiles.
.PP
2) imcopy cimage.fit image2.fit
.IP
This uncompress the image created in the first example.
image2.fit should be identical to image.fit if the image
has an integer datatype. There will be small differences
in the pixel values if it is a floating point image.
.PP
3) imcopy image.fit 'cimage.fit[compress GZIP 100,100;4]'
.IP
This compresses the input image using the following parameters:
.IP
GZIP compression algorithm;
100 X 100 pixel compression tiles;
noise_bits = 4 (only used with floating point images)
.SH SEE ALSO
\fBfitscopy\fP(1).

4
debian/libcfitsio-bin.install vendored Normal file
View File

@ -0,0 +1,4 @@
usr/bin/fitscopy
usr/bin/fpack
usr/bin/funpack
usr/bin/imcopy

4
debian/libcfitsio-bin.manpages vendored Normal file
View File

@ -0,0 +1,4 @@
debian/fitscopy.1
debian/fpack.1
debian/funpack.1
debian/imcopy.1

4
debian/libcfitsio-dev.install vendored Normal file
View File

@ -0,0 +1,4 @@
usr/include/*
usr/lib/*/lib*.a
usr/lib/*/lib*.so
usr/lib/*/pkgconfig/*

4
debian/libcfitsio-doc.dirs vendored Normal file
View File

@ -0,0 +1,4 @@
usr/share/doc/libcfitsio-doc
usr/share/doc/libcfitsio-doc/cfitsio
usr/share/doc/libcfitsio-doc/fitsio
usr/share/doc/libcfitsio-doc/quick

15
debian/libcfitsio-doc.doc-base.cfitsio vendored Normal file
View File

@ -0,0 +1,15 @@
Document: cfitsio
Title: CFITSIO User's Guide
Author: Dr. William Pence <pence@tetra.gsfc.nasa.gov>
Abstract: This is the CFITSIO User's Guide. Cfitsio is a C library for
reading and writing FITS format data files. FITS (Flexible Image
Transport System) is a data format most used in astronomy. See fitsio
document page for documentation on fortran-callable subroutines.
Section: Programming
Format: pdf
Files: /usr/share/doc/libcfitsio-doc/cfitsio.pdf.gz
Format: HTML
Index: /usr/share/doc/libcfitsio-doc/cfitsio/index.html
Files: /usr/share/doc/libcfitsio-doc/cfitsio/*.html

View File

@ -0,0 +1,14 @@
Document: cfitsio-quick
Title: CFITSIO Quick Start Guide
Author: Dr. William Pence <pence@tetra.gsfc.nasa.gov>
Abstract: This is the CFITSIO Quick Start Guide. Cfitsio is a C library for
reading and writing FITS format data files. FITS (Flexible Image
Transport System) is a data format most used in astronomy.
Section: Programming
Format: pdf
Files: /usr/share/doc/libcfitsio-doc/quick.pdf.gz
Format: HTML
Index: /usr/share/doc/libcfitsio-doc/quick/index.html
Files: /usr/share/doc/libcfitsio-doc/quick/*.html

18
debian/libcfitsio-doc.doc-base.fitsio vendored Normal file
View File

@ -0,0 +1,18 @@
Document: fitsio
Title: FITSIO User's Guide
Author: Dr. William Pence <pence@tetra.gsfc.nasa.gov>
Abstract: This is the FITSIO User's Guide. This document describes the
Fortran-callable subroutine interface that is provided as part of the
CFITSIO library (which is written in ANSI C). This is a companion
document to the CFITSIO User's Guide which should be consulted for
further information about the underlying CFITSIO library. FITS
(Flexible Image Transport System) is a data format most used in
astronomy.
Section: Programming
Format: pdf
Files: /usr/share/doc/libcfitsio-doc/fitsio.pdf.gz
Format: HTML
Index: /usr/share/doc/libcfitsio-doc/fitsio/index.html
Files: /usr/share/doc/libcfitsio-doc/fitsio/*.html

7
debian/libcfitsio-doc.docs vendored Normal file
View File

@ -0,0 +1,7 @@
README
docs/cfitsio
docs/cfitsio.pdf
docs/fitsio
docs/fitsio.pdf
docs/quick
docs/quick.pdf

6
debian/libcfitsio-doc.examples vendored Normal file
View File

@ -0,0 +1,6 @@
debian/README.examples
cookbook.c
imcopy.c
smem.c
speed.c
testprog.c

1
debian/libcfitsio8.install vendored Normal file
View File

@ -0,0 +1 @@
usr/lib/*/lib*.so.*

1775
debian/libcfitsio8.symbols vendored Normal file

File diff suppressed because it is too large Load Diff

11
debian/patches/01-LDFLAGS.diff vendored Normal file
View File

@ -0,0 +1,11 @@
--- cfitsio-3.390.orig/configure.in
+++ cfitsio-3.390/configure.in
@@ -173,7 +173,7 @@ if test "x$EXT" != xcygwin && test "x$EX
fi
fi
AC_PROG_CC
-LDFLAGS="$CFLAGS"
+#LDFLAGS="$CFLAGS"
LDFLAGS_BIN="$LDFLAGS"
if test "x$FC" = "xnone" ; then

131
debian/patches/02-system-cfortran.patch vendored Normal file
View File

@ -0,0 +1,131 @@
Use system cfortran header.
--- a/f77_wrap.h
+++ b/f77_wrap.h
@@ -1,6 +1,6 @@
#define UNSIGNED_BYTE
-#include "cfortran.h"
+#include <cfortran.h>
/************************************************************************
Some platforms creates longs as 8-byte integers. On other machines, ints
@@ -29,16 +29,16 @@
#undef LONGV_cfT
#undef PLONG_cfT
-#define LONGV_cfSTR(N,T,A,B,C,D,E) _(CFARGS,N)(T,LONGV,A,B,C,D,E)
-#define PLONG_cfSTR(N,T,A,B,C,D,E) _(CFARGS,N)(T,PLONG,A,B,C,D,E)
+#define LONGV_cfSTR(N,T,A,B,C,D,E) CFORTRAN_XCAT_(CFARGS,N)(T,LONGV,A,B,C,D,E)
+#define PLONG_cfSTR(N,T,A,B,C,D,E) CFORTRAN_XCAT_(CFARGS,N)(T,PLONG,A,B,C,D,E)
#define LONGVVVVVVV_cfTYPE int
#define PLONG_cfTYPE int
-#define LONGV_cfQ(B) long *B, _(B,N);
+#define LONGV_cfQ(B) long *B, CFORTRAN_XCAT_(B,N);
#define PLONG_cfQ(B) long B;
-#define LONGV_cfT(M,I,A,B,D) ( (_(B,N) = * _3(M,_LONGV_A,I)), \
- B = F2Clongv(_(B,N),A) )
+#define LONGV_cfT(M,I,A,B,D) ( (CFORTRAN_XCAT_(B,N) = * CFORTRAN_XCAT_3(M,_LONGV_A,I)), \
+ B = F2Clongv(CFORTRAN_XCAT_(B,N),A) )
#define PLONG_cfT(M,I,A,B,D) ((B=*A),&B)
-#define LONGV_cfR(A,B,D) C2Flongv(_(B,N),A,B);
+#define LONGV_cfR(A,B,D) C2Flongv(CFORTRAN_XCAT_(B,N),A,B);
#define PLONG_cfR(A,B,D) *A=B;
#define LONGV_cfH(S,U,B)
#define PLONG_cfH(S,U,B)
@@ -93,7 +93,7 @@ extern unsigned long gMinStrLen;
A->dsc$w_length, \
num_elem(A->dsc$a_pointer, \
A->dsc$w_length, \
- _3(M,_STRV_A,I) ) )
+ CFORTRAN_XCAT_3(M,_STRV_A,I) ) )
#else
#ifdef CRAYFortran
#define PPSTRING_cfT(M,I,A,B,D) (unsigned char*)_fcdtocp(A)
@@ -103,20 +103,20 @@ extern unsigned long gMinStrLen;
#endif
#define _cfMAX(A,B) ( (A>B) ? A : B )
-#define STRINGV_cfQ(B) char **B; unsigned int _(B,N), _(B,M);
+#define STRINGV_cfQ(B) char **B; unsigned int CFORTRAN_XCAT_(B,N), CFORTRAN_XCAT_(B,M);
#define STRINGV_cfR(A,B,D) free(B[0]); free(B);
#define TTSTR( A,B,D) \
((B=(char*)malloc(_cfMAX(D,gMinStrLen)+1))[D]='\0',memcpy(B,A,D), \
kill_trailing(B,' '))
#define TTTTSTRV( A,B,D,E) ( \
- _(B,N)=_cfMAX(E,1), \
- _(B,M)=_cfMAX(D,gMinStrLen)+1, \
- B=(char**)malloc(_(B,N)*sizeof(char*)), \
- B[0]=(char*)malloc(_(B,N)*_(B,M)), \
- vindex(B,_(B,M),_(B,N),f2cstrv2(A,B[0],D,_(B,M),_(B,N))) \
+ CFORTRAN_XCAT_(B,N)=_cfMAX(E,1), \
+ CFORTRAN_XCAT_(B,M)=_cfMAX(D,gMinStrLen)+1, \
+ B=(char**)malloc(CFORTRAN_XCAT_(B,N)*sizeof(char*)), \
+ B[0]=(char*)malloc(CFORTRAN_XCAT_(B,N)*CFORTRAN_XCAT_(B,M)), \
+ vindex(B,CFORTRAN_XCAT_(B,M),CFORTRAN_XCAT_(B,N),f2cstrv2(A,B[0],D,CFORTRAN_XCAT_(B,M),CFORTRAN_XCAT_(B,N))) \
)
#define RRRRPSTRV(A,B,D) \
- c2fstrv2(B[0],A,_(B,M),D,_(B,N)), \
+ c2fstrv2(B[0],A,CFORTRAN_XCAT_(B,M),D,CFORTRAN_XCAT_(B,N)), \
free(B[0]), \
free(B);
@@ -169,10 +169,10 @@ static char *f2cstrv2(char *fstr, char*
#undef BYTE_cfSTR
#undef BYTEV_cfSTR
-#define BYTE_cfINT(N,A,B,X,Y,Z) _(CFARGS,N)(A,BYTE,B,X,Y,Z,0)
-#define BYTEV_cfINT(N,A,B,X,Y,Z) _(CFARGS,N)(A,BYTEV,B,X,Y,Z,0)
-#define BYTE_cfSTR(N,T,A,B,C,D,E) _(CFARGS,N)(T,BYTE,A,B,C,D,E)
-#define BYTEV_cfSTR(N,T,A,B,C,D,E) _(CFARGS,N)(T,BYTEV,A,B,C,D,E)
+#define BYTE_cfINT(N,A,B,X,Y,Z) CFORTRAN_XCAT_(CFARGS,N)(A,BYTE,B,X,Y,Z,0)
+#define BYTEV_cfINT(N,A,B,X,Y,Z) CFORTRAN_XCAT_(CFARGS,N)(A,BYTEV,B,X,Y,Z,0)
+#define BYTE_cfSTR(N,T,A,B,C,D,E) CFORTRAN_XCAT_(CFARGS,N)(T,BYTE,A,B,C,D,E)
+#define BYTEV_cfSTR(N,T,A,B,C,D,E) CFORTRAN_XCAT_(CFARGS,N)(T,BYTEV,A,B,C,D,E)
#define BYTE_cfSEP(T,B) INT_cfSEP(T,B)
#define BYTEV_cfSEP(T,B) INT_cfSEP(T,B)
#define BYTE_cfH(S,U,B) STRING_cfH(S,U,B)
@@ -211,11 +211,11 @@ static char *f2cstrv2(char *fstr, char*
#undef LOGICALV_cfSTR
#undef LOGICALV_cfT
-#define LOGICALV_cfSTR(N,T,A,B,C,D,E) _(CFARGS,N)(T,LOGICALV,A,B,C,D,E)
-#define LOGICALV_cfQ(B) char *B; unsigned int _(B,N);
-#define LOGICALV_cfT(M,I,A,B,D) (_(B,N)= * _3(M,_LOGV_A,I), \
- B=F2CcopyLogVect(_(B,N),A))
-#define LOGICALV_cfR(A,B,D) C2FcopyLogVect(_(B,N),A,B);
+#define LOGICALV_cfSTR(N,T,A,B,C,D,E) CFORTRAN_XCAT_(CFARGS,N)(T,LOGICALV,A,B,C,D,E)
+#define LOGICALV_cfQ(B) char *B; unsigned int CFORTRAN_XCAT_(B,N);
+#define LOGICALV_cfT(M,I,A,B,D) (CFORTRAN_XCAT_(B,N)= * CFORTRAN_XCAT_3(M,_LOGV_A,I), \
+ B=F2CcopyLogVect(CFORTRAN_XCAT_(B,N),A))
+#define LOGICALV_cfR(A,B,D) C2FcopyLogVect(CFORTRAN_XCAT_(B,N),A,B);
#define LOGICALV_cfH(S,U,B)
static char *F2CcopyLogVect(long size, int *A)
@@ -268,20 +268,20 @@ extern fitsfile *gFitsFiles[]; /*
memchr(A,'\0',D) ? A : TTSTR(A,B,D)
#define FCALLSCFUN0(T0,CN,UN,LN) \
- CFextern _(T0,_cfFZ)(UN,LN) void ABSOFT_cf2(T0)); \
- CFextern _(T0,_cfFZ)(UN,LN) void ABSOFT_cf2(T0)) \
- {_Icf(2,UU,T0,A0,0); _Icf(0,L,T0,0,0) CN(); _Icf(0,K,T0,0,0) _(T0,_cfI)}
+ CFextern CFORTRAN_XCAT_(T0,_cfFZ)(UN,LN) void ABSOFT_cf2(T0)); \
+ CFextern CFORTRAN_XCAT_(T0,_cfFZ)(UN,LN) void ABSOFT_cf2(T0)) \
+ {_Icf(2,UU,T0,A0,0); _Icf(0,L,T0,0,0) CN(); _Icf(0,K,T0,0,0) CFORTRAN_XCAT_(T0,_cfI)}
#define FCALLSCFUN14(T0,CN,UN,LN,T1,T2,T3,T4,T5,T6,T7,T8,T9,TA,TB,TC,TD,TE) \
- CFextern _(T0,_cfF)(UN,LN) \
+ CFextern CFORTRAN_XCAT_(T0,_cfF)(UN,LN) \
CFARGT14(NCF,DCF,ABSOFT_cf2(T0),T1,T2,T3,T4,T5,T6,T7,T8,T9,TA,TB,TC,TD,TE)); \
- CFextern _(T0,_cfF)(UN,LN) \
+ CFextern CFORTRAN_XCAT_(T0,_cfF)(UN,LN) \
CFARGT14(NCF,DCF,ABSOFT_cf2(T0),T1,T2,T3,T4,T5,T6,T7,T8,T9,TA,TB,TC,TD,TE)) \
{ CFARGT14S(QCF,T1,T2,T3,T4,T5,T6,T7,T8,T9,TA,TB,TC,TD,TE) \
_Icf(2,UU,T0,A0,0); _Icf(0,L,T0,0,0) CN( TCF(LN,T1,1,0) TCF(LN,T2,2,1) \
TCF(LN,T3,3,1) TCF(LN,T4,4,1) TCF(LN,T5,5,1) TCF(LN,T6,6,1) TCF(LN,T7,7,1) \
TCF(LN,T8,8,1) TCF(LN,T9,9,1) TCF(LN,TA,10,1) TCF(LN,TB,11,1) TCF(LN,TC,12,1) \
TCF(LN,TD,13,1) TCF(LN,TE,14,1) ); _Icf(0,K,T0,0,0) \
- CFARGT14S(RCF,T1,T2,T3,T4,T5,T6,T7,T8,T9,TA,TB,TC,TD,TE) _(T0,_cfI) \
+ CFARGT14S(RCF,T1,T2,T3,T4,T5,T6,T7,T8,T9,TA,TB,TC,TD,TE) CFORTRAN_XCAT_(T0,_cfI) \
}

24
debian/patches/03-off_t.diff vendored Normal file
View File

@ -0,0 +1,24 @@
--- a/fitsio.h
+++ b/fitsio.h
@@ -69,7 +69,7 @@
# define _MIPS_SZLONG 64
#endif
-#if defined(linux) || defined(__APPLE__) || defined(__sgi)
+#if defined(__linux__) || defined(__APPLE__) || defined(__sgi)
# include <sys/types.h> /* apparently needed on debian linux systems */
#endif /* to define off_t */
@@ -83,10 +83,10 @@
/* on whether _LARGEFILE_SOURCE is defined in sys/feature_tests.h */
/* (at least on Solaris platforms using cc) */
-/* Debian systems require: "(defined(linux) && defined(__off_t_defined))" */
+/* Debian systems require: "(defined(__linux__) && defined(__off_t_defined))" */
/* the mingw-w64 compiler requires: "(defined(__MINGW32__) && defined(_OFF_T_DEFINED))" */
#if defined(_OFF_T) \
- || (defined(linux) && defined(__off_t_defined)) \
+ || (defined(__linux__) && defined(__off_t_defined)) \
|| (defined(__MINGW32__) && defined(_OFF_T_DEFINED)) \
|| defined(_MIPS_SZLONG) || defined(__APPLE__) || defined(_AIX)
# define OFF_T off_t

View File

@ -0,0 +1,15 @@
---
cfitsio.pc.in | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- a/cfitsio.pc.in
+++ b/cfitsio.pc.in
@@ -7,6 +7,6 @@
Description: FITS File Subroutine Library
URL: https://heasarc.gsfc.nasa.gov/fitsio/
Version: @CFITSIO_MAJOR@.@CFITSIO_MINOR@
-Libs: -L${libdir} -lcfitsio @LIBS@
-Libs.private: -lm
+Libs: -L${libdir} -lcfitsio -lpthread
+Libs.private: -lm @LIBS@
Cflags: -I${includedir}

48
debian/patches/05-system-zlib.patch vendored Normal file
View File

@ -0,0 +1,48 @@
---
Makefile.in | 6 ++----
cfitsio.pc.in | 2 +-
zlib/zcompress.c | 2 +-
3 files changed, 4 insertions(+), 6 deletions(-)
--- a/Makefile.in
+++ b/Makefile.in
@@ -68,9 +68,7 @@
pliocomp.c fits_hcompress.c fits_hdecompress.c \
simplerng.c @GSIFTP_SRC@
-ZLIB_SOURCES = zlib/adler32.c zlib/crc32.c zlib/deflate.c zlib/infback.c \
- zlib/inffast.c zlib/inflate.c zlib/inftrees.c zlib/trees.c \
- zlib/uncompr.c zlib/zcompress.c zlib/zuncompress.c zlib/zutil.c
+ZLIB_SOURCES = zlib/zcompress.c zlib/zuncompress.c
SOURCES = ${CORE_SOURCES} ${ZLIB_SOURCES} @F77_WRAPPERS@
@@ -103,7 +101,7 @@
shared: lib${PACKAGE}${SHLIB_SUFFIX}
lib${PACKAGE}${SHLIB_SUFFIX}: ${OBJECTS}
- ${SHLIB_LD} ${LDFLAGS} -o ${CFITSIO_SHLIB} ${OBJECTS} -lm ${LIBS_CURL} ${LIBS}
+ ${SHLIB_LD} ${LDFLAGS} -o ${CFITSIO_SHLIB} ${OBJECTS} -lm -lz ${LIBS_CURL} ${LIBS}
@if [ "x${CFITSIO_SHLIB_SONAME}" != x ]; then \
ln -sf ${CFITSIO_SHLIB} ${CFITSIO_SHLIB_SONAME}; \
ln -sf ${CFITSIO_SHLIB_SONAME} $@; \
--- a/cfitsio.pc.in
+++ b/cfitsio.pc.in
@@ -8,5 +8,5 @@
URL: https://heasarc.gsfc.nasa.gov/fitsio/
Version: @CFITSIO_MAJOR@.@CFITSIO_MINOR@
Libs: -L${libdir} -lcfitsio -lpthread
-Libs.private: -lm @LIBS@
+Libs.private: -lm -lz @LIBS@
Cflags: -I${includedir}
--- a/zlib/zcompress.c
+++ b/zlib/zcompress.c
@@ -3,7 +3,7 @@
#include <stdlib.h>
#include <string.h>
#include <limits.h>
-#include "zlib.h"
+#include <zlib.h>
#define GZBUFSIZE 115200 /* 40 FITS blocks */
#define BUFFINCR 28800 /* 10 FITS blocks */

36
debian/patches/06-riscv64.diff vendored Normal file
View File

@ -0,0 +1,36 @@
--- a/fitsio2.h
+++ b/fitsio2.h
@@ -137,6 +137,20 @@ extern int Fitsio_Pthread_Status;
# error "can't handle long size given by _MIPS_SZLONG"
# endif
+#elif defined(__riscv)
+
+/* RISC-V is little endian */
+
+#define BYTESWAPPED TRUE
+
+# if __riscv_xlen == 32
+# define LONGSIZE 32
+# elif __riscv_xlen == 64
+# define LONGSIZE 64
+# else
+# error "can't handle long size given by __riscv_xlen"
+# endif
+
/* ============================================================== */
/* the following are all 32-bit byteswapped platforms */
@@ -204,12 +218,6 @@ extern int Fitsio_Pthread_Status;
#define BYTESWAPPED FALSE
#endif
-#elif defined(__riscv)
-
-/* RISC-V is little endian */
-
-#define BYTESWAPPED TRUE
-
#else
/* assume all other machine uses the same IEEE formats as used in FITS files */

14
debian/patches/08-hurd.diff vendored Normal file
View File

@ -0,0 +1,14 @@
--- cfitsio-3.370.orig/configure.in
+++ cfitsio-3.370/configure.in
@@ -130,6 +130,11 @@ case $host in
ARCH="linux"
EXT="lnx"
;;
+ *-*-gnu)
+ # Hurd only has 3 values in the triplet
+ ARCH="linux"
+ EXT="lnx"
+ ;;
*hpux*)
ARCH="hp"
EXT="hpu"

View File

@ -0,0 +1,13 @@
--- cfitsio-3.470.orig/drvrnet.c
+++ cfitsio-3.470/drvrnet.c
@@ -1257,9 +1257,7 @@ int curlProgressCallback(void *clientp,
urlname = (char *)clientp;
if (urlname)
{
- fprintf(stderr,"Downloading ");
- fprintf(stderr,urlname);
- fprintf(stderr,"...\n");
+ fprintf(stderr,"Downloading %s...\n", urlname);
}
isFirst = 0;
}

8
debian/patches/series vendored Normal file
View File

@ -0,0 +1,8 @@
01-LDFLAGS.diff
02-system-cfortran.patch
03-off_t.diff
04-pkgconfig-private.patch
05-system-zlib.patch
06-riscv64.diff
08-hurd.diff
09-drvnet-format-security.diff

50
debian/rules vendored Executable file
View File

@ -0,0 +1,50 @@
#!/usr/bin/make -f
export DEB_CFLAGS_MAINT_APPEND = -Wall
%:
dh $@
override_dh_auto_clean:
dh_auto_clean
rm -f fitscopy imcopy
rm -f testprog.fit
rm -rf docs/cfitsio docs/fitsio docs/quick
override_dh_auto_configure-arch:
dh_auto_configure -- --enable-reentrant --with-bzip2
override_dh_auto_configure-indep:
# Nothing to do
override_dh_auto_build-arch:
dh_auto_build -- shared
dh_auto_build -- fitscopy fpack funpack imcopy testprog
override_dh_auto_build-indep:
for i in cfitsio fitsio quick ; do \
cd $(CURDIR) ; \
mkdir -p $(CURDIR)/docs/$$i ; \
hevea -fix -o docs/$$i/$$i docs/$$i.tex ; \
cd $(CURDIR)/docs/$$i ; \
hacha $$i ; \
rm -f $$i *.haux *.htoc *.hind ; \
cd $(CURDIR)/docs ; \
latex $$i.tex ; \
latex $$i.tex ; \
latex $$i.tex ; \
dvipdf $$i.dvi ; \
done
override_dh_auto_test-arch:
ifeq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
LD_LIBRARY_PATH=$(CURDIR) $(CURDIR)/testprog
endif
override_dh_auto_install-arch:
dh_auto_install
install -d -m 755 $(CURDIR)/debian/tmp/usr/bin
install -m 755 fitscopy fpack funpack imcopy $(CURDIR)/debian/tmp/usr/bin
override_dh_auto_install-indep:
# Nothing to do

1
debian/source/format vendored Normal file
View File

@ -0,0 +1 @@
3.0 (quilt)

2
debian/tests/control vendored Normal file
View File

@ -0,0 +1,2 @@
Tests: testprog
Depends: build-essential, libcfitsio-dev, pkg-config

17
debian/tests/testprog vendored Executable file
View File

@ -0,0 +1,17 @@
#!/bin/sh
set -e
WORKDIR=$(mktemp -d)
trap "rm -rf $WORKDIR" 0 INT QUIT ABRT PIPE TERM
CFLAGS="-O2 -Wall $(pkg-config --cflags cfitsio)"
LDFLAGS=$(pkg-config --libs cfitsio)
cc $CFLAGS -o $WORKDIR/testprog.o -c testprog.c
cc $LDFLAGS -o $WORKDIR/testprog $WORKDIR/testprog.o
echo "build: OK"
[ -x $WORKDIR/testprog ]
$WORKDIR/testprog
echo "run: OK"