]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Add the "tool-zip" makefile target with the intention of using it to build
authordrh <>
Thu, 7 Sep 2023 13:43:46 +0000 (13:43 +0000)
committerdrh <>
Thu, 7 Sep 2023 13:43:46 +0000 (13:43 +0000)
the "sqlite-tool-*.zip" deliverables.
deliverables.

FossilOrigin-Name: 06e4af492d669bb45c00b1b876cd82ec8813ac9ed580eb1dddd18147f7fbe7f6

Makefile.in
Makefile.msc
manifest
manifest.uuid
tool/mktoolzip.tcl [new file with mode: 0644]

index e3bf1c0e7aa9ff1ca80418b2d88beec95cc5dc07..3857b335cc26fd2f73ad5abff49717eb7e0e52c3 100644 (file)
@@ -1468,6 +1468,11 @@ amalgamation-tarball: sqlite3.c sqlite3rc.h
 snapshot-tarball: sqlite3.c sqlite3rc.h
        TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh --snapshot
 
+# Build a ZIP archive containing various command-line tools.
+#
+tool-zip:      testfixture sqlite3 sqldiff sqlite3_analyzer tool/mktoolzip.tcl
+       ./testfixture $(TOP)/tool/mktoolzip.tcl
+
 # The next two rules are used to support the "threadtest" target. Building
 # threadtest runs a few thread-safety tests that are implemented in C. This
 # target is invoked by the releasetest.tcl script.
index 3179e301ced35eee336bd5708690a66b5742bb2c..fe442ff02715eea1b390c3774831a7ddb3a25876 100644 (file)
@@ -2466,6 +2466,9 @@ extensiontest:    testfixture.exe testloadext.dll
        @set PATH=$(LIBTCLPATH);$(PATH)
        .\testfixture.exe $(TOP)\test\loadext.test $(TESTOPTS)
 
+tool-zip:      testfixture.exe sqlite3.exe sqldiff.exe sqlite3_analyzer.exe tool\mktoolzip.tcl
+       .\testfixture.exe $(TOP)\tool\mktoolzip.tcl
+
 coretestprogs: $(TESTPROGS)
 
 testprogs:     coretestprogs srcck1.exe fuzzcheck.exe sessionfuzz.exe
index efa971009bfea81b9ec01a73752fb2b39f115d2e..c66d8b91ed9bb06fac81511333edb49e981a15a0 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,11 +1,11 @@
-C Fix\sa\sproblem\swith\sthe\snew\sxIntegrity\smethod\sfor\svirtual\stables,\sand\salso\sfix\na\sbad\sassert()\sin\sFTS3\sthat\swas\sfound\sby\sthe\snew\sxIntegrity\smethod.
-D 2023-09-07T02:13:01.712
+C Add\sthe\s"tool-zip"\smakefile\starget\swith\sthe\sintention\sof\susing\sit\sto\sbuild\nthe\s"sqlite-tool-*.zip"\sdeliverables.\ndeliverables.
+D 2023-09-07T13:43:46.267
 F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
 F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
 F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724
-F Makefile.in 345a8599cf8ff015db534cedad7af70a1a6c36e295b85d720966c18af836ed30
+F Makefile.in 3982c6eae796e50f3752938a01baa6795f15c18d84b3519273c08a197449eaf5
 F Makefile.linux-gcc f3842a0b1efbfbb74ac0ef60e56b301836d05b4d867d014f714fa750048f1ab6
-F Makefile.msc 26c2d196391a285c279adb10fd6001774d9b243af94b700b681e4a49cd476684
+F Makefile.msc f926abe4737ffa3303aeb67d8ea74857f4038754a95605c332be1c9dbf8b96c7
 F README.md 963d30019abf0cc06b263cd2824bce022893f3f93a531758f6f04ff2194a16a8
 F VERSION 4c09b629c03b8ae32317cb336a32f3aa3252841d6dcd51184cecc4278d08f21e
 F aclocal.m4 a5c22d164aff7ed549d53a90fa56d56955281f50
