Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2016-09-01
16:10 • Ticket [427697ffff] Script for Making Dependency Information status still Op... artifact: d337c8438f user: dkf
2016-08-20
16:46 • Ticket [427697ffff]: 6 changes artifact: 30bb2bacb2 user: dkf
2003-03-27
18:01 • Ticket [427697ffff]: 4 changes artifact: 0c48f58fbb user: dkf
13:25 • Ticket [427697ffff]: 4 changes artifact: 0dadcfe267 user: mdejong
2001-09-20
16:34 • Ticket [427697ffff]: 4 changes artifact: 14c2ac86b1 user: dkf
2001-09-19
00:07 • Ticket [427697ffff]: 4 changes artifact: beedfec188 user: msofer
00:01 • Ticket [427697ffff]: 4 changes artifact: 75c3ab321e user: mdejong
2001-08-25
01:12 • Ticket [427697ffff]: 1 change artifact: ec15a6baa1 user: andreas_kupries
2001-05-28
22:21 • Ticket [427697ffff]: 4 changes artifact: fa185404a6 user: msofer
2001-05-27
19:34 • Ticket [427697ffff]: 4 changes artifact: 018f4887ae user: dkf
19:34 • Add attachment makedep.tcl to ticket [427697ffff] artifact: bc3a3aa614 user: dkf
12:34 • New ticket [427697ffff] Script for Making Dependency Information. artifact: 21bd3cd489 user: dkf

Script for Making Dependency Information

Open427697ffffffffffffffffffffffffffffffffffCreated 26 years agoUpdated 10 years ago
Descriptionplain2001-05-27 12:34:17
There has been some discussion recently online (in the Tcler's chat and elsewhere) about how 
Tcl's dependency information is seriously out-of-date. Normally this does not matter (most 
people just build everything from scratch) but given the number of people now developing in 
the core, it is becoming more important to have accurate dependency information in the core. 
However, it was discovered that makedepend (and gcc -M) do not always get this information 
right with Tcl's build structure. This Tcl script is intended to be a replacement for that that allows 
dependency information to be built relatively easily and accurately.
dkfplain2001-05-27 19:34:17
File Added - 6698: makedep.tcl
msoferplain2001-05-28 22:21:29
Logged In: YES 
user_id=148712

This is a 'solution' to bugs 427101 and 427105
andreas_kupries Ticket [427697ffff]: 1 change [History diff]2001-08-25 01:12:34
mdejongplain2001-09-19 00:01:06
Logged In: YES 
user_id=90858

I still don't understand how this script is to be
run. It is the old chicken and the egg problem.
How does one run a Tcl script before building Tcl?
Typically, the `make depend` target appends a
bunch of additional deps to the Makefile. But,
we can't expect people to have Tcl around before
building Tcl.
msoferplain2001-09-19 00:07:50
Logged In: YES 
user_id=148712

Well, the only ones who *really* need dependency information
are developers - ie, those that modify some files andwant to
rebuild partially. It is not important if you are building
from scratch (from a distro, or after 'make clean').

I think it is safe to assume that core developers do have a
working version of Tcl, so that this script indeed solves
the problem for them/us.
dkfplain2001-09-20 16:34:15
Logged In: YES 
user_id=79902

The intention is that this script is only used by people
developing the core; when you're building for installation,
you just make the lot and don't worry about when you need to
rebuild.  OTOH, if you make a far-reaching change in tclIO.h
to some structure definition, you'd *really* like to check
that everything that depends on it rebuilds correctly...
mdejongplain2003-03-27 13:25:46
Logged In: YES 
user_id=90858

I looked at this script and tried to adapt it to the
existing build
environment, but I was not able to get it working. The script
assumes that the src dir is the build dir. Unless it can be
rewritten
so that it works with run in a build dir that is not the
source dir,
I can't approve it.
dkfplain2003-03-27 18:01:40
Logged In: YES 
user_id=79902

I don't quite see what the problem is.  The script assumes
that it is being run in the directory where generated .o
files will be produced and where the makefile is.  It is
configured (by default) to search the current directory (and
its sibling directories compat and generic) for source
files, but the directories searched may be configured
through the use of the -directory flag.

For example (the '-directory -' option removes the built-in
search path) and trying to solve the sort of problem that
you described:
  tclsh makedep.tcl -directory - \
-directory $(SRCLOC)/compat \
-directory $(SRCLOC)/generic \
-directory $(SRCLOC)/unix

You can also control the name of the makefile that is
modified with the -makefile option.  The script does not
currently allow configuring of the file extensions, but it
shouldn't be hard to add that.
dkf Ticket [427697ffff]: 6 changes [History diff]2016-08-20 16:46:49
dkf Ticket [427697ffff]: 3 changes [History diff]2016-09-01 16:10:26
Log in (anonymous is fine) to add a comment.

Attachments: