diff options
author | rmax <rmax> | 2002-06-25 15:20:44 (GMT) |
---|---|---|
committer | rmax <rmax> | 2002-06-25 15:20:44 (GMT) |
commit | 9d463d106e0773295dc5bd223472ee3d3e45b418 (patch) | |
tree | 9090ac7b4aaaee3e54b370c88ec48ef023f05b95 /unix/mkLinks.tcl | |
parent | 34f767148b4bb7594082e532936d0ab590a82064 (diff) | |
download | tcl-9d463d106e0773295dc5bd223472ee3d3e45b418.zip tcl-9d463d106e0773295dc5bd223472ee3d3e45b418.tar.gz tcl-9d463d106e0773295dc5bd223472ee3d3e45b418.tar.bz2 |
* unix/tcl.m4: New macro SC_CONFIG_MANPAGES.
* unix/configure.in: Added support for symlinks and compression
* unix/Makefile.in: when installing the manpages. [Patch 518052]
* unix/mkLinks.tcl: Default is still hardlinks and no compression.
* unix/mkLinks: generated
* unix/configure:
* unix/README: Added documentation for the new features.
Diffstat (limited to 'unix/mkLinks.tcl')
-rw-r--r-- | unix/mkLinks.tcl | 34 |
1 files changed, 30 insertions, 4 deletions
diff --git a/unix/mkLinks.tcl b/unix/mkLinks.tcl index dd6dc52..166bc88 100644 --- a/unix/mkLinks.tcl +++ b/unix/mkLinks.tcl @@ -22,11 +22,33 @@ puts stdout \ # The script takes one argument, which is the name of the directory # where the manual entries have been installed. +while true; do + case $1 in + -s | --symlinks ) + S=-s + ;; + -z | --compress ) + ZIP=$2 + shift + ;; + *) break + ;; + esac + shift +done + if test $# != 1; then - echo "Usage: mkLinks dir" + echo "Usage: mkLinks <options> dir" exit 1 fi +if test -n "$ZIP"; then + touch TeST + $ZIP TeST + Z=`ls TeST* | sed 's/^[^.]*//'` + rm -f TeST* +fi + cd $1 echo foo > xyzzyTestingAVeryLongFileName.foo x=`echo xyzzyTe*` @@ -72,12 +94,16 @@ foreach file $argv { set tstfi "" } lappend namelist $name$ext - append rmOutput " $tst rm -f $name$ext$tstfi\n" - append lnOutput " $tst ln $tail $name$ext$tstfi\n" + append rmOutput " $tst rm -f $name$ext $name$ext\$Z$tstfi\n" + append lnOutput " $tst ln \$S $tail\$Z $name$ext\$Z$tstfi\n" } } + puts "if test -n \"\$ZIP\" -a -r $tail; then" + puts " rm -f $tail\$Z" + puts " \$ZIP $tail" + puts "fi" if { [llength $namelist] } { - puts "if test -r $tail; then" + puts "if test -r $tail\$Z; then" puts -nonewline $rmOutput puts -nonewline $lnOutput puts "fi" |