@@ -2052,6 +2052,7 @@ F tool/mksqlite3c-noext.tcl 4f7cfef5152b0c91920355cbfc1d608a4ad242cb819f1aea07f6
 F tool/mksqlite3c.tcl 49e39b1e616abc92fd8c24445f2b0a38881825f764541e0026f72371f0d84b65
 F tool/mksqlite3h.tcl d391cff7cad0a372ee1406faee9ccc7dad9cb80a0c95cae0f73d10dd26e06762
 F tool/mksqlite3internalh.tcl eb994013e833359137eb53a55acdad0b5ae1049b
+F tool/mktoolzip.tcl 6e17f53eb924c76ea5f290cf7b8f554cc245ad6299e46928419abcd2de691663
 F tool/mkvsix.tcl b9e0777a213c23156b6542842c238479e496ebf5
 F tool/offsets.c 8ed2b344d33f06e71366a9b93ccedaa38c096cc1dbd4c3c26ad08c6115285845
 F tool/omittest-msvc.tcl d6b8f501ac1d7798c4126065030f89812379012cad98a1735d6d7221492abc08
@@ -2116,8 +2117,8 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
 F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
 F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
 F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
-P 2f08e7d233b6ddc28b61f0d17ae9b815a91c3c6e080862ce009dc0ad73c64cf5
-R 952f8907b9fdf93e9f346e8c246b709e
+P 52bbf44f2d9addc2b5f68b0fe33542470852310ce3a283e2c7ff4c52831d0ed1
+R a7d6d8c069f8111be4f8b370cfa74f7e
 U drh
-Z f56679f795893da1dd120112bad946ce
+Z 548c7d955d69da5eec73ae6299ce924e
 # Remove this line to create a well-formed Fossil manifest.
index 7ef4021f92e01a491052439150da1546a8d4f7c6..d250e1fbf64bef75766d830171d79193a8caebe5 100644 (file)
@@ -1 +1 @@
-52bbf44f2d9addc2b5f68b0fe33542470852310ce3a283e2c7ff4c52831d0ed1
\ No newline at end of file
+06e4af492d669bb45c00b1b876cd82ec8813ac9ed580eb1dddd18147f7fbe7f6
\ No newline at end of file
diff --git a/tool/mktoolzip.tcl b/tool/mktoolzip.tcl
new file mode 100644 (file)
index 0000000..0eb6788
--- /dev/null
@@ -0,0 +1,59 @@
+#!/usr/bin/tclsh
+#
+# Run this script in order to generate a ZIP archive containing various
+# command-line tools.
+#
+# The makefile that invokes this script must first build the following
+# binaries:
+#
+#     testfixture             -- used to run this script
+#     sqlite3                 -- the SQLite CLI
+#     sqldiff                 -- Program to diff two databases
+#     sqlite3_analyzer        -- Space analyzer
+#
+switch $tcl_platform(os) {
+  {Windows NT} {
+    set OS win32
+    set EXE .exe
+  }
+  Linux {
+    set OS linux
+    set EXE {}
+  }
+  Darwin {
+    set OS osx
+    set EXE {}
+  }
+  default {
+    set OS unknown
+    set EXE {}
+  }
+}
+switch $tcl_platform(machine) {
+  arm64 {
+    set ARCH arm64
+  }
+  x86_64 {
+    set ARCH x64
+  }
+  amd64 -
+  intel {
+    if {$tcl_platform(pointerSize)==4} {
+      set ARCH x86
+    } else {
+      set ARCH x64
+    }
+  }
+  default {
+    set ARCH unk
+  }
+}
+set in [open VERSION]
+set vers [read $in]
+close $in
+scan $vers %d.%d.%d v1 v2 v3
+set v2 [format 3%02d%02d00 $v2 $v3]
+set name sqlite-tools-$OS-$ARCH-$v2.zip
+puts "zip $name sqlite3$EXE sqldiff$EXE sqlite3_analyzer$EXE"
+puts [exec zip $name sqlite3$EXE sqldiff$EXE sqlite3_analyzer$EXE]
+puts [exec ls -l $name]