Server Wait On Clients System - API Documentation  v1.6.4
Server Wait On Clients System.
cmdlineargs.h
Go to the documentation of this file.
1 
14 /* **********************************************************************
15  * *
16  * Changelog *
17  * *
18  * Date Author Version Description *
19  * *
20  * 08/07/2015 MG 1.0.1 First release. *
21  * 09/05/2016 MG 1.0.2 Move header files to include directory. *
22  * 13/06/2016 MG 1.0.3 Adopt convention of using void in empty *
23  * function parameter lists. *
24  * 17/07/2016 MG 1.0.4 Move towards kernel coding style. *
25  * 07/05/2017 MG 1.0.5 Add --wait as a command line argument. *
26  * 12/11/2017 MG 1.0.6 Add Doxygen comments. *
27  * Add SPDX license tag. *
28  * 22/05/2018 MG 1.0.7 Make more generic for copy and paste *
29  * re-usability by using function with a *
30  * variable number of arguments. *
31  * 18/05/2019 MG 1.0.8 Merge sub-projects into one. *
32  * 27/03/2020 MG 1.0.9 Move into swocclient sub-directory as *
33  * the directory hierarchy needs to be the *
34  * same accross the source tree for *
35  * temporary libraries to work based on *
36  * the search in configure.ac. *
37  * 11/10/2021 MG 1.0.10 Move to internal directory. *
38  * Merge server and client versions. *
39  * 08/12/2021 MG 1.0.11 Tighten SPDX tag. *
40  * 17/09/2022 MG 1.0.12 Rename portability.h *
41  * Use pkginclude location. *
42  * *
43  ************************************************************************
44  */
45 
46 #ifndef CMDLINEARGS_H
47 #define CMDLINEARGS_H
48 
49 #include <limits.h>
50 
51 #include <libmgec/mge-portability.h>
52 
53 BEGIN_C_DECLS
54 
60 #define ARG_BUF PATH_MAX
61 
63 struct cla {
64  int is_set;
65  char argument[ARG_BUF];
66 };
67 
68 int process_cla(int argc, char **argv, ...);
69 
70 int cpyarg(char *flagarg, char *srcarg);
71 
72 END_C_DECLS
73 
74 #endif /* ndef CMDLINEARGS_H */
#define ARG_BUF
Argument buffer size.
Definition: cmdlineargs.h:60
int process_cla(int argc, char **argv,...)
Process command line arguments using getopt_long.
Definition: cmdlineargs.c:74
int cpyarg(char *flagarg, char *srcarg)
Definition: cmdlineargs.c:257
Command line argument.
Definition: cmdlineargs.h:63
char argument[ARG_BUF]
A possible argument to the flag.
Definition: cmdlineargs.h:65
int is_set
Flag is set, 1 is true, 0 is false.
Definition: cmdlineargs.h:64