install target in makefile.vc doesn't set the registry key
Closed / Wont Fix219352ffffffffffffffffffffffffffffffffffCreated 26 years agoUpdated 19 years ago
Descriptionplain2000-10-26 05:11:12
OriginalBugID: 5798 RFE
Version: 8.4a1
SubmitDate: '2000-06-02'
LastModified: '2000-10-25'
Severity: LOW
Status: UnAssn
Submitter: techsupp
OS: Windows 2000
FixedDate: '2000-10-25'
ClosedDate: '2000-10-25'
Name:
David Gravereaux
CVS:
updated 6/1/00
Comments:
It falls short with regedit.exe popping-up a dialog asking whether
you really want to add it or not. Not a good thing. I tried looking
for a switch that bypasses the dialog, but like most things Microsoft,
commandline args aren't documented and switches like /he, /a, and /l
appear to try to do something, but I haven't hit the sweet spot.
DesiredBehavior:
win/README says you need to manually set
HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\8.X\Root to the
install directory when building from the sources. Can't we
do this from the makefile?
Here's a first try.
Patch:
*** makefile.vc2000/05/03 00:15:111.52
--- makefile.vc2000/06/02 20:24:49
***************
*** 31,36 ****
--- 31,37 ----
ROOT= ..
INSTALLDIR= c:\Progra~1\Tcl
+ QINSTALLDIR= c:\\Progra~1\\Tcl
!IF "$(MACHINE)" == "IA64"
TOOLS32= c:\ia64sdk17
***************
*** 359,364 ****
--- 360,371 ----
@copy "$(TCLPIPEDLL)" "$(BIN_INSTALL_DIR)"
@echo installing $(TCLSTUBLIBNAME)
@copy "$(TCLSTUBLIB)" "$(LIB_INSTALL_DIR)"
+ regedit <<setTcl.reg
+ Windows Registry Editor Version 5.00
+
+ [HKEY_LOCAL_MACHINE\SOFTWARE\Scriptics\Tcl\$(DOTVERSION)]
+ "Root"="$(QINSTALLDIR)"
+ <<nokeep
install-libraries:
-@$(MKDIR) "$(LIB_INSTALL_DIR)"
PatchFiles:
win/makefile.vc
dkf Ticket [219352ffff]: 1 change
[History diff]2000-11-19 18:39:17
dkf Ticket [219352ffff]: 1 change
[History diff]2001-02-08 22:00:53
hobbsplain2001-08-07 07:33:51
Logged In: YES user_id=72656 The scriptics registry key is no longer referenced in a significant way.
davygrvyplain2004-01-03 16:34:08
Logged In: YES user_id=7549 I still like this idea, reopening, so I can ponder this.
davygrvyplain2004-04-10 05:07:45
Logged In: YES user_id=7549 Given an application that needs to run-time load the Tcl dll, there is no "best practices" for this, anywhere. It needs to be invented and adhered to. Existing applications such as WinCVS that do use the Scriptics reg key for the time when it was current, have no new fallback. We can assume the ActiveState regkey could replace it, but still there is no "best practices" for where any makefile or installing methods will write pertinent info in the windows registry for applications that need to know such things. The .tcl association is not a fully valid datum to use as the install targets for the makefiles don't set associations as part of the work of installing. Even if they did, this doesn't allow the future space of providing a catalog manager any more info than one shell that can run a .tcl file. Did I explain this problem well? What if my application wants the newest Tcl dll at or greater than 8.4.1, that has symbols and thread support. Or at the least, my applications would ask, "where is a tcl84g.dll located on this virgin system that I'm being run on for the first time?" Need a "best practices" document and code to ensure all methods of installations allow such data to be advertised in the registry.
dkfplain2004-04-13 15:55:41
Logged In: YES user_id=79902 Comments: What should the registry key be? Perhaps not AS (or Scriptics) but TclCoreTeam? After all, Tcl is officially looked after by them. I really do not like the Progra~1 part of those filenames. It is the sort of thing that I really don't think ought to be done as it is dependant on the Windows installation being "just so". Can't we use the proper long names instead? Indeed, can we derive the quoted form from the unquoted form?
davygrvyplain2004-04-15 00:40:09
Logged In: YES user_id=7549 I was thinking HKLM\Software\BSD\Tcl, but not partial to it. As for the data to put there, I don't know yet how to organize it. What I envision is an extended form of Tcl_PkgRequire that will do the LoadLibrary for me and prepare my Stubs table. All this code should get added to tclstubXX.lib. I envision it as Tcl_InitStubs but with search and load capabilities and I can give it a list of requirements, like "8.4 or greater, with symbols, but no thread support". To do this, I need to start with some data in the registry I can count on being there. Still pondering... Will experiment with some ideas shortly.
davygrvy Ticket [219352ffff]: 1 change
[History diff]2005-11-04 04:56:06
patthoytsplain2005-11-05 07:21:37
Logged In: YES user_id=202636 We don't need no steeeking registry key. If someone needs to find tcl they can search the PATH like everyone else.
mistachkinplain2005-11-05 09:35:58
Logged In: YES user_id=113501 I agree with Pat, no registry is required nor desirable. The registry is polluted enough. The PATH can be searched and/or the Tcl and Tk DLLs to load can be explicitly specified by the application somehow (i.e. TCLBridge used the Tcl_DLL/Tk_DLL environment variables).
davygrvyplain2005-11-06 05:43:39
Logged In: YES user_id=7549 What if tclXX.dll isn't in the path? Should I: 1) look at the association to *.tcl files (yes, found in the registry) to get the <path>\wish<version>.exe and piece back together an assumed <path>\tcl<version>.dll and try to load that? 2) assume 'g' and 't' suffixes for the Tcl dll if my application needs special build attributes such as threaded or symbols? 3) require user intervention to "fill in the blanks" for where a suitable tcll dll can't be found because the lack of such a global datum is considered to be the way things are? History lesson: Back when WinCVS used Tcl (july of 91 is when it switched to python) it used the info found in the registry writted by the Scriptics installer and it worked great. You'd install a new Tcl version and life was grand as it loaded the right one every time. Then ActiveState came out with their own builds, and changed their registry key at least two times, yet Jeff wouldn't have his installer write a backward compat key. WinCVS with Tcl looked awfully bad then, and is probably the prime reason for Alex's descision to switch to python. I passed out a silly script that fixed things, but it wasn't well liked due to it needing user intervension and most newbies with WinCVS could barly get their thumb outa their.... So the question I want answered from this is, what can I use across any build or install to answer the big "Where is Tcl?" question without ANY user intervention. At the moment there is no such reliable datum for this problem.
patthoytsplain2008-04-22 02:31:10
Logged In: YES
user_id=202636
Originator: NO
This hasn't happened and clearly isnt going to. http://wiki.tcl.tk/2074 has examples of finding the most current version. Roughly:
for (nMinor = 9; hTcl == NULL && nMinor > 2; nMinor--) {
wsprintf(szLibrary, _T("tcl8%d.dll"), nMinor);
hTcl = LoadLibrary(szLibrary);
}
searches the PATH for the most recent tcl8 library. This works fine in practice.
http://www.patthoyts.tk/tclkit/building-basekits.html shows another method that would probably be more useful for things like WinCVS by using a basekit/stardll to contain a known complete version of tcl.
Log in (anonymous is fine) to add a comment.