sci-misc/fitsverify: add 4.20

Bug: https://bugs.gentoo.org/875128
Signed-off-by: David Seifert <soap@gentoo.org>
This commit is contained in:
David Seifert
2022-12-26 13:52:18 +01:00
parent 4d50c7b5b4
commit f52f3baed9
4 changed files with 118 additions and 0 deletions

View File

@@ -1 +1,2 @@
DIST fitsverify-4.18.tar.gz 42840 BLAKE2B e02fc9d5558e31fa2fa98b155a8acabe75f1fa2dfd8924519c6117cfde4754a2f49085e77fe52c0f859310877f5927e7a17f93c458e7d5aa72cb14b313c99211 SHA512 4be82078bf328538e1b98b386aedd6b2501a25e3d17f19e0db5b82ed8f62493e51f01228653ecf769ff3c706a16c8d65fe64ebc8693e8dd406e88d0a9ffc5010
DIST fitsverify-4.20.tar.gz 43113 BLAKE2B b449a93cc99b477b7c720f2fd460baa706235929ac87b15f18405dd507e085c6759cb9c4b76b2abc4318a4711e4db507334972cf0cf1620251df32a4cf1709fa SHA512 686940d509ffd355f7616d6348e143f91152a6f248c0fea512cd8a47cda4b93048e1e7304652af598b7cca4685437c0a0e6f170213335381c77e8ff7cd7bf49c

View File

@@ -0,0 +1,75 @@
--- a/fverify.h
+++ b/fverify.h
@@ -169,16 +169,16 @@
int errnum; /* number of errors in this hdu */
int wrnno; /* number of warnning in this hdu */
}HduName;
-int get_total_warn();
-int get_total_err();
-void init_hduname();
+int get_total_warn(void);
+int get_total_err(void);
+void init_hduname(void);
void set_hduname(int hdunum,int hdutype, char* extname,int extver);
void set_hduerr(int hdunum);
void set_hdubasic(int hdunum,int hdutype);
int test_hduname(int hdunum1, int hdunum2);
void total_errors (int *totalerr, int * totalwrn);
void hdus_summary(FILE *out);
-void destroy_hduname();
+void destroy_hduname(void);
void test_end(fitsfile *infits, FILE *out);
void init_report(FILE *out, char *rootnam);
void close_report(FILE *out);
@@ -198,7 +198,7 @@
int wrtserr(FILE *out, char* mess, int *status, int severity);
void wrtsep (FILE *out,char fill, char *title, int nchar);
void num_err_wrn(int *num_err, int *num_wrn);
-void reset_err_wrn();
+void reset_err_wrn(void);
int compkey (const void *key1, const void *key2);
int compcol (const void *col1, const void *col2);
int compcol (const void *col1, const void *col2);
--- a/fvrf_file.c
+++ b/fvrf_file.c
@@ -3,17 +3,17 @@
static int total_err=1; /* initialzed to 1 in case fail to open file */
static int total_warn=0;
-int get_total_warn()
+int get_total_warn(void)
{
return (total_warn);
}
-int get_total_err()
+int get_total_err(void)
{
return (total_err);
}
/* Get the total hdu number and allocate the memory for hdu array */
-void init_hduname()
+void init_hduname(void)
{
int i;
/* allocate memories for the hdu structure array */
@@ -168,7 +168,7 @@
-void destroy_hduname()
+void destroy_hduname(void)
{
int i;
for (i=0; i < totalhdu; i++) free(hduname[i]);
--- a/fvrf_misc.c
+++ b/fvrf_misc.c
@@ -20,7 +20,7 @@
return;
}
-void reset_err_wrn()
+void reset_err_wrn(void)
{
nwrns = 0;
nerrs = 0;

View File

@@ -0,0 +1,10 @@
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,7 @@
+PKG_CONFIG ?= pkg-config
+
+CPPFLAGS += -DSTANDALONE $(shell $(PKG_CONFIG) --cflags cfitsio)
+LIBS += $(shell $(PKG_CONFIG) --libs cfitsio)
+
+fitsverify: ftverify.o fvrf_data.o fvrf_file.o fvrf_head.o fvrf_key.o fvrf_misc.o
+ $(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LIBS)

View File

@@ -0,0 +1,32 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs
DESCRIPTION="FITS file format checker"
HOMEPAGE="https://heasarc.gsfc.nasa.gov/docs/software/ftools/fitsverify/"
SRC_URI="https://heasarc.gsfc.nasa.gov/docs/software/ftools/fitsverify/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
RDEPEND="sci-libs/cfitsio:0="
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig"
PATCHES=(
"${FILESDIR}"/${P}-makefile.patch
"${FILESDIR}"/${P}-Wimplicit-function-declaration.patch
)
src_configure() {
tc-export CC PKG_CONFIG
}
src_install() {
dobin fitsverify
einstalldocs
}