From: drh <> Date: Sat, 4 Jan 2025 14:10:45 +0000 (+0000) Subject: Add new tcl-extension-testing.md document. The Windows side is not yet X-Git-Tag: major-relase~33^2~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8f1bdc0f73af1b80989c1624bef6633cf9259180;p=thirdparty%2Fsqlite.git Add new tcl-extension-testing.md document. The Windows side is not yet working. FossilOrigin-Name: 9dc805df1b1c26196ca53baa6b1b8c2f7e59e0150d02ead53228c77a63ad40f4 --- diff --git a/doc/tcl-extension-testing.md b/doc/tcl-extension-testing.md new file mode 100644 index 0000000000..7dab3eafbd --- /dev/null +++ b/doc/tcl-extension-testing.md @@ -0,0 +1,142 @@ +# Test Procedures For The SQLite TCL Extension + + +## 1.0 Testing On Unix-like Systems (Including Mac) + +### 1.1 Setup + +
    +
  1. + [Fossil](https://fossil-scm.org/) installed. +
  2. + A Fossil check-out of the TCL source tree. Let the directory + of this check-out be called **$TCLCO** (mnemonic: "TCL Check-Out"). +
  3. + A Fossil check-out of the SQLite source tree. Let the directory + of this check-out be called **$SRCCO** (mnemonic: "SouRCe Check-Out"). +
  4. + Let **$TCLTD** (mnemonic: "TCL Test Directory") be the name of a directory + that does not exist at the start of the test, and which will be + deleted at the end of the test, that will contain the test builds + of the TCL libraries and the SQLite TCL Extensions. +
+ +### 1.2 Building the TCL libraries and tclsh executables + +
    +
  1. `mkdir $TCLTD $TCLTD/tcl86 $TCLTD/tcl90` +
  2. `cd $TCLCO/unix` +
  3. `fossil up core-8-6-16` ← or some other version of Tcl8.6. +
  4. `fossil clean -x` +
  5. `./configure --prefix=$TCLTD/tcl86` +
  6. `make install` +
  7. `fossil up core-9-0-0` ← or some other version of Tcl9 +
  8. `fossil clean -x` +
  9. `./configure --prefix=$TCLTD/tcl90` +
  10. `make install` +
+ +### 1.3 Building the SQLite TCL extension + +
    +
  1. `cd $SRCCO` +
  2. `fossil clean -x` +
  3. `./configure --with-tclsh=$TCLTD/tcl86/bin/tclsh8.6` +
  4. `make tclextension-install` +
  5. → Verify extension installed at $TCLTD/tcl86/lib/tcl8.6/sqlite3.* +
  6. `fossil clean -x` +
  7. `./configure --with-tclsh=$TCLTD/tcl90/bin/tclsh9.0` +
  8. `make tclextension-install` +
  9. → Verify extension installed at $TCLTD/tcl90/lib/sqlite3.* +
+ +### 1.4 Testing the extension + +
    +
  1. + `$TCLTD/tcl86/bin/tclsh8.6 test/testrunner.tcl release --explain` +
  2. ↑ Verify thousands of lines of output with no errors +
  3. `$TCLTD/tcl90/bin/tclsh9.0 test/testrunner.tcl release --explain` +
  4. ↑ Verify thousands of lines of output with no errors +
+ +### 1.5 Cleanup + +
    +
  1. `rm -rf $TCLTD` +
+ +## 2.0 Testing On Windows + +### 2.1 Setup for Windows + +
    +
  1. + [Fossil](https://fossil-scm.org/) installed. +
  2. + A Fossil check-out of the TCL source tree. Let the directory + of this check-out be called **%TCLCO%** (mnemonic: "TCL Check-Out"). +
  3. + A Fossil check-out of the SQLite source tree. Let the directory + of this check-out be called **%SRCCO%** (mnemonic: "SouRCe Check-Out"). +
  4. + Let **%TCLTD%** (mnemonic: "TCL Test Directory") be the name of a directory + that does not exist at the start of the test, and which will be + deleted at the end of the test, that will contain the test builds + of the TCL libraries and the SQLite TCL Extensions. +
  5. + Unix-like command-line tools installed. Example: + [unxutils](https://unxutils.sourceforge.net/) +
  6. [Visual Studio](https://visualstudio.microsoft.com/vs/community/) + installed. VS2015 or later required. +
  7. `set ORIGINALPATH=%PATH%` ← remember the original %PATH% value +
+ +### 2.2 Building the TCL libraries and tclsh.exe executables on Windows + +
    +
  1. `mkdir %TCLTD% %TCLTD%\tcl86 %TCLTD%\tcl90` +
  2. `cd %TCLCO%\win` +
  3. `fossil up core-8-6-16` ← or some other version of Tcl8.6. +
  4. `fossil clean -x` +
  5. `nmake /f makefile.vc INSTALLDIR=%TCLTD%\tcl86 release install` +
  6. `fossil up core-9-0-0` ← or some other version of Tcl9 +
  7. `fossil clean -x` +
  8. `nmake /f makefile.vc INSTALLDIR=%TCLTD%\tcl86 release install` +
+ +### 2.3 Building the SQLite TCL extension on Windows + +
    +
  1. `cd %SRCCO%` +
  2. `fossil clean -x` +
  3. `set TCLDIR=%TCLTD%\tcl86` +
  4. `set PATH=%TCLTD%\tcl86\bin;%ORIGINALPATH%` +
  5. `set TCLSH_CMD=%TCLTD%\tcl86\bin\tclsh86t.exe` +
  6. `nmake /f Makefile.msc tclextension-install` +
  7. → Verify extension installed at %TCLTD%\tcl86\lib\tcl8.6\sqlite3.* +
  8. `fossil clean -x` +
  9. `set TCLDIR=%TCLTD%\tcl90` +
  10. `set PATH=%TCLTD%\tcl90\bin;%ORIGINALPATH%` +
  11. `set TCLSH_CMD=%TCLTD%\tcl90\bin\tclsh90.exe` +
  12. `nmake /f Makefile.msc tclextension-install` +
  13. → Verify extension installed at %TCLTD%\tcl906\lib\sqlite3.* +
+ +### 2.4 Testing on Windows + +
    +
  1. + `set PATH=%TCLTD%\tcl86\bin;%ORIGINALPATH%` +
  2. `tclsh86t test/testrunner.tcl release --explain` +
  3. ↑ Verify thousands of lines of output with no errors +
  4. `set PATH=%TCLTD%\tcl90\bin;%ORIGINALPATH%` +
  5. `tclsh90 test/testrunner.tcl release --explain` +
  6. ↑ Verify thousands of lines of output with no errors +
+ +### 2.5 Cleanup + +
    +
  1. `rm -rf %TCLTD%` +
diff --git a/manifest b/manifest index dbe9f57581..ceadd6eb7b 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Add\scomment\sto\sthe\scolumnIsGoodIndexCandidate()\sroutine\sto\srecord\sthe\sresults\nof\sa\sfailed\sexperiment.\s\sNo\schanges\sto\scode. -D 2025-01-03T11:51:50.103 +C Add\snew\stcl-extension-testing.md\sdocument.\s\sThe\sWindows\sside\sis\snot\syet\nworking. +D 2025-01-04T14:10:45.730 F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1 F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea F LICENSE.md e108e1e69ae8e8a59e93c455654b8ac9356a11720d3345df2a4743e9590fb20d @@ -61,6 +61,7 @@ F doc/json-enhancements.md e356fc834781f1f1aa22ee300027a270b2c960122468499bf347b F doc/jsonb.md 5fab4b8613aa9153fbeb6259297bd4697988af8b3d23900deba588fa7841456b F doc/lemon.html 8b266ff711d2ec7f867c3dca37634963f48a630329908cc282beebfa8c708706 F doc/pager-invariants.txt 27fed9a70ddad2088750c4a2b493b63853da2710 +F doc/tcl-extension-testing.md e7ce7dbd7394c411d5d3c1d29b86455e81203d750af1765304d603fd12973a27 F doc/testrunner.md 15583cf8c7d8a1c3378fd5d4319ca769a14c4d950a5df9b015d01d5be290dc69 F doc/trusted-schema.md 33625008620e879c7bcfbbfa079587612c434fa094d338b08242288d358c3e8a F doc/vdbesort-memory.md 4da2639c14cd24a31e0af694b1a8dd37eaf277aff3867e9a8cc14046bc49df56 @@ -2204,8 +2205,11 @@ F tool/version-info.c 3b36468a90faf1bbd59c65fd0eb66522d9f941eedd364fabccd7227350 F tool/warnings-clang.sh bbf6a1e685e534c92ec2bfba5b1745f34fb6f0bc2a362850723a9ee87c1b31a7 F tool/warnings.sh 49a486c5069de041aedcbde4de178293e0463ae9918ecad7539eedf0ec77a139 F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f -P 1291b013a8c93e7001fe25783bc98d12f5f7c341d1f728e6852632e18a38af58 -R 0507e66ed59bfa5a55bc14583a9d765f +P 9ee57a30a49d9813bf2669a5d8346f7e018e3fbf1792739951311a8d3a249d45 +R 33caf2e9f23e286037be195e768a7a16 +T *branch * test-procedures +T *sym-test-procedures * +T -sym-trunk * U drh -Z 3304d535a779543ccf066c65753e6b08 +Z a6ccc4c86b9da5c35c8534fa7413feee # Remove this line to create a well-formed Fossil manifest. diff --git a/manifest.uuid b/manifest.uuid index d506d57c15..ce9315f27f 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -9ee57a30a49d9813bf2669a5d8346f7e018e3fbf1792739951311a8d3a249d45 +9dc805df1b1c26196ca53baa6b1b8c2f7e59e0150d02ead53228c77a63ad40f4