From 332517d98651da55a7de991076e13abd67480d44fc3fa51fb1d218f631ff8522 Mon Sep 17 00:00:00 2001 From: OBS User unknown Date: Fri, 1 Aug 2008 22:49:41 +0000 Subject: [PATCH] OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/sqlite3?expand=0&rev=10 --- disable-check.diff | 11 --- sqlite-3.5.7.tar.bz2 | 3 - sqlite-3.6.0.tar.bz2 | 3 + sqlite-strcasecmp.patch | 19 ------ sqlite-test-notime.diff | 24 ------- sqlite.diff | 35 ---------- sqlite3-tcl85.diff | 73 -------------------- sqlite3-upstream-fixes.patch | 126 +++++++++++++++++++++++++++++++++++ sqlite3.changes | 30 +++++++++ sqlite3.spec | 43 ++++++++---- 10 files changed, 190 insertions(+), 177 deletions(-) delete mode 100644 disable-check.diff delete mode 100644 sqlite-3.5.7.tar.bz2 create mode 100644 sqlite-3.6.0.tar.bz2 delete mode 100644 sqlite-strcasecmp.patch delete mode 100644 sqlite-test-notime.diff delete mode 100644 sqlite.diff delete mode 100644 sqlite3-tcl85.diff create mode 100644 sqlite3-upstream-fixes.patch diff --git a/disable-check.diff b/disable-check.diff deleted file mode 100644 index f471443..0000000 --- a/disable-check.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- test/expr.test -+++ test/expr.test 2007/07/30 14:41:17 -@@ -136,7 +136,7 @@ - test_expr expr-1.102 {i1=40, i2=1} {i2<1} 1 - - test_expr expr-1.106 {i1=0} {(1<<63)/-1} -9223372036854775808 diff --git a/sqlite-3.5.7.tar.bz2 b/sqlite-3.5.7.tar.bz2 deleted file mode 100644 index decc335..0000000 --- a/sqlite-3.5.7.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:f264a6d3f1e62fad4377d597af9b328a8c264451bd9f5231c31217b76aec9414 -size 2030719 diff --git a/sqlite-3.6.0.tar.bz2 b/sqlite-3.6.0.tar.bz2 new file mode 100644 index 0000000..4f614f9 --- /dev/null +++ b/sqlite-3.6.0.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c4061b233645f6d719918f7de7f2bc4a78d4124ab924ab91aac10041e3b62ba7 +size 1676870 diff --git a/sqlite-strcasecmp.patch b/sqlite-strcasecmp.patch deleted file mode 100644 index 45d97ac..0000000 --- a/sqlite-strcasecmp.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- src/tclsqlite.c 2008/03/25 16:16:29 1.212 -+++ src/tclsqlite.c 2008/04/04 12:21:09 1.213 -@@ -1340,11 +1340,11 @@ - Tcl_AppendResult(interp,"Error: non-null separator required for copy",0); - return TCL_ERROR; - } -- if(sqlite3StrICmp(zConflict, "rollback") != 0 && -- sqlite3StrICmp(zConflict, "abort" ) != 0 && -- sqlite3StrICmp(zConflict, "fail" ) != 0 && -- sqlite3StrICmp(zConflict, "ignore" ) != 0 && -- sqlite3StrICmp(zConflict, "replace" ) != 0 ) { -+ if(strcasecmp(zConflict, "rollback") != 0 && -+ strcasecmp(zConflict, "abort" ) != 0 && -+ strcasecmp(zConflict, "fail" ) != 0 && -+ strcasecmp(zConflict, "ignore" ) != 0 && -+ strcasecmp(zConflict, "replace" ) != 0 ) { - Tcl_AppendResult(interp, "Error: \"", zConflict, - "\", conflict-algorithm must be one of: rollback, " - "abort, fail, ignore, or replace", 0); diff --git a/sqlite-test-notime.diff b/sqlite-test-notime.diff deleted file mode 100644 index c720704..0000000 --- a/sqlite-test-notime.diff +++ /dev/null @@ -1,24 +0,0 @@ ---- test/select2.test -+++ test/select2.test 2006/04/11 15:09:32 -@@ -89,11 +89,16 @@ - list - } {} - puts "time without cache: $t2" --ifcapable tclvar { -- do_test select2-2.0.3 { -- expr {[lindex $t1 0]<[lindex $t2 0]} -- } 1 --} -+ -+## -+## wall clock comparisons are futile in a heavily loaded multiuser system -+## as found on a typical autobuild-host. Don't do that test here. -+## -+# ifcapable tclvar { -+# do_test select2-2.0.3 { -+# expr {[lindex $t1 0]<[lindex $t2 0]} -+# } 1 -+# } - - do_test select2-2.1 { - execsql {SELECT count(*) FROM tbl2} diff --git a/sqlite.diff b/sqlite.diff deleted file mode 100644 index 47eb9c5..0000000 --- a/sqlite.diff +++ /dev/null @@ -1,35 +0,0 @@ ---- test/printf.test -+++ test/printf.test 2007/11/06 10:21:21 -@@ -163,12 +163,6 @@ - sqlite3_mprintf_scaled {A double: %+g} 1.0e307 100.0 - } {A double: +Inf} - --do_test printf-8.1 { -- sqlite3_mprintf_int {%u %u %u} 0x7fffffff 0x80000000 0xffffffff --} {2147483647 2147483648 4294967295} --do_test printf-8.2 { -- sqlite3_mprintf_int {%lu %lu %lu} 0x7fffffff 0x80000000 0xffffffff --} {2147483647 2147483648 4294967295} - do_test printf-8.3 { - sqlite3_mprintf_int64 {%llu %llu %llu} 2147483647 2147483648 4294967296 - } {2147483647 2147483648 4294967296} ---- Makefile.in.orig 2008-04-07 08:53:45.000000000 +0200 -+++ Makefile.in 2008-04-07 09:10:31.000000000 +0200 -@@ -427,7 +427,7 @@ - # Rule to build the amalgamation - # - sqlite3.lo: sqlite3.c -- $(LTCOMPILE) -c $(TOP)/sqlite3.c -+ $(LTCOMPILE) -c sqlite3.c - - # Rules to build individual files - # -@@ -643,7 +643,7 @@ - testfixture$(TEXE): $(TESTFIXTURE_SRC) - $(LTLINK) -DTCLSH=1 -DSQLITE_TEST=1 -DSQLITE_CRASH_TEST=1 \ - -DSQLITE_SERVER=1 -DSQLITE_PRIVATE="" -DSQLITE_CORE $(TEMP_STORE) \ -- -o $@ $(TESTFIXTURE_SRC) $(LIBTCL) -+ -o $@ $(TESTFIXTURE_SRC) $(LIBTCL) -lpthread - - - fulltest: testfixture$(TEXE) sqlite3$(TEXE) diff --git a/sqlite3-tcl85.diff b/sqlite3-tcl85.diff deleted file mode 100644 index ac0065f..0000000 --- a/sqlite3-tcl85.diff +++ /dev/null @@ -1,73 +0,0 @@ -Index: sqlite/test/tclsqlite.test -RCS File: /sqlite/sqlite/test/tclsqlite.test,v -================================================================================ ---- Makefile.in -+++ Makefile.in -@@ -392,7 +392,7 @@ - - libtclsqlite3.la: tclsqlite.lo libsqlite3.la - $(LTLINK) -o $@ tclsqlite.lo \ -- $(LIBOBJ) @TCL_STUB_LIB_SPEC@ $(TLIBS) \ -+ libsqlite3.la @TCL_STUB_LIB_SPEC@ $(TLIBS) \ - -rpath "$(libdir)/sqlite" \ - -version-info "8:6:8" - ---- src/test1.c -+++ src/test1.c -@@ -2621,8 +2621,20 @@ - - if( getStmtPointer(interp, Tcl_GetString(objv[1]), &pStmt) ) return TCL_ERROR; - if( Tcl_GetIntFromObj(interp, objv[2], &idx) ) return TCL_ERROR; -- if( Tcl_GetDoubleFromObj(interp, objv[3], &value) ) return TCL_ERROR; - -+ /* Intercept the string "NaN" and generate a NaN value for it. -+ ** All other strings are passed through to Tcl_GetDoubleFromObj(). -+ ** Tcl_GetDoubleFromObj() should understand "NaN" but some versions -+ ** contain a bug. -+ */ -+ if( strcmp(Tcl_GetString(objv[3]), "NaN")==0 ){ -+ sqlite3_int64 i; -+ i = 0xfff80000; -+ i <<= 32; -+ value = *(double*)(char*)&i; -+ }else if( Tcl_GetDoubleFromObj(interp, objv[3], &value) ){ -+ return TCL_ERROR; -+ } - rc = sqlite3_bind_double(pStmt, idx, value); - if( sqlite3TestErrCode(interp, StmtToDb(pStmt), rc) ) return TCL_ERROR; - if( rc!=SQLITE_OK ){ ---- test/tclsqlite.test -+++ test/tclsqlite.test -@@ -69,15 +69,15 @@ - } msg] - lappend v $msg - } {0 {}} -+catch {expr x*} msg - do_test tcl-1.6 { - set v [catch { - db eval {SELECT * FROM t1} data { - expr x* - } - } msg] -- regsub {:.*$} $msg {} msg - lappend v $msg --} {1 {syntax error in expression "x*"}} -+} [list 1 $msg] - do_test tcl-1.7 { - set v [catch {db} msg] - lappend v $msg ---- test/types3.test -+++ test/types3.test -@@ -74,10 +74,11 @@ - set V [db one {SELECT 123}] - tcl_variable_type V - } int -+set Vx [expr {1+wide(123456789123456)}] - do_test types3-2.3 { - set V [db one {SELECT 1234567890123456}] - tcl_variable_type V --} wideInt -+} [tcl_variable_type Vx] - do_test types3-2.4.1 { - set V [db one {SELECT 1234567890123456.1}] - tcl_variable_type V diff --git a/sqlite3-upstream-fixes.patch b/sqlite3-upstream-fixes.patch new file mode 100644 index 0000000..e2d1d1d --- /dev/null +++ b/sqlite3-upstream-fixes.patch @@ -0,0 +1,126 @@ +Index: sqlite/Makefile.in +RCS File: /sqlite/sqlite/Makefile.in,v +================================================================================ +--- Makefile.in ++++ Makefile.in +@@ -427,7 +427,7 @@ + + libtclsqlite3.la: tclsqlite.lo libsqlite3.la + $(LTLINK) -o $@ tclsqlite.lo \ +- $(LIBOBJ) @TCL_STUB_LIB_SPEC@ $(TLIBS) \ ++ libsqlite3.la @TCL_STUB_LIB_SPEC@ $(TLIBS) \ + -rpath "$(libdir)/sqlite" \ + -version-info "8:6:8" + +@@ -623,7 +623,7 @@ + $(LTCOMPILE) -c $(TOP)/src/table.c + + tclsqlite.lo: $(TOP)/src/tclsqlite.c $(HDR) +- $(LTCOMPILE) -c $(TOP)/src/tclsqlite.c ++ $(LTCOMPILE) -DUSE_TCL_STUBS=1 -c $(TOP)/src/tclsqlite.c + + tokenize.lo: $(TOP)/src/tokenize.c keywordhash.h $(HDR) + $(LTCOMPILE) -c $(TOP)/src/tokenize.c +--- src/test_osinst.c ++++ src/test_osinst.c +@@ -17,6 +17,7 @@ + ** $Id: test_osinst.c,v 1.17 2008/07/12 15:55:55 danielk1977 Exp $ + */ + ++#ifdef SQLITE_ENABLE_INSTVFS + /* + ** C interface: + ** +@@ -809,6 +810,7 @@ + + return pVfs; + } ++#endif /* SQLITE_ENABLE_INSTVFS */ + + /************************************************************************** + *************************************************************************** +@@ -818,6 +820,7 @@ + + #include + ++#ifdef SQLITE_ENABLE_INSTVFS + struct InstVfsCall { + Tcl_Interp *interp; + Tcl_Obj *pScript; +@@ -1039,10 +1042,28 @@ + + return TCL_OK; + } ++#endif /* SQLITE_ENABLE_INSTVFS */ ++ ++/* Alternative implementation of sqlite3_instvfs when the real ++** implementation is unavailable. ++*/ ++#ifndef SQLITE_ENABLE_INSTVFS ++static int test_sqlite3_instvfs( ++ void * clientData, ++ Tcl_Interp *interp, ++ int objc, ++ Tcl_Obj *CONST objv[] ++){ ++ Tcl_AppendResult(interp, ++ "not compiled with -DSQLITE_ENABLE_INSTVFS; sqlite3_instvfs is " ++ "unavailable", (char*)0); ++ return TCL_ERROR; ++} ++#endif /* !defined(SQLITE_ENABLE_INSTVFS) */ + + int SqlitetestOsinst_Init(Tcl_Interp *interp){ + Tcl_CreateObjCommand(interp, "sqlite3_instvfs", test_sqlite3_instvfs, 0, 0); + return TCL_OK; + } + +-#endif ++#endif /* SQLITE_TEST */ +--- test/func.test ++++ test/func.test +@@ -298,10 +298,22 @@ + } {0} + do_test func-8.6 { + execsql { +- SELECT sum(x) FROM (SELECT '9223372036' || '854775808' AS x ++ SELECT typeof(sum(x)) FROM (SELECT '9223372036' || '854775807' AS x + UNION ALL SELECT -9223372036854775807) + } +-} {1.0} ++} {integer} ++do_test func-8.7 { ++ execsql { ++ SELECT typeof(sum(x)) FROM (SELECT '9223372036' || '854775808' AS x ++ UNION ALL SELECT -9223372036854775807) ++ } ++} {real} ++do_test func-8.8 { ++ execsql { ++ SELECT sum(x)>0.0 FROM (SELECT '9223372036' || '854775808' AS x ++ UNION ALL SELECT -9223372036850000000) ++ } ++} {1} + + # How do you test the random() function in a meaningful, deterministic way? + # +--- test/memsubsys1.test ++++ test/memsubsys1.test +@@ -133,7 +133,7 @@ + } $max_pagecache + do_test memsubsys1-4.5 { + set maxreq [lindex [sqlite3_status SQLITE_STATUS_MALLOC_SIZE 0] 2] +- expr {$maxreq<4096} ++ expr {$maxreq<7000} + } 1 + do_test memsubsys1-4.6 { + set s_used [lindex [sqlite3_status SQLITE_STATUS_SCRATCH_USED 0] 2] +@@ -211,7 +211,7 @@ + } 0 + do_test memsubsys1-7.5 { + set maxreq [lindex [sqlite3_status SQLITE_STATUS_MALLOC_SIZE 0] 2] +- expr {$maxreq<2500} ++ expr {$maxreq<4000} + } 1 + do_test memsubsys1-7.6 { + set s_used [lindex [sqlite3_status SQLITE_STATUS_SCRATCH_USED 0] 2] diff --git a/sqlite3.changes b/sqlite3.changes index a4ffd85..4eb4c91 100644 --- a/sqlite3.changes +++ b/sqlite3.changes @@ -1,3 +1,33 @@ +------------------------------------------------------------------- +Fri Jul 25 13:30:50 CEST 2008 - max@suse.de + +- Update to version 3.6.0: + * Modifications to the virtual file system interface to support a + wider range of embedded systems. See 35to36.html for additional + information. *** Potentially incompatible change *** + * The handling of IN and NOT IN operators that contain a NULL on + their right-hand side expression is brought into compliance with + the SQL standard and with other SQL database engines. This is a + bug fix, but as it has the potential to break legacy applications + that depend on the older buggy behavior, we mark that as a + *** Potentially incompatible change *** + * The result column names generated for compound subqueries have + been simplified to show only the name of the column of the + original table and omit the table name. This makes SQLite + operate more like other SQL database engines. + * Added the sqlite3_config() interface for doing run-time + configuration of the entire SQLite library. + * Added the sqlite3_status() interface used for querying run-time + status information about the overall SQLite library and its + subsystems. + * Added the sqlite3_initialize() and sqlite3_shutdown() interfaces. + * The SQLITE_OPEN_NOMUTEX option was added to sqlite3_open_v2(). + * Added the PRAGMA page_count command. + * Added the sqlite3_next_stmt() interface. + * Added a new R*Tree virtual table +- Link libtclsqlite against the Tcl stubs library, so that it can be + used from tclkit. + ------------------------------------------------------------------- Thu May 8 15:03:21 CEST 2008 - max@suse.de diff --git a/sqlite3.spec b/sqlite3.spec index 7f25b87..1cf3ecf 100644 --- a/sqlite3.spec +++ b/sqlite3.spec @@ -1,5 +1,5 @@ # -# spec file for package sqlite3 (Version 3.5.7) +# spec file for package sqlite3 (Version 3.6.0) # # Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine @@ -20,19 +20,15 @@ License: Public Domain, Freeware Group: Productivity/Databases/Servers Summary: Embeddable SQL Database Engine Url: http://www.sqlite.org/ -Version: 3.5.7 -Release: 12 +Version: 3.6.0 +Release: 1 Requires: libsqlite3-0 = %version Provides: sqlite = %version Obsoletes: sqlite < %version Source0: http://www.sqlite.org/sqlite-%version.tar.bz2 Source1: sqlite.desktop Source2: sqlite-check_fsync_dir.c -Patch0: sqlite.diff -Patch2: sqlite-test-notime.diff -Patch8: disable-check.diff -Patch9: sqlite3-tcl85.diff -Patch10: sqlite-strcasecmp.patch +Patch0: sqlite3-upstream-fixes.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %description @@ -129,10 +125,6 @@ Authors: %prep %setup -q -n sqlite-%version %patch0 -%patch2 -%patch8 -%patch9 -%patch10 # does not work due to our ulimits in our build system rm test/bigfile.test @@ -201,6 +193,33 @@ autoreconf -f -i %_libdir/pkgconfig/sqlite3.pc %changelog +* Fri Jul 25 2008 max@suse.de +- Update to version 3.6.0: + * Modifications to the virtual file system interface to support a + wider range of embedded systems. See 35to36.html for additional + information. *** Potentially incompatible change *** + * The handling of IN and NOT IN operators that contain a NULL on + their right-hand side expression is brought into compliance with + the SQL standard and with other SQL database engines. This is a + bug fix, but as it has the potential to break legacy applications + that depend on the older buggy behavior, we mark that as a + *** Potentially incompatible change *** + * The result column names generated for compound subqueries have + been simplified to show only the name of the column of the + original table and omit the table name. This makes SQLite + operate more like other SQL database engines. + * Added the sqlite3_config() interface for doing run-time + configuration of the entire SQLite library. + * Added the sqlite3_status() interface used for querying run-time + status information about the overall SQLite library and its + subsystems. + * Added the sqlite3_initialize() and sqlite3_shutdown() interfaces. + * The SQLITE_OPEN_NOMUTEX option was added to sqlite3_open_v2(). + * Added the PRAGMA page_count command. + * Added the sqlite3_next_stmt() interface. + * Added a new R*Tree virtual table +- Link libtclsqlite against the Tcl stubs library, so that it can be + used from tclkit. * Thu May 08 2008 max@suse.de - Actually apply sqlite-strcasecmp.patch to fix the Tcl extension. - Link the Tcl extension dynamically.