1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-09-11 08:30:57 +03:00
Files
sqlite/autosetup/find_tclconfig.tcl
stephan 41c774c649 Configure refactoring to support an ongoing conversion of ./autoconf/tea to autosetup.
FossilOrigin-Name: 38d5acd9e0fa47a4b49c611dce11262fe8e43239bc8a7eb832ce8aad27172f8c
2025-03-23 15:37:34 +00:00

25 lines
614 B
Tcl

#
# Run this TCL script to find and print the pathname for the tclConfig.sh
# file. Used by ../configure
#
if {[catch {
set libdir [tcl::pkgconfig get libdir,install]
}]} {
puts stderr "tclsh too old: does not support tcl::pkgconfig"
exit 1
}
if {![file exists $libdir]} {
puts stderr "tclsh reported library directory \"$libdir\" does not exist"
exit 1
}
if {![file exists $libdir/tclConfig.sh]} {
set n1 $libdir/tcl$::tcl_version
if {[file exists $n1/tclConfig.sh]} {
set libdir $n1
} else {
puts stderr "cannot find tclConfig.sh in either $libdir or $n1"
exit 1
}
}
puts $libdir