Add qemu 2.4.0
[kvmfornfv.git] / qemu / roms / SLOF / lib / libc / include / getopt.h
1 /******************************************************************************
2  * Copyright (c) 2004, 2008 IBM Corporation
3  * All rights reserved.
4  * This program and the accompanying materials
5  * are made available under the terms of the BSD License
6  * which accompanies this distribution, and is available at
7  * http://www.opensource.org/licenses/bsd-license.php
8  *
9  * Contributors:
10  *     IBM Corporation - initial implementation
11  *****************************************************************************/
12
13 #ifndef GETOPT_H
14 #define GETOPT_H
15
16 extern char *optarg;
17 extern int optind;
18 extern int opterr;
19 extern int optopt;
20
21 struct option {
22         const char *name;
23         int has_arg;
24         int *flag;
25         int val;
26 };
27
28 enum {
29         no_argument = 0,
30         required_argument,
31         optional_argument
32 };
33
34 int getopt(int argc, char **, const char *);
35 int getopt_long(int argc, char **, const char *, const struct option *, int *);
36
37 #endif                          /* GETOPT_H */