Fixed msys2 build warnings and re-activated CI Mingw64 build.
* Removed Visual Studio leftovers. Maintaining an autotools project with VS integration requires some additional overhead. Signed-off-by: Toni Uhlig <matzeton@googlemail.com> Signed-off-by: lns <matzeton@googlemail.com>
This commit is contained in:
Vendored
+1
-1
@@ -63,7 +63,7 @@ do {
|
||||
#endif
|
||||
|
||||
/* a number of the hash function use uint32_t which isn't defined on Pre VS2010 */
|
||||
#if defined(_WIN32)
|
||||
#if defined(WIN32)
|
||||
#if defined(_MSC_VER) && _MSC_VER >= 1600
|
||||
#include <stdint.h>
|
||||
#elif defined(__WATCOMC__) || defined(__MINGW32__) || defined(__CYGWIN__)
|
||||
|
||||
+3
-3
@@ -629,11 +629,11 @@ static AC_ERROR_t dump_node_common(AC_AUTOMATA_t * thiz,
|
||||
char lbuf[512];
|
||||
int nl = 0,j;
|
||||
|
||||
nl = snprintf(lbuf,sizeof(lbuf),"'%.100s' N:%d{",rstr,n->matched_patterns->num);
|
||||
nl = ndpi_snprintf(lbuf,sizeof(lbuf),"'%.100s' N:%d{",rstr,n->matched_patterns->num);
|
||||
for (j=0; j<n->matched_patterns->num; j++) {
|
||||
AC_PATTERN_t *sid = &n->matched_patterns->patterns[j];
|
||||
if(j) nl += snprintf(&lbuf[nl],sizeof(lbuf)-nl-1,", ");
|
||||
nl += snprintf(&lbuf[nl],sizeof(lbuf)-nl-1,"%d %c%.100s%c",
|
||||
if(j) nl += ndpi_snprintf(&lbuf[nl],sizeof(lbuf)-nl-1,", ");
|
||||
nl += ndpi_snprintf(&lbuf[nl],sizeof(lbuf)-nl-1,"%d %c%.100s%c",
|
||||
sid->rep.number & 0x3fff,
|
||||
sid->rep.number & 0x8000 ? '^':' ',
|
||||
sid->astring,
|
||||
|
||||
Vendored
+2
-2
@@ -34,7 +34,7 @@
|
||||
#define GCM_VALIDATE( cond ) \
|
||||
MBEDTLS_INTERNAL_VALIDATE( cond )
|
||||
|
||||
#ifdef _WIN32
|
||||
#ifdef WIN32
|
||||
#define LBLOCKSIZE 4
|
||||
#else
|
||||
#define LBLOCKSIZE __SIZEOF_LONG__
|
||||
@@ -295,7 +295,7 @@ int mbedtls_gcm_starts( mbedtls_gcm_context *ctx,
|
||||
if( iv_len == 0)
|
||||
return( MBEDTLS_ERR_GCM_BAD_INPUT );
|
||||
#if __SIZE_WIDTH__ == 64
|
||||
if( iv_len >= (1UL << 32 ))
|
||||
if( iv_len >= (1ULL << 32 ))
|
||||
return( MBEDTLS_ERR_GCM_BAD_INPUT );
|
||||
#endif
|
||||
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
|
||||
#include <stdint.h>
|
||||
#ifndef _WIN32
|
||||
#ifndef WIN32
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
#include <string.h>
|
||||
|
||||
Vendored
+5
-5
@@ -300,7 +300,7 @@ static inline uint32_t croaring_detect_supported_architectures() {
|
||||
extern "C" { // portability definitions are in global scope, not a namespace
|
||||
#endif
|
||||
|
||||
#if defined(_MSC_VER) && !defined(__clang__) && !defined(_WIN64) && !defined(ROARING_ACK_32BIT)
|
||||
#if defined(_MSC_VER) && !defined(__clang__) && !defined(WIN64) && !defined(ROARING_ACK_32BIT)
|
||||
#pragma message( \
|
||||
"You appear to be attempting a 32-bit build under Visual Studio. We recommend a 64-bit build instead.")
|
||||
#endif
|
||||
@@ -373,7 +373,7 @@ extern "C" { // portability definitions are in global scope, not a namespace
|
||||
/* result might be undefined when input_num is zero */
|
||||
static inline int __builtin_ctzll(unsigned long long input_num) {
|
||||
unsigned long index;
|
||||
#ifdef _WIN64 // highly recommended!!!
|
||||
#ifdef WIN64 // highly recommended!!!
|
||||
_BitScanForward64(&index, input_num);
|
||||
#else // if we must support 32-bit Windows
|
||||
if ((uint32_t)input_num != 0) {
|
||||
@@ -389,7 +389,7 @@ static inline int __builtin_ctzll(unsigned long long input_num) {
|
||||
/* result might be undefined when input_num is zero */
|
||||
static inline int __builtin_clzll(unsigned long long input_num) {
|
||||
unsigned long index;
|
||||
#ifdef _WIN64 // highly recommended!!!
|
||||
#ifdef WIN64 // highly recommended!!!
|
||||
_BitScanReverse64(&index, input_num);
|
||||
#else // if we must support 32-bit Windows
|
||||
if (input_num > 0xFFFFFFFF) {
|
||||
@@ -479,14 +479,14 @@ static inline int hammingbackup(uint64_t x) {
|
||||
}
|
||||
|
||||
static inline int hamming(uint64_t x) {
|
||||
#if defined(_WIN64) && defined(_MSC_VER) && !defined(__clang__)
|
||||
#if defined(WIN64) && defined(_MSC_VER) && !defined(__clang__)
|
||||
#ifdef _M_ARM64
|
||||
return hammingbackup(x);
|
||||
// (int) _CountOneBits64(x); is unavailable
|
||||
#else // _M_ARM64
|
||||
return (int) __popcnt64(x);
|
||||
#endif // _M_ARM64
|
||||
#elif defined(_WIN32) && defined(_MSC_VER) && !defined(__clang__)
|
||||
#elif defined(WIN32) && defined(_MSC_VER) && !defined(__clang__)
|
||||
#ifdef _M_ARM
|
||||
return hammingbackup(x);
|
||||
// _CountOneBits is unavailable
|
||||
|
||||
Reference in New Issue
Block a user