FS-6010 VS2013 build changes
This commit is contained in:
parent
726981c5c8
commit
3687892e91
|
@ -27,6 +27,7 @@ APR_DECLARE(apr_status_t) apr_atomic_init(apr_pool_t *p)
|
||||||
* Remapping function pointer type to accept apr_uint32_t's type-safely
|
* Remapping function pointer type to accept apr_uint32_t's type-safely
|
||||||
* as the arguments for as our apr_atomic_foo32 Functions
|
* as the arguments for as our apr_atomic_foo32 Functions
|
||||||
*/
|
*/
|
||||||
|
#if (_MSC_VER < 1800)
|
||||||
typedef WINBASEAPI apr_uint32_t (WINAPI * apr_atomic_win32_ptr_fn)
|
typedef WINBASEAPI apr_uint32_t (WINAPI * apr_atomic_win32_ptr_fn)
|
||||||
(apr_uint32_t volatile *);
|
(apr_uint32_t volatile *);
|
||||||
typedef WINBASEAPI apr_uint32_t (WINAPI * apr_atomic_win32_ptr_val_fn)
|
typedef WINBASEAPI apr_uint32_t (WINAPI * apr_atomic_win32_ptr_val_fn)
|
||||||
|
@ -38,11 +39,14 @@ typedef WINBASEAPI apr_uint32_t (WINAPI * apr_atomic_win32_ptr_val_val_fn)
|
||||||
typedef WINBASEAPI void * (WINAPI * apr_atomic_win32_ptr_ptr_ptr_fn)
|
typedef WINBASEAPI void * (WINAPI * apr_atomic_win32_ptr_ptr_ptr_fn)
|
||||||
(volatile void **,
|
(volatile void **,
|
||||||
void *, const void *);
|
void *, const void *);
|
||||||
|
#endif
|
||||||
|
|
||||||
APR_DECLARE(apr_uint32_t) apr_atomic_add32(volatile apr_uint32_t *mem, apr_uint32_t val)
|
APR_DECLARE(apr_uint32_t) apr_atomic_add32(volatile apr_uint32_t *mem, apr_uint32_t val)
|
||||||
{
|
{
|
||||||
#if (defined(_M_IA64) || defined(_M_AMD64))
|
#if (defined(_M_IA64) || defined(_M_AMD64))
|
||||||
return InterlockedExchangeAdd(mem, val);
|
return InterlockedExchangeAdd(mem, val);
|
||||||
|
#elif (_MSC_VER >= 1800)
|
||||||
|
return InterlockedExchangeAdd(mem, val);
|
||||||
#else
|
#else
|
||||||
return ((apr_atomic_win32_ptr_val_fn)InterlockedExchangeAdd)(mem, val);
|
return ((apr_atomic_win32_ptr_val_fn)InterlockedExchangeAdd)(mem, val);
|
||||||
#endif
|
#endif
|
||||||
|
@ -55,6 +59,8 @@ APR_DECLARE(void) apr_atomic_sub32(volatile apr_uint32_t *mem, apr_uint32_t val)
|
||||||
{
|
{
|
||||||
#if (defined(_M_IA64) || defined(_M_AMD64))
|
#if (defined(_M_IA64) || defined(_M_AMD64))
|
||||||
InterlockedExchangeAdd(mem, -val);
|
InterlockedExchangeAdd(mem, -val);
|
||||||
|
#elif (_MSC_VER >= 1800)
|
||||||
|
InterlockedExchangeAdd(mem, -val);
|
||||||
#else
|
#else
|
||||||
((apr_atomic_win32_ptr_val_fn)InterlockedExchangeAdd)(mem, -val);
|
((apr_atomic_win32_ptr_val_fn)InterlockedExchangeAdd)(mem, -val);
|
||||||
#endif
|
#endif
|
||||||
|
@ -65,6 +71,8 @@ APR_DECLARE(apr_uint32_t) apr_atomic_inc32(volatile apr_uint32_t *mem)
|
||||||
/* we return old value, win32 returns new value :( */
|
/* we return old value, win32 returns new value :( */
|
||||||
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
||||||
return InterlockedIncrement(mem) - 1;
|
return InterlockedIncrement(mem) - 1;
|
||||||
|
#elif (_MSC_VER >= 1800)
|
||||||
|
return InterlockedIncrement(mem) - 1;
|
||||||
#else
|
#else
|
||||||
return ((apr_atomic_win32_ptr_fn)InterlockedIncrement)(mem) - 1;
|
return ((apr_atomic_win32_ptr_fn)InterlockedIncrement)(mem) - 1;
|
||||||
#endif
|
#endif
|
||||||
|
@ -74,6 +82,8 @@ APR_DECLARE(int) apr_atomic_dec32(volatile apr_uint32_t *mem)
|
||||||
{
|
{
|
||||||
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
||||||
return InterlockedDecrement(mem);
|
return InterlockedDecrement(mem);
|
||||||
|
#elif (_MSC_VER >= 1800)
|
||||||
|
return InterlockedDecrement(mem);
|
||||||
#else
|
#else
|
||||||
return ((apr_atomic_win32_ptr_fn)InterlockedDecrement)(mem);
|
return ((apr_atomic_win32_ptr_fn)InterlockedDecrement)(mem);
|
||||||
#endif
|
#endif
|
||||||
|
@ -83,6 +93,8 @@ APR_DECLARE(void) apr_atomic_set32(volatile apr_uint32_t *mem, apr_uint32_t val)
|
||||||
{
|
{
|
||||||
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
||||||
InterlockedExchange(mem, val);
|
InterlockedExchange(mem, val);
|
||||||
|
#elif (_MSC_VER >= 1800)
|
||||||
|
InterlockedExchange(mem, val);
|
||||||
#else
|
#else
|
||||||
((apr_atomic_win32_ptr_val_fn)InterlockedExchange)(mem, val);
|
((apr_atomic_win32_ptr_val_fn)InterlockedExchange)(mem, val);
|
||||||
#endif
|
#endif
|
||||||
|
@ -98,6 +110,8 @@ APR_DECLARE(apr_uint32_t) apr_atomic_cas32(volatile apr_uint32_t *mem, apr_uint3
|
||||||
{
|
{
|
||||||
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
||||||
return InterlockedCompareExchange(mem, with, cmp);
|
return InterlockedCompareExchange(mem, with, cmp);
|
||||||
|
#elif (_MSC_VER >= 1800)
|
||||||
|
return InterlockedCompareExchange(mem, with, cmp);
|
||||||
#else
|
#else
|
||||||
return ((apr_atomic_win32_ptr_val_val_fn)InterlockedCompareExchange)(mem, with, cmp);
|
return ((apr_atomic_win32_ptr_val_val_fn)InterlockedCompareExchange)(mem, with, cmp);
|
||||||
#endif
|
#endif
|
||||||
|
@ -107,6 +121,8 @@ APR_DECLARE(void *) apr_atomic_casptr(volatile void **mem, void *with, const voi
|
||||||
{
|
{
|
||||||
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
||||||
return InterlockedCompareExchangePointer(mem, with, cmp);
|
return InterlockedCompareExchangePointer(mem, with, cmp);
|
||||||
|
#elif (_MSC_VER >= 1800)
|
||||||
|
return InterlockedCompareExchangePointer(mem, with, cmp);
|
||||||
#else
|
#else
|
||||||
/* Too many VC6 users have stale win32 API files, stub this */
|
/* Too many VC6 users have stale win32 API files, stub this */
|
||||||
return ((apr_atomic_win32_ptr_ptr_ptr_fn)InterlockedCompareExchange)(mem, with, cmp);
|
return ((apr_atomic_win32_ptr_ptr_ptr_fn)InterlockedCompareExchange)(mem, with, cmp);
|
||||||
|
@ -117,6 +133,8 @@ APR_DECLARE(apr_uint32_t) apr_atomic_xchg32(volatile apr_uint32_t *mem, apr_uint
|
||||||
{
|
{
|
||||||
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
#if (defined(_M_IA64) || defined(_M_AMD64)) && !defined(RC_INVOKED)
|
||||||
return InterlockedExchange(mem, val);
|
return InterlockedExchange(mem, val);
|
||||||
|
#elif (_MSC_VER >= 1800)
|
||||||
|
return InterlockedExchange(mem, val);
|
||||||
#else
|
#else
|
||||||
return ((apr_atomic_win32_ptr_val_fn)InterlockedExchange)(mem, val);
|
return ((apr_atomic_win32_ptr_val_fn)InterlockedExchange)(mem, val);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -306,7 +306,7 @@ ESL_DECLARE(esl_status_t) esl_event_del_header_val(esl_event_t *event, const cha
|
||||||
esl_assert(x < 1000000);
|
esl_assert(x < 1000000);
|
||||||
hash = esl_ci_hashfunc_default(header_name, &hlen);
|
hash = esl_ci_hashfunc_default(header_name, &hlen);
|
||||||
|
|
||||||
if ((!hp->hash || hash == hp->hash) && (hp->name && !strcasecmp(header_name, hp->name)) && (esl_strlen_zero(val) || !strcmp(hp->value, val))) {
|
if ((!hp->hash || hash == hp->hash) && (hp->name && !strcasecmp(header_name, hp->name)) && (esl_strlen_zero(val) || (hp->value && !strcmp(hp->value, val)))) {
|
||||||
if (lp) {
|
if (lp) {
|
||||||
lp->next = hp->next;
|
lp->next = hp->next;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -40,6 +40,7 @@
|
||||||
#include "hpOutput.h"
|
#include "hpOutput.h"
|
||||||
#include "syntFilter.h"
|
#include "syntFilter.h"
|
||||||
|
|
||||||
|
#if (defined(WIN32) || defined(_WIN32)) && (_MSC_VER < 1800)
|
||||||
#if (defined(WIN32) || defined(_WIN32)) && !defined(_WIN64)
|
#if (defined(WIN32) || defined(_WIN32)) && !defined(_WIN64)
|
||||||
__inline long int rint(double dbl)
|
__inline long int rint(double dbl)
|
||||||
{
|
{
|
||||||
|
@ -63,6 +64,7 @@
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
/*----------------------------------------------------------------*
|
/*----------------------------------------------------------------*
|
||||||
* Initiation of decoder instance.
|
* Initiation of decoder instance.
|
||||||
|
|
|
@ -158,6 +158,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
#elif defined(_WIN64)
|
#elif defined(_WIN64)
|
||||||
|
#if (_MSC_VER < 1800)
|
||||||
__inline long int lrint(double x)
|
__inline long int lrint(double x)
|
||||||
{
|
{
|
||||||
return (long int) (x);
|
return (long int) (x);
|
||||||
|
@ -166,6 +167,7 @@
|
||||||
{
|
{
|
||||||
return (long int) (x);
|
return (long int) (x);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
#elif (defined (__MWERKS__) && defined (macintosh))
|
#elif (defined (__MWERKS__) && defined (macintosh))
|
||||||
|
|
||||||
/* This MacOS 9 solution was provided by Stephane Letz */
|
/* This MacOS 9 solution was provided by Stephane Letz */
|
||||||
|
|
|
@ -1803,7 +1803,9 @@ static int parse_ul(sdp_parser_t *p, char **r,
|
||||||
}
|
}
|
||||||
|
|
||||||
#if !HAVE_STRTOULL
|
#if !HAVE_STRTOULL
|
||||||
unsigned longlong strtoull(char const *string, char **return_end, int base);
|
#if !((defined(WIN32) || defined(_WIN32)) && (_MSC_VER >= 1800))
|
||||||
|
unsigned long long strtoull(char const *string, char **return_end, int base);
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -73,7 +73,10 @@ static char cvtIn[] = {
|
||||||
20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
|
20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
|
||||||
30, 31, 32, 33, 34, 35};
|
30, 31, 32, 33, 34, 35};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#if !((defined(WIN32) || defined(_WIN32)) && (_MSC_VER >= 1800))
|
||||||
|
|
||||||
/**Convert an ASCII string into an unsigned long long integer.
|
/**Convert an ASCII string into an unsigned long long integer.
|
||||||
*
|
*
|
||||||
* @param[in] string String of ASCII digits, possibly preceded by white
|
* @param[in] string String of ASCII digits, possibly preceded by white
|
||||||
|
@ -284,3 +287,5 @@ strtoull(const char *string, char **endPtr, int base)
|
||||||
|
|
||||||
return (unsigned longlong)-1;
|
return (unsigned longlong)-1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
|
@ -60,8 +60,10 @@
|
||||||
#include <sofia-sip/su_string.h>
|
#include <sofia-sip/su_string.h>
|
||||||
|
|
||||||
#ifndef HAVE_STRTOULL
|
#ifndef HAVE_STRTOULL
|
||||||
|
#if !((defined(WIN32) || defined(_WIN32)) && (_MSC_VER >= 1800))
|
||||||
unsigned longlong strtoull(const char *, char **, int);
|
unsigned longlong strtoull(const char *, char **, int);
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
/**@defgroup su_tag Tag Item Lists
|
/**@defgroup su_tag Tag Item Lists
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in New Issue