summaryrefslogtreecommitdiff
path: root/lib/getopt_long.c
Commit message (Collapse)AuthorAgeFilesLines
* lib: Move vlog.h to <openvswitch/vlog.h>Thomas Graf2014-12-151-1/+1
| | | | | | | | A new function vlog_insert_module() is introduced to avoid using list_insert() from the vlog.h header. Signed-off-by: Thomas Graf <tgraf@noironetworks.com> Acked-by: Ben Pfaff <blp@nicira.com>
* getopt_long: Fix broken sequence of casts in __UNCONST macor.Eitan Eliahu2014-09-021-6/+5
| | | | | | | | | | | Unlike the compilation mode used for OVS x64 Linux Windows long word is 4 bytes for both 32 and 64 bit builds. Replaced _UNCONST macro with CONST_CAST to avoid the intermediate casting to an integer. Testing: 32 and 64 Windows builds. Signed-off-by: Eitan Eliahu eliahue@vmware.com Signed-off-by: Ben Pfaff <blp@nicira.com>
* getopt_long: Copy over the implementation from netbsd.Gurucharan Shetty2014-01-271-0/+460
Windows does not have a getopt_long function. This commit copies over the getopt_long implementation from netbsd with some minor modifications and is used only on Windows platform. Modifications on top of the version in NetBSD repo. * Remove header files not available in Visual Studio. * Remove some unwanted #defines. * Add Open vSwitch specific header files like config.h, vlog.h, util.h * Add the following #define's define __UNCONST(a) ((void *)(unsigned long)(const void *)(a)) define _DIAGASSERT(q) ovs_assert(q) define warnx VLOG_WARN * Add extern declaration in getopt.h for optarg, optind. Signed-off-by: Gurucharan Shetty <gshetty@nicira.com> Acked-by: Ben Pfaff <blp@nicira.com>