mirror of
https://github.com/moparisthebest/curl
synced 2024-12-22 08:08:50 -05:00
- Provide in external interface preprocessor symbol definitions for
CARES_HAVE_ARES_LIBRARY_INIT and CARES_HAVE_ARES_LIBRARY_CLEANUP to ease the use of new capabilities. - Move ares_version() prototype to ares.h
This commit is contained in:
parent
4c9c9f0b89
commit
084447e414
@ -221,7 +221,7 @@ $(OBJ_DIR)\ares_destroy.obj: ares_destroy.c setup.h setup_once.h ares.h \
|
||||
$(OBJ_DIR)\ares_mkquery.obj: ares_mkquery.c setup.h setup_once.h nameser.h \
|
||||
ares.h ares_dns.h ares_build.h ares_rules.h
|
||||
|
||||
$(OBJ_DIR)\ares_version.obj: ares_version.c setup.h setup_once.h \
|
||||
$(OBJ_DIR)\ares_version.obj: ares_version.c setup.h setup_once.h ares.h \
|
||||
ares_version.h ares_build.h ares_rules.h
|
||||
|
||||
$(OBJ_DIR)\ares_expand_name.obj: ares_expand_name.c setup.h setup_once.h \
|
||||
|
@ -19,8 +19,9 @@
|
||||
#ifndef ARES__H
|
||||
#define ARES__H
|
||||
|
||||
#include "ares_build.h" /* c-ares build definitions */
|
||||
#include "ares_rules.h" /* c-ares rules enforcement */
|
||||
#include "ares_version.h" /* c-ares version defines */
|
||||
#include "ares_build.h" /* c-ares build definitions */
|
||||
#include "ares_rules.h" /* c-ares rules enforcement */
|
||||
|
||||
/*
|
||||
* Define WIN32 when build target is Win32 API
|
||||
@ -248,6 +249,7 @@ typedef int (*ares_sock_create_callback)(ares_socket_t socket_fd,
|
||||
|
||||
int ares_library_init(int flags);
|
||||
void ares_library_cleanup(void);
|
||||
const char *ares_version(int *version);
|
||||
|
||||
int ares_init(ares_channel *channelptr);
|
||||
int ares_init_options(ares_channel *channelptr, struct ares_options *options,
|
||||
|
@ -1,7 +1,7 @@
|
||||
/* $Id$ */
|
||||
|
||||
#include "setup.h"
|
||||
#include "ares_version.h"
|
||||
#include "ares.h"
|
||||
|
||||
const char *ares_version(int *version)
|
||||
{
|
||||
|
@ -11,15 +11,12 @@
|
||||
(ARES_VERSION_PATCH))
|
||||
#define ARES_VERSION_STR "1.6.1-CVS"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
const char *ares_version(int *version);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#if (ARES_VERSION >= 0x010601)
|
||||
# define CARES_HAVE_ARES_LIBRARY_INIT 1
|
||||
# define CARES_HAVE_ARES_LIBRARY_CLEANUP 1
|
||||
#else
|
||||
# undef CARES_HAVE_ARES_LIBRARY_INIT
|
||||
# undef CARES_HAVE_ARES_LIBRARY_CLEANUP
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user