Check-in [bf5bd8b1ba]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:supporting LIKE in VirtualTables accordingly to changes introduced since sqlite-3.10
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: bf5bd8b1ba3981f064d4266d1a3c10d009d403c5
User & Date: sandro 2016-01-24 15:56:43
Context
2016-01-24
16:35
implementing --enable-knn ./configure option and testing for sqlite3 >= 3.8.5 check-in: 2e8f4cfcec user: sandro tags: trunk
15:56
supporting LIKE in VirtualTables accordingly to changes introduced since sqlite-3.10 check-in: bf5bd8b1ba user: sandro tags: trunk
15:19
fixing exponential FP notations (as e.g. -1.e-4) in all text parsers (WKT, GML etc)) check-in: aa408ed10d user: sandro tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to config.h.in.

17
18
19
20
21
22
23



24
25
26
27
28
29
30

/* Should be defined in order to fully disable GEOS non-thread-safe API. */
#undef GEOS_ONLY_REENTRANT

/* Should be defined in order to enable GEOS_REENTRANT (fully thread-safe). */
#undef GEOS_REENTRANT




/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H

/* Define to 1 if you have the <fcntl.h> header file. */
#undef HAVE_FCNTL_H

/* Define to 1 if you have the `fdatasync' function. */







>
>
>







17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33

/* Should be defined in order to fully disable GEOS non-thread-safe API. */
#undef GEOS_ONLY_REENTRANT

/* Should be defined in order to enable GEOS_REENTRANT (fully thread-safe). */
#undef GEOS_REENTRANT

/* depending on SQLite library version. */
#undef HAVE_DECL_SQLITE_INDEX_CONSTRAINT_LIKE

/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H

/* Define to 1 if you have the <fcntl.h> header file. */
#undef HAVE_FCNTL_H

/* Define to 1 if you have the `fdatasync' function. */

Changes to configure.

2115
2116
2117
2118
2119
2120
2121














































2122
2123
2124
2125
2126
2127
2128
....
3126
3127
3128
3129
3130
3131
3132

3133
3134
3135
3136
3137
3138
3139
.....
18792
18793
18794
18795
18796
18797
18798








18799
18800
18801
18802
18803
18804
18805
fi
eval ac_res=\$$3
	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno

} # ac_fn_c_check_type














































cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by libspatialite $as_me 4.4.0-RC0, which was
generated by GNU Autoconf 2.69.  Invocation command line was

................................................................................

# disabling debug support

$as_echo "#define NDEBUG 1" >>confdefs.h


# config depending options








................................................................................
# Checking for Android
 if test "$target_alias" = "android"; then
  ANDROID_TRUE=
  ANDROID_FALSE='#'
else
  ANDROID_TRUE='#'
  ANDROID_FALSE=








fi


cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
# scripts and configure runs, see configure's option --config-cache.







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







 







>







 







>
>
>
>
>
>
>
>







2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
....
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
.....
18839
18840
18841
18842
18843
18844
18845
18846
18847
18848
18849
18850
18851
18852
18853
18854
18855
18856
18857
18858
18859
18860
fi
eval ac_res=\$$3
	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno

} # ac_fn_c_check_type

# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
# ---------------------------------------------
# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
# accordingly.
ac_fn_c_check_decl ()
{
  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  as_decl_name=`echo $2|sed 's/ *(.*//'`
  as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
if eval \${$3+:} false; then :
  $as_echo_n "(cached) " >&6
else
  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
$4
int
main ()
{
#ifndef $as_decl_name
#ifdef __cplusplus
  (void) $as_decl_use;
#else
  (void) $as_decl_name;
#endif
#endif

  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
  eval "$3=yes"
else
  eval "$3=no"
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
eval ac_res=\$$3
	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno

} # ac_fn_c_check_decl
cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by libspatialite $as_me 4.4.0-RC0, which was
generated by GNU Autoconf 2.69.  Invocation command line was

................................................................................

# disabling debug support

$as_echo "#define NDEBUG 1" >>confdefs.h


# config depending options








................................................................................
# Checking for Android
 if test "$target_alias" = "android"; then
  ANDROID_TRUE=
  ANDROID_FALSE='#'
else
  ANDROID_TRUE='#'
  ANDROID_FALSE=
fi


ac_fn_c_check_decl "$LINENO" "SQLITE_INDEX_CONSTRAINT_LIKE" "ac_cv_have_decl_SQLITE_INDEX_CONSTRAINT_LIKE" "#include <sqlite3.h>
"
if test "x$ac_cv_have_decl_SQLITE_INDEX_CONSTRAINT_LIKE" = xyes; then :
  $as_echo "#define HAVE_DECL_SQLITE_INDEX_CONSTRAINT_LIKE 1" >>confdefs.h

fi


cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
# scripts and configure runs, see configure's option --config-cache.

Changes to configure.ac.

57
58
59
60
61
62
63


64
65
66
67
68
69
70
...
421
422
423
424
425
426
427



428
429
430
431
432
433
434
            [Should be defined in order to enable GeoPackage support.])
AH_TEMPLATE([POSTGIS_2_1],
            [Should be defined when linking liblwgeom from PostGIS 2.1 (or later).])
AH_TEMPLATE([POSTGIS_2_2],
            [Should be defined when linking liblwgeom from PostGIS 2.2 (or later).])
AH_TEMPLATE([TARGET_CPU],
            [Should contain a text-string describing the intended target CPU])



# Checks for header files.
AC_CHECK_HEADERS(stdlib.h,, [AC_MSG_ERROR([cannot find stdlib.h, bailing out])])
AC_CHECK_HEADERS(stdio.h,, [AC_MSG_ERROR([cannot find stdio.h, bailing out])])
AC_CHECK_HEADERS(string.h,, [AC_MSG_ERROR([cannot find string.h, bailing out])])
AC_CHECK_HEADERS(memory.h,, [AC_MSG_ERROR([cannot find memory.h, bailing out])])
AC_CHECK_HEADERS(math.h,, [AC_MSG_ERROR([cannot find math.h, bailing out])])
................................................................................
# Checking for MinGW
AM_CONDITIONAL([MINGW], [test "$target_alias" = "mingw32"])
# Checking for Mac OsX
AM_CONDITIONAL([MACOSX], [test "$target_alias" = "macosx"])
# Checking for Android
AM_CONDITIONAL([ANDROID], [test "$target_alias" = "android"])




AC_OUTPUT

#-----------------------------------------------------------------------
# printing an eventual message reporting about GPL escalation
#-----------------------------------------------------------------------
gpl_escalation=no;
if test x"$enable_lwgeom" != "xno"; then







>
>







 







>
>
>







57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
...
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
            [Should be defined in order to enable GeoPackage support.])
AH_TEMPLATE([POSTGIS_2_1],
            [Should be defined when linking liblwgeom from PostGIS 2.1 (or later).])
AH_TEMPLATE([POSTGIS_2_2],
            [Should be defined when linking liblwgeom from PostGIS 2.2 (or later).])
AH_TEMPLATE([TARGET_CPU],
            [Should contain a text-string describing the intended target CPU])
AH_TEMPLATE([HAVE_DECL_SQLITE_INDEX_CONSTRAINT_LIKE],
            [depending on SQLite library version.])

# Checks for header files.
AC_CHECK_HEADERS(stdlib.h,, [AC_MSG_ERROR([cannot find stdlib.h, bailing out])])
AC_CHECK_HEADERS(stdio.h,, [AC_MSG_ERROR([cannot find stdio.h, bailing out])])
AC_CHECK_HEADERS(string.h,, [AC_MSG_ERROR([cannot find string.h, bailing out])])
AC_CHECK_HEADERS(memory.h,, [AC_MSG_ERROR([cannot find memory.h, bailing out])])
AC_CHECK_HEADERS(math.h,, [AC_MSG_ERROR([cannot find math.h, bailing out])])
................................................................................
# Checking for MinGW
AM_CONDITIONAL([MINGW], [test "$target_alias" = "mingw32"])
# Checking for Mac OsX
AM_CONDITIONAL([MACOSX], [test "$target_alias" = "macosx"])
# Checking for Android
AM_CONDITIONAL([ANDROID], [test "$target_alias" = "android"])

