4
#ifndef NET_SNMP_CONFIG_H
5
#error "Please include <net-snmp/net-snmp-config.h> before this file"
12
/* Portions of this file are subject to the following copyrights. See
13
* the Net-SNMP's COPYING file for more details and other copyrights
16
/***********************************************************
17
Copyright 1993 by Carnegie Mellon University
21
Permission to use, copy, modify, and distribute this software and its
22
documentation for any purpose and without fee is hereby granted,
23
provided that the above copyright notice appear in all copies and that
24
both that copyright notice and this permission notice appear in
25
supporting documentation, and that the name of CMU not be
26
used in advertising or publicity pertaining to distribution of the
27
software without specific, written prior permission.
29
CMU DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
30
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
31
CMU BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
32
ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
33
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
34
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
36
******************************************************************/
38
* portions Copyright � 2003 Sun Microsystems, Inc. All rights reserved.
39
* Use is subject to license terms specified in the COPYING file
40
* distributed with the Net-SNMP package.
45
* function to create a daemon. Will fork and call setsid().
47
* Returns: -1 : fork failed
50
int netsnmp_daemonize(int quit_immediately, int stderr_log);
53
* Definitions for the system dependent library file
58
#ifndef HAVE_DIRENT_H /* MingGW has dirent.h but also defines WIN32 */
60
* structure of a directory entry
62
typedef struct direct {
63
long d_ino; /* inode number (not used by MS-DOS) */
64
int d_namlen; /* Name length */
65
char d_name[257]; /* file name */
69
* structure for dir operations
71
typedef struct _dir_struc {
72
char *start; /* Starting position */
73
char *curr; /* Current position */
74
long size; /* Size of string table */
75
long nfiles; /* number if filenames in table */
76
struct direct dirstr; /* Directory structure to return */
79
DIR *opendir(const char *filename);
80
struct direct *readdir(DIR * dirp);
81
int closedir(DIR * dirp);
82
#endif /* HAVE_DIRENT_H */
84
#ifndef HAVE_GETTIMEOFDAY
85
int gettimeofday(struct timeval *, struct timezone *tz);
87
#ifndef HAVE_STRCASECMP
88
int strcasecmp(const char *s1, const char *s2);
90
#ifndef HAVE_STRNCASECMP
91
int strncasecmp(const char *s1, const char *s2, size_t n);
94
char *winsock_startup(void);
95
void winsock_cleanup(void);
97
#define SOCK_STARTUP winsock_startup()
98
#define SOCK_CLEANUP winsock_cleanup()
106
#endif /* MSVC_PERL */
108
#include <net-snmp/types.h> /* For definition of in_addr_t */
110
in_addr_t get_myaddr(void);
111
long get_uptime(void);
114
char *strdup(const char *);
117
int setenv(const char *, const char *, int);
120
int calculate_time_diff(struct timeval *,
123
#ifndef HAVE_STRCASESTR
124
char *strcasestr(const char *, const char *);
127
long strtol(const char *, char **, int);
130
unsigned long strtoul(const char *, char **, int);
132
#ifndef HAVE_SNPRINTF
133
int snprintf(char *, size_t, const char *, ...);
136
int mkdirhier(const char *pathname, mode_t mode,
139
size_t strlcpy(char *, const char *, size_t);
145
#endif /* SNMP_SYSTEM_H */