User:Gifti/Tcl

From Wikitech
Jump to navigation Jump to search

Recipe for Compiling Tcl that is Unicode-aware beyond the BMP on Tool Labs

Creating the needed directories

mkdir -p /data/project/shared/tcl/src
cd /data/project/shared/tcl/src

Build dependency: fossil

local: pacman -Sy fossil

remote:

curl -o- https://www.fossil-scm.org/index.html/uv/fossil-linux-x64-2.7.tar.gz > fossil-bin-2.7.tgz
tar xzf fossil-bin-2.7.tgz
mkdir ../bin
mv fossil ../bin
echo alias fossil=/data/project/shared/tcl/bin/fossil >> ~/.bash_aliases
. ~/.bash_aliases

tcl

fossil clone http://core.tcl.tk/tcl/ tcl.fossil
mkdir tcl
cd tcl
fossil open ../tcl.fossil core-8-branch
generic/tcl.h:2145: #define TCL_UTF_MAX 6
cd unix
./configure --prefix=/data/project/shared/tcl
make all install

tcllib

fossil clone http://core.tcl.tk/tcllib/ tcllib.fossil
mkdir tcllib
cd tcllib
fossil open ../tcllib.fossil tcllib-1-19
./configure --prefix=/data/project/shared/tcl
make all install
/data/project/shared/tcl/lib/tcllib1.19/oauth/oauth.tcl:286: fix spurious brace
/data/project/shared/tcl/lib/tcllib1.19/oauth/oauth.tcl:275: change $header to $params

tdom

fossil clone http://core.tcl.tk/tdom/ tdom.fossil
mkdir tdom
cd tdom
fossil open ../tdom.fossil
cd unix
../configure --prefix=/data/project/shared/tcl
make install

tls

fossil clone https://core.tcl.tk/tcltls/ tls.fossil
mkdir tls
cd tls
fossil open ../tls.fossil
./autogen.sh
./configure --prefix=/data/project/shared/tcl --disable-stubs
make install

mysqltcl-3.052

local: pacman -Sy mariadb

curl -o- http://www.xdobry.de/mysqltcl/mysqltcl-3.052.tar.gz > mysqltcl-3.052.tgz
tar xzf mysqltcl-3.052.tgz
cd mysqltcl-3.052
./configure --prefix=/data/project/shared/tcl --exec-prefix=/data/project/shared/tcl
make install

TclCurl-7.22.0

curl -o- http://archive.ubuntu.com/ubuntu/pool/universe/t/tclcurl/tclcurl_7.22.0.orig.tar.gz > tclcurl-7.22.0.tgz
tar xzf tclcurl-7.22.0.tgz
cd TclCurl-7.22.0
./configure --prefix=/data/project/shared/tcl --exec-prefix=/data/project/shared/tcl
make install

trf2.1.4 (Trf)

curl -o- https://master.dl.sourceforge.net/project/tcltrf/tcltrf/2.1.4/trf2.1.4.tar.gz > trf-2.1.4.tgz
tar xzf trf-2.1.4.tgz
cd trf2.1.4
./configure --prefix=/data/project/shared/tcl --exec-prefix=/data/project/shared/tcl
Makefile: delete -DHAVE_MD2_H=1
generic/registry.c: CONST84 → CONST86
make install
/data/project/shared/tcl/lib/Trf2.1.4/pkgIndex.tcl:2: [list load -lazy [file join $dir libTrf2.1.4.so]]

xmlgen-1.4

curl -o- https://netix.dl.sourceforge.net/project/tclxml/xmlgen/v1.4/xmlgen-1.4.tar.gz > xmlgen-1.4.tgz
tar xzf xmlgen-1.4.tgz
cd xmlgen-1.4
./bras-sa prefix=/data/project/shared/tcl install

Fcgi

local: pacman -Sy fcgi

git clone https://github.com/nagarajanchinnasamy/tclfcgi
c-src/Makefile:4: LIB_INSTALL_DIR=/data/project/shared/tcl/lib/tcl8.7/tclfcgi$(LIB_VERSION)
c-src/Makefile:5: TCL_LIB=tcl8.7
c-src/Makefile:8: gcc -fPIC -c -Wall -I/data/project/shared/tcl/include tclFcgiCmd.c
c-src/Makefile:9: gcc -L/data/project/shared/tcl/lib -shared -Wl,-soname,$(LIB).so. -o $(LIB)$(LIB_VERSION).so tclFcgiCmd.o -l$(TCL_LIB) -l$(FCGI_LIB) -ltclstub8.7
tclFcgiCmd.c:76: CONST86 char *buf, int toWrite, int *errorCodePtr));
cd c-src
make all install

critcl

git clone git://github.com/andreas-kupries/critcl
lib/critcl/critcl_c/tcl8.*/tcl.h: #define TCL_UTF_MAX 6
lib/critcl/critcl_c/tcl8.*/tcl.h: #define TCL_STUB_MAGIC ((int)0xFCA3BAD0) [on newer builds]
/data/project/shared/tcl/bin/tclsh8.7 build.tcl install

WMF Labs extras

sudo mkdir -p /data/project/shared
sudo chmod o+w /data/project/shared
sudo apt-get install rlwrap joe poppler-utils automake gcc make libcurl4-gnutls-dev bc libmariadbclient-dev-compat libssl-dev tclsh
mysqltcl: --with-mysql-lib=/usr/lib/x86_64-linux-gnu
tls: --with-tcl=/data/project/shared/tcl/lib --with-openssl-dir=/usr/lib/x86_64-linux-gnu