AC_CHECK_DECL([SQLITE_INDEX_CONSTRAINT_LIKE],
  [AC_DEFINE(HAVE_DECL_SQLITE_INDEX_CONSTRAINT_LIKE)],[],[[#include <sqlite3.h>]])

AC_OUTPUT

#-----------------------------------------------------------------------
# printing an eventual message reporting about GPL escalation
#-----------------------------------------------------------------------
gpl_escalation=no;
if test x"$enable_lwgeom" != "xno"; then

Changes to src/spatialite/virtualXL.c.

686
687
688
689
690
691
692






693
694
695
696
697
698
699
		      if (ret < 0)
			  ok = 1;
		      break;
		  case SQLITE_INDEX_CONSTRAINT_GE:
		      if (ret >= 0)
			  ok = 1;
		      break;






		  };
	    }
	done:
	  if (!ok)
	      return 0;
	  pC = pC->next;
      }







>
>
>
>
>
>







686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
		      if (ret < 0)
			  ok = 1;
		      break;
		  case SQLITE_INDEX_CONSTRAINT_GE:
		      if (ret >= 0)
			  ok = 1;
		      break;
#ifdef HAVE_DECL_SQLITE_INDEX_CONSTRAINT_LIKE
case SQLITE_INDEX_CONSTRAINT_LIKE:
					      if (ret >= 0)
				ok = 1;
			    break;
#endif
		  };
	    }
	done:
	  if (!ok)
	      return 0;
	  pC = pC->next;
      }

Changes to src/spatialite/virtualdbf.c.

657
658
659
660
661
662
663






664
665
666
667
668
669
670
					      if (ret < 0)
						  ok = 1;
					      break;
					  case SQLITE_INDEX_CONSTRAINT_GE:
					      if (ret >= 0)
						  ok = 1;
					      break;






					  };
				    }
				  break;
			      };
			}
		      goto done;
		  }







>
>
>
>
>
>







657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
					      if (ret < 0)
						  ok = 1;
					      break;
					  case SQLITE_INDEX_CONSTRAINT_GE:
					      if (ret >= 0)
						  ok = 1;
					      break;
#ifdef HAVE_DECL_SQLITE_INDEX_CONSTRAINT_LIKE
					  case SQLITE_INDEX_CONSTRAINT_LIKE:
					      if (ret >= 0)
						  ok = 1;
					      break;
#endif
					  };
				    }
				  break;
			      };
			}
		      goto done;
		  }

Changes to src/spatialite/virtualshape.c.

943
944
945
946
947
948
949






950
951
952
953
954
955
956
					      if (ret < 0)
						  ok = 1;
					      break;
					  case SQLITE_INDEX_CONSTRAINT_GE:
					      if (ret >= 0)
						  ok = 1;
					      break;






					  };
				    }
				  break;
			      };
			}
		      goto done;
		  }







>
>
>
>
>
>







943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
					      if (ret < 0)
						  ok = 1;
					      break;
					  case SQLITE_INDEX_CONSTRAINT_GE:
					      if (ret >= 0)
						  ok = 1;
					      break;
#ifdef HAVE_DECL_SQLITE_INDEX_CONSTRAINT_LIKE
					  case SQLITE_INDEX_CONSTRAINT_LIKE:
					      if (ret >= 0)
						  ok = 1;
					      break;
#endif
					  };
				    }
				  break;
			      };
			}
		      goto done;
		  }

Changes to test/test-legacy-3.0.1.sqlite.

cannot compute difference between binary files