On Fri, Mar 19, 2021 at 12:02:48PM +0100, Theo Buehler wrote:
> On Fri, Mar 19, 2021 at 11:01:27AM +0100, Claudio Jeker wrote:
> > This is mostly for -portable but also the native version should be able to
> > mention that it is not the -portable version.
> > This is a compromise I can live with, hope everyone else agrees.
> 
> Yes. Let's keep the diff in portable as simple as possible (I'd also be
> fine with #ifndef so it can be defined from the build framework if that
> helps). I don't really care what it prints in OpenBSD.

There is a #ifndef patch already in portable for the other defines so I
think adding this should be fine. Lets keep the autoconf # madness to
-portable.

> However, I would do Vv instead of vV in usage() and SYNOPSIS - somewhat
> surprised that mandoc -Tlint doesn't complain.
> 
> ok tb

Good catch, I changed the usage and SYNOPSIS.
 
> > 
> > -- 
> > :wq Claudio
> > 
> > ? obj
> > Index: extern.h
> > ===================================================================
> > RCS file: /cvs/src/usr.sbin/rpki-client/extern.h,v
> > retrieving revision 1.54
> > diff -u -p -r1.54 extern.h
> > --- extern.h        18 Mar 2021 14:03:42 -0000      1.54
> > +++ extern.h        19 Mar 2021 09:58:07 -0000
> > @@ -458,5 +458,6 @@ int     mkpath(const char *);
> >  
> >  #define            RPKI_PATH_OUT_DIR       "/var/db/rpki-client"
> >  #define            RPKI_PATH_BASE_DIR      "/var/cache/rpki-client"
> > +#define            RPKI_VERSION            "OpenBSD"
> >  
> >  #endif /* ! EXTERN_H */
> > Index: main.c
> > ===================================================================
> > RCS file: /cvs/src/usr.sbin/rpki-client/main.c,v
> > retrieving revision 1.121
> > diff -u -p -r1.121 main.c
> > --- main.c  19 Mar 2021 09:43:59 -0000      1.121
> > +++ main.c  19 Mar 2021 09:58:08 -0000
> > @@ -880,7 +880,7 @@ main(int argc, char *argv[])
> >         "proc exec unveil", NULL) == -1)
> >             err(1, "pledge");
> >  
> > -   while ((c = getopt(argc, argv, "b:Bcd:e:jnos:t:T:v")) != -1)
> > +   while ((c = getopt(argc, argv, "b:Bcd:e:jnos:t:T:vV")) != -1)
> >             switch (c) {
> >             case 'b':
> >                     bind_addr = optarg;
> > @@ -923,6 +923,8 @@ main(int argc, char *argv[])
> >             case 'v':
> >                     verbose++;
> >                     break;
> > +           case 'V':
> > +                   errx(0, "version: %s", RPKI_VERSION);
> >             default:
> >                     goto usage;
> >             }
> > @@ -1294,7 +1296,7 @@ main(int argc, char *argv[])
> >  
> >  usage:
> >     fprintf(stderr,
> > -       "usage: rpki-client [-Bcjnov] [-b sourceaddr] [-d cachedir]"
> > +       "usage: rpki-client [-BcjnovV] [-b sourceaddr] [-d cachedir]"
> >         " [-e rsync_prog]\n"
> >         "                   [-s timeout] [-T table] [-t tal]"
> >         " [outputdir]\n");
> > Index: rpki-client.8
> > ===================================================================
> > RCS file: /cvs/src/usr.sbin/rpki-client/rpki-client.8,v
> > retrieving revision 1.33
> > diff -u -p -r1.33 rpki-client.8
> > --- rpki-client.8   9 Dec 2020 11:33:10 -0000       1.33
> > +++ rpki-client.8   19 Mar 2021 09:58:08 -0000
> > @@ -22,7 +22,7 @@
> >  .Nd RPKI validator to support BGP Origin Validation
> >  .Sh SYNOPSIS
> >  .Nm
> > -.Op Fl Bcjnov
> > +.Op Fl BcjnovV
> >  .Op Fl b Ar sourceaddr
> >  .Op Fl d Ar cachedir
> >  .Op Fl e Ar rsync_prog
> > @@ -122,6 +122,8 @@ By default
> >  .Nm
> >  will load all TAL files in
> >  .Pa /etc/rpki .
> > +.It Fl V
> > +Show the version and exit.
> >  .It Fl v
> >  Specified once, prints information about status.
> >  Twice, prints each filename as it's processed.
> > 
> 

-- 
:wq Claudio

Reply via email to