Skip to content

Commit

Permalink
Fix issue #126 (use of quadmath in VSV extension)
Browse files Browse the repository at this point in the history
Use of 128-bit floats for conversion purposes in the VSV extension could cause compilation problems due to the dependency on the GCC-specific quadmath library. This library will now only be used, if the prprocessor symbol SQLITE_USE_QUADMATH is defined. This symbol will not be defined by default.
  • Loading branch information
utelle committed Nov 17, 2023
1 parent dfdb048 commit 60ea8e7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/vsv.c
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ SQLITE_EXTENSION_INIT1

#undef LONGDOUBLE_CONSTANT
#undef LONGDOUBLE_TYPE
#if defined(__GNUC__) && defined(_WIN64)
#if defined(SQLITE_USE_QUADMATH) && defined(__GNUC__) && defined(_WIN64)
#include <quadmath.h>
#define LONGDOUBLE_TYPE __float128
#define LONGDOUBLE_CONSTANT(x) x##Q
Expand Down Expand Up @@ -1765,7 +1765,7 @@ static int vsvtabColumn(
{
LONGDOUBLE_TYPE dv, fp, ip;

#if defined(__GNUC__) && defined(_WIN64)
#if defined(SQLITE_USE_QUADMATH) && defined(__GNUC__) && defined(_WIN64)
if (!hasExtended) hasExtended = 1;
#else
if (!hasExtended) {
Expand Down

0 comments on commit 60ea8e7

Please sign in to comment.