/usr/include/skalibs/sgetopt.h is in skalibs-dev 0.47-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | /* Public domain. */
#ifndef SGETOPT_H
#define SGETOPT_H
/* reentrant */
struct subgetopt_t
{
int ind ;
int err ;
int problem ;
char const *arg ;
unsigned int pos ;
char const *prog ;
} ;
#define SUBGETOPT_ZERO { 1, 1, 0, 0, 0, 0 }
extern int subgetopt_r (int, char const *const *, char const *, struct subgetopt_t *) ;
/* non-reentrant */
extern int sgetopt_r (int, char const *const *, char const *, struct subgetopt_t *) ;
extern struct subgetopt_t subgetopt_here ;
#define subgetopt(argc, argv, opts) subgetopt_r((argc), (argv), (opts), &subgetopt_here)
#define sgetopt(argc, argv, opts) sgetopt_r((argc), (argv), (opts), &subgetopt_here)
#define sgetopt_prog() (subgetopt_here.prog = PROG)
/* define SUBGETOPTNOSHORT to avoid potential name conflicts */
#ifndef SUBGETOPTNOSHORT
# define getopt sgetopt
# define optarg subgetopt_here.arg
# define optind subgetopt_here.ind
# define opterr subgetopt_here.err
# define optopt subgetopt_here.problem
# define opteof (-1)
#endif
#endif
|