Skip to content

Commit

Permalink
Merge pull request #345 from olebole/tbtables
Browse files Browse the repository at this point in the history
NOIRLAB: Clean up tbtables package
  • Loading branch information
olebole authored Jan 28, 2024
2 parents 7f50182 + c0f6337 commit 81fde24
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 815 deletions.
15 changes: 3 additions & 12 deletions pkg/tbtables/mkpkg
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
# Phil Hodge, 31-July-2001, move @cfitsio.



update:
$checkout libtbtables.a lib$
$update libtbtables.a
Expand Down Expand Up @@ -236,15 +235,7 @@ libtbtables.a:
tbnparse.x <ctype.h> <ctotok.h> <tbset.h>
@selector

# $ifdef (SPPFITSIO)
$echo "NOTE: SPP FITSIO will be used for FITS tables."
tbfhp_f.x <tbset.h> tbtables.h tblfits.h
@fitsio
# $else
# $echo "NOTE: CFITSIO will be used for FITS tables."
# $echo "NOTE: CFITSIO does not support IRAF networking."
# tbfhp.x <tbset.h> tbtables.h tblfits.h
# tbfxff.c "cfitsio/fitsio.h" fitsio_spp.h underscore.h
# @cfitsio
# $endif
$echo "NOTE: SPP FITSIO will be used for FITS tables."
tbfhp_f.x <tbset.h> tbtables.h tblfits.h
@fitsio
;
2 changes: 1 addition & 1 deletion pkg/tbtables/selector/trsopen.x
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ int nc, ic, index, delta, size

pointer sp, token, ptr, valbuf

string notnum "not a number"
#string notnum "not a number"
string noroom "expression too complex"
string nostop "trailing quote not found"

Expand Down
8 changes: 7 additions & 1 deletion pkg/tbtables/tbcrcd.x
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,8 @@ int clen # length in char of entire entry
int value # this will be returned
int tbeszt() # size in char of one element of type text

int sz

begin
clen = COL_LEN(cptr)

Expand Down Expand Up @@ -204,7 +206,11 @@ begin
value = 1

default:
value = clen / tbeszt (cptr) # char string
sz = tbeszt (cptr) # char string
if (sz > 0)
value = clen / sz
else
value = 0
}

return (value)
Expand Down
2 changes: 1 addition & 1 deletion pkg/tbtables/tbfnew.x
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ bool simple, extend
int status # zero is OK
int hdu # HDU number (zero is primary header)
int fd[2] # unit number for FITS file; cfitsio pointer
double dfd # to force alignment of fd
#double dfd # to force alignment of fd
#equivalence (fd, dfd) # to force alignment of fd
int hdutype # type of current HDU
int extver # value of EXTVER from existing header, or -1
Expand Down
2 changes: 1 addition & 1 deletion pkg/tbtables/tbfopn.x
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ int hdu # HDU number
int extver # extension version number
int hdutype # type of HDU
int fd[2] # unit number for FITS file; cfitsio pointer
double dfd # to force alignment of fd
#double dfd # to force alignment of fd
#equivalence (fd, dfd) # to force alignment of fd
int tbffnd()
bool strne()
Expand Down
Loading

0 comments on commit 81fde24

Please sign in to comment.