想看看sqlite3的官方demo工程, 没看到. 想编译一下sqlite3源码, 看看编译后有没有example 工程.
看了sqlite3的官方说明, 他们工程使用tcl来编译的.
一听tcl, 咋这么耳熟呢? 去看了一下笔记, 原来cadence中也是可以用TCL命令的.
搜索了一下*.tcl, 在本机上好多软件都用这个.
将TCL库编译通过, 大致看了一下TCL官方教程.
sqlite3的下载点
https://www.sqlite.org/download.html
当前sqlite3版本为3.44.2
sqlite3的源码镜像 https://github.com/sqlite/sqlite.git
readme.md中有编译TCL库的说明
Install Microsoft Visual Studio. The free "community edition"
will work fine. Do a standard install for C++ development.
SQLite only needs the
"cl" compiler and the "nmake" build tool.
我本地有VS2019和VS2022的企业版, 不需要装VS.
我就用VS2019来弄一下.
Under the "Start" menu, find "All Apps" then go to "Visual Studio 20XX"
and find "x64 Native Tools Command Prompt for VS 20XX". Pin that
application to your task bar, as you will use it a lot. Bring up
an instance of this command prompt and do all of the subsequent steps
in that "x64 Native Tools" command prompt. (Or use "x86" if you want
a 32-bit build.) The subsequent steps will not work in a vanilla
DOS prompt. Nor will they work in PowerShell.
打开VS2019本地工具命令行.
编译一个X64版本的TCL库出来.
TCL下载url : https://www.tcl.tk/software/tcltk/download.html
将新版的源码包下载到本地
将源码包拷贝到D盘
d:\tcl8.6.13 是编译前的TCL库源码包, Tcl是编译后安装好的发布目录.
编译时, 360有警告, 说木马啥的, 将d:\tcl8.6.13加入白名单再编译.
在vs2019本地工具命令行中编译
cd /d d:\tcl8.6.13
cd win
# 编译T
nmake /f makefile.vc release
# 等待编译完成.
# a
nmake /f makefile.vc INSTALLDIR=d:\Tcl install
将发布目录的库和exe都改个名字(可以改一个本地独一无二的名字), 方便使用. 防止和其他软件用的TCL库和EXE名称相同.
sqlite官方建议将自己编译出的TCL库发布目录的bin目录添加到环境变量.
因为本地有很多tcl发布目录(好多软件都带这个TCL发布包…)
我还是用bat启动, 然后加个临时环境变量好点.
写了一个脚本,来运行tcl命令. 使用的TCL库指定为自己编译的那个.
@echo off
rem https://www.tcl.tk/man/tcl8.5/tutorial/Tcl0.html 这是TCL官方教程
cls
rem the .cmd must save as ansi, 否则乱码
rem 指定代码页为GB2312
chcp 936
rem 进入当前目录
cd /d %~dp0
rem %~dp0 是当前目录的路径, 已经带\了
rem echo %~dp0TCL\bin
rem 将当前目录加入临时的环境变量
set path=%~dp0\TCL\bin;%path%
rem 将tcl拖拽到.cmd上面就行, 就可以运行. 不用在命令行窗口运行
tclsh86.exe %1
pause
我直接将TCL发布目录拷贝到bat脚本文件的当前目录, 就使用自己的TCL目录.
如果想做TCL实验, 直接将.tcl拖动到.cmd上面, 就可以运行了.
https://www.tcl.tk/man/tcl8.5/tutorial/tcltutorial.html
忘了怎么找个这个官方教程url了.
反正去看 https://www.tcl.tk/man/
能看到每个版本的帮助
其他版本的都是帮助文件, 这个TCL8.5是个网页版教程, 讲的很详细.
如果只是出于维护(学习)已有TCL程序的目的, 需要啥, 就去找啥就行.
一共有49个特性.
TCL官方教程中说, 大概几个小时就能用TCL来干活.
应该没那么简单, 熟悉还有个过程呢.
大致翻了一下. 知道有啥特性了. 官方给出的demo大部分(和linux无关的部分)都可以运行.
要想看完, 就能马上自己写TCL程序, 那有点扯.
不过大致翻一下, 做TCL程序的维护是没问题的.
默认的编译是x86, 带参数编译可以编译出x86, amd64版本.
真正编译时, TCL官方说的也不是很清楚.
要想编译win版的TCL(x86, amd64)版本, 需要看 D:\tcl8.6.13\win\makefile.vc, 能看到编译用到的命令行参数.
重新来一次.
解压 tcl8613-src.zip, 将 E:\tools\database\sqlite3.44.2\tcl8613-src\tcl8.6.13 拷贝到D盘
cd /d D:\tcl8.6.13\win
编译动作都要在 d:\tcl8.6.13/win目录下进行, 且命令行环境为vs2019本地x64命令行窗口
set path=D:\tcl8.6.13\win;%path%
nmake -f makefile.vc clean
nmake -f makefile.vc all MACHINE=AMD64 PROCESSOR_ARCHITECTURE=AMD64
nmake -f makefile.vc install INSTALLDIR=d:\TCL\x64
set path=D:\tcl8.6.13\win;%path%
nmake -f makefile.vc clean
# 不执行下面这句, 报错
nmake -f makefile.vc all MACHINE=X86
报错, 无法指定MACHINE=X86
rules.vc(472) : fatal error U1050: Specified MACHINE macro IX86 does not match detected target architecture AMD64.
Stop.
nmake -f makefile.vc all MACHINE=AMD64 PROCESSOR_ARCHITECTURE=IX86
nmake -f makefile.vc install INSTALLDIR=d:\TCL\x86
用010Editor看了一下
差别只有6个字节, 应该就是编译时间和校验和的区别.
编译出来的应该都是x86版本.
这个是最干净清晰的编译命令脚本
# 将tcl/win目录加入临时path环境变量, 让 tcl/win目录在path的最前面.
set path=D:\tcl8.6.13\win;%path%
# 清除工程编译结果(回到未编译之前的状态)
nmake -f makefile.vc clean
# 全部编译, 本机编译环境为AMD64
nmake -f makefile.vc all MACHINE=AMD64
# 看了编译的日志, 以上编译过程, 全程没有err信息
# 将编译完的TCL输出, 安装到自己指定的目录 d:\TCL
nmake -f makefile.vc install INSTALLDIR=d:\TCL\
cd /d d:\TCL
D:\TCL>tree /a /f
文件夹 PATH 列表
卷序列号为 36AD-51CE
D:.
+---bin
| tcl86t.dll
| tclsh86t.exe
| zlib1.dll
|
+---include
| itcl.h
| itclDecls.h
| tcl.h
| tclDecls.h
| tclOO.h
| tclOODecls.h
| tclPlatDecls.h
| tclTomMath.h
| tclTomMathDecls.h
| tdbc.h
| tdbcDecls.h
|
\---lib
| tcl86t.lib
| tclConfig.sh
| tclooConfig.sh
| tclstub86.lib
|
+---dde1.4
| pkgIndex.tcl
| tcldde14.dll
|
+---itcl4.2.3
| itcl.tcl
| itcl423t.dll
| itclHullCmds.tcl
| itclstub423.lib
| itclWidget.tcl
| pkgIndex.tcl
| test_Itcl_CreateObject.tcl
|
+---nmake
| nmakehlp.c
| rules.vc
| targets.vc
| tcl.nmake
| x86_64-w64-mingw32-nmakehlp.exe
|
+---reg1.3
| pkgIndex.tcl
| tclreg13.dll
|
+---sqlite3.40.0
| pkgIndex.tcl
| sqlite3.n
| sqlite3400t.dll
|
+---tcl8
| +---8.4
| | | platform-1.0.19.tm
| | |
| | \---platform
| | shell-1.1.4.tm
| |
| +---8.5
| | msgcat-1.6.1.tm
| | tcltest-2.5.5.tm
| |
| \---8.6
| | http-2.9.8.tm
| |
| \---tdbc
| sqlite3-1.1.5.tm
|
+---tcl8.6
| | auto.tcl
| | clock.tcl
| | history.tcl
| | init.tcl
| | package.tcl
| | parray.tcl
| | safe.tcl
| | tclIndex
| | tm.tcl
| | word.tcl
| |
| +---encoding
| | ascii.enc
| | big5.enc
| | cns11643.enc
| | cp1250.enc
| | cp1251.enc
| | cp1252.enc
| | cp1253.enc
| | cp1254.enc
| | cp1255.enc
| | cp1256.enc
| | cp1257.enc
| | cp1258.enc
| | cp437.enc
| | cp737.enc
| | cp775.enc
| | cp850.enc
| | cp852.enc
| | cp855.enc
| | cp857.enc
| | cp860.enc
| | cp861.enc
| | cp862.enc
| | cp863.enc
| | cp864.enc
| | cp865.enc
| | cp866.enc
| | cp869.enc
| | cp874.enc
| | cp932.enc
| | cp936.enc
| | cp949.enc
| | cp950.enc
| | dingbats.enc
| | ebcdic.enc
| | euc-cn.enc
| | euc-jp.enc
| | euc-kr.enc
| | gb12345.enc
| | gb1988.enc
| | gb2312-raw.enc
| | gb2312.enc
| | iso2022-jp.enc
| | iso2022-kr.enc
| | iso2022.enc
| | iso8859-1.enc
| | iso8859-10.enc
| | iso8859-11.enc
| | iso8859-13.enc
| | iso8859-14.enc
| | iso8859-15.enc
| | iso8859-16.enc
| | iso8859-2.enc
| | iso8859-3.enc
| | iso8859-4.enc
| | iso8859-5.enc
| | iso8859-6.enc
| | iso8859-7.enc
| | iso8859-8.enc
| | iso8859-9.enc
| | jis0201.enc
| | jis0208.enc
| | jis0212.enc
| | koi8-r.enc
| | koi8-u.enc
| | ksc5601.enc
| | macCentEuro.enc
| | macCroatian.enc
| | macCyrillic.enc
| | macDingbats.enc
| | macGreek.enc
| | macIceland.enc
| | macJapan.enc
| | macRoman.enc
| | macRomania.enc
| | macThai.enc
| | macTurkish.enc
| | macUkraine.enc
| | shiftjis.enc
| | symbol.enc
| | tis-620.enc
| |
| +---http1.0
| | http.tcl
| | pkgIndex.tcl
| |
| +---msgs
| | af.msg
| | af_za.msg
| | ar.msg
| | ar_in.msg
| | ar_jo.msg
| | ar_lb.msg
| | ar_sy.msg
| | be.msg
| | bg.msg
| | bn.msg
| | bn_in.msg
| | ca.msg
| | cs.msg
| | da.msg
| | de.msg
| | de_at.msg
| | de_be.msg
| | el.msg
| | en_au.msg
| | en_be.msg
| | en_bw.msg
| | en_ca.msg
| | en_gb.msg
| | en_hk.msg
| | en_ie.msg
| | en_in.msg
| | en_nz.msg
| | en_ph.msg
| | en_sg.msg
| | en_za.msg
| | en_zw.msg
| | eo.msg
| | es.msg
| | es_ar.msg
| | es_bo.msg
| | es_cl.msg
| | es_co.msg
| | es_cr.msg
| | es_do.msg
| | es_ec.msg
| | es_gt.msg
| | es_hn.msg
| | es_mx.msg
| | es_ni.msg
| | es_pa.msg
| | es_pe.msg
| | es_pr.msg
| | es_py.msg
| | es_sv.msg
| | es_uy.msg
| | es_ve.msg
| | et.msg
| | eu.msg
| | eu_es.msg
| | fa.msg
| | fa_in.msg
| | fa_ir.msg
| | fi.msg
| | fo.msg
| | fo_fo.msg
| | fr.msg
| | fr_be.msg
| | fr_ca.msg
| | fr_ch.msg
| | ga.msg
| | ga_ie.msg
| | gl.msg
| | gl_es.msg
| | gv.msg
| | gv_gb.msg
| | he.msg
| | hi.msg
| | hi_in.msg
| | hr.msg
| | hu.msg
| | id.msg
| | id_id.msg
| | is.msg
| | it.msg
| | it_ch.msg
| | ja.msg
| | kl.msg
| | kl_gl.msg
| | ko.msg
| | kok.msg
| | kok_in.msg
| | ko_kr.msg
| | kw.msg
| | kw_gb.msg
| | lt.msg
| | lv.msg
| | mk.msg
| | mr.msg
| | mr_in.msg
| | ms.msg
| | ms_my.msg
| | mt.msg
| | nb.msg
| | nl.msg
| | nl_be.msg
| | nn.msg
| | pl.msg
| | pt.msg
| | pt_br.msg
| | ro.msg
| | ru.msg
| | ru_ua.msg
| | sh.msg
| | sk.msg
| | sl.msg
| | sq.msg
| | sr.msg
| | sv.msg
| | sw.msg
| | ta.msg
| | ta_in.msg
| | te.msg
| | te_in.msg
| | th.msg
| | tr.msg
| | uk.msg
| | vi.msg
| | zh.msg
| | zh_cn.msg
| | zh_hk.msg
| | zh_sg.msg
| | zh_tw.msg
| |
| +---opt0.4
| | optparse.tcl
| | pkgIndex.tcl
| |
| \---tzdata
| | CET
| | CST6CDT
| | Cuba
| | EET
| | Egypt
| | Eire
| | EST
| | EST5EDT
| | GB
| | GB-Eire
| | GMT
| | GMT+0
| | GMT-0
| | GMT0
| | Greenwich
| | Hongkong
| | HST
| | Iceland
| | Iran
| | Israel
| | Jamaica
| | Japan
| | Kwajalein
| | Libya
| | MET
| | MST
| | MST7MDT
| | Navajo
| | NZ
| | NZ-CHAT
| | Poland
| | Portugal
| | PRC
| | PST8PDT
| | ROC
| | ROK
| | Singapore
| | Turkey
| | UCT
| | Universal
| | UTC
| | W-SU
| | WET
| | Zulu
| |
| +---Africa
| | Abidjan
| | Accra
| | Addis_Ababa
| | Algiers
| | Asmara
| | Asmera
| | Bamako
| | Bangui
| | Banjul
| | Bissau
| | Blantyre
| | Brazzaville
| | Bujumbura
| | Cairo
| | Casablanca
| | Ceuta
| | Conakry
| | Dakar
| | Dar_es_Salaam
| | Djibouti
| | Douala
| | El_Aaiun
| | Freetown
| | Gaborone
| | Harare
| | Johannesburg
| | Juba
| | Kampala
| | Khartoum
| | Kigali
| | Kinshasa
| | Lagos
| | Libreville
| | Lome
| | Luanda
| | Lubumbashi
| | Lusaka
| | Malabo
| | Maputo
| | Maseru
| | Mbabane
| | Mogadishu
| | Monrovia
| | Nairobi
| | Ndjamena
| | Niamey
| | Nouakchott
| | Ouagadougou
| | Porto-Novo
| | Sao_Tome
| | Timbuktu
| | Tripoli
| | Tunis
| | Windhoek
| |
| +---America
| | | Adak
| | | Anchorage
| | | Anguilla
| | | Antigua
| | | Araguaina
| | | Aruba
| | | Asuncion
| | | Atikokan
| | | Atka
| | | Bahia
| | | Bahia_Banderas
| | | Barbados
| | | Belem
| | | Belize
| | | Blanc-Sablon
| | | Boa_Vista
| | | Bogota
| | | Boise
| | | Buenos_Aires
| | | Cambridge_Bay
| | | Campo_Grande
| | | Cancun
| | | Caracas
| | | Catamarca
| | | Cayenne
| | | Cayman
| | | Chicago
| | | Chihuahua
| | | Coral_Harbour
| | | Cordoba
| | | Costa_Rica
| | | Creston
| | | Cuiaba
| | | Curacao
| | | Danmarkshavn
| | | Dawson
| | | Dawson_Creek
| | | Denver
| | | Detroit
| | | Dominica
| | | Edmonton
| | | Eirunepe
| | | El_Salvador
| | | Ensenada
| | | Fortaleza
| | | Fort_Nelson
| | | Fort_Wayne
| | | Glace_Bay
| | | Godthab
| | | Goose_Bay
| | | Grand_Turk
| | | Grenada
| | | Guadeloupe
| | | Guatemala
| | | Guayaquil
| | | Guyana
| | | Halifax
| | | Havana
| | | Hermosillo
| | | Indianapolis
| | | Inuvik
| | | Iqaluit
| | | Jamaica
| | | Jujuy
| | | Juneau
| | | Knox_IN
| | | Kralendijk
| | | La_Paz
| | | Lima
| | | Los_Angeles
| | | Louisville
| | | Lower_Princes
| | | Maceio
| | | Managua
| | | Manaus
| | | Marigot
| | | Martinique
| | | Matamoros
| | | Mazatlan
| | | Mendoza
| | | Menominee
| | | Merida
| | | Metlakatla
| | | Mexico_City
| | | Miquelon
| | | Moncton
| | | Monterrey
| | | Montevideo
| | | Montreal
| | | Montserrat
| | | Nassau
| | | New_York
| | | Nipigon
| | | Nome
| | | Noronha
| | | Nuuk
| | | Ojinaga
| | | Panama
| | | Pangnirtung
| | | Paramaribo
| | | Phoenix
| | | Port-au-Prince
| | | Porto_Acre
| | | Porto_Velho
| | | Port_of_Spain
| | | Puerto_Rico
| | | Punta_Arenas
| | | Rainy_River
| | | Rankin_Inlet
| | | Recife
| | | Regina
| | | Resolute
| | | Rio_Branco
| | | Rosario
| | | Santarem
| | | Santa_Isabel
| | | Santiago
| | | Santo_Domingo
| | | Sao_Paulo
| | | Scoresbysund
| | | Shiprock
| | | Sitka
| | | St_Barthelemy
| | | St_Johns
| | | St_Kitts
| | | St_Lucia
| | | St_Thomas
| | | St_Vincent
| | | Swift_Current
| | | Tegucigalpa
| | | Thule
| | | Thunder_Bay
| | | Tijuana
| | | Toronto
| | | Tortola
| | | Vancouver
| | | Virgin
| | | Whitehorse
| | | Winnipeg
| | | Yakutat
| | | Yellowknife
| | |
| | +---Argentina
| | | Buenos_Aires
| | | Catamarca
| | | ComodRivadavia
| | | Cordoba
| | | Jujuy
| | | La_Rioja
| | | Mendoza
| | | Rio_Gallegos
| | | Salta
| | | San_Juan
| | | San_Luis
| | | Tucuman
| | | Ushuaia
| | |
| | +---Indiana
| | | Indianapolis
| | | Knox
| | | Marengo
| | | Petersburg
| | | Tell_City
| | | Vevay
| | | Vincennes
| | | Winamac
| | |
| | +---Kentucky
| | | Louisville
| | | Monticello
| | |
| | \---North_Dakota
| | Beulah
| | Center
| | New_Salem
| |
| +---Antarctica
| | Casey
| | Davis
| | DumontDUrville
| | Macquarie
| | Mawson
| | McMurdo
| | Palmer
| | Rothera
| | South_Pole
| | Syowa
| | Troll
| | Vostok
| |
| +---Arctic
| | Longyearbyen
| |
| +---Asia
| | Aden
| | Almaty
| | Amman
| | Anadyr
| | Aqtau
| | Aqtobe
| | Ashgabat
| | Ashkhabad
| | Atyrau
| | Baghdad
| | Bahrain
| | Baku
| | Bangkok
| | Barnaul
| | Beirut
| | Bishkek
| | Brunei
| | Calcutta
| | Chita
| | Choibalsan
| | Chongqing
| | Chungking
| | Colombo
| | Dacca
| | Damascus
| | Dhaka
| | Dili
| | Dubai
| | Dushanbe
| | Famagusta
| | Gaza
| | Harbin
| | Hebron
| | Hong_Kong
| | Hovd
| | Ho_Chi_Minh
| | Irkutsk
| | Istanbul
| | Jakarta
| | Jayapura
| | Jerusalem
| | Kabul
| | Kamchatka
| | Karachi
| | Kashgar
| | Kathmandu
| | Katmandu
| | Khandyga
| | Kolkata
| | Krasnoyarsk
| | Kuala_Lumpur
| | Kuching
| | Kuwait
| | Macao
| | Macau
| | Magadan
| | Makassar
| | Manila
| | Muscat
| | Nicosia
| | Novokuznetsk
| | Novosibirsk
| | Omsk
| | Oral
| | Phnom_Penh
| | Pontianak
| | Pyongyang
| | Qatar
| | Qostanay
| | Qyzylorda
| | Rangoon
| | Riyadh
| | Saigon
| | Sakhalin
| | Samarkand
| | Seoul
| | Shanghai
| | Singapore
| | Srednekolymsk
| | Taipei
| | Tashkent
| | Tbilisi
| | Tehran
| | Tel_Aviv
| | Thimbu
| | Thimphu
| | Tokyo
| | Tomsk
| | Ujung_Pandang
| | Ulaanbaatar
| | Ulan_Bator
| | Urumqi
| | Ust-Nera
| | Vientiane
| | Vladivostok
| | Yakutsk
| | Yangon
| | Yekaterinburg
| | Yerevan
| |
| +---Atlantic
| | Azores
| | Bermuda
| | Canary
| | Cape_Verde
| | Faeroe
| | Faroe
| | Jan_Mayen
| | Madeira
| | Reykjavik
| | South_Georgia
| | Stanley
| | St_Helena
| |
| +---Australia
| | ACT
| | Adelaide
| | Brisbane
| | Broken_Hill
| | Canberra
| | Currie
| | Darwin
| | Eucla
| | Hobart
| | LHI
| | Lindeman
| | Lord_Howe
| | Melbourne
| | North
| | NSW
| | Perth
| | Queensland
| | South
| | Sydney
| | Tasmania
| | Victoria
| | West
| | Yancowinna
| |
| +---Brazil
| | Acre
| | DeNoronha
| | East
| | West
| |
| +---Canada
| | Atlantic
| | Central
| | Eastern
| | Mountain
| | Newfoundland
| | Pacific
| | Saskatchewan
| | Yukon
| |
| +---Chile
| | Continental
| | EasterIsland
| |
| +---Etc
| | GMT
| | GMT+0
| | GMT+1
| | GMT+10
| | GMT+11
| | GMT+12
| | GMT+2
| | GMT+3
| | GMT+4
| | GMT+5
| | GMT+6
| | GMT+7
| | GMT+8
| | GMT+9
| | GMT-0
| | GMT-1
| | GMT-10
| | GMT-11
| | GMT-12
| | GMT-13
| | GMT-14
| | GMT-2
| | GMT-3
| | GMT-4
| | GMT-5
| | GMT-6
| | GMT-7
| | GMT-8
| | GMT-9
| | GMT0
| | Greenwich
| | UCT
| | Universal
| | UTC
| | Zulu
| |
| +---Europe
| | Amsterdam
| | Andorra
| | Astrakhan
| | Athens
| | Belfast
| | Belgrade
| | Berlin
| | Bratislava
| | Brussels
| | Bucharest
| | Budapest
| | Busingen
| | Chisinau
| | Copenhagen
| | Dublin
| | Gibraltar
| | Guernsey
| | Helsinki
| | Isle_of_Man
| | Istanbul
| | Jersey
| | Kaliningrad
| | Kiev
| | Kirov
| | Kyiv
| | Lisbon
| | Ljubljana
| | London
| | Luxembourg
| | Madrid
| | Malta
| | Mariehamn
| | Minsk
| | Monaco
| | Moscow
| | Nicosia
| | Oslo
| | Paris
| | Podgorica
| | Prague
| | Riga
| | Rome
| | Samara
| | San_Marino
| | Sarajevo
| | Saratov
| | Simferopol
| | Skopje
| | Sofia
| | Stockholm
| | Tallinn
| | Tirane
| | Tiraspol
| | Ulyanovsk
| | Uzhgorod
| | Vaduz
| | Vatican
| | Vienna
| | Vilnius
| | Volgograd
| | Warsaw
| | Zagreb
| | Zaporozhye
| | Zurich
| |
| +---Indian
| | Antananarivo
| | Chagos
| | Christmas
| | Cocos
| | Comoro
| | Kerguelen
| | Mahe
| | Maldives
| | Mauritius
| | Mayotte
| | Reunion
| |
| +---Mexico
| | BajaNorte
| | BajaSur
| | General
| |
| +---Pacific
| | Apia
| | Auckland
| | Bougainville
| | Chatham
| | Chuuk
| | Easter
| | Efate
| | Enderbury
| | Fakaofo
| | Fiji
| | Funafuti
| | Galapagos
| | Gambier
| | Guadalcanal
| | Guam
| | Honolulu
| | Johnston
| | Kanton
| | Kiritimati
| | Kosrae
| | Kwajalein
| | Majuro
| | Marquesas
| | Midway
| | Nauru
| | Niue
| | Norfolk
| | Noumea
| | Pago_Pago
| | Palau
| | Pitcairn
| | Pohnpei
| | Ponape
| | Port_Moresby
| | Rarotonga
| | Saipan
| | Samoa
| | Tahiti
| | Tarawa
| | Tongatapu
| | Truk
| | Wake
| | Wallis
| | Yap
| |
| +---SystemV
| | AST4
| | AST4ADT
| | CST6
| | CST6CDT
| | EST5
| | EST5EDT
| | HST10
| | MST7
| | MST7MDT
| | PST8
| | PST8PDT
| | YST9
| | YST9YDT
| |
| \---US
| Alaska
| Aleutian
| Arizona
| Central
| East-Indiana
| Eastern
| Hawaii
| Indiana-Starke
| Michigan
| Mountain
| Pacific
| Samoa
|
+---tdbc1.1.5
| pkgIndex.tcl
| tdbc.n
| tdbc.tcl
| tdbc115t.dll
| tdbcConfig.sh
| tdbcstub115.lib
| tdbc_connection.n
| tdbc_mapSqlState.n
| tdbc_resultset.n
| tdbc_statement.n
| tdbc_tokenize.n
|
+---tdbcmysql1.1.5
| pkgIndex.tcl
| tdbcmysql.tcl
| tdbcmysql115t.dll
| tdbc_mysql.n
|
+---tdbcodbc1.1.5
| pkgIndex.tcl
| tdbcodbc.tcl
| tdbcodbc115t.dll
| tdbc_odbc.n
|
+---tdbcpostgres1.1.5
| pkgIndex.tcl
| tdbcpostgres.tcl
| tdbcpostgres115t.dll
| tdbc_postgres.n
|
+---tdbcsqlite31.1.5
| tdbc_sqlite3.n
|
\---thread2.8.8
pkgIndex.tcl
thread.html
thread288t.dll
tpool.html
tsv.html
ttrace.html
ttrace.tcl
D:\TCL>
用编译出来的TCL, 编译sqlite3.44.2的shell.c时, 在有一行出现乱码. 怀疑是chcp 936的问题.
将chcp改为437(美国), 编译一次TCL再试试.
# 打开vs2019本地x64命令行
# 清屏
cls
# 改变代码页到美国
chcp 437
# 查看当前代码页
chcp
cd /d D:\tcl8.6.13\win
# 将tcl/win目录加入临时path环境变量, 让 tcl/win目录在path的最前面.
set path=D:\tcl8.6.13\win;%path%
# 清除工程编译结果(回到未编译之前的状态)
nmake -f makefile.vc clean
# 全部编译, 本机编译环境为AMD64
nmake -f makefile.vc all MACHINE=AMD64
# 看了编译的日志, 以上编译过程, 全程没有err信息
# 将编译完的TCL输出, 安装到自己指定的目录 d:\TCL
nmake -f makefile.vc install INSTALLDIR=d:\TCL\
查了, 是sqlite4.44.2的shell.c.in中写错了. chcp是啥都行, 默认的也行.
将shell.c.in的9462行不可见字符在vscode中删掉, 就可以按照正常流程将sqlite4.44.2编译过.
上图是原始安装后的截图.
有个tclstub86.lib的库.
在我用自己指定命令行编译时, 要用到的lib为tclstub86t.lib, 所以要拷贝一个tclstub86.lib, 改名为tclstub86t.lib. 如下.