summaryrefslogtreecommitdiffstats
path: root/library/package.tcl
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2003-07-11 18:46:25 (GMT)
committerdgp <dgp@users.sourceforge.net>2003-07-11 18:46:25 (GMT)
commit50e63af8e12e08f7d7e8f6808a1fe7a656d934f9 (patch)
treefcdd45abbf5345d69313b942b47ac6d8fb91f6eb /library/package.tcl
parent77af51dd0040c57831f60c5addcb925dc197980b (diff)
downloadtcl-50e63af8e12e08f7d7e8f6808a1fe7a656d934f9.zip
tcl-50e63af8e12e08f7d7e8f6808a1fe7a656d934f9.tar.gz
tcl-50e63af8e12e08f7d7e8f6808a1fe7a656d934f9.tar.bz2
* library/package.tcl: Corrected [pkg_mkIndex] bug reported on
comp.lang.tcl. The indexer was searching for newly indexed packages instead of newly provided packages.
Diffstat (limited to 'library/package.tcl')
-rw-r--r--library/package.tcl10
1 files changed, 7 insertions, 3 deletions
diff --git a/library/package.tcl b/library/package.tcl
index 96e2f00..663b84a 100644
--- a/library/package.tcl
+++ b/library/package.tcl
@@ -3,7 +3,7 @@
# utility procs formerly in init.tcl which can be loaded on demand
# for package management.
#
-# RCS: @(#) $Id: package.tcl,v 1.23 2003/02/25 23:58:09 dgp Exp $
+# RCS: @(#) $Id: package.tcl,v 1.23.2.1 2003/07/11 18:46:25 dgp Exp $
#
# Copyright (c) 1991-1993 The Regents of the University of California.
# Copyright (c) 1994-1998 Sun Microsystems, Inc.
@@ -272,7 +272,9 @@ proc pkg_mkIndex {args} {
set ::tcl::namespaces($::tcl::x) 1
}
foreach ::tcl::x [package names] {
- set ::tcl::packages($::tcl::x) 1
+ if {[string compare [package provide $::tcl::x] ""]} {
+ set ::tcl::packages($::tcl::x) 1
+ }
}
set ::tcl::origCmds [info commands]
@@ -366,7 +368,9 @@ proc pkg_mkIndex {args} {
set cmds [lsort [$c eval array names ::tcl::newCmds]]
set pkgs [$c eval set ::tcl::newPkgs]
if {$doVerbose} {
- tclLog "commands provided were $cmds"
+ if { !$::tcl::direct } {
+ tclLog "commands provided were $cmds"
+ }
tclLog "packages provided were $pkgs"
}
if {[llength $pkgs] > 1} {