Repository navigation
Commit c490376
committed
install: derive tclsh from --with-tcl when --with-tclsh is not set
When Tcl is installed in a non-default location, the extension library
is built against the tclConfig.sh designated by --with-tcl whereas the
installed scripts run with the first tclsh found in PATH unless
--with-tclsh is also passed. Such mismatch is not reported at build time
and only shows up later through a library load failure or behavior
differences.
Look for the Tcl interpreter shell in the Tcl installation designated by
--with-tcl before searching PATH: in the bin directory of the exec prefix
recorded in tclConfig.sh, or in the bin directory sibling to the
directory holding this script when it cannot be read. A version-suffixed
tclsh is tried first as some installations do not provide the generic
name. If no interpreter is found there, a warning is reported and the
PATH lookup applies. An explicit --with-tclsh still takes precedence so
both options can be decoupled when needed.
The version-specific names tried by the PATH lookup now cover Tcl 9.0
and no longer Tcl 8.4, which is not supported anymore.
Fixes #717
Assisted-by: Claude:claude-fable-5-1
Signed-off-by: Xavier Delaruelle <xavier.delaruelle@cea.fr>1 parent c42c58e commit c490376
3 files changed
Lines changed: 93 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1596 | 1596 | | |
1597 | 1597 | | |
1598 | 1598 | | |
| 1599 | + | |
| 1600 | + | |
| 1601 | + | |
| 1602 | + | |
| 1603 | + | |
| 1604 | + | |
| 1605 | + | |
| 1606 | + | |
| 1607 | + | |
| 1608 | + | |
| 1609 | + | |
| 1610 | + | |
| 1611 | + | |
| 1612 | + | |
| 1613 | + | |
1599 | 1614 | | |
1600 | 1615 | | |
1601 | 1616 | | |
| |||
1606 | 1621 | | |
1607 | 1622 | | |
1608 | 1623 | | |
| 1624 | + | |
| 1625 | + | |
| 1626 | + | |
| 1627 | + | |
| 1628 | + | |
| 1629 | + | |
1609 | 1630 | | |
1610 | 1631 | | |
1611 | 1632 | | |
1612 | 1633 | | |
| 1634 | + | |
| 1635 | + | |
| 1636 | + | |
| 1637 | + | |
1613 | 1638 | | |
1614 | 1639 | | |
1615 | 1640 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
9 | 20 | | |
10 | 21 | | |
11 | 22 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
| 91 | + | |
91 | 92 | | |
92 | 93 | | |
93 | 94 | | |
| |||
522 | 523 | | |
523 | 524 | | |
524 | 525 | | |
525 | | - | |
| 526 | + | |
| 527 | + | |
526 | 528 | | |
527 | 529 | | |
528 | 530 | | |
529 | 531 | | |
530 | 532 | | |
531 | | - | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
532 | 536 | | |
533 | 537 | | |
534 | 538 | | |
| |||
611 | 615 | | |
612 | 616 | | |
613 | 617 | | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
614 | 625 | | |
615 | 626 | | |
616 | 627 | | |
| |||
986 | 997 | | |
987 | 998 | | |
988 | 999 | | |
989 | | - | |
| 1000 | + | |
| 1001 | + | |
| 1002 | + | |
| 1003 | + | |
990 | 1004 | | |
991 | 1005 | | |
992 | 1006 | | |
| |||
1112 | 1126 | | |
1113 | 1127 | | |
1114 | 1128 | | |
1115 | | - | |
1116 | | - | |
| 1129 | + | |
| 1130 | + | |
| 1131 | + | |
| 1132 | + | |
| 1133 | + | |
| 1134 | + | |
| 1135 | + | |
| 1136 | + | |
| 1137 | + | |
| 1138 | + | |
| 1139 | + | |
| 1140 | + | |
| 1141 | + | |
| 1142 | + | |
| 1143 | + | |
| 1144 | + | |
| 1145 | + | |
| 1146 | + | |
| 1147 | + | |
| 1148 | + | |
| 1149 | + | |
| 1150 | + | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
| 1154 | + | |
| 1155 | + | |
| 1156 | + | |
| 1157 | + | |
| 1158 | + | |
| 1159 | + | |
| 1160 | + | |
| 1161 | + | |
| 1162 | + | |
| 1163 | + | |
| 1164 | + | |
| 1165 | + | |
| 1166 | + | |
| 1167 | + | |
| 1168 | + | |
1117 | 1169 | | |
1118 | 1170 | | |
1119 | 1171 | | |
| |||
0 commit comments