OSDN Git Service

Tk8.3 upgrade merge.
authorirox <irox>
Mon, 10 Sep 2001 01:01:01 +0000 (01:01 +0000)
committerirox <irox>
Mon, 10 Sep 2001 01:01:01 +0000 (01:01 +0000)
tk/ChangeLog
tk/configure
tk/unix/configure
tk/unix/configure.in
tk/win/Makefile.in
tk/win/configure

index 96ab464..98d0c56 100644 (file)
+2001-08-08  Mo DeJong  <mdejong@redhat.com>
+
+       * cygtcl.m4: Update from Tcl.
+       * unix/configure: Regen.
+       * win/configure: Regen.
+
+2001-08-06  Mo DeJong  <mdejong@redhat.com>
+
+       * cygtcl.m4: Update from Tcl.
+       * unix/configure: Regen.
+       * win/configure: Regen.
+
+2001-08-06  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/Makefile.in: Remove TCL_LIB_FLAG, replace TCL_LIB_SPEC
+       with TCL_BUILD_LIB_SPEC.        
+       * unix/configure: Regen.
+       * unix/configure.in: Avoid resetting TCL_LIB_SPEC and
+       TCL_STUB_LIB_SPEC since they are already set in tclConfig.sh. Subst
+       TCL_BUILD_STUB_LIB_SPEC and TCL_BUILD_LIB_SPEC into the Makefile.
+       * win/Makefile.in: Use TCL_LIB_SPEC and TCL_STUB_LIB_SPEC from
+       tclConfig.sh instead of creating them via a cygpath call. Use
+       TCL_STUB_LIB_SPEC in place of TCL_STUB_LIB_FILE.
+       * win/configure: Regen.
+       * win/configure.in: Fixup TK_STUB_LIB_SPEC, TK_BUILD_STUB_LIB_PATH,
+       TK_STUB_LIB_PATH, TK_LIB_FLAG, TK_BUILD_LIB_SPEC, TK_LIB_SPEC
+       and TK_LIB_FULL_PATH variables so they work like the unix version.
+
+2001-08-01  Mo DeJong  <mdejong@redhat.com>
+
+       * cygtcl.m4: Update from Tcl.
+       * unix/configure: Regen.
+       * unix/configure.in: Use TCL_TOOL_SHARED_LIB_LONGNAME
+       and TCL_TOOL_STATIC_LIB_LONGNAME to generate lib names.
+       * win/configure: Regen.
+       * win/configure.in: Use TCL_TOOL_SHARED_LIB_LONGNAME
+       and TCL_TOOL_STATIC_LIB_LONGNAME to generate lib names.
+
+2001-07-24  Mo DeJong  <mdejong@redhat.com>
+
+       * generic/default.h: Include tkWinDefault.h
+       when built with Cygwin or Mingw.
+
+2001-07-24  Mo DeJong  <mdejong@redhat.com>
+
+       * win/configure:
+       * win/tcl.m4: Update from Tcl.
+
+2001-07-12  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/Makefile.in:
+       * unix/configure: Regen.
+       * unix/configure.in:
+       * unix/tcl.m4:
+       * win/Makefile.in:
+       * win/configure: Regen.
+       * win/configure.in:
+       * win/tcl.m4:
+       Revert ill-conceived EXTRA_CFLAGS changes made on 2001-07-09.
+       The change ended up causing big problems with the
+       tclConfig.sh file since it exported EXTRA_CFLAGS and did
+       not deal with the debug/non-debug case.
+
+2001-07-11  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/configure: Regen.
+       * unix/tcl.m4: Update from Tcl.
+
+2001-07-11  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/Makefile.in: Add AR and STLIB_LD variables.
+       * unix/configure: Regen.
+       * unix/configure.in: Use STLIB_LD when defining MAKE_LIB
+       and MAKE_STUB_LIB. Subst STLIB_LD, RANLIB, and AR.
+       * unix/tcl.m4: Update from Tcl.
+       * win/configure: Regen.
+       * win/tcl.m4: Update from Tcl.
+
+2001-07-10  Mo DeJong  <mdejong@redhat.com>
+
+       * win/configure:
+       * win/tcl.m4 (SC_CONFIG_CFLAGS): Use STLIB_LD in MAKE_LIB instead
+       of AR which can be overridden on the make command line.
+
+2001-07-09  Mo DeJong  <mdejong@redhat.com>
+
+       * win/configure:
+       * win/tcl.m4 (SC_CONFIG_CFLAGS): Fix quoting of CYGPATH
+       argument to AC_CHECK_PROG.
+
+2001-07-09  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/Makefile.in: Add EXTRA_CFLAGS_DEBUG and EXTRA_CFLAGS_OPTIMIZE
+       variables. These two do not actually differ in the unix version
+       but are there to keep in sync with the Windows version.
+       * unix/configure: Regen.
+       * unix/configure.in: Don't subst EXTRA_CFLAGS. Subst EXTRA_CFLAGS_DEFAULT,
+       EXTRA_CFLAGS_DEBUG, and EXTRA_CFLAGS_OPTIMIZE.
+       * unix/tcl.m4: Update from Tcl.
+       * win/Makefile.in: Add EXTRA_CFLAGS_DEBUG and EXTRA_CFLAGS_OPTIMIZE
+       variables. This is needed so that the proper runtime lib gets linked
+       into VC++ produced .obj files when CFLAGS is reset on the command line.
+       * win/configure: Regen.
+       * win/configure.in: Don't subst EXTRA_CFLAGS. Subst EXTRA_CFLAGS_DEFAULT,
+       EXTRA_CFLAGS_DEBUG, and EXTRA_CFLAGS_OPTIMIZE.
+       * win/tcl.m4: Update from Tcl.
+
+2001-07-06  Mo DeJong  <mdejong@redhat.com>
+
+       * win/configure: Regen.
+       * win/tcl.m4: Update from Tcl.
+
+2001-07-06  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/configure: Regen.
+       * unix/configure.in: Replace call to SC_ENABLE_GCC with
+       AC_PROG_CC so that CC passed in from the caller is respected.
+       * unix/tcl.m4: Update from Tcl.
+       * win/configure: Regen.
+       * win/configure.in: Replace call to SC_ENABLE_GCC with
+       AC_PROG_CC so that CC passed in from the caller is respected.
+       * win/tcl.m4: Update from Tcl.
+
+2001-07-06  Mo DeJong  <mdejong@redhat.com>
+
+       * win/Makefile.in: Subst DEPARG directly instead
+        of relying on a variable. This will make Cygwin
+        builds faster since an extra exec will be avoided.
+       * win/configure: Regen.
+       * win/configure.in: Subst DEPARG.
+       * win/tcl.m4: Update from Tcl.
+
+2001-06-26  Mo DeJong  <mdejong@redhat.com>
+
+       * cygtcl.m4: Update from Tcl.
+       * unix/configure: Regen.
+       * win/Makefile.in: Remove PATHTYPE variable.
+       Use : in VPATH instead of VPSEP.
+       * win/configure: Regen.
+       * win/configure.in: Don't subst PATHTYPE or VPSEP.
+       * win/tcl.m4: Update from Tcl.
+
+2001-06-25  Mo DeJong  <mdejong@redhat.com>
+
+       * win/configure: Regen.
+       * win/tcl.m4: Update from Tcl.
+
+2001-06-22  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/Makefile.in: Set CFLAGS to @CFLAGS@ and @CFLAGS_DEFAULT@.
+       Set LDFLAGS to @LDFLAGS@ and @LDFLAGS_DEFAULT@. Add LDFLAGS_DEBUG
+       and LDFLAGS_OPTIMIZE to match the way CFLAGS_DEFAULT works. Use
+       new LDFLAGS variable in the Makefile instead of @LDFLAGS@.
+       * unix/configure: Regen.
+       * unix/configure.in: Don't set CFLAGS to CFLAGS_DEFAULT, instead
+       subst CFLAGS_DEFAULT into the Makefile. Add AC_SUBST for CFLAGS_DEBUG,
+       CFLAGS_OPTIMIZE, LDFLAGS_DEFAULT, LDFLAGS_DEBUG, and LDFLAGS_OPTIMIZE.
+       Remove unused LD_FLAGS subst.
+       * unix/tcl.m4: Update from Tcl.
+       * win/Makefile.in: Set CFLAGS to @CFLAGS@ and @CFLAGS_DEFAULT@.
+       Set LDFLAGS to @LDFLAGS@ and @LDFLAGS_DEFAULT@.
+       * win/configure: Regen.
+       * win/configure.in: Don't set CFLAGS or LDFLAGS, instead subst
+       CFLAGS_DEFAULT and LDFLAGS_DEFAULT into the Makefile.
+       * win/tcl.m4: Update from Tcl.
+
+2001-06-22  Mo DeJong  <mdejong@redhat.com>
+
+       * configure:
+       * configure.in: When a windows32 host is detected
+       configure in the win subdirectory.
+       * cygtcl.m4: Update from Tcl.
+       * unix/configure: Regen.
+       * win/configure: Regen.
+
+2001-06-22  Mo DeJong  <mdejong@redhat.com>
+
+       * win/configure:
+       * win/tcl.m4: Update from Tcl.
+
+2001-06-08  Mo DeJong  <mdejong@redhat.com>
+
+       * win/Makefile.in: Set TK_LIBRARY to
+       $INSTALL/share/tk8.3 instead of
+       $INSTALL/lib/tk8.3.
+
+2001-06-06  Mo DeJong  <mdejong@redhat.com>
+
+       * win/configure:
+       * win/configure.in: Handle the --prefix option correctly
+       it should default to /usr/local like the unix version.
+
+2001-06-05  Mo DeJong  <mdejong@redhat.com>
+
+       * cygtcl.m4:
+       * unix/configure: Update from Tcl.
+
+2001-06-01  Mo DeJong  <mdejong@redhat.com>
+
+       * cygtcl.m4:
+       * unix/configure:
+       * win/configure:
+       * win/tcl.m4: Update from Tcl.
+
+2001-05-30  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/configure: Regen.
+       * unix/tcl.m4:
+       Update from Tcl version.
+
+2001-05-30  Mo DeJong  <mdejong@redhat.com>
+
+       * cygtcl.m4:
+       * unix/configure: Regen.
+       * unix/tcl.m4:
+       Update from Tcl versions.
+
+2001-05-26  Mo DeJong  <mdejong@redhat.com>
+
+       * cygtcl.m4:
+       * unix/aclocal.m4:
+       * unix/configure: Regen.
+       * unix/tcl.m4:
+       * win/aclocal.m4:
+       * win/configure: Regen.
+       * win/tcl.m4:
+       Update from Tcl versions.
+
+2001-05-09  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/Makefile.in: Use TK_STUB_LIB_FILE instead
+       of STUB_LIB_FILE subst.
+       * unix/configure: Regen.
+       * unix/configure.in: Use new path macros.
+       * unix/tcl.m4: Update from Tcl.
+       * win/configure: Regen.
+       * win/configure.in: Use new path macros.
+       * win/tcl.m4: Update from Tcl.
+
+2001-05-08  Ian Roxborough  <irox@redhat.com>
+
+       * unix/configure.in: Cygnus local change
+       to build gdbtk: Set TK_BUILD_INCLUDES to
+       correct path.
+       * unix/configure: Regenerated.
+       
+2001-04-09  Mo DeJong  <mdejong@redhat.com>
+
+       * unix/aclocal.m4: Pull in tcl.m4.
+       * unix/configure: Regen.
+       * unix/tcl.m4: Add from tcl/unix.
+       * win/Makefile.in: Append version to tclsh
+       in the win subdirectory.
+       * win/configure: Regen.
+       * win/configure.in: The TK_BUILD_LIB_SPEC and
+       TK_BUILD_LIB_SPEC variables need to use the
+       lib file and not the dll file, since it is
+       not possible to link to a dll with VC++.
+       Use new TCL_TOOL_PATH macro to correctly
+       set the XINCLUDES variable.
+       * win/tcl.m4: Update from tcl/win so we can use
+       the TCL_TOOL_PATH macro.
+
+2001-04-05  Mo DeJong  <mdejong@redhat.com>
+
+       * win/Makefile.in: Don't depend on
+       TCLSH_PROG variable from configure.
+       *  win/configure: Regen.
+       * win/configure.in: Don't call
+       SC_PROG_TCLSH, it was removed from
+       Tcl. This macro required that Tcl
+       be built before Tk could be configured.
+       * win/tcl.m4: Update from Tcl version.
+
 2000-12-08  Syd Polk  <spolk@redhat.com>
 
-       * unix/configure.in: Change hppa*w to hppa*64.
-       * unix/configure: Regenerate.
+       * unix/configure.in: Change hppa*w to hppa*64.
+       * unix/configure: Regenerate.
+
+2000-08-08  Jeff Hobbs  <hobbs@ajubasolutions.com>
+
+       8.3.2 RELEASE finalized
+
+       * changes: updated for release notes version of ChangeLog
+
+2000-08-05  Jeff Hobbs  <hobbs@ajubasolutions.com>
+
+       * win/Makefile.in (cat32.${OBJEXT}): corrected where to find cat.c
+       given the change in default def'n of TCL_SRC_DIR.
+
+       * win/tcl.m4: changed references from 8.4 to 8.3 (leftover from a
+       backported file).
+
+       * library/safetk.tcl: rationalized the setting of tk_library when
+       initialized Tk in a safe interpreter.
+
+2000-08-04  Jeff Hobbs  <hobbs@ajubasolutions.com>
+
+       * BACKPORTED FROM 8.4 (HEAD) BRANCH:
+
+       * tests/button.test:
+       * generic/tkButton.c: Added -activeforeground, -activebackground
+       for labels, for the -state option.
+
+       * doc/label.n: Added -disabledforeground to list of options [Bug:
+       6053].
+
+       * tests/focus.test (focusSetupAlt): removed wm withdraw from proc
+       as it would cause a hang for tkwait visibility
+
+       * tests/menu.test:
+       * generic/tk3d.c:
+       * generic/tkColor.c:
+       * generic/tkCursor.c: corrected handling of 3DBorder, Cursor and
+       Color objects on multiple screens. [Bug: 5454]
+
+       * generic/tkCursor.c: Added initialization for nextPtr field of
+       TkCursor, patch from Nijtmans/Howlett.
+
+       * canvas.test: added test for 5783.
+       * generic/tkCanvPoly.c (DisplayPolygon): added checks for the
+       polygon fillGC not being empty to prevent segfault. [Bug: 5783]
+
+       * generic/tkImgGIF.c: Applied patch from Jan Nijtmans to fix a
+       problem with the GIF writing code [Bug: 5823].
+       * generic/tkImgGIF.c: Changed defines for GIF87a/GIF89a to be
+       static char arrays with integer initialization, to address EBCIDIC
+       vs. ASCII encoding issues and to handle compilers that don't deal
+       with "\xAB" syntax for specifying hex values in strings.
+
+       * generic/tkMenu.c (DeleteMenuCloneEntries): Applied fix from
+       [Bug: 5275], which corrected a segfault-causing indexing problem
+       when deleting entries from torn-off menus.
+
+       * generic/tkPlace.c (Tk_PlaceCmd): reworked place master/slave
+       table init'n to prevent seg fault when using place on multiple
+       displays.
+
+       * tests/text.test: Added tests for -regexp -nocase searches with
+       backslash character classes.
+       * tests/text.test: Added tests for searching when text is elided.
+       * generic/tkText.c (TextSearchCmd): Text search did not work
+       properly when -regexp and -nocase were used, in combination with
+       backslash character classes represented by capital letters (ie,
+       \W, \M); altered implementation of -regexp -nocase searches to use
+       new regexp interfaces to fix this problem.  [Bug: 5988].
+       * generic/tkText.c (TextSearchCmd): Text search was not returning
+       the correct index when the search covered (but did not search)
+       elided characters; corrected this by adjusting the match index by
+       the number of elided characters preceeding the start of the match,
+       just as is done with embedded windows, etc. [Bug: 5470].
+       * generic/tkText.c (TextSearchCmd): Added a test for a NULL
+       segment pointer when doing backwards searches for "" on an empty
+       text widget. [Bug: 6007].
+
+       * library/focus.tcl: fixed calling of takeFocus proc [Bug: 5372]
+
+       * win/tkWinMenu.c (ReconfigureWindowsMenu): Added MF_GRAYED bit
+       for disabled menu entries, to ensure that those which are drawn by
+       the system are shown grayed (such as entries on menubars) [Bug: 4372].
+       * win/tkWinMenu.c (ReconfigureWindowsMenu): Added code to add the
+       MF_SEPARATOR bit for SEPARATOR_ENTRY menu items.  This causes
+       separator entries on the system menu to be drawn correctly [Bug: 5451].
+       * win/tkWinMenu.c (GetMenuSeparatorGeometry): Tweaked height
+       requested for separator bars to be (linespace - (2*descent))
+       instead of just (linespace); this makes the separator occupy a
+       more correct amount of vertical space. [Bug: 5303].
+
+2000-07-20  Brent Welch <welch@ajubasolutions.com>
+
+       * win/tkConfig.sh.in:
+       Made corresponding changes to match gcc for windows mods
+       to the rest of the files.
+
+2000-07-28  Mo DeJong  <mdejong@redhat.com>
+
+       * win/Makefile.in:
+       * win/aclocal.m4:
+       * win/configure.in:
+       * win/tcl.m4: Back port of gcc for windows
+       build system from 8.4.
+
+2000-07-26  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * unix/configure.in (TK_PATCH_LEVEL): updated to 8.3.2
+       * unix/tk.spec:
+       * win/configure.in: 
+       * generic/tk.h:
+       * README:
+
+2000-07-22  Brent Welch <welch@ajubasolutions.com>
+       * win/Makefile.in, win/configure.in, win/rc/tk.rc, win/rc/tk_base.rc
+       Trying to generalize .rc files so they work with both DLL's and
+       static shell builds.
+
+2000-07-10  Brent Welch <welch@ajubasolutions.com>
+
+       * win/{Makefile.in,configure.in,tkConfig.sh.in}: 
+       Cleanup of defines in tkConfig.sh
+
+Tue Jun  6 22:09:02 2000  Christopher Faylor <cgf@cygnus.com>
+
+       * win/Makefile.in: Set up and use autoconf variables throughout to
+       allow overriding variables from the make command line.
+
+2000-05-15  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/tkWinWm.c: changed wm deiconify from using idle
+       callback to calling restack and focus code immediately.
+
+2000-04-26  Jeff Hobbs  <hobbs@scriptics.com>
+
+       8.3.1 RELEASE
+
+       * README:
+       * mac/README:
+       * unix/README:
+       * unix/tk.spec:
+       * win/README: Updating URLs to reference dev.scriptics.com
+
+2000-04-25  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * unix/Makefile.in:
+       * win/Makefile.in: makefile cleanup
+
+2000-04-25  Eric Melski  <ericm@scriptics.com>
+
+       * generic/tkMain.c: Fixed function header comment for Tk_MainEx.
+
+       * unix/mkLinks: 
+       * doc/GetScroll.3: Added information about Tk_GetScrollInfoObj
+       [Bug: 1866].
+
+2000-04-24  Eric Melski  <ericm@scriptics.com>
+
+       * unix/mkLinks: 
+       * doc/Grab.3: Man page for Tk_Grab and Tk_Ungrab [Bug: 1868, 1889]
+
+       * unix/mkLinks: 
+       * doc/MainWin.3: Added entry for Tk_GetNumMainWindows [Bug: 1865].
+
+       * unix/mkLinks: 
+       * doc/GetHINSTANCE.3: Man page for Tk_GetHINSTANCE [Bug: 1862].
+
+2000-04-24  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkImage.c (Tk_PostscriptImage): added check to create
+       necessary prolog for photos
+       * generic/tkCanvPs.c: added Tk_PostscriptPhoto that outputs PS for
+       photo images
+       * generic/tkImgPhoto.c: new func ImgPhotoPostscript and added that
+       in as ps proc in tkPhotoImageType.
+       * generic/tkStubInit.c:
+       * generic/tkDecls.h:
+       * generic/tk.decls: added Tk_PostscriptPhoto
+
+       * generic/tkConfig.c (DoObjConfig): removed direct setting of
+       interp->result.
+
+       * mac/tkMacWm.c (Tk_WmCmd): initialized gotToplevel in
+       colormapwindows case (bug found by Reasoning, Inc's automated code
+       testing).
+
+2000-04-24  Eric Melski  <ericm@scriptics.com>
+
+       * unix/mkLinks: 
+       * doc/GetHWND.3: Man page for Tk_GetHWND [Bug: 1863].
+
+       * unix/mkLinks: 
+       * doc/HWNDToWindow.3: Man page for Tk_HWNDToWindow [Bug: 1869].
+
+       * unix/mkLinks: 
+       * doc/AddOption.3: Man page for Tk_AddOption [Bug: 1854]
+
+2000-04-22  Jim Ingham <jingham@cygnus.com>
+
+       * mac/tkMacDialog.c (Tk_MacGetOpenFile): Add empty bodies for the 
+       "-initialfile" and "-defaultextension" options.
+
+       * mac/tkMacDialog.c (NavServicesGetFile): Only cons the result up
+       into a list if multiple is true.
+
+       * mac/tkMacMenus.c (SourceDialog): Use the "tk_getOpenFile"
+       instead of hand-coding the dialog with StandardGetFile.  This way
+       we get the Navigation dialogs for free.
+
+       * doc/getOpenFile.n: Document the -multiple and -message flags
+       which are only implemented on the Mac.  Also note that the -title
+       works on the Mac with Nav Services installed.
+
+2000-04-19  Eric Melski  <ericm@scriptics.com>
+
+       * doc/WinViewable.3: 
+       * unix/mkLinks: Removed docs for Tk_IsViewable.
+
+       * win/tkWinDialog.c: Removed calls to Tk_IsViewable.
+
+       * generic/tkUtil.c: 
+       * generic/tkStubInit.c: 
+       * generic/tkDecls.h: 
+       * generic/tkCmds.c: 
+       * generic/tk.decls: Removed Tk_IsViewable function (it was not
+       actually needed).
+
+2000-04-19  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/aclocal.m4: made SC_PROG_TCLSH search specifically for
+       tclsh*.exe type files to find an executable.
+
+       * win/Makefile.in: fixed up cleanup, winhelp, cat32 targets
+
+       * library/console.tcl: made console use systemfixed font on Win
+
+       * generic/tkEntry.c: removed unnecessary ENTRY_VALIDATE #define
+
+2000-04-19  Eric Melski  <ericm@scriptics.com>
+
+       * generic/tkRectOval.c (ConfigureRectOval): Added checks for valid
+       outline settings before creating of outline GC; this means that it
+       is really possible now to have an oval or rectangle with no
+       outline.  [Bug: 5029].
+
+2000-04-19  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * library/choosedir.tcl (::tk::dialog::file::chooseDir::Config):
+       * library/tkfbox.tcl (::tk::dialog::file::Config): removed the
+       extraneous glob on -initialdir after file isdir already returned 1
+       and moved cd trick into this case as the else already uses [pwd].
+       [Bug: 5181]
+
+       * win/winMain.c: moved extern call out of WinMain func
+
+       * README:
+       * generic/tk.h:
+       * unix/configure.in:
+       * unix/tk.spec:
+       * win/configure.in: bumped to version 8.3.1
+
+       * library/msgbox.tcl (tkMessageBox): changed to use grid in some
+       places, realign icon to anchor nw.
+
+       * mac/tkMacScale.c: reverted tkMacScale.c to 1.5 equivalent (it
+       was accidentally bumped forward).
+
+2000-04-18  Eric Melski  <ericm@scriptics.com>
+
+       * win/tkWinPointer.c: Changed Mod2Mask in TkWinGetModifierState to
+       ALT_MASK, to fix some event problems [Bugs: 1160, 5088].
+
+       * win/tkWinX.c: Changed Mod2Mask in GetState to ALT_MASK, to fix
+       some event problems [Bugs: 1160, 5088].
+
+       * generic/tkInt.h: Moved definition of ALT_MASK and META_MASK here
+       so that it would be accessible from other modules than tkBind.c.
+
+       * generic/tkBind.c: Added code in BindEvent to check for ALT_MASK
+       and META_MASK in the event state field, as this field may not be
+       set up with the correct display modifier mask bits if the XEvent
+       structure was created by [event generate] or by the Windows X
+       emulation. [Bugs: 1160, 5088].
+
+2000-04-18  Scott Redman  <redman@HILO>
+
+       * win/tk.rc:
+       * win/wish.rc:
+       * win/wish.ico:  Modified copyright dates in Windows resource
+       files.  Updated the icon for wish.exe.
+
+2000-04-17  Eric Melski  <ericm@scriptics.com>
+
+       * win/tkWinDialog.c: Added checks for visibility of parent window
+       before creating MessageBox and ChooseColor dialogs; this prevents
+       the application from locking when the parent is withdrawn and the
+       message box is created.  In these cases, the window will be
+       created without a parent.
+
+       * unix/mkLinks: Added WinViewable.3.
+
+       * tests/msgbox.test: Added tests for patch from [Bug: 4997].
+
+       * library/msgbox.tcl: 
+       * library/dialog.tcl: Applied patch from [Bug: 4997]; detaches
+       dialog window from parent if parent is not viewable.
+
+       * library/bgerror.tcl: Removed workaround from [Bug: 4370]; this
+       is superceeded by patches to dialog.tcl.
+
+       * generic/tkCmds.c: Changed WinfoObjCmd to use Tk_IsViewable
+       function to determine visibility of windows instead of inlining
+       the code.
+
+       * generic/tkStubInit.c: 
+       * generic/tkDecls.h: 
+       * generic/tk.decls: Added Tk_IsViewable declaration.
+
+2000-04-17  Eric Melski  <ericm@scriptics.com>
+
+       * library/text.tcl: Tweaked double-/triple-click selection;
+       previously, anchor and insert marks were placed in unexpected
+       locations following a double or triple click.  Now they are placed
+       logically.  Also tweaked the extension of selection via
+       shift-double-clicks so that it no longer selects the contiguous
+       whitespace on the side of the selection opposite the
+       double-click. [RFE: 4253].
+
+       * doc/menu.n: Added note regarding rendering of
+       checkbuttons/radiobuttons in menubars on different platforms --
+       some systems do not draw indicators for check/radiobuttons in
+       menubars.
+
+       * library/menu.tcl: Corrected behavior of
+       checkbuttons/commands/radiobuttons in menubars [Bug: 630].
+
+       * tests/grid.test: Added test for [grid propagate . 0] to not toggle.
+       
+       * generic/tkGrid.c: Fixed bogus logic in [grid propagate] that
+       caused [grid propagate . 0] to act as a toggle instead of an
+       absolute set. [Bug: 2286].
+
+2000-04-16  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/tkWinColor.c (FindSystemColor): correct calculation of
+       colors when shifting value. [Bug: 4919]
+
+2000-04-16  Jim Ingham   <jingham@cygnus.com>
+
+       * mac/tkMacPort.h: protect against strncasecmp already defined -
+       it is in the Pro5 version of MSL.
+
+       * mac/tkMacWindowMgr.c (GenerateKeyEvent): Check for a null tkWin.
+       If the hidden window we use for double-buffering controls manages
+       to percolate to the top (should never happen, but...) this will
+       keep us from crashing.
+
+       * mac/tkMacButton.c (InitSampleControls): Hide the
+       double-buffering window BEHIND the first "." window you can find.
+       This will keep it from ever being the front window, and thus a
+       black hole for events.  * mac/tkMacButton.c (ButtonEventProc):
+       Disable the controls when the window is in the background.  This
+       is required by the MacOS HIG. This doesn't always get called when
+       it should, it still needs more work.
+
+       * mac/tkMacDialog.c: Pretty substantial rewrite to include
+       Navigation Services support for systems which have it.
+
+2000-04-14  Eric Melski  <ericm@scriptics.com>
+
+       * win/tkWinKey.c: Added check for ASCII delete character in
+       KeycodeToKeysym, to fix [Bug: 5090].  See comment in code for more
+       information.
+
+       * generic/ks_names.h: Added Scroll_Lock and Sys_Req definitions.
+
+       * win/tkWinKey.c: Changed implementation of KeycodeToKeysym,
+       et. al., to use a keycode table for lookups; this will result in
+       faster keycode -> keysym translations for non-ASCII keys like
+       Control, Alt, etc.
+
+2000-04-14  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/tkWinWm.c (WmProc): added check in WM_MOUSEACTIVATE so we
+       correctly activate native menus when clicking in when we didn't
+       have focus [Bug: 2272]
+
+       * generic/tkCanvas.c (CanvasEventProc:2451): corrected cast
+
+       * generic/tkEntry.c (Tk_EntryObjCmd): adjusted finishing error
+       cases and changed TK_CONFIG_NULL_OK to TK_OPTION_NULL_OK
+
+       * tests/scale.test:
+       * generic/tkScale.c:
+       * generic/tkScale.h:
+       * unix/tkUnixScale.c:
+       * mac/tkMacScale.c: moved (PixelToValue|ValueToPixel|SetScaleValue)
+       to tkScale.c.  Caused an associated variable to be immediately set
+       [Bug: 4833]
+
+       * library/scale.tcl (tkScaleActivate): reduced number of scale
+       redisplays by checking current value of state before setting it
+       again.  [Bug: 4191]
+
+       * tests/winDialog.test: tk_chooseDirectory seems to get a noop
+       from GetOpenFileName in the static build, hanging some tests.
+       The tests were fixed to timeout (noop cause unknown).
+
+       * unix/aclocal.m4 (SC_ENABLE_THREADS): enhanced the detection of
+       pthread_mutex_init [Bug: 4359] and (SC_CONFIG_CFLAGS) added
+       --enable-64bit-vis switch for Sparc VIS compilation [Bug: 4995]
+
+2000-04-13  Eric Melski  <ericm@scriptics.com>
+
+       * win/tkWinKey.c: Added smarts to check whether the left or right
+       Control, Shift, or Alt key was pressed.  [Bug: 870].
+
+       * win/tkWinMenu.c: Corrected code that created separator items on
+       menus; originally, it requested that the system be responsible for
+       drawing those items, so it would ignore configuration items like
+       the widget background.  Now, we draw the separators ourselves (as
+       we do with every other kind of menu item already). [Bug: 1166].
+
+       * win/tkWin3d.c: 
+       * unix/tkUnix3d.c: Applied patch from [RFE: 2501]: adds more
+       sophisticated smarts to TkpGetShadows, so that the highlight of a
+       very bright color is actually distinguishable from the color, and
+       the shadow of a very dark color is similarly distinguishable from
+       the color.
+
+       * generic/tkCanvas.c: Applied patch from [Bug: 4202]; adds a check
+       for NULL tkwin in Tk_CanvasEventuallyRedraw.
+
+2000-04-12  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * test/winClipboard.test:
+       * win/tkWinInt.h:
+       * win/tkWinClipboard.c (UpdateClipboard):
+       * win/tkWinX.c (GenerateXEvent): added updatingClipboard tsd and
+       TkWinUpdatingClipboard accessor function to allow us to flag
+       ourselves when we are the ones updating the clipboard.  This
+       corrected inability to create our own clipboard types within a Tk
+       application.  [Bug: 2338 4318]
+       * win/tkWinTest.c (TestclipboardCmd): improved TestclipboardCmd
+       with better error handling and obj'ification
+
+2000-04-11  Eric Melski  <ericm@scriptics.com>
+
+       * msgcat.n: Added docs for new behavior from patch in [Bug: 4158].
+
+       * msgcat.test: Added tests for new behavior from patch in [Bug:
+       4158].
+       
+       * msgcat.tcl: Applied patch from [Bug: 4158], which enables
+       msgcat::mc to search the entire namespace ancestry chain for
+       message translations (ie, first it checks the current namespace,
+       then the parent, then the parent's parent, etc).  Also allows the
+       specification of additional args for msgcat::mc; if extra args are
+       given, the [format] command is used to substitute the additional
+       args in the translated message.
+
+       * library/bgerror.tcl: Moved check for withdrawn state after check
+       for tkerror; this was causing problems when tkerror was used.
+
+2000-04-10  Eric Melski  <ericm@scriptics.com>
+
+       * library/bgerror.tcl: Added check for withdrawn state of . and
+       unsetting of transient bit for .bgerrorDialog if . is not
+       viewable; this protects against the application hanging on systems
+       like Windows, where transient windows are withdrawn with their
+       parents. [Bug: 4370].
+
+       * tests/event.test: Added test for [event generate $widget
+       <Alt-z>] [Bug: 4611].
+
+       * tests/choosedir.test: Changed "namespace import ::tcltest" to
+       "namespace import -force ::tcltest".
+
+       * win/tkWinKey.c: 
+       * unix/tkUnixKey.c: 
+       * mac/tkMacKeyboard.c: Changed InitKeymapInfo to
+       TkpInitKeymapInfo. [Bug: 4611].
+
+       * generic/tkStubInit.c: 
+       * generic/tkIntDecls.h: Re-gen'd from tkInt.decls.
+
+       * generic/tkInt.decls: Added TkpInitKeymapInfo to list of function
+       decls.
+
+       * generic/tkBind.c (HandleEventGenerate): Added code to initialize
+       keymap info if necessary, and to correctly set modifier bits in
+       XEvent structure create to handle [event generate] calls.
+       Previously, the alt/meta bits were not set correctly, so [event
+       generate $widget <Alt-z>] would always fail. [Bug: 4611]
+
+2000-04-07  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkGrid.c (InitMasterData): fixed uninit'd data in
+       GridMaster struct [Bug: 4387]
+
+       * library/safetk.tcl (disallowTk): made disallowTk work in the
+       simple case.
+
+       * library/comdlg.tcl (tkFocusGroup_In): fixed key navigation
+       problems in dialogs under CDE [Bug: 2960]
+
+       * tests/winDialog.test: removed knownBug constraint from 5.16
+
+       * win/tkWinFont.c (GetScreenFont): corrected adjustment against
+       LC_FACESIZE limitation for NT [Bug: 4931]
+
+       * win/makefile.vc (TKTEST_OBJS):
+       * win/Makefile.in (TKTEST_OBJS): moved tkWinTest.c from normal
+       objs to TKTEST_OBJS where it belonged.
+
+2000-04-03  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkTest.c: fixed incorrect platform inclusion for
+       TkplatformtestInit (it would never get called).
+
+       * unix/Makefile.in (MAN_INSTALL_DIR): patch to accept --mandir
+       correctly [Bug: 4085]
+
+       * library/clrpick.tcl (tkColorDialog_Config): error now thrown
+       when -initialcolor "" specified. [Bug: 4198]
+
+2000-03-31  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * doc/DrawFocHlt.3: doc name correction
+
+       * generic/tkEntry.c: set TK_OPTION_NULL_OK bit on -invcmd option
+       and removed #ifdef ENTRY_VALIDATE expressions
+
+       * library/menu.tcl (tkMenuInvoke): corrected naming of tearoffs
+       [Bug: 4506]
+
+       * library/tkfbox.tcl (tkIconList_Goto): caused browsecmd to be
+       called in tkIconList_Select.  This causes the entry to be set
+       properly when using the type-in-name-in-listbox bindings.
+
+       * win/tkWinDialog.c: added unicode-aware open/save file dialogs
+
+       * win/tkWinFont.c (TkpFontPkgInit): move private ref to platformId
+       to TkWinGetPlatformId
+
+       * win/tkWinMenu.c (SetDefaults): moved private use of versionInfo
+       to TkWinGetPlatformId and removed all code for
+       (versionInfo.dwMajorVersion < 4) (== Win32s)
+
+       * win/tkWinX.c:
+       * win/tkWin32Dll.c: moved TkWinGetPlatformId to tkWinX.c
+       * win/tkWinInit.c: added TkWinXInit to TkpInit to ensure that its
+       called for static Windows shells. [Bug: 3647]
+
+       * win/tkWinInt.h:
+       * win/tkWinX.c:
+       * win/tkWinDraw.c (SetUpGraphicsPort): 
+       * win/tkWinScrlbr.c (UpdateScrollbar): removed use of tkpIsWin32s
+
+       * win/tkWinInt.h (TkWinDCState struct): added bkmode value
+       * win/tkWinDraw.c (TkWinGetDrawableDC, et al): added support for
+       properly transparent dashed lines on Windows. [Bug: 4617]
+
+2000-03-30  Eric Melski  <ericm@scriptics.com>
+
+       * generic/tkImgGIF.c: Fixed some ANSI specific bits to avoid
+       compile problems with non-ANSI compilers (ie, replace const with
+       CONST, etc).  [Bug: 4223].
+
+       * unix/configure.in: Applied patch from [Bug: 4237]; ensures that
+       srcdir is fully qualified.
+
+       * unix/Makefile.in: Applied patch from [Bug: 4237]; if tcltest was
+       not compiled, make test/tktest failed.  Now it has a rule to build
+       tcltest if it has not been built.
+
+2000-03-28  Eric Melski  <ericm@scriptics.com>
+
+       * library/tkfbox.tcl: Moved an overlooked tkFDialog* function in
+       ::tk::dialog::file namespace.
+
+       * tests/unixWm.test: Added tests for memory leak conditions in
+       tkUnixWm.c.
+
+       * tests/canvas.test: Added test for bad configuration options on
+       empty and non-empty canvas.
+
+       * generic/tkCanvas.c: Removed bad code in CANV_CONFIGURE block of
+       CanvasWidgetCmd; this was causing non-empty canvases to improperly
+       handle bad configuration options [Bug: 4456].
+
+2000-03-27  Eric Melski  <ericm@scriptics.com>
+
+       * unix/tkUnixWm.c: Applied patch from [Bug: 4405]; fixes memory
+       leak in Unix wm command.
+
+2000-03-24  Eric Melski  <ericm@scriptics.com>
+
+       * tests/filebox.test: 
+       * tests/choosedir.test: Updated tests.
+
+       * library/xmfbox.tcl: Updated to stash data array in
+       ::tk::dialog::file namespace instead of in global namespace.
+
+       * library/tkfbox.tcl: Extended some functions to support creation
+       of a choosedir dialog, to allow greater code reuse between the two
+       dialogs.  Moved tkFDialog* functions into a namespace
+       (::tk::dialog::file).  Because these are private Tk functions (and
+       should thus not be used directly by users), this should not impact
+       anybody (the tk_getOpenFile and tk_getSaveFile commands still
+       exist at the global scope).
+
+       * library/tk.tcl: 
+       * library/tclIndex: Updated function names for tkFDialog*
+       functions and choosedir functions.
+
+       * library/choosedir.tcl: New and improved implementation of
+       tk_chooseDirectory dialog.  Based on tk_getOpenFile dialog.
+
+2000-03-23  Eric Melski  <ericm@scriptics.com>
+
+       * generic/tkWindow.c: 
+       * generic/tkInt.h: Updated Tcl_OptionCmd -> Tcl_OptionObjCmd
+
+       * generic/tkOption.c: Tcl_Obj'ectified the "option" command.
+
+2000-03-22  Eric Melski  <ericm@scriptics.com>
+
+       * library/listbox.tcl (tkListboxCancel): Added a check for empty
+       string value for tkPriv(listboxPrev).  Without this check, it's
+       possible to get a stack trace under certain conditions. [Bug: 4373].
+
+2000-03-15  Sven Delmas  <sven@scriptics.com>
+
+       * win/tkWinDialog.c: Changed the behavior for the
+       tk_chooseDirectory dialog under Windows. Instead of trying to
+       return the currently selected listbox entry (which didn't work in
+       case the user selected the initial directory anyway), we now
+       return the value shown in the entry. This seems to be in
+       accordance with the expected behavior for this dialog.
+
+2000-03-14  Eric Melski  <ericm@scriptics.com>
+
+       * tests/choosedir.test: Marked test 3.1 and 3.2 as bad until the
+       issue with those tests on IRIX can be determined.
+
+2000-03-10  Eric Melski  <ericm@scriptics.com>
+
+       * library/menu.tcl: Applied patch from [Bug: 4155]; protects
+       against grabs on non-viewable windows.
+
+2000-03-08  Eric Melski  <ericm@scriptics.com>
+
+       * tests/choosedir.test: Modified test 3.1 (-mustexist works) to be
+       more careful about cleaning up its potentially troublesome after 
+       events.
+
+2000-03-07  Eric Melski  <ericm@scriptics.com>
+
+       * tests/button.test: 
+       * generic/tkButton.c: Added -disabledforeground/-state to labels.
+
+2000-03-07  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * tests/entry.test:
+       * generic/tkEntry.c (EntrySetValue): malloc the value when
+       validating because validation could cause the pointer to become
+       invalid.  Also fixed configure to not trigger focus-based
+       validation.  Improved use of Tcl_WrongNumArgs. [Bug: 4320]
+
+2000-03-06  Eric Melski  <ericm@scriptics.com>
+
+       * library/menu.tcl: Added a check in tkMenuFirstEntry that changes
+       menu behavior to only auto-post an immediate child cascade if we
+       are currently on a menubar menu.  This prevents massive
+       auto-cascading in cases where the first entry of the cascade is
+       itself a cascade, and the first entry of that cascade is a
+       cascade, and the first entry of that cascade is a cascade
+       ... [Bug: 676].
+
+       * generic/tkOldConfig.c: Added check for NULL tkwin value in
+       Tk_ConfigureWidget [Bug: 4079]
+
+       * generic/tkWindow.c: Added check for NULL tkwin value in
+       Tk_NameToWindow [Bug: 4079]
+
+2000-03-02  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * tests/color.test:
+       * xlib/xcolors.c (XParseColor FindColor):
+       * win/tkWinColor.c (XAllocColor): Fixed bit fiddling for colors to
+       return "correct" values for color mapping. [Bug: 4282]
+
+       * unix/Makefile.in (SCRIPT_INSTALL_DIR): removed extraneous '/'
+       * unix/aclocal.m4: corrected TCL_NEEDS_EXP_FILE to be 1 for AIX
+
+       * win/tkWinInt.h: change extern to EXTERN for TkWinChildProc
+       declaration with extra #defs. [Bug: 4240]
+
+       * library/focus.tcl: fixed tkFocusOK to protect $w in
+       uplevel with list. [Bug: 4208]
+
+       * doc/CrtItemType.3: fixed docs for Tk_CreateItemType to reflect
+       changes made in 8.3.0 (but old style would still work as well).
+       [Bug: 4252]
+
+       * tests/config.test: extra test to check object cleanup when
+       destroying the widget
+       * generic/tkListbox.c (DestroyListbox): fixed crash in
+       DestroyListbox due to null tkwin.  [Bug: 4207]
+
+       * tests/entry.test: added test suite for entry validation
+       * doc/entry.n: improved docs discussing caveats and gotchas when
+       mixing textvar with widget validation
+       * generic/tkEntry.c (EntryValidateChange): improved handling of
+       validation with relation to -textvariable.  Previously, it would
+       turn off whenever the textvar was set.  Now it will it will turn
+       off only when the textvar is set and validation returns 0.  Added
+       %V (type of validation occuring) to %-subs to help work with
+       trickier validation.
+
+2000-03-01  Eric Melski  <ericm@scriptics.com>
+
+       * tests/clrpick.test: 
+       * library/clrpick.tcl: Added code to make color chooser dialog
+       inherit screen setting from parent (bug #2334)
+
+2000-02-25  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/tkWinWm.c (RaiseWinWhenIdle): Checked for the possibility
+       that the window could be destroyed (can occur with
+       wm deiconify .toplevel; destroy .toplevel).
+
+2000-02-25  Eric Melski  <ericm@scriptics.com>
+
+       * generic/tkImgGIF.c: Applied "spirit of" the patch in 1605 (the
+       submitted patch was more complicated than necessary and did not
+       extend to writing GIF's, only reading), to allow reading/writing
+       of GIF files on EBCDIC and other non-ASCII based systems.
+
+2000-02-14  Eric Melski  <ericm@scriptics.com>
+
+       * unix/tk.spec: RPM specification for producing a binary Tk RPM
+       for Linux.
+
+       * unix/Makefile.in: Added rpm target to generate Tk
+       binary RPM.
+
+2000-02-10  Jeff Hobbs  <hobbs@scriptics.com>
+
+       8.3.0 RELEASE
+
+       * changes: updated for 8.3.0 release
+
+       * generic/tkImgGIF.c (FileReadGIF): added cast for trashBuffer
+
+       * generic/tkIntXlibDecls.h:
+       * generic/tkInt.decls: declared some Xlib emulation calls for
+       the Mac
+
+       * generic/tkFrame.c (TkInstallFrameMenu): added extra panic to
+       inform user of bad call when framePtr is NULL [Bug: 2530]
+
+       * generic/tkMenu.c (DestroyMenuInstance): Placed checks around
+       menu name objects before trying to incr the ref.  [Bug: 3402]
+
+       * generic/tkTest.c: removed USE_OLD_IMAGE def for Mac
+
+       * library/listbox.tcl:
+       * library/text.tcl: added support for <4> and <5> for mousewheel
+       style scrolling on Unix for mice that map to these buttons.
+
+       * tests/scrollbar.test: fixed check of testmetrics command to
+       allow unix tests to run (testmetrics is mac/pc only)
+
+       * unix/tkUnixWm.c (Tk_CoordsToWindow): qualified delete of error
+       handler as the goto label is reached from above and below.
+
+       * unix/configure.in:
+       * unix/aclocal.m4: cleaned up macros to coincide with tcl.m4,
+       added -export-dynamic to LDFLAGS for FreeBSD-3+ [Bug: 2998]
+
+       * unix/README:
+       * unix/Makefile.in (dist): removed porting.notes and porting.old
+       from distribution and CVS.  The information was very outdated.  Now
+       refer to http://dev.scriptics.com/services/support/platforms.html
+
+       * xlib/xgc.c: #def'd out XDrawSegments for the Mac, and added
+       some extra include info for the Mac
+
+2000-02-09  Jim Ingham  <jingham@cygnus.com>
+
+       * mac/tkMacButton.c: Stop removing the appearance window from the
+       Window List.  It is not clear why Ray did this, and it causes the
+       Appearance manager to crash at random times.
+       
+       * mac/tkMacWM.c: Add support in unsupported1 style for the Appearance
+       specification of window styles, including floating window support.
+       * mac/tkMacWindowMgr.c: Operate on the front non-floating window,
+       unless the mouse is directly over the floating window.  Also,
+       keystrokes go to the front non-floating window.
+       * mac/tkMacAppInit.c: Initialize floating window support.
+       * mac/tkMacScrlbr.c:
+       * mac/tkMacmenu.c: Fixes for floating windows - operate on the 
+       FrontNonFloatingWindow.
+       * mac/tkMacLibrary.r: Fix typo in File info string.
+       * mac/tkMacApplication.r: Fix typo in file info string.  Add
+       Finder balloon help for no apparent reason.
+       
+       * mac/tkMacSubwindows.c: Change panic in tkMacGetDrawablePort to
+       Debugger.  This is only a temporary fix.  The panic is only
+       triggered when a safeTk interpreter is torn down, and ignoring it
+       does no harm.  I haven't figured out how to avoid it yet, however.
+       Also use the Appearance MoveWindowStructure call when available.
+       
+       New Files:
+       * MW_TkOldImageHeader.h: Handle #defining USE_OLD_IMAGE for tkImgPPM.c.
+       * MW_TkTestHeader.h:
+       * MW_TkTestHeader.pch:
+       * MW_TkHeader.h: Add separate prefix files for test & release
+       versions of Tk, so we can just have separate targets w/o having to
+       edit files.
+       
+       * tclets.r: The D&D Tclets icon in rez form so we can have a
+       target for this.
+
+       The above are curtesy of Daniel Steffen (steffen@math.mq.edu.au)
+       
+       * tkMacAppearanceStubs.c: Stubs of the Mac Appearance calls I use
+       so I can link the static 68K Shell without putting ifdef's all
+       over the code.
+       
+2000-02-08  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tk.decls:
+       * generic/tkBind.c:
+       * generic/tkInt.decls:
+       * generic/tkIntDecls.h:
+       * generic/tkStubInit.c:
+       * mac/tkMacKeyboard.c:
+       * unix/tkUnixKey.c:
+       * win/tkWinKey.c: Fix for keyboard handling of "dead" keys and
+       caps lock from Peter Spjuth. [Bug: 4105 3359 2493]
+       Split functions into platform specific files:
+       Static functions GetKeySym(), SetKeycodeAndState() and InitKeymapInfo()
+       from tkBind.c moved into platform files tkWinKey.c tkUnixKey.c and
+       tkMacKeyboard.c.  GetKeySym() and SetKeycodeAndState() renamed to 
+       Tkp* and made public (as private functions) in tkInt.decls.
+
+       Step 2, fixes in tkWinKey.c
+       New static function: KeycodeToKeysym(), based on XKeycodeToKeysym()
+       but with different arguments, and a lot of improvements.
+       TkpGetString() changed to use KeycodeToKeysym() + other fixes.
+       TkpGetKeySym() changed to use KeycodeToKeysym() + other fixes.
+       InitKeymapInfo() changed to use KeycodeToKeysym().
+       TkpSetKeycodeAndState() rewritten, mostly by copying code from
+       XKeysymToKeycode().
+       XKeycodeToKeysym() rewritten. Preferably it should be removed.
+
+       EXPLANATION: The main problem is ToAscii() which has a lot of side
+       effects, and also that XKeycodeToKeysym() is not provided enough
+       input to do a proper job.  The changes' main goal is to avoid
+       calling ToAscii() if not necessary, and to provide it with as
+       correct information as possible when called.  Also some attempts
+       to clean up what ToAscii() did are done.  See the code for details.
+
+       BUGS FIXED: Typing shifted (and AltGr) dead keys did not work.
+       Keyboard lock lamps did not work on Win98.
+       Events regarding AltGr-keys behaved badly.
+       Example: On a Swedish keyboard, $ is typed with AltGr-4.
+       That keyboard event would get the keysym '4' not 'dollar'.
+       Also, doing [event generete . <Key-dollar>] would send keysym '4'.
+       Translation to ascii in TkpGetString did not handle return and
+       tab correctly. I.e. [event generate . <Key-Return>] gave wrong %A
+
+       * generic/tkDecls.h:
+       * generic/tk.decls:
+       * generic/tk.h: moved new public functions created in dash patch
+       to the stubs interface [Bug: 4062]
+
+       * generic/tk.h: 
+       * doc/CrtImgType.3:
+       * doc/CrtPhImgFmt.3:
+       * generic/tk.h:
+       * generic/tkImgGIF.c:
+       * generic/tkImgPhoto.c:
+       * generic/tkStubImg.c (new file):
+       * generic/tkTest.c:
+       * unix/Makefile.in:
+       * win/Makefile.in:
+       * win/makefile.vc: improved support for moving from the old style
+       image C API to the new obj'ified one with new Tk_InitImageArgs
+       command and stub'ing of image code.  See docs for how to make the
+       transition. [Bug: 4060]
+
+       * library/tk.tcl: wrapped check for tcl_platform(os) around info
+       exists because it won't in safe interpreters
+
+       * win/tkWinFont.c: corrected symbol font use to only work on 8-bit
+       characters [Bug: 2406]
+
+       * unix/aclocal.m4: changed all -fpic to -fPIC
+
+       * README:
+       * unix/configure.in:
+       * win/configure.in:
+       * generic/tk.h (TK_RELEASE_SERIAL): Moved to 8.3.0 patchlevel
+
+2000-02-07  Eric Melski  <ericm@scriptics.com>
+
+       * library/tkfbox.tcl: Applied patch from bug #4117,
+       tk_getOpenFile/getSaveFile doesn't do the right thing when user
+       types a directory name in the entry and a default extension is
+       specified.
+
+2000-02-05  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * unix/tkUnixScale.c (TkpDestroyScale): changed ckfree to
+       Tcl_EventuallyFree to behave with Tcl_Preserve in TkpDisplayScale
+       (prevents possible segfault).
+
+2000-02-03  Eric Melski  <ericm@scriptics.com>
+
+       * tests/canvText.test: test for fix for bug #2525.
+
+       * generic/tkFont.c (Tk_ComputeTextLayout): Was erroneously setting
+       the width of newline-only text display chunks to some arbitrary
+       huge number, instead of 0; this was interfering with things like
+       the canvas find enclosed feature. (bug #2525).
+
+       * tests/text.test: 
+       * generic/tkText.c (DumpLine/DumpSegment): Changed DumpSegment to
+       take a TkTextIndex instead of two integer offsets, so that it
+       could use TkTextPrintIndex to format the offsets into an index,
+       which makes it UTF smart (bug #2582).
+
+2000-02-01  Eric Melski  <ericm@scriptics.com>
+
+       * library/tk.tcl: 
+       * library/tclIndex: 
+       * library/choosedir.tcl: Moved choosedir functions into the
+       ::tk::dialog::chooseDir namespace instead of a toplevel
+       ::tkChooseDirectory namespace.  Additional cleanup on the
+       chooseDir dialog.
+
+2000-02-01  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * doc/text.n: clarified docs on what happens during a search with
+       -count when images/windows are embedded
+
+       * win/Makefile.in (install-*): reduced verbosity of install
+
+       * win/tkWinPixmap.c (XGetGeometry): added support for windows in
+       XGetGeometry [Bug: 4069]
+
+       * win/tkWinFont.c (GetScreenFont): fixed possible mem overrun with
+       long font names [Bug: 4108]
+
+       * win/tkWinDialog.c: added EnableWindow calls to dialogs to
+       correct for possible loss of control in parent Tk toplevel
+       [Bug: 1212 et al]
+
+       * generic/tkRectOval.c (ConfigureRectOval): 
+       * generic/tkCanvLine.c (ConfigureLine): 
+       * generic/tkCanvPoly.c (ConfigurePoly): 
+       * generic/tkCanvArc.c (Configure/DisplayArc): fixed handling for
+       negative dash values [Bug: 4104]
+
+       * generic/tkScale.c (TkRoundToResolution): fixed incorrect
+       assumption that (N+1)*delta = N*delta + delta with floating point
+       math [Bug: 3689, 4099]
+       (DestroyScale) Fixed check for cancelling TkpDisplayScale (was
+       REDRAW_ALL, is now REDRAW_PENDING)
+
+       * tests/listbox.test: corrected test case for listbox itemconfigure
+
+       * unix/aclocal.m4: added *BSD ELF recognition for
+       SHARED_LIB_SUFFIX determination (from Tcl's tcl.m4)
+
+2000-01-27  Eric Melski  <ericm@scriptics.com>
+
+       * generic/tkImgPhoto.c: Removed unneccesary object translation in 
+       MatchStringFormat (bug #4103).
+
+2000-01-27  Eric Melski  <ericm@scriptics.com>
+
+       * generic/tkImgGIF.c: Additional code cleanup (now we only have
+       one decoder!  neat!)
+
+2000-01-26  DJ Delorie  <dj@cygnus.com>
+
+       * win/tkWin32Dll.c (DllMain): Use _imp__ instead of __imp_
+
+2000-01-26  Eric Melski  <ericm@scriptics.com>
+
+       * doc/getOpenFile.n: 
+       * doc/chooseDirectory.n: Man page/cross links for
+       tk_chooseDirectory (bug #1786).
+
+       * library/tk.tcl: 
+       * library/tclIndex: Added hooks for tk_chooseDirectory. (bug #1786)
+
+       * library/choosedir.tcl: tk_chooseDirectory implementation for
+       Unix/Mac (bug #1786).
+
+       * generic/tkImgPhoto.c: Added some comments regarding slow
+       processing of transparent images.
+
+       * generic/tkImgGIF.c: Improved GIF decoder for ~60% speed
+       increase.  Added some comments on how to further improve the
+       implementation, time permitting.
+
+       * doc/photo.n: Added a description of what the -data string can
+       contain (base64 or binary data).
+
+       * generic/tkImgPhoto.c: Fixed bug with use of binary data for
+       "-data" option to "image create" command.
+
+2000-01-21  Eric Melski  <ericm@scriptics.com>
+
+       * library/tkfbox.tcl: Fixed bug relating to incorrect parent
+       values for error message boxes displayed by the file dialog (bug
+       #3616).
+
+       * tests/text.test: 
+       * generic/tkText.c: Fixed bug relating to regexp searching for
+       empty lines; previously, the starting line was ignored. (bug #1643).
+
+2000-01-20  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * library/text.tcl: fixed double-click selection behavior where
+       there were embedded windows/widgets in the same line. [Bug: 3989]
+
+       * win/tkWinWm.c (TkWmProtocolEventProc): cached atom name as the
+       window could get destroyed during eval [Bug: 2513]
+
+       * generic/tkCanvLine.c (LineCoords): fixed segfault when too few
+       coords were passed to a line with certain options set (it should
+       always have thrown an error anyway). [Bug: 4042]
+
+       * tests/text.test:
+       * generic/tkText.c: fixed missing " in error case and missing
+       'dump' in subcommand listing [Bug: 4036]
+
+       * generic/tkListbox.c: adjusted use of basic string concatenation
+       in (non-K&R behavior) [Bug: 4027]
+       Swapped bg/fg class for -select(bg|fg) for listbox and their
+       items [Bug: 4039]
+
+       * unix/mkLinks:
+       * doc/WindowId.3: added docs for Tk_IsContainer and Tk_IsEmbedded
+
+       * doc/text.n: clarified mark gravity definition and usage of
+       ``word'' in binding definitions.  [Bug: 2004 2277 1388]
+
+       * generic/tkInt.h: moved new TkDisplay useInputMethods structure
+       element to end to not disturb position of previous elements in
+       the structure (as compared to Tk <=8.2).
+
+2000-01-20  Eric Melski  <ericm@scriptics.com>
+
+       * tests/grid.test: Added a test for the consecutive ^ and multiple
+       widget case (bug #1386).
+
+       * generic/tkGrid.c: Fixed interpretation of consecutive ^
+       characters in grid command.  Previously, ^ ^ was interpreted as
+       meaning that there must be a 2-column widget above to extend,
+       neglecting the case where there was actually 2 1-column widgets
+       above.  Now, ^ ^ is interpreted as a possible width; the gridder
+       will consume as many ^'s as there are columns in the widget, and
+       leave the rest for the extension of other widgets.  (bug #1386).
+
+2000-01-19  Eric Melski  <ericm@scriptics.com>
+
+       * library/tk.tcl: Created a virtual event <<PrevWindow>> for
+       reverse tab traversals, with one default binding <Shift-Tab>, and
+       OS specific bindings for Linux, HP-UX, and IRIX. (bug #3163)
+
+2000-01-13  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * changes: updated changes file to reflect 8.3b2 mods
+       * README:
+       * generic/tk.h:
+       * unix/configure.in:
+       * win/configure.in: updated to patchlevel 8.3b2
+
+       * win/tkWinWm.c: added visibility event handler to make sure
+       that transient window wrappers would be updated when the master
+       was initially mapped.
+
+2000-01-12  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * tests/text.test: changed test to reflect change of -hidden
+       to -elide in search options.
+
+       * win/tkWinScrlbr.c: added check for valid hwnd in ModalLoopProc
+       to avoid crash when building statically
+
+       * doc/event.n:
+       * generic/tkBind.c: prevented core with event -warp on Windows
+       when window wasn't mapped [Bug: 4004] and added docs stating
+       the requirement for mapped windows.
+
+       * generic/tkCanvas.c: fixed mem leak with TagSearchExprInit
+       [Bug: 3977]
+
+       * generic/tkStubInit.c:
+       * generic/tkDecls.h: remove non-existent
+       Tk_(Get|Create)CanvasVisitor prototypes
+
+       * generic/tkText.c:
+       * generic/tkEntry.c: fixed cursor to not blink when widget was
+       disabled [Bug: 1807]
+
+       * generic/tkRectOval.c: added note about change to bloat for
+       RectOval bounds calculation for WIN32 only
+
+       * library/dialog.tcl: improved handling of $default arg to allow
+       for name of given button, as well as bounds checking
+
+       * doc/wm.n:
+       * tests/winWm.test:
+       * tests/unixWm.test:
+       * mac/tkMacWm.c:
+       * unix/tkUnixWm.c: fixed possible X error being raised [Bug: 3377]
+       * win/tkWinWm.c: wm deiconify in zoom state [Bug: 2077],
+       fixed possible flashing of unmapped toplevel in deiconify [Bug: 3338]
+       and fixed mapping of transient window [Bug: 572]
+       Also, for all wm's, extended 'wm state' command to allow setting
+       of the state, and added official support of 'zoomed' state on Win.
+
+       * unix/aclocal.m4: strtod bug on Tru64 [Bug: 3378]
+
+       * unix/Makefile.in: added tests to prevent unnecessary chmod +x
+       in source dirs while installing [Bug: 3367]
+
+       * unix/configure.in: properly sub'ed in TK_SHARED_BUILD [Bug: 3385]
+
+2000-01-05  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * doc/text.n:
+       * generic/tkText.c:
+       * generic/tkText.h:
+       * generic/tkTextBTree.c:
+       * generic/tkTextDisp.c:
+       * generic/tkTextTag.c: removed the -state option for text tags,
+       and reoriented it around -elide, as -state disabled was never
+       implemented, and -state hidden is better as -elide.
+
+       * mac/tkMacClipboard.c: fixed i18n problems with clipboard [Bug: 3544]
+
+       * library/entry.tcl:
+       * library/focus.tcl:
+       * library/listbox.tcl:
+       * library/scale.tcl:
+       * library/scrlbar.tcl:
+       * library/tearoff.tcl:
+       * library/text.tcl:
+       * library/tkfbox.tcl:
+       * library/xmfbox.tcl: fixed unprotected arg parsing through eval/after
+       [Bug: 3943]
+
+       * unix/Makefile.in: added unix/aclocal.m4 to distribution [Bug: 3938]
+       * unix/aclocal.m4: changed NetBSD SHLIB_CFLAGS from -fpic to -fPIC
+
+       * win/tkWinImage.c: added static declaration to function
+
+1999-12-22  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * changes: updated changes file
+
+       * generic/tkScale.c:
+       * generic/tkScale.h:
+       * mac/tkMacScale.c:
+       * unix/tkUnixScale.c: fixed potential segv from patch in 3897
+
+       * tests/unixWm.test: nonPOrtable -> nonPortable
+
+1999-12-21  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tk.h:
+       * unix/configure.in:
+       * win/configure.in:
+       * win/aclocal.m4:
+       * README: updated for patch level 8.3b1
+
+       * unix/tkUnixWm.c: fixed panic in Tk_CoordsToWindow to print error
+       and continue instead (for Tix) [Bug: 716 et al]
+
+       * scale.test:
+       * generic/tkScale.c:
+       * generic/tkScale.h: fixed possible core when freeing options
+       (cursor) associated with scale widget [Bug: 3897]
+
+       * doc/MeasureChar.3: fixed docs for Tk_MeasureChars to reflect code
+       * doc/listbox.n: fixed formatting problem
+
+       * generic/tk3d.c: added extra calculations to ensure that thin
+       frames get refreshed too [Bug: 3596]
+
+       * unix/tkUnixMenu.c:
+       * unix/tkUnixFont.c:
+       * generic/tkCanvText.c:
+       * generic/tkEntry.c:
+       * generic/tkFont.c:
+       * generic/tkImgPPM.c: removed extranneous vars that were set but
+       never used.
+
+       * mac/tclMacHLEvents.c: fixed applescript for I18N [Bug: 3644]
+
+       * unix/aclocal.m4: removed -O flag for AIX when using the IBM
+       compiler (several versions have a bug that crops up in the text
+       widget). [Bug: 2316]
+
+       * unix/Makefile.in: removed extra slash in SCRIPT_INSTALL_DIR
+       [Bug: 3896]
+
+       * library/listbox.tcl: added extra checks for existence of
+       tkPriv(listboxSelection) before it was used. [Bug: 3892]
+
+1999-12-16  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * doc/GetCursor.3:
+       * win/tkWinCursor.c: added support for Windows cursors to
+       TkGetCursorByName (.ani, .cur) using -cursor @<filename>
+       (Ascher) [Bug: 1350]
+
+       * win/tkWinWm.c: fixed 'wm deiconify' to update position of the
+       toplevel if event is waiting before mapping. (Mao) [Bug: 3687]
+       This removes the need for 'update idle' before 'wm deiconify' on
+       Windows.
+
+       * doc/listbox.n: added doc for <<ListboxSelect>> [Bug: 3500]
+
+       * doc/getOpenFile.n: removed note that -initialfile didn't work
+       for tk_getOpenFile
+       * library/tkfbox.tcl: updated tk_get*File to better match the
+       Windows file box it emulates, give proper support to -initialfile,
+       and fixes lack of global tkPriv call.  [Bug: 3735 3882]
+
+       * doc/tk.n: added doc for 'tk useinputmethods ...'
+       * tests/tk.test:
+       * unix/tkUnixKey.c:
+       * generic/tkCmds.c:
+       * generic/tkEvent.c:
+       * generic/tkWindow.c:
+       * generic/tkInt.h: add 'tk useinputmethods ?-display win? ?bool?'
+       call to provide support for disabling/enabling the use of XIM on
+       X.  This was previously all done at compile time, and always on.
+       Now it is turned off by default, even when available, and the user
+       must turn it on to use XIM (per display).
+
+       * generic/tkCanvUtil.c: fixed bug in Tk_CanvasPsOutline that freed
+       mem it shouldn't.
+
+       * generic/tkFont.c: added "bitstream cyberbit" (popular Windows
+       CJK font) to list of font fallbacks. (kenny) [Bug: 2407]
+
+       * mac/tkMacMenu.c: finished bug 3075 by changing the char values of
+       what was checked (verified correctness on Mac).
+
+1999-12-13  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * doc/canvas.n: added docs for items added by dash patch (-*dash*,
+       -state, -active*, -disabled*, -offset, essentially rewrote the
+       man patch for completely updated 8.3 canvas widget.
+       * doc/entry.n: added docs for entry widget validation
+       * doc/event.n: added docs for -warp
+       * doc/text.n: doc'ed new -state value 'hidden'
+       * doc/GetDash.3: (new file) man page explaining Tk_GetDash
+       * generic/tkStubInit.c:
+       * generic/tkDecls.h:
+       * generic/tkIntXlibDecls.h:
+       * generic/tkInt.decls: added XSetDashes and XWarpPointer
+       * generic/tk.decls: added Tk_CreateSmoothMethod, and reserved
+       two spots
+       * generic/tk.h: added Tk_SmoothMethod struct,
+       state item to canvas record, #defines for item state,
+       support for using old char*-based canvas item C creation
+       procedures with -DUSE_OLD_CANVAS,
+       Tk_Dash, Tk_TSOffset (-offsets) & Tk_Outline structs and #defs,
+       decls for dash, outline and postscript routines
+       * generic/tkBind.c: added support for Quadruple clicks, and added
+       the -warp option to 'event' with pointer warping routines
+       * xlib/xgc.c:
+       * generic/tkRectOval.c:
+       * generic/tkCanvArc.c:
+       * generic/tkCanvBmap.c:
+       * generic/tkCanvImg.c:
+       * generic/tkCanvLine.c:
+       * generic/tkCanvPoly.c:
+       * generic/tkCanvPs.c:
+       * generic/tkCanvText.c:
+       * generic/tkCanvUtil.c:
+       * generic/tkCanvWind.c:
+       * generic/tkCanvas.c:
+       * generic/tkCanvas.h: Canvas and items received overhaul to with
+       the addition of the dash patch (Nijtmans, et al)  This includes
+       objectification of the 'canvas' command, as well as support for
+       (where appropriate) dashes in items, extended stipple support,
+       state for all items, and postscript generation of images and
+       windows.  See the new canvas man page for related docs.
+       * generic/tkEntry.c: added entry widget validation, see entry.n
+       * generic/tkEvent.c: on simulated events, ButtonPress should
+       be matched with ButtonRelease to be correct
+       * generic/tkFont.c: corrected possible null reference
+       * generic/tkFrame.c: made frame a Tcl_Obj based command
+       * generic/tkGet.c: added TkGetDoublePixels
+       * generic/tkImage.c: bug fixes from Img patch and new
+       Tk_PostscriptImage and Tk_SetTSOrigin functions
+       * generic/tkImgBmap.c: new ImgBmapPostscript function
+       * generic/tkImgPhoto.c: new Tk_CreatePhotoOption, Tk_DitherPhoto
+       * generic/tkInt.h: declarations for some new functions
+       * generic/tkMessage.c: reworked relief drawing
+       * generic/tkOldConfig.c: added TK_CONFIG_OBJS so old style
+       ConfigureWidget calls can pass in Tcl_Obj arrays
+       * generic/tkScrollbar.c:
+       * generic/tkScrollbar.h: made -orient use an option table
+       * generic/tkText.c:
+       * generic/tkText.h: made -wrap and -state use option tables
+       * generic/tkTextBTree.c:
+       * generic/tkTextDisp.c:
+       * generic/tkTextImage.c:
+       * generic/tkTextMark.c:
+       * generic/tkTextTag.c:
+       * generic/tkTextWind.c: added support for -elide and -state hidden
+       * generic/tkTrig.c: changed TkMakeBezierCurve to support returning
+       the upper limit of points needed for spline
+       * generic/tkUtil.c: new option table parsing routines
+       * generic/tkWindow.c: init'ing of warp stuff, mouseButtonState
+
+       related bug ids for the fixes:
+       [Bug: 648 1541 1540 1779 2168 2311 2297 2340 2348 2578 3386]
+
+       * tests/bind.test:
+       * tests/canvImg.test:
+       * tests/canvPsArc.tcl:
+       * tests/canvPsImg.tcl: (new file)
+       * tests/canvRect.test:
+       * tests/canvText.test:
+       * tests/canvas.test:
+       * tests/defs.tcl:
+       * tests/entry.test:
+       * tests/event.test:
+       * tests/font.test:
+       * tests/frame.test:
+       * tests/imgPhoto.test:
+       * tests/safe.test:
+       * tests/scale.test:
+       * tests/scrollbar.test:
+       * tests/select.test:
+       * tests/text.test:
+       * tests/textDisp.test:
+       * tests/textTag.test:
+       * tests/unixFont.test:
+       * tests/unixWm.test:
+       * tests/visual_bb.test:
+       * tests/winClipboard.test: tests for the dash patch changes
+
+       * unix/mkLinks: added GetDash.3 into the mkLink step
+
+       * mac/tkMacDraw.c: mac still needs pointer warping routine
+       * mac/tkMacXStubs.c:
+       * win/tkWinDraw.c:
+       * win/tkWinPointer.c: added support for pointer warping and
+       platform specific support for dash patch items
+
+1999-12-12  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkText.c: fixed bug in TextSearchCmd for multibyte chars
+       (Darley) [Bug: 3839]
+
+       * unix/aclocal.m4: added warning when configuring with
+       --enable-threads that Tk may have problems
+
+1999-12-09  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkImgGIF.c: updated casting
+
+       * win/makefile.vc: removed 16bit stuff, simplified makefile.
+
+1999-12-06  Scott Redman  <redman@scriptics.com>
+
+       * generic/tkMain.c: need to include tclInt.h for new hook
+       functions that are internal-use-only.
+
+1999-12-06  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * library/comdlg.tcl: removed tclVerifyInteger and tclSortNoCase,
+       they weren't used, and were not actually correct
+
+       * mac/tkMacFont.c:
+       * mac/tkMacMenu.c:
+       * mac/tkMacWindowMgr.c: fixed greyed out menu items, handling of
+       ... elipsis, font mapping problem, and enabled generated menu
+       posting [Bug: 3705]
+
+1999-12-02  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkInt.h:
+       * generic/tkWindow.c:
+       * generic/tkCmds.c: converted Tk_DestroyCmd, Tk_LowerCmd and
+       Tk_RaiseCmd to their ObjCmd equivalent.
+
+       * library/msgbox.tcl: added color icons for tk_messageBox on Unix
+       and Mac when tk_strictMotif isn't set. (Hipp)
+       * library/tk.tcl: added window bounds checking to ::tk::PlaceWindow
+
+       * tests/imgPPM.test: fixed test 2.2 to use -format ppm (since
+       we know have GIF write capability)
+
+1999-12-01  Scott Redman <redman@scriptics.com>
+
+       * generic/tkMain.c :
+       * unix/tkAppInit.c: 
+       * win/winMain.c: Added added hooks into the main() code for
+       supporting TclPro and other "big" shells more easily without
+       requiring a copy of the main() code.
+
+1999-11-29  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkImgGIF.c: added GIF writing that uses miGIF RLE
+       [Bug: 2039, new patch]
+
+       * library/entry.tcl: fixed up tkEntrySeeInsert (Nemthi)
+
+       * generic/tkListbox.c: fixed 'get' of listbox to return a string
+       when only one item is requested.
+
+       * tests/clrpick.test:
+       * tests/filebox.test: minor whitespace cleanup
+
+       * library/tk.tcl: fixed missing $w in ::tk::PlaceWindow
+
+1999-11-24  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * library/clrpick.tcl:
+       * library/msgbox.tcl:
+       * library/tk.tcl:
+       * library/tkfbox.tcl:
+       * library/xmfbox.tcl: fixed dialogs to center over -parent,
+       added utility functions ::tk::PlaceWindow, ::tk::SetFocusGrab,
+       ::tk::RestoreFocusGrab to tk.tcl to help
+
+1999-11-23  Eric Melski  <ericm@scriptics.com>
+
+       * tests/listbox.test: Added a test to check that the topIndex is
+       update when items are removed from the listvar variable.
+
+       * generic/tkListbox.c: Added a check the updates the topIndex when
+       items are removed from the listvar variable.
+
+       * tests/listbox.test: Added a test to check that the vertical
+       scrollbar is updated when the listvar changes.
 
-Tue Jun  6 22:09:02 2000  Christopher Faylor <cgf@cygnus.com>
+       * generic/tkListbox.c (ListboxListVarProc): added a check that
+       sets the UPDATE_V_SCROLLBAR flag if the length of the listvar has
+       changed.
 
-       * win/Makefile.in: Set up and use autoconf variables throughout to
-       allow overriding variables from the make command line.
+1999-11-23  Jeff Hobbs  <hobbs@scriptics.com>
 
-2000-01-26  DJ Delorie  <dj@cygnus.com>
+       * generic/tk.h:
+       * generic/tkConfig.c: added support for TK_OPTION_DONT_SET_DEFAULT
+       as equiv for TK_CONFIG_DONT_SET_DEFAULT
+       * generic/tkListbox.c: added TK_OPTION_DONT_SET_DEFAULT to the
+       item specs
 
-       * win/tkWin32Dll.c (DllMain): Use _imp__ instead of __imp_
+1999-11-19  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkColor.c:
+       * generic/tkColor.h: fixed Tk_NameOfColor to work correctly,
+       with minor change to TkColor struct.
+
+       * generic/tkConsole.c: added static declaration to
+       ConsoleDeleteProc function (proto already had it)
+
+       * win/tkWinInt.h: removed TkFontAttributes typedef (was
+       redundant with tkFont.h).
+       * win/tkWinPort.h: put #ifndef __GNUC__ around redefinition
+       of str[n]casecmp, as cygwin uses the originals.
+       * win/tkWinX.c: changed GetCurrentTime to GetTickCount (the
+       former is deprecated).  [Bug: 2053]
+
+1999-11-19  Eric Melski  <ericm@scriptics.com>
+
+       * tests/listbox.test: Added tests for itemcget and itemconfigure.
+
+       * doc/listbox.n: Added documentation for -listvar option and for
+       itemconfigure and itemcget commands.
+
+       * generic/tkListbox.c: Added support for itemconfigure/itemcget
+       listbox subcommands (addresses rfe #936)
+
+1999-11-17  Eric Melski  <ericm@scriptics.com>
+
+       * tests/listbox.test: Updated tests for new error messages.
+
+       * generic/tkListbox.c: Improved error messages for bad -listvar's.
+
+       * tests/listbox.test: Added tests for bad -listvar's.
+
+       * generic/tkListbox.c: Added handlers for bad -listvar's (ie, bad
+       lists)
+
+       * tests/listbox.test: Added tests for ListboxUpdateHScrollbar.
+
+       * generic/tkListbox.c: Changed some old static buffers to base
+       size on TCL_DOUBLLE_SPACE instead of (completely) hardcoding the size.
+
+       * tests/listbox.test: New tests for -listvar functionality, and an
+       odd extra case that wasn't covered before.
+
+       * generic/tkListbox.c: Tests exposed some bugs, now fixed.
+
+1999-11-16  Eric Melski  <ericm@scriptics.com>
+
+       * tests/listbox.test: Fixed tests to comply with new objectified
+       error messages.  No -listvar specific tests yet.
+
+       * win/tkWinDefault.h: 
+       * unix/tkUnixDefault.h: 
+       * mac/tkMacDefault.h: Added default value for -listvar option.
+
+       * generic/tkWindow.c: Changed "listbox" mapping from old-school to
+       new-school objectified command.
+
+       * generic/tkListbox.c: Objectified listbox; added support for
+       -listvar option.  Converted internal structure to use a Tcl list
+       object to store the data.
+
+       * generic/tkInt.h: Changed reference to Tk_ListboxCmd to
+       Tk_ListboxObjCmd.
+
+1999-11-09  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkGrid.c: changed Tcl_Alloc to ckalloc
+
+       * generic/tkEntry.c: fixed C expr error in destroy of entry
+       that could lead to 'malformed bucket chain' error
 
-1999-03-02  James Ingham  <jingham@cygnus.com>
+       * win/winMain.c: corrected winMain to not do a DebugBreak when
+       returning an error message from the top level
 
-       Copying over irox's 3D changes from Tk8.1 for a more Win95 look.
-       The button changes don't seem to work, so I will leave them out
-       for now.
+1999-10-30  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/tkWinKey.c: fixed XKeysymToKeycode to handle mapping of
+       symbolic keysyms (Left, Home, ...) with event generate
+
+       * library/entry.tcl: change tkEntrySeeInsert to avoid the use
+       of a while loop that could eat CPU tremendously.  Behavior of
+       moving the cursor at the right edge changes slightly (previously
+       it tried to keep the cursor at the right edge, now it moves the
+       cursor to a "central right" location - better IMHO).
+
+1999-10-28  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * doc/CrtImgType.3:
+       * doc/CrtPhImgFmt.3:
+       * doc/FindPhoto.3:
+       * doc/photo.n:
+       * generic/tk.h:
+       * generic/tkCmds.c:
+       * generic/tkImage.c:
+       * generic/tkImgBmap.c:
+       * generic/tkImgGIF.c:
+       * generic/tkImgPPM.c:
+       * generic/tkImgPhoto.c:
+       * generic/tkInt.h:
+       * generic/tkTest.c:
+       * generic/tkWindow.c:
+       * tests/imgPhoto.test: added Img patch (Nijtmans) with docs,
+       headers #def'd with USE_OLD_IMAGE.  Upgrades image stuff to
+       Tcl_Obj API, adds alpha channel (images are now 32 bpp)
+
+       * makefile.vc: changed 'c:/program files' to c:/progra~1
+
+1999-10-19  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * library/scrlbar.tcl: changed tkScrollButtonUp to check for
+       existence of tkPriv(relief) in order to avoid spurious release
+       events
+
+       * unix/Makefile.in: added ChangeLog to dist archive
+
+1999-09-24  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * */README:
+       * win/makefile.vc:
+       * */configure.in:
+       * generic/tk.h:
+       * library/tk.tcl: up'd to 8.3a1
+
+       * unix/Makefile.in: changed 'mkdir' to 'mkdir -p'
+
+       * library/dialog.tcl: changed {Times 18} to {Times 12} for
+       dialog font.
+
+1999-09-16  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkFont.c: fixed processing of font options and error
+       returned [Bug: 2075]
+
+       * win/tkWinWm.c: fixed bug in 'wm deiconify' that raised the
+       wrong toplevel, and changed it to not set focus on overridden
+       toplevels
+
+1999-09-15  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * unix/aclocal.m4: added fix for FreeBSD-[1-2] recognition [Bug: 2070]
+       and fix to AIX-* to get ldAix right [Bug: 2624], fixed AIX
+       version check (readjust from 8-21 fix) and several other config
+       fixes for AIX
+       * mac/tkMacMenubutton.c:
+       * unix/tkUnixMenubu.c: fixed permanently stippled menubutton image
+       * win/tkWinButton.c: fixed possible pointer smash [Bug: 2733]
+
+1999-09-14  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/tkWinMenu.c: fix for stack overrun in GetTextFace [Bug: 909]
+
+1999-09-01  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/tkWinDraw.c:
+       * unix/tkUnixDraw.c: fixed header style for TkpDrawHighlightBorder
+       * generic/tkCanvas.c: fixed GC error (bg <> fg) in tkCanvas.c
+       (from code added to support TkpDrawHighlightBorder) [Bug: 2676]
+       * unix/aclocal.m4: added -bnoentry to the AIX-* flags
+       * library/msgbox.tcl: changed the behavior of tk_messageBox on
+       Unix to be more Windows like in handling of <Return> and the
+       default button
+       * library/button.tcl:
+       * library/clrpick.tcl:
+       * library/comdlg.tcl:
+       * library/console.tcl:
+       * library/dialog.tcl:
+       * library/entry.tcl:
+       * library/focus.tcl:
+       * library/listbox.tcl:
+       * library/menu.tcl:
+       * library/msgbox.tcl:
+       * library/palette.tcl:
+       * library/safetk.tcl:
+       * library/scale.tcl:
+       * library/scrlbar.tcl:
+       * library/tearoff.tcl:
+       * library/text.tcl:
+       * library/tk.tcl:
+       * library/tkfbox.tcl:
+       * library/xmfbox.tcl: updated commands to use [string] ops
+       instead of expr equality operators
+
+1999-08-21  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * unix/aclocal.m4: Changed AIX-4.[2-9] check to AIX-4.[1-9]
+       [Bug: 1909]
+
+1999-08-20  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * generic/tkCursor.c: fixed bug in GetCursorFromObj that caused
+       panic [Bug: 2562]
+
+       * TK 8.2.0 RELEASED
+
+1999-08-13  Jim Ingham  <jingham@cygnus.com>
+
+       * mac/tkMacMenu.c: Tk_DrawChars ends up setting the menu background
+       wrong.  There is no clean way to stop it, so I use lower level routines
+       here to draw the text.
+       * mac/tkMacProjects.sea.hqx: Rearrange the projects so that the build 
+       directory is separate from the sources.  Much more convenient! 
+        
+1999-08-10  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * win/tkWinWm.c: changed "wm deiconify" on Windows to raise and
+       force the focus on the deiconified window (behavioral change from
+       8.1 to comply better with Windows style) [Bug: 1609]
+       * doc/wm.n: clarified behavior of "wm deiconify".
+       * generic/tkInt.decls: added TkSetFocusWin
+       * generic/tkFocus.c: changed static SetFocus to TkSetFocusWin
+
+       * library/clrpick.tcl:
+       * library/console.tcl:
+       * library/tk.tcl: fixed code where abbreviations where used
+       in calling widget methods (confuses iWidgets) [Bug: 2422]
+
+1999-08-09  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * library/button.tcl: cleaned up programming (config -> configure)
+       and fixed Windows relief bug [Bug: 664]
+       * library/entry.tcl: changed Entry C/C/P to not use global data
+       (now uses tkPriv(data)) [Bug: 1475]
+       * library/listbox.tcl: fixed extended mode script error [Bug: 866]
+       * doc/options.n: clarified that -troughcolor doesn't work on Windows
+       * doc/wm.n: fixed wm positionfrom docs [Bug: 2284]
+
+1999-08-01  Jeff Hobbs  <hobbs@scriptics.com>
+
+       * mac/tkMacPort.h: wrapped panic in #ifndef panic to avoid
+       compiler errors when used with stubs-#defines, from Vince Darley.
+       [Bug: 2389]
        
-       * win/tkWin3d.c (Tk_3DVerticalBevel, Tk_3DHorizontalBevel): The
-       dark pixels are drawn inside the bevel, not outside.
+1999-07-31  Scott Redman  <redman@scriptics.com>
 
-Fri Feb 26 17:40:55 1999  Geoffrey Noer  <noer@cygnus.com>
+       * xlib/X11/Xlib.h: Remove XFillRectangle since it is now in the
+       stub tables.
 
-        * win/configure.in: change "cygwin32*" to "cygwin*"
-        * win/configure: Regenerated.
-        * configure.in: Change "cygwin32*" to "cygwin*"
-        * configure: Regenerate.
+1999-07-30  Jeff Hobbs  <hobbs@scriptics.com>
 
-1999-02-11  Syd Polk  <spolk@cygnus.com>
+       * generic/tkInt.decls: Added stub entry for XFillRectangle [Bug: 2446]
 
-       * unix/configure.in: Forgot to AC_SUBST TK_LIB_FULL_PATH.
-       * unix/configure: Regenerate.
+1999-07-30    <redman@scriptics.com>
+
+       * win/makefile.vc: Corrected building threaded tktest.exe on
+       Windows.  Needed to link in .obj files from Tcl, needs to change
+       later so that code is in Tk and doesn't require a Tcl build.
+       Also added runtest target.
+
+1999-07-29    <redman@scriptics.com>
+
+       * generic/tkConsole.c: Allow tcl to open CON and NUL, even for std
+       channels.  Checking for bad/unusable std channels was moved to Tk
+       since its only purpose was to check whether to use the Tk Console
+       Window for the std channels.  [Bug: 2393 2392 2209 2458]
+
+       * win/Makefile.in: Corrected building threaded tktest.exe on
+       Windows.  Needed to link in .obj files from Tcl, needs to change
+       later so that code is in Tk and doesn't require a Tcl build.
+
+1999-07-22    <redman@scriptics.com>
+
+       * Changed version to 8.2b2
+
+       * win/tkWinPort.h: Block out include of sys/stat.h in order to
+       build extensions with MetroWerks compiler for Win32. [Bug: 2385]
+       
+       * unix/Makefile.in: Need to make install-sh executable before
+       calling (with chmod +x).  [Bug: 2413]
+       
+       * library/menu.tcl: Applied patch from Jeff Hobbs to fix typo.
+       [Bug: 2425]
+       
+1999-07-21    <redman@scriptics.com>
+
+       * unix/Makefile.in: Add Windows configure script to distribution.
+
+1999-07-16    <redman@scriptics.com>
+
+       * unix/Makefile.in:
+       * win/Makefile.in:  Copy the prolog.ps from the generic directory
+       for install-libraries.
+
+       * unix/aclocal.m4: Check for Alpha/Linux to set the IEEE flag to
+       the compiler to be -mieee.  Patch from Don Porter.
+
+1999-07-08    <stanton@scriptics.com>
+
+       * tests/unixSelect.test: Fixed broken test.
+
+       * win/makefile.vc: Added special case target to ensure that 
+       tkStubLib.obj is built with -DSTATIC_BUILD.
+
+       * win/tkWinX.c (TkWinChildProc): Changed to pass
+       WM_WINDOWPOSCHANGED through to DefWindowProc to make OpenGL
+       sub-windows happy.  This allows Windows to generate the WM_SIZE
+       and WM_MOVE messages.
+
+1999-07-08    <redman@scriptics.com>
+
+       * unix/configure.in: Fix Tk stub lib file names and flags.
+
+1999-06-30    <redman@scriptics.com>
+
+       * generic/tkGrid.c: removed deprecated functions (applied patch
+       from Jan Nijtmans). [Bug: 2080]
+
+       * generic/tkImgGIF.c:
+       * generic/tkImgPPM.c:
+       * generic/tkImgPhoto.c: Applied patch to allow Img extension to
+       work with 8.2, from Jan Nijtmans. [Bug: 2068]
+
+       * win/tkWinWm.c: Applied patch from Don Porter to prevent the
+       windows code from calling the Tcl functions when the stub table
+       has not been initialized in TkWinWmCleanup.  [Bug: 2269]
+       
+1999-06-16    <wart@scriptics.com>
+
+       * unix/configure.in:
+       * unix/Makefile.in:
+       * unix/aclocal.m4: Numerous build changes to make Tk conform to
+       the proposed TEA spec
+
+       * tkConsole.c: changed some variable types from (int) to (size_t)
+       to prevent compiler warnings.  Cast return value from strlen()
+       to (int) in one place for the same reason.
+
+1999-06-03    <stanton@scriptics.com>
+
+       * unix/tkUnixSelect.c: 
+       * tests/unixSelect.test: 
+       * generic/tkSelect.c: Fixed selection code to handle Unicode data
+       in COMPOUND_TEXT and STRING selections. [Bug: 1791]
+
+1999-06-02    <stanton@scriptics.com>
+
+       * generic/tkIntXlibDecls.h: 
+       * xlib/X11/Xlib.h: Added Mac specific defines to help with
+       compilation. 
+
+       * generic/tkFont.c: lint
+
+1999-06-01    <stanton@scriptics.com>
+
+       * unix/tkUnixSelect.c: Improved I18N selection support.
+       COMPOUND_TEXT is converted to/from iso2022, and STRING is
+       converted to/from iso8859-1.  There are still a few loose ends to
+       tie up before this is completely done.
+
+       * unix/tkUnixFont.c: Eliminated redundant case folding code.
+
+       * generic/tkFont.c: Eliminated use of isupper/tolower in favor of
+       Unicode variants.
+
+1999-05-24    <stanton@scriptics.com>
+
+       * generic/tkStubLib.c: 
+       * generic/tkStubInit.c:
+       * generic/tkIntXlibDecls.h: 
+       * generic/tkIntPlatDecls.h: 
+       * generic/tkIntDecls.h: 
+       * generic/tkInt.decls: 
+       * generic/tkConsole.c: Various changes to try to get the Mac
+       builds working.
+
+1999-05-21    <stanton@scriptics.com>
+
+       * win/tkWinClipboard.c: Fixed clipboard code to handle lack of
+       CF_LOCALE information (e.g. from command.com).
+
+1999-05-20    <redman@scriptics.com>
+
+       * library/console.tcl: Changed copyright string to read 1999
+       Scriptics Corp. in wish console about box.
+       
+1999-05-19    <redman@scriptics.com>
+
+       * generic/tk.h: Add extern "C" block around entire header file for
+       C++ compilers to fix linkage issues.  Submitted by Don Porter and
+       Paul Duffin.
+
+1999-05-18    <stanton@scriptics.com>
+
+       * tests/winClipboard.test: 
+       * win/tkWinClipboard.c: Fixed clipboard code so it handles Unicode
+       data properly on Windows NT and 95. [Bug: 1791]
+
+1999-05-07    <stanton@scriptics.com>
+
+       * library/menu.tcl: Fixed bug where tk_popup fails when called too
+       quickly. [Bug: 2009]
+
+1999-04-30    <stanton@scriptics.com>
+
+       * Changed version number to 8.1.1.
+
+1999-04-30    <stanton@scriptics.com>
+
+       * Merged changes from 8.1.0 branch:
+
+       * generic/tkDecls.h: 
+       * generic/tkIntDecls.h: 
+       * generic/tkIntPlatDecls.h: 
+       * generic/tkIntXlibDecls.h: 
+       * generic/tkPlatDecls.h: 
+       * generic/tkStubInit.c: Changed to avoid the need for forward
+       declarations in stub initializers.  Added extern "C" blocks around
+       stub table pointer declarations so the stubs can be used from C++
+       code. [Bug: 1934]
+
+       * generic/tkInt.decls: Added TkClipBox, XDrawSegments, and
+       XForceScreenSaver to stubs.
+
+       * generic/tkStubLib.c: Reordered declarations to avoid
+       circularities and forward references.
+
+       * generic/tkStubInit.c: Added includes for Mac.
+
+       * generic/tkMenubutton.c: lint
+
+       * generic/tkEntry.c: Fixed bad option table entry.
+
+       * generic/tkImgBmap.c:
+       * generic/tkImgPPM.c:
+       * generic/tkImgPhoto.c: Set the -translation and -encoding options
+       to binary for image files. (reported by Marco Gazzetta)
+       
+1999-04-23    <stanton@scriptics.com>
+
+       * generic/tkInt.decls: Added TkClipBox, XDrawSegments, and
+       XForceScreenSaver to stubs.
+
+       * generic/tkStubLib.c: Reordered declarations to avoid
+       circularities and forward references.
+
+       * generic/tkStubInit.c: Added includes for Mac.
+
+       * generic/tkMenubutton.c: lint
+
+       * generic/tkEntry.c: Fixed bad option table entry.
+
+1999-04-22    <redman@scriptics.com>
+
+       * generic/tkImgBmap.c:
+       * generic/tkImgPPM.c:
+       * generic/tkImgPhoto.c: Set the -translation and -encoding options
+       to binary for image files. (reported by Marco Gazzetta)
+
+1999-04-20    <redman@scriptics.com>
+
+       * xlib/X11/Xlib.h: changed definition of Status type to use a
+       typedef instead of a #define to avoid conflicting with the cygwin
+       win32 headers [Bug 1804]
+
+1999-04-15    <stanton@scriptics.com>
+
+       * Merged 8.1 branch into the main trunk
+
+1999-04-09    <redman@scriptics.com>
+
+       * generic/tkWindow.c: Fixed deadlock situation when the Initialize()
+       function returns without releasing the mutex.  Found while testing
+       Bug 1700, during safe.test (tk).
+
+1999-04-06    <stanton@scriptics.com>
+
+       * generic/tkMain.c (Tk_MainEx): Changed to reset result before
+       calling Tcl_EvalFile.  The ensures that error messages will be
+       generated cleanly.
+
+       * tests/winfo.test: Enabled tests that previously failed.
+
+1999-04-05    <stanton@scriptics.com>
+
+       * library/bgerror.tcl:
+       * library/button.tcl:
+       * library/clrpick.tcl:
+       * library/console.tcl:
+       * library/dialog.tcl:
+       * library/entry.tcl:
+       * library/focus.tcl:
+       * library/listbox.tcl:
+       * library/menu.tcl:
+       * library/msgbox.tcl:
+       * library/palette.tcl:
+       * library/scale.tcl:
+       * library/scrlbar.tcl:
+       * library/tearoff.tcl:
+       * library/text.tcl:
+       * library/tk.tcl: Lots of minor performance improvements
+       contributed by Jeffrey Hobbs. [Bug: 1118]
+
+       * win/tkWinWm.c (Tk_WmCmd): Fixed bad code in tracing
+       suboption. [Bug: 1519]
 
-1999-02-10  Syd Polk  <spolk@cygnus.com>
+       * library/tkfbox.tcl: Change to restore button text after an
+       action to avoid the sticky "Open" button in a save dialog.
+       [Bug: 1640]
 
-       * unix/configure.in unix/tkConfig.sh.in: Export TK_LIB_FULL_PATH.
+       * library/entry.tcl: Fixed so selection is returned using the
+       -show character during cut and paste operations. [Bug: 1687]
+       
+1999-04-5     <redman@scriptics.com>
+
+       * generic/tkInt.decls:
+       * generic/tkIntXlibDecls.h:
+       * generic/tkStubInit.c:
+       * xlib/xgc.c:
+       * xlib/X11/Xlib.h:
+       * xlib/X11/Xutil.h: Added more X functions to the Win & Mac stubs
+       tables.
+       
+1999-04-05    <stanton@scriptics.com>
+
+       * unix/configure.in:
+       * generic/tkCanvPs.c: Added configure test for pw_gecos field in
+       pwd to support OS/390. [Bug: 1724]
+
+1999-04-02    <stanton@scriptics.com>
+
+       * tests/text.test: 
+       * generic/tkText.c: Fixed handling of Unicode in text searches.
+       The -count option was returning byte counts instead of character
+       counts. [Bug: 1056, 1148, 1666]
+
+1999-04-01    <redman@scriptics.com>
+
+       * generic/tk.decls:
+       * generic/tk.h:
+       * generic/tkStubInit.c:
+       * generic/tkWindow.c:
+       * unix/Makefile.in:
+       * win/makefile.vc: Tk now uses its own stub library to store
+       pointers to its own stubs table.
+
+       * doc/dde.n: (removed)
+       * doc/send.n:
+       * generic/tk.decls:
+       * tests/winSend.test:
+       * generic/tkPlatDecls.h:
+       * win/tkWinSend.c:  Removed the DDE-based send and dde commands,
+       they were causing Tk to lock up when any window on the system was
+       not processing its message queue (more importantly, windows in Tcl
+       and Tk).  The send command needs to be rewritten to prevent the
+       deadlock situation (soon).  The dde command is being pushed into
+       its own package and will provide almost all of the capabilities
+       that send did before (using a "dde eval" command), not yet
+       completed.
+
+1999-03-31    <redman@scriptics.com>
+
+       * win/tkWinSend.c: Modified dde/send code to work properly on
+       Win95/Win98. String lengths are not returned properly by DDE, so
+       NULL terminate all strings going in and ignore the string length
+       coming back out.  Do not destroy handles until all necessary work
+       on those handles (and child handles) is done.
+
+1999-03-30    <stanton@scriptics.com>
+
+       * generic/tkWindow.c (Tk_DestroyWindow): Image handlers are now
+       finalized before the font subsystem since complex image handlers
+       may contain references to fonts (e.g. Tix compound images).
+       [Bug: 1603]
+
+1999-03-29    <stanton@scriptics.com>
+
+       * doc/MeasureChar.3: 
+       * doc/TextLayout.3: 
+       * generic/tk.decls: 
+       * generic/tkCanvText.c: 
+       * generic/tkEntry.c:
+       * generic/tkFont.c: 
+       * generic/tkListbox.c: 
+       * generic/tkMessage.c: 
+       * mac/tkMacFont.c: 
+       * unix/tkUnixButton.c: 
+       * unix/tkUnixFont.c: 
+       * unix/tkUnixMenu.c: 
+       * win/tkWinFont.c: 
+       * win/tkWinMenu.c: Standardized text layout and font interfaces
+       so they are consistent with respect to byte versus character
+       oriented indices.  The layout functions all manipulate character
+       oriented values while the lower level measurement functions all
+       operate on byte oriented values.  This distinction was not clear
+       and so the functions were being used improperly in a number of
+       places.  [Bug: 1053, 747, 749, 1646]
+
+       * generic/tk.decls: Eliminated uses of C++ STL types string and
+       list from declarations.
+
+       * generic/tkFont.c: Changes to named fonts were not being
+       propagated in some cases. [Bug: 1144]
+       
+       * xlib/X11/Xlib.h:
+       * generic/tkInt.decls: Added XParseColor to xlib stub
+       tables. [Bug: 1574] 
+
+       * doc/GetBitmap.3: 
+       * generic/tkBitmap.c (BitmapInit): Eliminated use of Tk_Uid's in
+       bitmaps.  Added a few CONST declarations.
+
+1999-03-29    <redman@scriptics.com>
+
+       * unix/configure.in:
+       * unix/Makefile.in:
+       * win/makefile.vc:
+       * generic/tkDecls.h:
+       * generic/tkIntDecls.h:
+       * generic/tkIntPlatDecls.h:
+       * generic/tkPlatDecls.h:
+       * generic/tkIntXlibDecls.h: Removed stub functions. Always use the
+       Tcl stubs when building with --enable-shared.
+       
+
+1999-03-26    <redman@scriptics.com>
+
+       * generic/tkTextIndex.c:
+       * tests/testIndex.test: Avoid looking past the beginning of the
+       array storing data for the text widget (.t index end-2c).  Added
+       test case to check for the bug.  [Bug 991]
+       
+       * generic/tkConsole.c: Copy static strings into a Tcl_DString
+       before passing to Tcl_Eval, in case the compiler puts static
+       strings into read-only memory.
+
+1999-03-26    <suresh@scriptics.com>
+       
+       * unix/configure.in:
+        --nameble-shared is now the default and builds Tk as a shared
+        library; specify --disable-shared to build a static Tk library
+        and shell.
+
+1999-03-26    <surles@scriptics.com>
+
+       * library/menu.tcl: Fixed bug reported by Bryan Oakley in the
+       menubutton bindings.  There was a false assumption that there was
+       always a menu attached to the button.  [Bug 1116] 
+
+1999-03-26    <redman@scriptics.com>
+
+       * unix/configure.in: Removed --enable-tcl-stub.  Linking Tk to Tcl
+       stubs is causing too many problems when linking executables like wish.
+       Until the Tk is a fully loadable extension, linking against the Tcl
+       stubs is not supported in Tk.
+
+1999-03-19    <redman@scriptics.com>
+
+       * generic/tkBitmap.c:
+       * generic/tkCursor.c:
+       * generic/tkGC.c: When creating hash tables that key off of XID
+       handles, make sure to pass TCL_ONE_WORD_KEYS.  XIDs are guaranteed
+       to be 32bit numbers, although on some 64bit systems (including 64bit
+       Solaris 7) they are packed into a 64bit value where the upper 32bits
+       are zero. The normal method of sizeof(XID)/sizeof(int) causes the
+       hash table code to assume that the XID is a pointer to an array of 
+       two ints, which it is not.  Tk now supports 64bit Solaris 7.
+
+1999-03-17    <stanton@scriptics.com>
+
+       * win/makefile.vc: 
+       * generic/tk.h: Changed to use TCL_BETA_RELEASE macro, and fixed
+       so this works in rc files.
+       
+       * win/makefile.vc: 
+       * win/makefile.bc: 
+       * win/README: 
+       * unix/configure.in: 
+       * generic/tk.h: 
+       * README: Updated version to 8.1b3.
+
+1999-03-14    <stanton@GASPODE>
+
+       * unix/configure.in: Added missing stub related definitions.
+
+       * unix/Makefile.in: Install tkDecls.h in addition to tk.h.
+
+       * generic/tkStubLib.c: Added flags to ensure we are using Tcl
+       stub macros.
+
+1999-03-11    <stanton@GASPODE>
+
+       * generic/tkInt.decls: Added reserved slot for XSetDashes for use
+       by the dash patch.
+
+1999-03-10    <redman@scriptics.com>
+
+       * xlib/xdraw.c:
+       * xlib/X11/Xlib.h:
+       * mac/tkMac.h:
+       * mac/tkMacInt.h:
+       * mac/tkMacPort.h:
+       * mac/tkMacXStubs.c:
+       * mac/tkMacAppInit.c:
+       * mac/tkMacCursor.c:
+       * win/makefile.vc:
+       * win/tkWin.h:
+       * win/tkWinInt.h:
+       * win/tkWinPort.h:
+       * win/winMain.c:
+       * generic/tk.h:
+       * generic/tkInt.h:
+       * generic/tk.decls:
+       * generic/tkInt.decls:
+       * generic/tkDecls.h:
+       * generic/tkPlatDecls.h:
+       * generic/tkIntDecls.h:
+       * generic/tkIntPlatDecls.h:
+       * generic/tkIntXlibDecls.h:
+       * generic/tkStubs.c:
+       * generic/tkPlatStubs.c:
+       * generic/tkIntStubs.c:
+       * generic/tkIntPlatStubs.c:
+       * generic/tkIntXlibStubs.c:
+       * generic/tkStubInit.c:
+       * generic/tkStubLib.c:
+       * generic/tkBind.c:
+       * generic/tkCmds.c:
+       * generic/tkConfig.c:
+       * generic/tkConsole.c: 
+       * generic/tkCursor.c:
+       * generic/tkGrab.c:
+       * generic/tkImgPhoto.c:
+       * generic/tkMain.c:
+       * generic/tkMenu.c:
+       * generic/tkPointer.c:
+       * generic/tkTextDisp.c:
+       * generic/tkWindow.c:
+       * unix/tkUnixInt.h:
+       * unix/tkUnixPort.h:
+       * unix/Makefile.in:
+       * unix/configure.in:
+       * unix/tkConfig.sh.in:
+       * unix/tkUnix.c:
+       * unix/tkUnix3d.c:
+       * unix/tkUnixDraw.c:
+       * unix/tkUnixFont.c:
+       * unix/tkUnixMenubu.c: Stubs implementation for 8.1.  Tk_Main() is
+       replaced with a macro which calls Tk_MainEx(). Tk can link to the Tcl
+       stubs library, wish links directly to Tcl and Tk. Use
+       --enable-tcl-stubs to link Tk to the Tcl stubs library (Unix), on
+       by default on Windows. Exported all public functions through the
+       stubs mechanism (see the *.decls files) and many of the internal
+       functions. Most of the changes dealt with shifting around the
+       function declarations in the header files.  Mac code may not
+       compile, but it shouldn't take much work to fix this.
+       
+       * mac/tkMacMenu.c: Added dummy TkpMenuThreadInit for Mac to be
+       consistent with Unix and Windows versions.
+       
+1999-03-08    <lfb@scriptics.com>
+
+       * win/tkWinWm.c: Toplevel class no longer shared between 
+       threads.
+       
+       * win/tkWinX.c: Multiple threads no longer share the same
+       TkDisplay structure.  Required because TkDisplay stores much
+       thread-specific data for a given thread.
+
+       * win/tkWinSend.c: Moved application instance handle out
+       out thread-local storage.  DDE was failing to initialize
+       when the instance handles were different between threads.
+       
+       * win/makefile.vc: Added THREADDEFINES for building with
+       threads enabled.
+       
+       * generic/tkMenu.c:
+       * win/tkWinMenu.c:
+       * unix/tkUnixMenu.c: Added TkpMenuThreadInit for initializing
+       thread-specific Menu state.
+
+1999-03-01    <redman@scriptics.com>
+
+       * win/tkWinWm.c: 
+       * win/tkWinPointer.c:
+       * win/tkWinInt.h: Fix "focus -force" for Windows.  The Win32 API
+       function SetForegroundWindow() does not work unless the window
+       handle is a toplevel window (a Windows toplevel).  The handle
+       being passed was a Tk toplevel, which is a child of the Windows
+       toplevel.
+
+1999-02-26    <redman@scriptics.com>
+
+       * win/cat.c: Remove this file, use the one in the Tcl source directory.
+
+       * win/makefile.vc: Remove the wishc.exe from the default targets.  Add
+       a separate console-wish target to build it.  The need for a 
+       console-wish will go away soon, so we don't want to encourage its
+       use.
+
+1999-02-25    <redman@scriptics.com>
+
+       * win/tkWinWm.c: Properly initialize the tsdPtr->firstWindow field.
+       
+       * win/cat.c: Code for cat32.exe, copied from the Tcl sources. Required
+       in order to run the test suite from the makefile
+
+       * win/winMain.c: Add main() for a console-based wishc.exe, which meant
+       adding code to disable the call to Tk_ConsoleInit().
+       
+       * generic/tkConsole.c: Check the standard handles before creating the
+       new standard channels.  This allows a windows app that has stdin,
+       stdout, or stderr to correctly connect to them.
+       
+       * generic/tkMain.c: Add a proper check for the interactive mode, since
+       the standard channels may actually be connected in windows mode or
+       even in the console-based wish.
+       
+       * win/makefile.vc: Add targets for wishc.exe (console-based wish) and
+       cat32.exe (for testing). Fix the test suite target so it can be run
+       from the makefile (which can happen since the standard handles have
+       been fixed).
+
+1999-02-12    <lfb@scriptics.com>
+
+       * generic/tkMenuButton.h:
+       * generic/tkMenuButton.c:
+       * mac/tkMacMenubutton.c:
+       * mac/tkMacDefault.h
+       * unix/tkUnixMenubu.c: Eliminated Tk_Uids used by -state option.
+       * unix/tkUnixDefault.h
+       * win/tkWinDefault.h
+       
+
+       * generic/tk.h:
+       * generic/tkScale.h:
+       * generic/tkScale.c:
+       * generic/tkWindow.c:
+       * unix/tkUnixScale.c:   
+       * unix/tkUnixDefault.h:
+       * unix/tkWinDefault.h:
+       * mac/tkMacDefault.h:  Objectified scale widget.
+
+       * win/tkWinX.c: Removed Thread-specific data from process
+       initialization code that was stopping the Tk Dll from 
+       loading.
+
+1999-02-11    <stanton@GASPODE>
+
+       * README:
+       * generic/tk.h: 
+       * unix/configure.in:
+       * win/README:
+       * win/makefile.bc:
+       * win/makefile.vc: Updated version to 8.1b2.
+       
+       * unix/tkUnixSend.c: Fixed one more Tcl_*ObjVar instance.
+       
+1999-02-04    <stanton@GASPODE>
+
+       * Various cleanup related to the Tcl_Eval and Tcl_ObjSetVar
+       changes in Tcl.
+       
+       INTEGRATED PATCHES FROM 8.0.5b2: 
+       
+       * win/tkWinMenu.c (TkpDestroyMenu): Changed so modalMenuPtr is
+       cleared when it is being destroyed.
+
+       * generic/tkImgPhoto.c: Changed so color tables are freed
+       immediately instead of being delayed.  This ensures that color
+       tables are properly disposed at process exit.
+
+       * library/prolog.ps: Changed string that determines font height to
+       include European character with an umlaut.
+
+       * generic/tkImgBmap.c (ImgBmapConfigureInstance): If an image
+       mask changed but ended up with the same XID, the GC failed to be
+       updated and so the new mask was not used. [Bug: 970]
+
+       * generic/tkFocus.c (SetFocus): Changed so focus window is always
+       set if -force is specified.  This fixes the problem on Windows
+       where Tk does not activate the window if it already has focus.
+
+       * generic/tkConsole.c: Fixed so errors in console eval are
+       reported properly.  Eliminated duplicate result messages. [Bug: 973]
+
+       * win/tkWinWm.c: Changed so windows that aren't resizable don't
+       have resize handles and the zoom box is disabled.
+
+       * win/tkWinInt.h:
+       * win/tkWinPointer.c: Changed to cancel the mouse timer when a
+       user initiated move/resize loop begins.
+
+       * unix/configure.in: TK_LD_SEARCH_FLAGS was set incorrectly if
+       SHLIB_LD_LIBS='${LIBS}', and shared linking is performed through
+       the C compiler. Systems affected are Linux, MP-RAS and NEXTSTEP,
+       but also with gcc on many more systems. [Bug: 908]
+
+       * win/makefile.vc: First stab at install target.  Fixed quoting so
+       paths with spaces work.
+       
+       * tests/main.test:
+       * tests/unixWm.test: Better cleanup of temporary files.
+       
+       * mac/tkMacAppInit.c:
+       * generic/tkTest.c:
+       * generic/tkAppInit.c:
+       * win/winMain.c: Changed some EXTERN declarations to extern
+       since they are not defining exported interfaces.  This avoids
+       generating useless declspec() attributes and makes the windows
+       makefile simpler.
+
+       * library/menu.tcl (tkMenuFind): Changed so keyboard shortcuts
+       will only be found in the current toplevel.  Previously, they
+       might be found in menus attached to other toplevels that might not
+       even be mapped. [Bug: 924]
+
+       * generic/tkCanvLine.c: Changed to treat zero width lines like
+       they have width 1 for purposes of selection. [Bug: 925]
+
+       * win/tkWinFont.c (Tk_MeasureChars): Added a workaround for a bug
+       in GetTextExtentExPoint on Win NT 4.0/Japanese. [Bug: 1006]
+
+       * unix/tkUnixSend.c (Tk_SetAppName): Fixed uninitialized memory
+       access bug. [Bug: 919]
+
+1999-1-28    <stanton@GASPODE>
+
+       * generic/tkGrid.c: Fixed bug in "grid forget" that failed to cancel
+       pending idle handlers, resulting in a crash in a few odd cases.
+
+1999-01-06  <lfb@JUSTICE>
+
+       * generic/tk.h, generic/tkGet.c, generic/tkConfig.c, 
+       * generic/tkOldConfig.c, generic/tkEntry.c, generic/tkMenubutton.c, 
+       * generic/tkMenubutton.h, generic/tkScale.c, generic/tkScale.h, 
+       * generic/tkTextDisplay.c, generic/tkText.c, unix/tkUnixMenubu.c, 
+       * unix/tkUnixScale.c, mac/tkMacMenu.c, mac/tkMacMenubutton.c, 
+       
+       Removed global Tk_Uids dealing with "-state" configuration option
+       and added new TK_CONFIG_STATE configSpec that doesn't use 
+       Tk_Uids.
+
+1998-12-11    === Tk 8.1b1 Release ===
+       
+1998-12-11    <stanton@GASPODE>
+
+       * generic/tkMain.c (Tk_Main): Fixed improper command line encoding
+       handling. 
+
+1998-12-08    <stanton@GASPODE>
+
+       * tkMacMenu.c, tkUnixMenu.c, tkWinMenu.c, tkMenuDraw.c, tkMenu.h,
+       * tkMenu.c: Backed out the previous fix for bug 620 and
+       eliminated a bunch of code that created unnecessary objects.
+       Changed back to using internal types instead of objects for many
+       configuration options.  There are many more fixes like this that
+       could be made, but some require a little restructuring of the
+       code. In any case the leaks are fixed and there is a lot less
+       allocation happening. [Bug: 620]
+       
+2000-03-21  Syd Polk  <spolk@cygnus.com>
+
+       * configure.in: Compare to cygwin, not cygwin32.
+       * configure: Regenerate.
+
+1999-05-24  Syd Polk  <spolk@cygnus.com>
+
+       * generic/tkArgv.c: Updated version string.
+
+1999-04-22  Syd Polk  <spolk@cygnus.com>
+
+       * unix/Makefile.in: Don't install tk.h for install-libraries.
+
+1999-03-19  Khamis Abuelkomboz  <khamis@cygnus.com>
+       
+       * library/tkfbox.tcl (tkFDialog_OkCmd): Bug fix for double-click on
+       a directory when multiple-mode is turned on, double-clicking a
+       directory didn't switch to that directory.
+
+1999-03-19  Khamis Abuelkomboz  <khamis@cygnus.com>
+
+       * win/tkWinDialog.c (GetFileName): set the multi flag to the boolean
+       value it was given to turn multi-selection on/off.
+
+       * library/tkfbox.tcl (tkFDialog): mask list of selected files using the
+       list command only when the string isn't empty to avoid getting "{}"
+       in the entry box.
+
+1999-03-19  Khamis Abuelkomboz  <khamis@cygnus.com>
+
+       * library/tkfbox.tcl (tkFDialog): Corrected reference to not valid
+       variable name.
+
+       * win/tkWinDialog.c (GetFileName): set the multi flag to the boolean
+        value it was given to turn multi-selection on/off.
+
+1999-03-18  Syd Polk  <spolk@cygnus.com>
+
+       * library/tkfbox.txl (tkFDialog): Fix a reference to an unknown
+       variable $text.
+
+1999-03-18  Khamis Abuelkomboz  <khamis@cygnus.com>
+
+       * win/tkWinDialog.c (GetFileName): When only one file is selected and
+       multi selection is enabled, add the file using tcl_AppendElement to the
+       result to get a list of files (here with only one file). This makes
+        the functionality consistent to  the case when multiple files are
+        selected. This has produced a bug when only one file is selected that
+       contains spaces.
+
+       * library/tkfbox.tcl (tkFDialog): mask a file containing spaces using
+       the list command when -multipl flag is set to yes.
+       (tkFDialog_ListBrowse): likewise.
+
+1999-03-03  Syd Polk  <spolk@cygnus.com>
+
+       * generic/tkText.c (TextSearchCmd): Was incorrectly returning
+       number of bytes instead of number of characters in search subcommand.
+
+1999-03-04  Syd Polk  <spolk@cygnus.com>
+
+       * win/tkWinMenu.c: Fixed compile error introduced by merge
+       of 1999-03-02.
+
+1999-02-28  Ian Roxborough  <irox@cygnus.com>
+
+       * win/tkWin3d(Tk_3DHorizontalBevel,Tk_3DVerticalBevel):
+       Draw sunken 3D effect the same as Window95/98/NT.
+       * win/tkWinButton: Decrease this minimum button high
+       for a better Windowz look and feel.
+       * win/tkWinDefault.h: Increase default button y padding.
+
+1999-02-22  Syd Polk  <spolk@cygnus.com>
+
+       * win/configure.in: Fix TK_LIB_FULL_PATH for cygwin build.
+       * win/configure: Regenerate.
+
+1999-02-18  Syd Polk  <spolk@cygnus.com>
+
+       * win/configure.in: Set TK_SRC_DIR and export it.
+       Set TK_LIB_FULL_PATH and export it.
+       * win/configure: Regenerate.
+
+1999-02-09  Syd Polk  <spolk@cygnus.com>
+
+       * unix/configure.in: Export TK_LIB_FULL_PATH so that dependency
+       tracking can be done.
+       Use TCL_LIB_FULL_PATH to track dependencies.
        * unix/configure: Regenerate.
+       * unix/tkConfig.sh.in: Export TK_LIB_FULL_PATH so that dependecy
+       tracking can be done.
+       * unix/Makefile.in: Add dependency for TCL_LIB_FULL_PATH.
+
+1998-12-31  Syd Polk  <spolk@cygnus.com>
+
+        * generic/tkFont.c (Tk_UnderlineTextLayout):
+       Don't draw an underline if underline value is
+       -1.
+
+1998-12-30  Syd Polk  <spolk@cygnus.com>
+
+       * generic/tkFont.c (Tk_UnderlineTextLayout):
+       Tk_CharBBox needs a byte offset, not a character
+       offset.
+
+1998-12-17  Syd Polk  <spolk@cygnus.com>
+
+        * win/tkWinMenu.c: (TkWinMenuHandleEvent): WM_MENUCHAR
+        needs to index characters, not bytes, when handling the
+        underline character.
+
+1998-12-11  Syd Polk  <spolk@cygnus.com>
+
+       * generic/tkMain.c (Tk_Main): All arguments except the filename
+       on the command-line were not being translated to UTF.
+
+1998-12-10  Ian Roxborough  <irox@cygnus.com>
+
+       * win/tkWinDialog.c (GetFileName): Increased the buffer size in the
+       file select dialog so that there is less change of it filling up
+       if the user selects a lot of files.
 
-1999-01-29  James Ingham  <jingham@cygnus.com>
+1998-12-04  Syd Polk  <spolk@cygnus.com>
 
-       * win/configure.in: Fill in the XINCLUDE symbol.
-       * win/configure: regenerate.
+       * win/tkWinClipboard.c: The clipboard was not translating to
+       and from the Windows character set.
 
-Mon Jan 11 10:57:05 1999  Jim Ingham  <jingham@cygnus.com>
+1998-12-03  Ian Roxborough  <irox@cygnus.com>
 
-       * win/tkTextDisp.c (tkTextSeeCmd): This is only a workaround for 
-        a bug somewhere in Tk.  If you change the font for the gdbtk
-        debug window the see command that follows the report of the 
-       destruction of the preferences window will return a NULL from 
-       FindDLine.  This should not happen, but I can't find a simple
-        case that shows the behavior, and have not taken the time to 
-       chase it all the way down.  This fix makes the error harmless.
+       * win/tkWinInit.c: Merged in changes from WishCon.
+       * win/tkMain.c: Merged in changes from WishCon.
 
-Thu Dec 17 10:43:53 1998  Jim Ingham  <jingham@cygnus.com>
+1998-11-18  Syd Polk  <spolk@cygnus.com>
+       * generic/tkMenu.c (ConfigureMenuCloneEntries): The parameter for
+       the configure command when reconfiguring entries for a clone menu
+       should have been "-menu", not "menu".
 
-        * win/tkWinFont.c (Tk_MeasureChar): Add dummy max argument and
-        bogus (infinte) maxLength to second call to
-        GetTextExtentExPoint to work around a bug in NT/J 4.0 service
-        pack 3 or less.
+1998-11-19  Ben Elliston  <bje@cygnus.com>
 
-Thu Dec  3 12:34:18 1998 Jim Ingham    jingham@cygnus.com
+       * win/tkWinWm.c: Local grabs did not exclude menus or the caption
+       bar. `wm frame' would crash if the window had not been mapped yet.
+       Patch obtained from the Scriptics CVS repository.
 
-        * library/tkfbox.tcl (tkIconListInvoke): Fixed a merge goof 
-       that was preventing double-clicking in the file dialog from
-       working.
+       * win/tkWinWindow.c: Reduce message traffic by setting
+       WS_EX_NOPARENTNOTIFY on TkChild windows. Patch obtained from the
+       Scriptics CVS repository.
 
-Tue Nov 24 18:27:40 1998 Jim Ingham    jingham@cygnus.com
+1998-11-13  Khamis Abuelkomboz  <khamis@cygnus.com>
 
-        * Import of Tk 8.0.4 from Scriptics.
+       * generic/tkMenu.c (MenuWidgetObjCmd): added patch for selection
+       problem. Disabled menu entries remain disabled.
+       (DestroyMenuEntry): added patch for memory leak.
 
-Thu Aug 20 14:32:59 1998  Jim Ingham    jingham@cygnus.com
+1998-11-11  Syd Polk  <spolk@cygnus.com>
 
-       * Import of Tk 8.0.3 from Scriptics, with our modifications.
+       * win/tkWinMenu.c: Merged from latest tcl8.1 source.
 
-Thu Aug 20 18:14:43 1998  Khamis Abuelkomboz  <khamis@cygnus.com>
+1998-11-06  Ian Roxborough  <irox@cygnus.com>
 
-       * win/tkWinDialog.c: Enlarged the file dialog buffer to include more
-       files that the magic (14 files) limit.
+       * win/tkWinDialog.c (GetFileName): Add support for --multiple to
+       tk_getOpenFile.
 
-Wed Aug 12 18:24:45 1998  Ian Lance Taylor  <ian@cygnus.com>
+1998-11-06  Syd Polk  <spolk@cygnus.com>
 
-       * win/Makefile.in (TK_CFLAGS): Remove $(include32).
+       * win/tkWinMenu.c (GetEntryText): Fixed menubars and system 
+       menu character set problems.
+       * win/tkWinWm.c: Fixed title bar text character set problems.
 
-Fri Jul 31 14:37:29 1998  Ian Roxborough  <irox@cygnus.com>
+1998-10-28  Syd Polk  <spolk@cygnus.com>
 
-       * win/Makefile.in: add tkTextCharType symbol to tkcyg.def require by SN.
+       * win/Makefile.in: Remove prolog.ps from install
 
-Mon Jul 22 15:44:19 1998  Ian Roxborough  <irox@cygnus.com>
+1998-10-26  Syd Polk  <spolk@cygnus.com>
 
-       * win/Makefile.in: add some symbols to tkcyg.def require by SN.
+       * win/Makefile.in: Change tcl directory.
+       * win/configure.in: XINCLUDES needs be generated correctly.
+       * win/configure: Regenerated.
 
-Mon Jul 13 14:12:39 1998  Jeff Holcomb  <jeffh@cygnus.com>
+1998-10-23  Ben Elliston  <bje@cygnus.com>
 
-       * win/tkWinX.c: Removed temporary define for MNC_CLOSE.
+       * generic/tkFont.c (Tk_UnderlineChars): Count multibyte characters
+       correctly when underlining. Contributed by Scott Stanton
+       <stanton@scriptics.com>.
+
+1998-10-20  Syd Polk  <spolk@cygnus.com>
+
+       * unix/configure.in: Work with tcl8.1 directory name
+       * unix/configure: Regenerated
+       
+1998-10-04  Syd Polk  <spolk@cygnus.com>
+
+       * win/Makefile.in: Somehow this ended up on the main branch.
+
+1998-10-14  Syd Polk  <spolk@cygnus.com>
+
+       * win/Makefile.in configure.in: More work for tk 8.1 build.
+       * win/configure: Regenerated
+       * win/tkWinDialog.c: Added dummy -multiple option. irox will re-implement
+       this soon.
+
+1998-09-29  Syd Polk  <spolk@cygnus.com>
+
+       * win/configure.in: Generate the correct version number
+       * win/configure: Regenerated.
+       * win/Makefile.in: Now compiles for Visual C++.
+       * win/tkWinFont.c win/TkWinInt.h win/TkWinWm.c: Removed changing
+       font map when system changes. 8.1 is eventually supposed to support
+       this and the font package changed dramatically. The changes were
+       not easy to bring forward, so we will have to do something if
+       Tk 8.1 does not support this.
+
+1998-09-29  Syd Polk  <spolk@cygnus.com>
+
+       * win/configure.in: Merged from devo
+       * win/configure: Regenerated.
+
+1998-09-28  Syd Polk  <spolk@cygnus.com>
+
+       * win/Makefile.in: Fixes for OBJEXT; removed hard-coded 80
+       references; added new tk files for 8.1.
+
+Wed Aug 19 17:48:00 PDT 1998  Syd Polk  <spolk@cygnus.com>
+
+       * Continued 8.1 integration
 
 Mon Jul  6 18:13:02 1998  Martin M. Hunt  <hunt@cygnus.com>
 
@@ -883,7 +3706,7 @@ Sun Aug 20 00:15:51 1995  Jason Molenda  (crash@phydeaux.cygnus.com)
        conflict with the one in the new tcl/tclBasic.c.
 
 Mon Jun 12 17:09:28 1995  Stu Grossman  (grossman@cygnus.com)
-
+       
        * configure:  Ignore --cache-file option instead of bombing out.
 
 Mon Dec 12 12:17:16 1994  Stu Grossman  (grossman@cygnus.com)
index f60a117..839b4dd 100755 (executable)
@@ -28,6 +28,7 @@ program_suffix=NONE
 program_transform_name=s,x,x,
 silent=
 site=
+sitefile=
 srcdir=
 target=NONE
 verbose=
@@ -142,6 +143,7 @@ Configuration:
   --help                  print this message
   --no-create             do not create output files
   --quiet, --silent       do not print \`checking...' messages
+  --site-file=FILE        use FILE as the site file
   --version               print the version of autoconf that created configure
 Directory and file names:
   --prefix=PREFIX         install architecture-independent files in PREFIX
@@ -312,6 +314,11 @@ EOF
   -site=* | --site=* | --sit=*)
     site="$ac_optarg" ;;
 
+  -site-file | --site-file | --site-fil | --site-fi | --site-f)
+    ac_prev=sitefile ;;
+  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
+    sitefile="$ac_optarg" ;;
+
   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
     ac_prev=srcdir ;;
   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -477,12 +484,16 @@ fi
 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
 
 # Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
-  if test "x$prefix" != xNONE; then
-    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-  else
-    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+if test -z "$sitefile"; then
+  if test -z "$CONFIG_SITE"; then
+    if test "x$prefix" != xNONE; then
+      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+    else
+      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+    fi
   fi
+else
+  CONFIG_SITE="$sitefile"
 fi
 for ac_site_file in $CONFIG_SITE; do
   if test -r "$ac_site_file"; then
@@ -548,7 +559,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
 fi
 
 echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:552: checking host system type" >&5
+echo "configure:563: checking host system type" >&5
 
 host_alias=$host
 case "$host_alias" in
@@ -570,7 +581,7 @@ echo "$ac_t""$host" 1>&6
 
 
 case "${host}" in
-*-*-cygwin* | *-*-mingw32*)
+*cygwin* | *mingw32* | *windows32*)
        CONFIGDIR="win"
        
        ;;
@@ -600,7 +611,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
 esac
 
 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:604: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:615: checking whether ${MAKE-make} sets \${MAKE}" >&5
 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -788,7 +799,7 @@ cat >> $CONFIG_STATUS <<\EOF
 
 # Split the substitutions into bite-sized pieces for seds with
 # small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
+ac_max_sed_cmds=60 # Maximum number of lines to put in a sed script.
 ac_file=1 # Number of current file.
 ac_beg=1 # First line for current file.
 ac_end=$ac_max_sed_cmds # Line after last line for current file.
index eff419d..f3f4dbf 100755 (executable)
@@ -12,13 +12,21 @@ ac_help=
 ac_default_prefix=/usr/local
 # Any additions from configure.in:
 ac_help="$ac_help
-  --enable-gcc            allow use of gcc if available"
+  --enable-threads        build with threads"
 ac_help="$ac_help
-  --with-tcl=DIR          use Tcl 8.0 binaries from DIR"
+  --with-tcl              directory containing tcl configuration (tclConfig.sh)"
+ac_help="$ac_help
+  --enable-64bit          enable 64bit support (where applicable)"
+ac_help="$ac_help
+  --enable-64bit-vis      enable 64bit Sparc VIS support"
+ac_help="$ac_help
+  --disable-load          disallow dynamic loading and "load" command"
+ac_help="$ac_help
+  --enable-symbols        build with debugging symbols [--disable-symbols]"
 ac_help="$ac_help
   --with-x                use the X Window System"
 ac_help="$ac_help
-  --enable-shared         build libtk as a shared library"
+  --enable-shared         build and link with shared libraries [--enable-shared]"
 
 # Initialize some variables set by options.
 # The variables have the same names as the options, with
@@ -540,121 +548,86 @@ else
 fi
 
 
-# SCCS: @(#) configure.in 1.90 97/11/20 12:45:45
-
-# CYGNUS LOCAL tromey - find config.guess/config.sub in our tree
-ac_aux_dir=
-for ac_dir in $srcdir/../.. $srcdir/$srcdir/../..; do
-  if test -f $ac_dir/install-sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f $ac_dir/install.sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { echo "configure: error: can not find install-sh or install.sh in $srcdir/../.. $srcdir/$srcdir/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
-
-# Do some error checking and defaulting for the host and target type.
-# The inputs are:
-#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
-#
-# The rules are:
-# 1. You are not allowed to specify --host, --target, and nonopt at the
-#    same time.
-# 2. Host defaults to nonopt.
-# 3. If nonopt is not specified, then host defaults to the current host,
-#    as determined by config.guess.
-# 4. Target and build default to nonopt.
-# 5. If nonopt is not specified, then target and build default to host.
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-case $host---$target---$nonopt in
-NONE---*---* | *---NONE---* | *---*---NONE) ;;
-*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
-esac
+# RCS: @(#) $Id$
 
+TK_VERSION=8.3
+TK_MAJOR_VERSION=8
+TK_MINOR_VERSION=3
+TK_PATCH_LEVEL=".2"
+VERSION=${TK_VERSION}
 
-# Make sure we can run config.sub.
-if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
-else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
+if test "${prefix}" = "NONE"; then
+    prefix=/usr/local
 fi
+if test "${exec_prefix}" = "NONE"; then
+    exec_prefix=$prefix
+fi
+# Make sure srcdir is fully qualified!
+srcdir=`cd $srcdir ; pwd`
 
-echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:594: checking host system type" >&5
-
-host_alias=$host
-case "$host_alias" in
-NONE)
-  case $nonopt in
-  NONE)
-    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
-    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
-    fi ;;
-  *) host_alias=$nonopt ;;
-  esac ;;
-esac
+  val="`cd $srcdir/..; pwd`"
 
-host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
-host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$host" 1>&6
-
-echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:615: checking target system type" >&5
-
-target_alias=$target
-case "$target_alias" in
-NONE)
-  case $nonopt in
-  NONE) target_alias=$host_alias ;;
-  *) target_alias=$nonopt ;;
-  esac ;;
-esac
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_SRC_DIR" 1>&2; exit 1; }
+  fi
 
-target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
-target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$target" 1>&6
-
-echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:633: checking build system type" >&5
-
-build_alias=$build
-case "$build_alias" in
-NONE)
-  case $nonopt in
-  NONE) build_alias=$host_alias ;;
-  *) build_alias=$nonopt ;;
-  esac ;;
-esac
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_SRC_DIR=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_SRC_DIR="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_SRC_DIR=$val
+    ;;
+  esac
 
-build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
-build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$build" 1>&6
 
-test "$host_alias" != "$target_alias" &&
-  test "$program_prefix$program_suffix$program_transform_name" = \
-    NONENONEs,x,x, &&
-  program_prefix=${target_alias}-
+# Extract the first word of "ranlib", so it can be a program name with args.
+set dummy ranlib; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:601: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$RANLIB"; then
+  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_RANLIB="ranlib"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
+fi
+fi
+RANLIB="$ac_cv_prog_RANLIB"
+if test -n "$RANLIB"; then
+  echo "$ac_t""$RANLIB" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
 
 # Extract the first word of "gcc", so it can be a program name with args.
 set dummy gcc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:658: checking for $ac_word" >&5
+echo "configure:631: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -684,7 +657,7 @@ if test -z "$CC"; then
   # Extract the first word of "cc", so it can be a program name with args.
 set dummy cc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:688: checking for $ac_word" >&5
+echo "configure:661: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -735,7 +708,7 @@ fi
       # Extract the first word of "cl", so it can be a program name with args.
 set dummy cl; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:739: checking for $ac_word" >&5
+echo "configure:712: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -767,7 +740,7 @@ fi
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:771: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:744: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -778,12 +751,12 @@ cross_compiling=$ac_cv_prog_cc_cross
 
 cat > conftest.$ac_ext << EOF
 
-#line 782 "configure"
+#line 755 "configure"
 #include "confdefs.h"
 
 main(){return(0);}
 EOF
-if { (eval echo configure:787: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   ac_cv_prog_cc_works=yes
   # If we can't run a trivial program, we are probably using a cross compiler.
   if (./conftest; exit) 2>/dev/null; then
@@ -809,12 +782,12 @@ if test $ac_cv_prog_cc_works = no; then
   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
 fi
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:813: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:786: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
 cross_compiling=$ac_cv_prog_cc_cross
 
 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:818: checking whether we are using GNU C" >&5
+echo "configure:791: checking whether we are using GNU C" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -823,7 +796,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:827: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:800: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
   ac_cv_prog_gcc=yes
 else
   ac_cv_prog_gcc=no
@@ -842,7 +815,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
 ac_save_CFLAGS="$CFLAGS"
 CFLAGS=
 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:846: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:819: checking whether ${CC-cc} accepts -g" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -873,539 +846,1734 @@ else
   fi
 fi
 
-# Find a good install program.  We prefer a C program (faster),
-# so one script is as good as another.  But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# ./install, which can be erroneously created by make from ./install.sh.
-echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:889: checking for a BSD compatible install" >&5
-if test -z "$INSTALL"; then
-if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
+
+echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
+echo "configure:852: checking how to run the C preprocessor" >&5
+# On Suns, sometimes $CPP names a directory.
+if test -n "$CPP" && test -d "$CPP"; then
+  CPP=
+fi
+if test -z "$CPP"; then
+if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-    IFS="${IFS=        }"; ac_save_IFS="$IFS"; IFS=":"
-  for ac_dir in $PATH; do
-    # Account for people who put trailing slashes in PATH elements.
-    case "$ac_dir/" in
-    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
-    *)
-      # OSF1 and SCO ODT 3.0 have their own names for install.
-      # Don't use installbsd from OSF since it installs stuff as root
-      # by default.
-      for ac_prog in ginstall scoinst install; do
-        if test -f $ac_dir/$ac_prog; then
-         if test $ac_prog = install &&
-            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
-           # AIX install.  It has an incompatible calling convention.
-           :
-         else
-           ac_cv_path_install="$ac_dir/$ac_prog -c"
-           break 2
-         fi
-       fi
-      done
-      ;;
-    esac
-  done
-  IFS="$ac_save_IFS"
-
+    # This must be in double quotes, not single quotes, because CPP may get
+  # substituted into the Makefile and "${CC-cc}" will confuse make.
+  CPP="${CC-cc} -E"
+  # On the NeXT, cc -E runs the code through the compiler's parser,
+  # not just through cpp.
+  cat > conftest.$ac_ext <<EOF
+#line 867 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:873: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP="${CC-cc} -E -traditional-cpp"
+  cat > conftest.$ac_ext <<EOF
+#line 884 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:890: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP="${CC-cc} -nologo -E"
+  cat > conftest.$ac_ext <<EOF
+#line 901 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:907: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP=/lib/cpp
 fi
-  if test "${ac_cv_path_install+set}" = set; then
-    INSTALL="$ac_cv_path_install"
-  else
-    # As a last resort, use the slow shell script.  We don't cache a
-    # path for INSTALL within a source directory, because that will
-    # break other packages using the cache if that directory is
-    # removed, or if the path is relative.
-    INSTALL="$ac_install_sh"
-  fi
+rm -f conftest*
 fi
-echo "$ac_t""$INSTALL" 1>&6
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-# END CYGNUS LOCAL
-
-TK_VERSION=8.0
-TK_MAJOR_VERSION=8
-TK_MINOR_VERSION=0
-TK_PATCH_LEVEL=".4"
-VERSION=${TK_VERSION}
-
-if test "${prefix}" = "NONE"; then
-    prefix=/usr/local
+rm -f conftest*
 fi
-if test "${exec_prefix}" = "NONE"; then
-    exec_prefix=$prefix
+rm -f conftest*
+  ac_cv_prog_CPP="$CPP"
+fi
+  CPP="$ac_cv_prog_CPP"
+else
+  ac_cv_prog_CPP="$CPP"
 fi
-TK_SRC_DIR=`cd $srcdir/..; pwd`
+echo "$ac_t""$CPP" 1>&6
 
-# Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:960: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
+for ac_hdr in unistd.h limits.h
+do
+ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+echo "configure:935: checking for $ac_hdr" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-  if test -n "$RANLIB"; then
-  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
+  cat > conftest.$ac_ext <<EOF
+#line 940 "configure"
+#include "confdefs.h"
+#include <$ac_hdr>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:945: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=yes"
 else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_RANLIB="ranlib"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
-  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=no"
 fi
+rm -f conftest*
 fi
-RANLIB="$ac_cv_prog_RANLIB"
-if test -n "$RANLIB"; then
-  echo "$ac_t""$RANLIB" 1>&6
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_hdr 1
+EOF
 else
   echo "$ac_t""no" 1>&6
 fi
+done
+
+
+#------------------------------------------------------------------------
+# Threads support
+#------------------------------------------------------------------------
+
 
-# Check whether --enable-gcc or --disable-gcc was given.
-if test "${enable_gcc+set}" = set; then
-  enableval="$enable_gcc"
-  tk_ok=$enableval
+    echo $ac_n "checking for building with threads""... $ac_c" 1>&6
+echo "configure:978: checking for building with threads" >&5
+    # Check whether --enable-threads or --disable-threads was given.
+if test "${enable_threads+set}" = set; then
+  enableval="$enable_threads"
+  tcl_ok=$enableval
 else
-  tkl_ok=no
+  tcl_ok=no
 fi
 
-if test "$tk_ok" = "yes"; then
-    # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:999: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+
+    if test "$tcl_ok" = "yes"; then
+       echo "$ac_t""yes" 1>&6
+       TCL_THREADS=1
+       cat >> confdefs.h <<\EOF
+#define TCL_THREADS 1
+EOF
+
+       cat >> confdefs.h <<\EOF
+#define _REENTRANT 1
+EOF
+
+       cat >> confdefs.h <<\EOF
+#define _THREAD_SAFE 1
+EOF
+
+       echo $ac_n "checking for pthread_mutex_init in -lpthread""... $ac_c" 1>&6
+echo "configure:1004: checking for pthread_mutex_init in -lpthread" >&5
+ac_lib_var=`echo pthread'_'pthread_mutex_init | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
+  ac_save_LIBS="$LIBS"
+LIBS="-lpthread  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 1012 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char pthread_mutex_init();
+
+int main() {
+pthread_mutex_init()
+; return 0; }
+EOF
+if { (eval echo configure:1023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
 else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_CC="gcc"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
 fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
 fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  tcl_ok=yes
 else
   echo "$ac_t""no" 1>&6
-fi
-
-if test -z "$CC"; then
-  # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1029: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+tcl_ok=no
+fi
+
+       if test "$tcl_ok" = "no"; then
+           # Check a little harder for __pthread_mutex_init in the same
+           # library, as some systems hide it there until pthread.h is
+           # defined.  We could alternatively do an AC_TRY_COMPILE with
+           # pthread.h, but that will work with libpthread really doesn't
+           # exist, like AIX 4.2.  [Bug: 4359]
+           echo $ac_n "checking for __pthread_mutex_init in -lpthread""... $ac_c" 1>&6
+echo "configure:1051: checking for __pthread_mutex_init in -lpthread" >&5
+ac_lib_var=`echo pthread'_'__pthread_mutex_init | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
+  ac_save_LIBS="$LIBS"
+LIBS="-lpthread  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 1059 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char __pthread_mutex_init();
+
+int main() {
+__pthread_mutex_init()
+; return 0; }
+EOF
+if { (eval echo configure:1070: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  tcl_ok=yes
+else
+  echo "$ac_t""no" 1>&6
+tcl_ok=no
+fi
+
+       fi
+
+       if test "$tcl_ok" = "yes"; then
+           # The space is needed
+           THREADS_LIBS=" -lpthread"
+       else
+           echo $ac_n "checking for pthread_mutex_init in -lpthreads""... $ac_c" 1>&6
+echo "configure:1098: checking for pthread_mutex_init in -lpthreads" >&5
+ac_lib_var=`echo pthreads'_'pthread_mutex_init | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lpthreads  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 1106 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char pthread_mutex_init();
+
+int main() {
+pthread_mutex_init()
+; return 0; }
+EOF
+if { (eval echo configure:1117: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  tcl_ok=yes
+else
+  echo "$ac_t""no" 1>&6
+tcl_ok=no
+fi
+
+           if test "$tcl_ok" = "yes"; then
+               # The space is needed
+               THREADS_LIBS=" -lpthreads"
+           else
+               echo $ac_n "checking for pthread_mutex_init in -lc""... $ac_c" 1>&6
+echo "configure:1143: checking for pthread_mutex_init in -lc" >&5
+ac_lib_var=`echo c'_'pthread_mutex_init | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lc  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 1151 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char pthread_mutex_init();
+
+int main() {
+pthread_mutex_init()
+; return 0; }
+EOF
+if { (eval echo configure:1162: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  tcl_ok=yes
+else
+  echo "$ac_t""no" 1>&6
+tcl_ok=no
+fi
+
+               if test "$tcl_ok" = "no"; then
+                   TCL_THREADS=0
+                   echo "configure: warning: "Don t know how to find pthread lib on your system - you must disable thread support or edit the LIBS in the Makefile..."" 1>&2
+               fi
+           fi
+       fi
+
+       # Does the pthread-implementation provide
+       # 'pthread_attr_setstacksize' ?
+
+       for ac_func in pthread_attr_setstacksize
+do
+echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
+echo "configure:1196: checking for $ac_func" >&5
+if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1201 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char $ac_func();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+$ac_func();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:1224: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_func 1
+EOF
+else
+  echo "$ac_t""no" 1>&6
+fi
+done
+
+    else
+       TCL_THREADS=0
+       echo "$ac_t""no (default)" 1>&6
+    fi
+
+
+#------------------------------------------------------------------------------
+# If we're using GCC, see if the compiler understands -pipe.  If so, use it.
+# It makes compiling go faster.  (This is only a performance feature.)
+#------------------------------------------------------------------------------
+
+if test -z "$no_pipe"; then
+if test -n "$GCC"; then
+  echo $ac_n "checking if the compiler understands -pipe""... $ac_c" 1>&6
+echo "configure:1262: checking if the compiler understands -pipe" >&5
+  OLDCC="$CC"  
+  CC="$CC -pipe"
+  cat > conftest.$ac_ext <<EOF
+#line 1266 "configure"
+#include "confdefs.h"
+
+int main() {
+
+; return 0; }
+EOF
+if { (eval echo configure:1273: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  echo "$ac_t""yes" 1>&6
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CC="$OLDCC"
+    echo "$ac_t""no" 1>&6
+fi
+rm -f conftest*
+fi  
+fi
+
+#--------------------------------------------------------------------
+# Find and load the tclConfig.sh file
+#--------------------------------------------------------------------
+
+
+    #
+    # Ok, lets find the tcl configuration
+    # First, look for one uninstalled.
+    # the alternative search directory is invoked by --with-tcl
+    #
+
+    if test x"${no_tcl}" = x ; then
+       # we reset no_tcl in case something fails here
+       no_tcl=true
+       # Check whether --with-tcl or --without-tcl was given.
+if test "${with_tcl+set}" = set; then
+  withval="$with_tcl"
+  with_tclconfig=${withval}
+fi
+
+       echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6
+echo "configure:1308: checking for Tcl configuration" >&5
+       if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+
+           # First check to see if --with-tclconfig was specified.
+           if test x"${with_tclconfig}" != x ; then
+               if test -f "${with_tclconfig}/tclConfig.sh" ; then
+                   ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
+               else
+                   { echo "configure: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" 1>&2; exit 1; }
+               fi
+           fi
+
+           # then check for a private Tcl installation
+           if test x"${ac_cv_c_tclconfig}" = x ; then
+               for i in \
+                       ../tcl \
+                       `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
+                       ../../tcl \
+                       `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
+                       ../../../tcl \
+                       `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
+                   if test -f "$i/unix/tclConfig.sh" ; then
+                       ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
+                       break
+                   fi
+                   if test -f "$i/win/tclConfig.sh" ; then
+                       ac_cv_c_tclconfig=`(cd $i/win; pwd)`
+                       break
+                   fi
+               done
+           fi
+
+           # check in a few common install locations
+           if test x"${ac_cv_c_tclconfig}" = x ; then
+               for i in `ls -d ${prefix}/lib 2>/dev/null` \
+                       `ls -d /usr/local/lib 2>/dev/null` ; do
+                   if test -f "$i/tclConfig.sh" ; then
+                       ac_cv_c_tclconfig=`(cd $i; pwd)`
+                       break
+                   fi
+               done
+           fi
+
+           # check in a few other private locations
+           if test x"${ac_cv_c_tclconfig}" = x ; then
+               for i in \
+                       ${srcdir}/../tcl \
+                       `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
+                   if test -f "$i/unix/tclConfig.sh" ; then
+                   ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
+                   break
+                   fi
+                   if test -f "$i/win/tclConfig.sh" ; then
+                   ac_cv_c_tclconfig=`(cd $i/win; pwd)`
+                   break
+                   fi
+               done
+           fi
+       
+fi
+
+
+       if test x"${ac_cv_c_tclconfig}" = x ; then
+           TCL_BIN_DIR="# no Tcl configs found"
+           { echo "configure: error: Can't find Tcl configuration definitions" 1>&2; exit 1; }
+           exit 0
+       else
+           no_tcl=
+           TCL_BIN_DIR=${ac_cv_c_tclconfig}
+           echo "$ac_t""found $TCL_BIN_DIR/tclConfig.sh" 1>&6
+       fi
+    fi
+
+
+    echo $ac_n "checking for existence of $TCL_BIN_DIR/tclConfig.sh""... $ac_c" 1>&6
+echo "configure:1386: checking for existence of $TCL_BIN_DIR/tclConfig.sh" >&5
+
+    if test -f "$TCL_BIN_DIR/tclConfig.sh" ; then
+        echo "$ac_t""loading" 1>&6
+       . $TCL_BIN_DIR/tclConfig.sh
+    else
+        echo "$ac_t""file not found" 1>&6
+    fi
+
+    #
+    # The eval is required to do the TCL_DBGX substitution in the
+    # TCL_LIB_FILE variable
+    #
+
+    eval TCL_LIB_FILE=${TCL_LIB_FILE}
+    eval TCL_LIB_FLAG=${TCL_LIB_FLAG}
+
+    
+    
+    
+
+
+#--------------------------------------------------------------------
+# Recompute the necessary flags to run the compiler
+#--------------------------------------------------------------------
+
+
+
+    # Step 0.a: Enable 64 bit support?
+
+    echo $ac_n "checking if 64bit support is requested""... $ac_c" 1>&6
+echo "configure:1417: checking if 64bit support is requested" >&5
+    # Check whether --enable-64bit or --disable-64bit was given.
+if test "${enable_64bit+set}" = set; then
+  enableval="$enable_64bit"
+  :
+else
+  enableval="no"
+fi
+
+
+    if test "$enableval" = "yes"; then
+       do64bit=yes
+    else
+       do64bit=no
+    fi
+    echo "$ac_t""$do64bit" 1>&6
+
+    # Step 0.b: Enable Solaris 64 bit VIS support?
+
+    echo $ac_n "checking if 64bit Sparc VIS support is requested""... $ac_c" 1>&6
+echo "configure:1437: checking if 64bit Sparc VIS support is requested" >&5
+    # Check whether --enable-64bit-vis or --disable-64bit-vis was given.
+if test "${enable_64bit_vis+set}" = set; then
+  enableval="$enable_64bit_vis"
+  :
+else
+  enableval="no"
+fi
+
+
+    if test "$enableval" = "yes"; then
+       # Force 64bit on with VIS
+       do64bit=yes
+       do64bitVIS=yes
+    else
+       do64bitVIS=no
+    fi
+    echo "$ac_t""$do64bitVIS" 1>&6
+
+    # Step 1: set the variable "system" to hold the name and version number
+    # for the system.  This can usually be done via the "uname" command, but
+    # there are a few systems, like Next, where this doesn't work.
+
+    echo $ac_n "checking system version (for dynamic loading)""... $ac_c" 1>&6
+echo "configure:1461: checking system version (for dynamic loading)" >&5
+    if test -f /usr/lib/NextStep/software_version; then
+       system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
+    else
+       system=`uname -s`-`uname -r`
+       if test "$?" -ne 0 ; then
+           echo "$ac_t""unknown (can't find uname command)" 1>&6
+           system=unknown
+       else
+           # Special check for weird MP-RAS system (uname returns weird
+           # results, and the version is kept in special file).
+       
+           if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
+               system=MP-RAS-`awk '{print }' /etc/.relid'`
+           fi
+           if test "`uname -s`" = "AIX" ; then
+               system=AIX-`uname -v`.`uname -r`
+           fi
+           echo "$ac_t""$system" 1>&6
+       fi
+    fi
+
+    echo $ac_n "checking if gcc is being used""... $ac_c" 1>&6
+echo "configure:1484: checking if gcc is being used" >&5
+    if test "$CC" = "gcc" -o `$CC -v 2>&1 | grep -c gcc` != "0" ; then
+       using_gcc="yes"
+    else
+       using_gcc="no"
+    fi
+
+    echo "$ac_t""$using_gcc ($CC)" 1>&6
+
+    # Step 2: check for existence of -ldl library.  This is needed because
+    # Linux can use either -ldl or -ldld for dynamic loading.
+
+    echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
+echo "configure:1497: checking for dlopen in -ldl" >&5
+ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-ldl  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 1505 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char dlopen();
+
+int main() {
+dlopen()
+; return 0; }
+EOF
+if { (eval echo configure:1516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  have_dl=yes
+else
+  echo "$ac_t""no" 1>&6
+have_dl=no
+fi
+
+
+    # Step 3: set configuration options based on system name and version.
+
+    do64bit_ok=no
+    fullSrcDir=`cd $srcdir; pwd`
+    EXTRA_CFLAGS=""
+    TCL_EXPORT_FILE_SUFFIX=""
+    UNSHARED_LIB_SUFFIX=""
+    TCL_TRIM_DOTS='`echo ${VERSION} | tr -d .`'
+    ECHO_VERSION='`echo ${VERSION}`'
+    TCL_LIB_VERSIONS_OK=ok
+    CFLAGS_DEBUG=-g
+    CFLAGS_OPTIMIZE=-O
+    if test "$using_gcc" = "yes" ; then
+       CFLAGS_WARNING="-Wall -Wconversion -Wno-implicit-int"
+    else
+       CFLAGS_WARNING=""
+    fi
+    TCL_NEEDS_EXP_FILE=0
+    TCL_BUILD_EXP_FILE=""
+    TCL_EXP_FILE=""
+    # Extract the first word of "ar", so it can be a program name with args.
+set dummy ar; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1561: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$AR"; then
+  ac_cv_prog_AR="$AR" # Let the user override the test.
 else
   IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_prog_rejected=no
   ac_dummy="$PATH"
   for ac_dir in $ac_dummy; do
     test -z "$ac_dir" && ac_dir=.
     if test -f $ac_dir/$ac_word; then
-      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
-        ac_prog_rejected=yes
-       continue
-      fi
-      ac_cv_prog_CC="cc"
+      ac_cv_prog_AR="ar"
       break
     fi
   done
   IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
-  # We found a bogon in the path, so make sure we never use it.
-  set dummy $ac_cv_prog_CC
-  shift
-  if test $# -gt 0; then
-    # We chose a different compiler from the bogus one.
-    # However, it has the same basename, so the bogon will be chosen
-    # first if we set CC to just the basename; use the full file name.
-    shift
-    set dummy "$ac_dir/$ac_word" "$@"
-    shift
-    ac_cv_prog_CC="$@"
-  fi
 fi
 fi
+AR="$ac_cv_prog_AR"
+if test -n "$AR"; then
+  echo "$ac_t""$AR" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+    STLIB_LD='${AR} cr'
+    case $system in
+       AIX-4.[2-9])
+           if test "${TCL_THREADS}" = "1" -a "$using_gcc" = "no" ; then
+               # AIX requires the _r compiler when gcc isn't being used
+               if test "${CC}" != "cc_r" ; then
+                   CC=${CC}_r
+               fi
+               echo "$ac_t""Using $CC for compiling with threads" 1>&6
+           fi
+           SHLIB_CFLAGS=""
+           SHLIB_LD="$fullSrcDir/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS=""
+           LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
+           TCL_NEEDS_EXP_FILE=1
+           TCL_EXPORT_FILE_SUFFIX='${VERSION}\$\{DBGX\}.exp'
+           ;;
+       AIX-*)
+           if test "${TCL_THREADS}" = "1" -a "$using_gcc" = "no" ; then
+               # AIX requires the _r compiler when gcc isn't being used
+               if test "${CC}" != "cc_r" ; then
+                   CC=${CC}_r
+               fi
+               echo "$ac_t""Using $CC for compiling with threads" 1>&6
+           fi
+           SHLIB_CFLAGS=""
+           SHLIB_LD="$fullSrcDir/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           LIBOBJS="$LIBOBJS tclLoadAix.o"
+           DL_LIBS="-lld"
+           LDFLAGS=""
+           LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
+           TCL_NEEDS_EXP_FILE=1
+           TCL_EXPORT_FILE_SUFFIX='${VERSION}\$\{DBGX\}.exp'
+           ;;
+       BSD/OS-2.1*|BSD/OS-3*)
+           SHLIB_CFLAGS=""
+           SHLIB_LD="shlicc -r"
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS=""
+           LD_SEARCH_FLAGS=""
+           ;;
+       BSD/OS-4.*)
+           SHLIB_CFLAGS="-export-dynamic -fPIC"
+           SHLIB_LD="cc -shared"
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS="-export-dynamic"
+           LD_SEARCH_FLAGS=""
+           ;;
+       dgux*)
+           SHLIB_CFLAGS="-K PIC"
+           SHLIB_LD="cc -G"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS=""
+           LD_SEARCH_FLAGS=""
+           ;;
+       HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*|HP-UX-*.11.*)
+           SHLIB_SUFFIX=".sl"
+           echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
+echo "configure:1661: checking for shl_load in -ldld" >&5
+ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-ldld  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 1669 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char shl_load();
+
+int main() {
+shl_load()
+; return 0; }
+EOF
+if { (eval echo configure:1680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  tcl_ok=yes
+else
+  echo "$ac_t""no" 1>&6
+tcl_ok=no
+fi
+
+           if test "$tcl_ok" = yes; then
+               SHLIB_CFLAGS="+z"
+               SHLIB_LD="ld -b"
+               SHLIB_LD_LIBS=""
+               DL_OBJS="tclLoadShl.o"
+               DL_LIBS="-ldld"
+               LDFLAGS="-Wl,-E"
+               LD_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
+           fi
+           ;;
+       IRIX-4.*)
+           SHLIB_CFLAGS="-G 0"
+           SHLIB_SUFFIX=".a"
+           SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
+           SHLIB_LD_LIBS='${LIBS}'
+           DL_OBJS="tclLoadAout.o"
+           DL_LIBS=""
+           LDFLAGS="-Wl,-D,08000000"
+           LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
+           SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a'
+           ;;
+       IRIX-5.*|IRIX-6.*|IRIX64-6.5*)
+           SHLIB_CFLAGS=""
+           SHLIB_LD="ld -n32 -shared -rdata_shared"
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS=""
+           LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+           if test "$using_gcc" = "yes" ; then
+               EXTRA_CFLAGS="-mabi=n32"
+               LDFLAGS="-mabi=n32"
+           else
+               case $system in
+                   IRIX-6.3)
+                       # Use to build 6.2 compatible binaries on 6.3.
+                       EXTRA_CFLAGS="-n32 -D_OLD_TERMIOS"
+                       ;;
+                   *)
+                       EXTRA_CFLAGS="-n32"
+                       ;;
+               esac
+               LDFLAGS="-n32"
+           fi
+           ;;
+       IRIX64-6.*)
+           SHLIB_CFLAGS=""
+           SHLIB_LD="ld -32 -shared -rdata_shared"
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS=""
+           LDFLAGS=""
+           LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+           ;;
+       Linux*)
+           SHLIB_CFLAGS="-fPIC"
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+
+           # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings 
+           # when you inline the string and math operations.  Turn this off to
+           # get rid of the warnings.
+
+           CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
+
+           if test "$have_dl" = yes; then
+               SHLIB_LD="${CC} -shared"
+               DL_OBJS="tclLoadDl.o"
+               DL_LIBS="-ldl"
+               LDFLAGS="-rdynamic"
+               LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+           else
+               ac_safe=`echo "dld.h" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for dld.h""... $ac_c" 1>&6
+echo "configure:1776: checking for dld.h" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1781 "configure"
+#include "confdefs.h"
+#include <dld.h>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1786: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=yes"
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
 fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  
+                   SHLIB_LD="ld -shared"
+                   DL_OBJS="tclLoadDld.o"
+                   DL_LIBS="-ldld"
+                   LDFLAGS=""
+                   LD_SEARCH_FLAGS=""
 else
   echo "$ac_t""no" 1>&6
 fi
 
-  if test -z "$CC"; then
-    case "`uname -s`" in
-    *win32* | *WIN32*)
-      # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1080: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+           fi
+           if test "`uname -m`" = "alpha" ; then
+               EXTRA_CFLAGS="-mieee"
+           fi
+           ;;
+       MP-RAS-02*)
+           SHLIB_CFLAGS="-K PIC"
+           SHLIB_LD="cc -G"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS=""
+           LD_SEARCH_FLAGS=""
+           ;;
+       MP-RAS-*)
+           SHLIB_CFLAGS="-K PIC"
+           SHLIB_LD="cc -G"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS="-Wl,-Bexport"
+           LD_SEARCH_FLAGS=""
+           ;;
+       NetBSD-*|FreeBSD-[1-2].*|OpenBSD-*)
+           # Not available on all versions:  check for include file.
+           ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6
+echo "configure:1841: checking for dlfcn.h" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
+  cat > conftest.$ac_ext <<EOF
+#line 1846 "configure"
+#include "confdefs.h"
+#include <dlfcn.h>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1851: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=yes"
 else
-  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  ac_dummy="$PATH"
-  for ac_dir in $ac_dummy; do
-    test -z "$ac_dir" && ac_dir=.
-    if test -f $ac_dir/$ac_word; then
-      ac_cv_prog_CC="cl"
-      break
-    fi
-  done
-  IFS="$ac_save_ifs"
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=no"
 fi
+rm -f conftest*
 fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
-  echo "$ac_t""$CC" 1>&6
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  
+               # NetBSD/SPARC needs -fPIC, -fpic will not do.
+               SHLIB_CFLAGS="-fPIC"
+               SHLIB_LD="ld -Bshareable -x"
+               SHLIB_LD_LIBS=""
+               SHLIB_SUFFIX=".so"
+               DL_OBJS="tclLoadDl.o"
+               DL_LIBS=""
+               LDFLAGS=""
+               LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+               echo $ac_n "checking for ELF""... $ac_c" 1>&6
+echo "configure:1878: checking for ELF" >&5
+               cat > conftest.$ac_ext <<EOF
+#line 1880 "configure"
+#include "confdefs.h"
+
+#ifdef __ELF__
+       yes
+#endif
+               
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "yes" >/dev/null 2>&1; then
+  rm -rf conftest*
+  echo "$ac_t""yes" 1>&6
+                   SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
 else
+  rm -rf conftest*
   echo "$ac_t""no" 1>&6
+                   SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
+               
 fi
- ;;
-    esac
-  fi
-  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
+rm -f conftest*
+
+           
+else
+  echo "$ac_t""no" 1>&6
+
+               SHLIB_CFLAGS=""
+               SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r"
+               SHLIB_LD_LIBS='${LIBS}'
+               SHLIB_SUFFIX=".a"
+               DL_OBJS="tclLoadAout.o"
+               DL_LIBS=""
+               LDFLAGS=""
+               LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
+               SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
+           
 fi
 
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1112: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
+           # FreeBSD doesn't handle version numbers with dots.
 
-cat > conftest.$ac_ext << EOF
+           UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
+           TCL_LIB_VERSIONS_OK=nodots
+           ;;
+       FreeBSD-*)
+           # FreeBSD 3.* and greater have ELF.
+           SHLIB_CFLAGS="-fPIC"
+           SHLIB_LD="ld -Bshareable -x"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS=""
+           LDFLAGS="-export-dynamic"
+           LD_SEARCH_FLAGS=""
+           ;;
+       NEXTSTEP-*)
+           SHLIB_CFLAGS=""
+           SHLIB_LD="cc -nostdlib -r"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadNext.o"
+           DL_LIBS=""
+           LDFLAGS=""
+           LD_SEARCH_FLAGS=""
+           ;;
+       OS/390-*)
+           CFLAGS_OPTIMIZE=""      # Optimizer is buggy
+           cat >> confdefs.h <<\EOF
+#define _OE_SOCKETS 1
+EOF
+  # needed in sys/socket.h
+           ;;      
+       OSF1-1.0|OSF1-1.1|OSF1-1.2)
+           # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
+           SHLIB_CFLAGS=""
+           # Hack: make package name same as library name
+           SHLIB_LD='ld -R -export :'
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadOSF.o"
+           DL_LIBS=""
+           LDFLAGS=""
+           LD_SEARCH_FLAGS=""
+           ;;
+       OSF1-1.*)
+           # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2
+           SHLIB_CFLAGS="-fPIC"
+           SHLIB_LD="ld -shared"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS=""
+           LDFLAGS=""
+           LD_SEARCH_FLAGS=""
+           ;;
+       OSF1-V*)
+           # Digital OSF/1
+           SHLIB_CFLAGS=""
+           SHLIB_LD='ld -shared -expect_unresolved "*"'
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS=""
+           LDFLAGS=""
+           LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+           if test "$using_gcc" = "no" ; then
+               EXTRA_CFLAGS="-DHAVE_TZSET -std1"
+           fi
+           # see pthread_intro(3) for pthread support on osf1, k.furukawa
+           if test "${TCL_THREADS}" = "1" ; then
+               EXTRA_CFLAGS="${EXTRA_CFLAGS} -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
+               if test "$using_gcc" = "no" ; then
+                   EXTRA_CFLAGS="${EXTRA_CFLAGS} -pthread"
+                   LDFLAGS="-pthread"
+               else
+                   LIBS=`echo $LIBS | sed s/-lpthreads//`
+                   LIBS="$LIBS -lpthread -lmach -lexc"
+               fi
+           fi
 
-#line 1123 "configure"
+           ;;
+       RISCos-*)
+           SHLIB_CFLAGS="-G 0"
+           SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".a"
+           DL_OBJS="tclLoadAout.o"
+           DL_LIBS=""
+           LDFLAGS="-Wl,-D,08000000"
+           LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
+           ;;
+       SCO_SV-3.2*)
+           # Note, dlopen is available only on SCO 3.2.5 and greater. However,
+           # this test works, since "uname -s" was non-standard in 3.2.4 and
+           # below.
+           if test "$using_gcc" = "yes" ; then
+               SHLIB_CFLAGS="-fPIC -melf"
+               LDFLAGS="-melf -Wl,-Bexport"
+           else
+               SHLIB_CFLAGS="-Kpic -belf"
+               LDFLAGS="-belf -Wl,-Bexport"
+           fi
+           SHLIB_LD="ld -G"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS=""
+           LDFLAGS="-belf -Wl,-Bexport"
+           LD_SEARCH_FLAGS=""
+           ;;
+       SINIX*5.4*)
+           SHLIB_CFLAGS="-K PIC"
+           SHLIB_LD="cc -G"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS=""
+           LD_SEARCH_FLAGS=""
+           ;;
+       SunOS-4*)
+           SHLIB_CFLAGS="-PIC"
+           SHLIB_LD="ld"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS=""
+           LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
+
+           # SunOS can't handle version numbers with dots in them in library
+           # specs, like -ltcl7.5, so use -ltcl75 instead.  Also, it
+           # requires an extra version number at the end of .so file names.
+           # So, the library has to have a name like libtcl75.so.1.0
+
+           SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
+           UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
+           TCL_LIB_VERSIONS_OK=nodots
+           ;;
+       SunOS-5.[0-6]*)
+           SHLIB_CFLAGS="-KPIC"
+           SHLIB_LD="/usr/ccs/bin/ld -G -z text"
+
+           # Note: need the LIBS below, otherwise Tk won't find Tcl's
+           # symbols when dynamically loaded into tclsh.
+
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           LDFLAGS=""
+           LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
+           ;;
+       SunOS-5*)
+           SHLIB_CFLAGS="-KPIC"
+           SHLIB_LD="/usr/ccs/bin/ld -G -z text"
+           LDFLAGS=""
+    
+           do64bit_ok=no
+           if test "$do64bit" = "yes" ; then
+               arch=`isainfo`
+               if test "$arch" = "sparcv9 sparc" ; then
+                       if test "$using_gcc" = "no" ; then
+                           do64bit_ok=yes
+                           if test "$do64bitVIS" = "yes" ; then
+                               EXTRA_CFLAGS="-xarch=v9a"
+                               LDFLAGS="-xarch=v9a"
+                           else
+                               EXTRA_CFLAGS="-xarch=v9"
+                               LDFLAGS="-xarch=v9"
+                           fi
+                       else 
+                           echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2
+                       fi
+               else
+                   echo "configure: warning: "64bit mode only supported sparcv9 system"" 1>&2
+               fi
+           fi
+           
+           # Note: need the LIBS below, otherwise Tk won't find Tcl's
+           # symbols when dynamically loaded into tclsh.
+
+           SHLIB_LD_LIBS='${LIBS}'
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           if test "$using_gcc" = "yes" ; then
+               LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
+           else
+               LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
+           fi
+           ;;
+       ULTRIX-4.*)
+           SHLIB_CFLAGS="-G 0"
+           SHLIB_SUFFIX=".a"
+           SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
+           SHLIB_LD_LIBS='${LIBS}'
+           DL_OBJS="tclLoadAout.o"
+           DL_LIBS=""
+           LDFLAGS="-Wl,-D,08000000"
+           LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
+           if test "$using_gcc" = "no" ; then
+               EXTRA_CFLAGS="-DHAVE_TZSET -std1"
+           fi
+           ;;
+       UNIX_SV* | UnixWare-5*)
+           SHLIB_CFLAGS="-KPIC"
+           SHLIB_LD="cc -G"
+           SHLIB_LD_LIBS=""
+           SHLIB_SUFFIX=".so"
+           DL_OBJS="tclLoadDl.o"
+           DL_LIBS="-ldl"
+           # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
+           # that don't grok the -Bexport option.  Test that it does.
+           hold_ldflags=$LDFLAGS
+           echo $ac_n "checking for ld accepts -Bexport flag""... $ac_c" 1>&6
+echo "configure:2135: checking for ld accepts -Bexport flag" >&5
+           LDFLAGS="${LDFLAGS} -Wl,-Bexport"
+           cat > conftest.$ac_ext <<EOF
+#line 2138 "configure"
 #include "confdefs.h"
 
-main(){return(0);}
+int main() {
+int i;
+; return 0; }
 EOF
-if { (eval echo configure:1128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  ac_cv_prog_cc_works=yes
-  # If we can't run a trivial program, we are probably using a cross compiler.
-  if (./conftest; exit) 2>/dev/null; then
-    ac_cv_prog_cc_cross=no
-  else
-    ac_cv_prog_cc_cross=yes
-  fi
+if { (eval echo configure:2145: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  found=yes
 else
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
-  ac_cv_prog_cc_works=no
+  rm -rf conftest*
+  found=no
 fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
+rm -f conftest*
+           LDFLAGS=$hold_ldflags
+           echo "$ac_t""$found" 1>&6
+           if test $found = yes; then
+           LDFLAGS="-Wl,-Bexport"
+           else
+           LDFLAGS=""
+           fi
+           LD_SEARCH_FLAGS=""
+           ;;
+    esac
 
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
-  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1154: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
+    if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
+    echo "configure: warning: "64bit support being disabled -- don\'t know magic for this platform"" 1>&2
+    fi
 
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1159: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.c <<EOF
-#ifdef __GNUC__
-  yes;
+    # Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic
+    # Loading for Tcl -- What Became of It?".  Proc. 2nd Tcl/Tk Workshop,
+    # New Orleans, LA, Computerized Processes Unlimited, 1994), then we need
+    # to determine which of several header files defines the a.out file
+    # format (a.out.h, sys/exec.h, or sys/exec_aout.h).  At present, we
+    # support only a file format that is more or less version-7-compatible. 
+    # In particular,
+    #  - a.out files must begin with `struct exec'.
+    #  - the N_TXTOFF on the `struct exec' must compute the seek address
+    #    of the text segment
+    #  - The `struct exec' must contain a_magic, a_text, a_data, a_bss
+    #    and a_entry fields.
+    # The following compilation should succeed if and only if either sys/exec.h
+    # or a.out.h is usable for the purpose.
+    #
+    # Note that the modified COFF format used on MIPS Ultrix 4.x is usable; the
+    # `struct exec' includes a second header that contains information that
+    # duplicates the v7 fields that are needed.
+
+    if test "x$DL_OBJS" = "xtclLoadAout.o" ; then
+       echo $ac_n "checking sys/exec.h""... $ac_c" 1>&6
+echo "configure:2191: checking sys/exec.h" >&5
+       cat > conftest.$ac_ext <<EOF
+#line 2193 "configure"
+#include "confdefs.h"
+#include <sys/exec.h>
+int main() {
+
+           struct exec foo;
+           unsigned long seek;
+           int flag;
+#if defined(__mips) || defined(mips)
+           seek = N_TXTOFF (foo.ex_f, foo.ex_o);
+#else
+           seek = N_TXTOFF (foo);
 #endif
+           flag = (foo.a_magic == OMAGIC);
+           return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
+    
+; return 0; }
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1168: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
-  ac_cv_prog_gcc=yes
+if { (eval echo configure:2211: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  tcl_ok=usable
 else
-  ac_cv_prog_gcc=no
-fi
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  tcl_ok=unusable
 fi
+rm -f conftest*
+       echo "$ac_t""$tcl_ok" 1>&6
+       if test $tcl_ok = usable; then
+           cat >> confdefs.h <<\EOF
+#define USE_SYS_EXEC_H 1
+EOF
 
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
+       else
+           echo $ac_n "checking a.out.h""... $ac_c" 1>&6
+echo "configure:2229: checking a.out.h" >&5
+           cat > conftest.$ac_ext <<EOF
+#line 2231 "configure"
+#include "confdefs.h"
+#include <a.out.h>
+int main() {
 
-if test $ac_cv_prog_gcc = yes; then
-  GCC=yes
+               struct exec foo;
+               unsigned long seek;
+               int flag;
+#if defined(__mips) || defined(mips)
+               seek = N_TXTOFF (foo.ex_f, foo.ex_o);
+#else
+               seek = N_TXTOFF (foo);
+#endif
+               flag = (foo.a_magic == OMAGIC);
+               return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
+           
+; return 0; }
+EOF
+if { (eval echo configure:2249: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  tcl_ok=usable
 else
-  GCC=
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  tcl_ok=unusable
 fi
+rm -f conftest*
+           echo "$ac_t""$tcl_ok" 1>&6
+           if test $tcl_ok = usable; then
+               cat >> confdefs.h <<\EOF
+#define USE_A_OUT_H 1
+EOF
 
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1187: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
-  ac_cv_prog_cc_g=yes
+           else
+               echo $ac_n "checking sys/exec_aout.h""... $ac_c" 1>&6
+echo "configure:2267: checking sys/exec_aout.h" >&5
+               cat > conftest.$ac_ext <<EOF
+#line 2269 "configure"
+#include "confdefs.h"
+#include <sys/exec_aout.h>
+int main() {
+
+                   struct exec foo;
+                   unsigned long seek;
+                   int flag;
+#if defined(__mips) || defined(mips)
+                   seek = N_TXTOFF (foo.ex_f, foo.ex_o);
+#else
+                   seek = N_TXTOFF (foo);
+#endif
+                   flag = (foo.a_midmag == OMAGIC);
+                   return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
+               
+; return 0; }
+EOF
+if { (eval echo configure:2287: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  tcl_ok=usable
 else
-  ac_cv_prog_cc_g=no
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  tcl_ok=unusable
 fi
 rm -f conftest*
+               echo "$ac_t""$tcl_ok" 1>&6
+               if test $tcl_ok = usable; then
+                   cat >> confdefs.h <<\EOF
+#define USE_SYS_EXEC_AOUT_H 1
+EOF
+
+               else
+                   DL_OBJS=""
+               fi
+           fi
+       fi
+    fi
 
+    # Step 5: disable dynamic loading if requested via a command-line switch.
+
+    # Check whether --enable-load or --disable-load was given.
+if test "${enable_load+set}" = set; then
+  enableval="$enable_load"
+  tcl_ok=$enableval
+else
+  tcl_ok=yes
 fi
 
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
-  CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
-  if test "$GCC" = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-g"
-  fi
+    if test "$tcl_ok" = "no"; then
+       DL_OBJS=""
+    fi
+
+    if test "x$DL_OBJS" != "x" ; then
+       BUILD_DLTEST="\$(DLTEST_TARGETS)"
+    else
+       echo "Can't figure out how to do dynamic loading or shared libraries"
+       echo "on this system."
+       SHLIB_CFLAGS=""
+       SHLIB_LD=""
+       SHLIB_SUFFIX=""
+       DL_OBJS="tclLoadNone.o"
+       DL_LIBS=""
+       LDFLAGS=""
+       LD_SEARCH_FLAGS=""
+       BUILD_DLTEST=""
+    fi
+
+    # If we're running gcc, then change the C flags for compiling shared
+    # libraries to the right flags for gcc, instead of those for the
+    # standard manufacturer compiler.
+
+    if test "$DL_OBJS" != "tclLoadNone.o" ; then
+       if test "$using_gcc" = "yes" ; then
+           case $system in
+               AIX-*)
+                   ;;
+               BSD/OS*)
+                   ;;
+               IRIX*)
+                   ;;
+               NetBSD-*|FreeBSD-*|OpenBSD-*)
+                   ;;
+               RISCos-*)
+                   ;;
+               SCO_SV-3.2*)
+                   ;;
+               ULTRIX-4.*)
+                   ;;
+               *)
+                   SHLIB_CFLAGS="-fPIC"
+                   ;;
+           esac
+       fi
+    fi
+
+    if test "$SHARED_LIB_SUFFIX" = "" ; then
+       SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}${SHLIB_SUFFIX}'
+    fi
+    if test "$UNSHARED_LIB_SUFFIX" = "" ; then
+       UNSHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a'
+    fi
+
+# CYGNUS LOCAL
+    TCL_LIB_SUFFIX=.a
+    
+# END CYGNUS LOCAL
+
+    
+    
+    
+    
+
+
+
+    echo $ac_n "checking for build with symbols""... $ac_c" 1>&6
+echo "configure:2387: checking for build with symbols" >&5
+    # Check whether --enable-symbols or --disable-symbols was given.
+if test "${enable_symbols+set}" = set; then
+  enableval="$enable_symbols"
+  tcl_ok=$enableval
 else
-  if test "$GCC" = yes; then
-    CFLAGS="-O2"
-  else
-    CFLAGS=
-  fi
+  tcl_ok=no
 fi
 
-else
-    CC=${CC-cc}
+    if test "$tcl_ok" = "yes"; then
+       CFLAGS_DEFAULT='$(CFLAGS_DEBUG)'
+       LDFLAGS_DEFAULT='$(LDFLAGS_DEBUG)'
+       DBGX=g
+       echo "$ac_t""yes" 1>&6
+    else
+       CFLAGS_DEFAULT='$(CFLAGS_OPTIMIZE)'
+       LDFLAGS_DEFAULT='$(LDFLAGS_OPTIMIZE)'
+       DBGX=""
+       echo "$ac_t""no" 1>&6
+    fi
 
+
+LIB_RUNTIME_DIR='${LIB_RUNTIME_DIR}'
+
+TK_DBGX=${DBGX}
+
+#------------------------------------------------------------------------
+# If Tcl and Tk are installed in different places, adjust the library
+# search path to reflect this.
+#------------------------------------------------------------------------
+
+if test "$TCL_EXEC_PREFIX" != "$exec_prefix"; then
+    LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${TCL_EXEC_PREFIX}/lib"
 fi
-echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1223: checking how to run the C preprocessor" >&5
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
-  CPP=
-fi
-if test -z "$CPP"; then
-if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
+
+#--------------------------------------------------------------------
+# On a few very rare systems, all of the libm.a stuff is
+# already in libc.a.  Set compiler flags accordingly.
+# Also, Linux requires the "ieee" library for math to work
+# right (and it must appear before "-lm").
+#--------------------------------------------------------------------
+
+echo $ac_n "checking for sin""... $ac_c" 1>&6
+echo "configure:2430: checking for sin" >&5
+if eval "test \"`echo '$''{'ac_cv_func_sin'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-    # This must be in double quotes, not single quotes, because CPP may get
-  # substituted into the Makefile and "${CC-cc}" will confuse make.
-  CPP="${CC-cc} -E"
-  # On the NeXT, cc -E runs the code through the compiler's parser,
-  # not just through cpp.
-  cat > conftest.$ac_ext <<EOF
-#line 1238 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1244: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 1255 "configure"
+#line 2435 "configure"
 #include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char sin(); below.  */
 #include <assert.h>
-Syntax Error
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char sin();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_sin) || defined (__stub___sin)
+choke me
+#else
+sin();
+#endif
+
+; return 0; }
 EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1261: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
-else
-  echo "$ac_err" >&5
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
+if { (eval echo configure:2458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
-  CPP="${CC-cc} -nologo -E"
-  cat > conftest.$ac_ext <<EOF
-#line 1272 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1278: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
-  :
+  eval "ac_cv_func_sin=yes"
 else
-  echo "$ac_err" >&5
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
   rm -rf conftest*
-  CPP=/lib/cpp
-fi
-rm -f conftest*
-fi
-rm -f conftest*
+  eval "ac_cv_func_sin=no"
 fi
 rm -f conftest*
-  ac_cv_prog_CPP="$CPP"
 fi
-  CPP="$ac_cv_prog_CPP"
+
+if eval "test \"`echo '$ac_cv_func_'sin`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  MATH_LIBS=""
 else
-  ac_cv_prog_CPP="$CPP"
+  echo "$ac_t""no" 1>&6
+MATH_LIBS="-lm"
 fi
-echo "$ac_t""$CPP" 1>&6
 
-for ac_hdr in unistd.h limits.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1306: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+echo $ac_n "checking for main in -lieee""... $ac_c" 1>&6
+echo "configure:2479: checking for main in -lieee" >&5
+ac_lib_var=`echo ieee'_'main | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-  cat > conftest.$ac_ext <<EOF
-#line 1311 "configure"
+  ac_save_LIBS="$LIBS"
+LIBS="-lieee  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2487 "configure"
 #include "confdefs.h"
-#include <$ac_hdr>
+
+int main() {
+main()
+; return 0; }
 EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1316: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
+if { (eval echo configure:2494: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=yes"
+  eval "ac_cv_lib_$ac_lib_var=yes"
 else
-  echo "$ac_err" >&5
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
   rm -rf conftest*
-  eval "ac_cv_header_$ac_safe=no"
+  eval "ac_cv_lib_$ac_lib_var=no"
 fi
 rm -f conftest*
+LIBS="$ac_save_LIBS"
+
 fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
-    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
-  cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
+  MATH_LIBS="-lieee $MATH_LIBS"
 else
   echo "$ac_t""no" 1>&6
 fi
-done
-
 
-# set the warning flags depending on whether or not we are using gcc
-if test "${GCC}" = "yes" ; then
-    # leave -Wimplicit-int out, the X libs generate so many of these warnings
-    # that they obscure everything else.
-
-    CFLAGS_WARNING="-Wall -Wconversion -Wno-implicit-int"
-else
-    CFLAGS_WARNING=""
-fi
 
 #--------------------------------------------------------------------
-#      See if there was a command-line option for where Tcl is;  if
-#      not, assume that its top-level directory is a sibling of ours.
+# On AIX systems, libbsd.a has to be linked in to support
+# non-blocking file IO.  This library has to be linked in after
+# the MATH_LIBS or it breaks the pow() function.  The way to
+# insure proper sequencing, is to add it to the tail of MATH_LIBS.
+# This library also supplies gettimeofday.
 #--------------------------------------------------------------------
+libbsd=no
+if test "`uname -s`" = "AIX" ; then
+    echo $ac_n "checking for gettimeofday in -lbsd""... $ac_c" 1>&6
+echo "configure:2525: checking for gettimeofday in -lbsd" >&5
+ac_lib_var=`echo bsd'_'gettimeofday | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lbsd  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 2533 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char gettimeofday();
 
-# Check whether --with-tcl or --without-tcl was given.
-if test "${with_tcl+set}" = set; then
-  withval="$with_tcl"
-  TCL_BIN_DIR=$withval
+int main() {
+gettimeofday()
+; return 0; }
+EOF
+if { (eval echo configure:2544: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
 else
-  TCL_BIN_DIR=`cd ../../tcl/unix; pwd`
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
 fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
 
-if test -z "$TCL_BIN_DIR"; then
-    { echo "configure: error: couldn't find Tcl build directory in ../../tcl/unix" 1>&2; exit 1; }
-fi
-if test ! -d $TCL_BIN_DIR; then
-    { echo "configure: error: Tcl directory $TCL_BIN_DIR doesn't exist" 1>&2; exit 1; }
 fi
-if test ! -f $TCL_BIN_DIR/Makefile; then
-    { echo "configure: error: There's no Makefile in $TCL_BIN_DIR;  perhaps you didn't specify the Tcl *build* directory (not the toplevel Tcl directory) or you forgot to configure Tcl?" 1>&2; exit 1; }
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  libbsd=yes
+else
+  echo "$ac_t""no" 1>&6
 fi
 
-#--------------------------------------------------------------------
-#      Read in configuration information generated by Tcl for shared
-#      libraries, and arrange for it to be substituted into our
-#      Makefile.
-#--------------------------------------------------------------------
-
-file=$TCL_BIN_DIR/tclConfig.sh
-. $file
-SHLIB_CFLAGS=$TCL_SHLIB_CFLAGS
-SHLIB_LD=$TCL_SHLIB_LD
-SHLIB_LD_LIBS=$TCL_SHLIB_LD_LIBS
-SHLIB_SUFFIX=$TCL_SHLIB_SUFFIX
-SHLIB_VERSION=$TCL_SHLIB_VERSION
-DL_LIBS=$TCL_DL_LIBS
-LD_FLAGS=$TCL_LD_FLAGS
-
-LIB_RUNTIME_DIR='${LIB_RUNTIME_DIR}'
-
-# If Tcl and Tk are installed in different places, adjust the library
-# search path to reflect this.
-
-if test "$TCL_EXEC_PREFIX" != "$exec_prefix"; then
-    LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${TCL_EXEC_PREFIX}"
+    if test $libbsd = yes; then
+       MATH_LIBS="$MATH_LIBS -lbsd"
+    fi
 fi
 
 #--------------------------------------------------------------------
-#      Supply a substitute for stdlib.h if it doesn't define strtol,
-#      strtoul, or strtod (which it doesn't in some versions of SunOS).
+# Supply a substitute for stdlib.h if it doesn't define strtol,
+# strtoul, or strtod (which it doesn't in some versions of SunOS).
 #--------------------------------------------------------------------
 
 echo $ac_n "checking stdlib.h""... $ac_c" 1>&6
-echo "configure:1407: checking stdlib.h" >&5
+echo "configure:2575: checking stdlib.h" >&5
 cat > conftest.$ac_ext <<EOF
-#line 1409 "configure"
+#line 2577 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -1420,7 +2588,7 @@ fi
 rm -f conftest*
 
 cat > conftest.$ac_ext <<EOF
-#line 1424 "configure"
+#line 2592 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -1434,7 +2602,7 @@ fi
 rm -f conftest*
 
 cat > conftest.$ac_ext <<EOF
-#line 1438 "configure"
+#line 2606 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -1456,26 +2624,26 @@ fi
 echo "$ac_t""$tk_ok" 1>&6
 
 #--------------------------------------------------------------------
-#      Include sys/select.h if it exists and if it supplies things
-#      that appear to be useful and aren't already in sys/types.h.
-#      This appears to be true only on the RS/6000 under AIX.  Some
-#      systems like OSF/1 have a sys/select.h that's of no use, and
-#      other systems like SCO UNIX have a sys/select.h that's
-#      pernicious.  If "fd_set" isn't defined anywhere then set a
-#      special flag.
+# Include sys/select.h if it exists and if it supplies things
+# that appear to be useful and aren't already in sys/types.h.
+# This appears to be true only on the RS/6000 under AIX.  Some
+# systems like OSF/1 have a sys/select.h that's of no use, and
+# other systems like SCO UNIX have a sys/select.h that's
+# pernicious.  If "fd_set" isn't defined anywhere then set a
+# special flag.
 #--------------------------------------------------------------------
 
 echo $ac_n "checking fd_set and sys/select""... $ac_c" 1>&6
-echo "configure:1470: checking fd_set and sys/select" >&5
+echo "configure:2638: checking fd_set and sys/select" >&5
 cat > conftest.$ac_ext <<EOF
-#line 1472 "configure"
+#line 2640 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 int main() {
 fd_set readMask, writeMask;
 ; return 0; }
 EOF
-if { (eval echo configure:1479: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2647: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   tk_ok=yes
 else
@@ -1487,7 +2655,7 @@ fi
 rm -f conftest*
 if test $tk_ok = no; then
     cat > conftest.$ac_ext <<EOF
-#line 1491 "configure"
+#line 2659 "configure"
 #include "confdefs.h"
 #include <sys/select.h>
 EOF
@@ -1514,17 +2682,17 @@ EOF
 fi
 
 #--------------------------------------------------------------------
-#      Check for various typedefs and provide substitutes if
-#      they don't exist.
+# Check for various typedefs and provide substitutes if
+# they don't exist.
 #--------------------------------------------------------------------
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:1523: checking for ANSI C header files" >&5
+echo "configure:2691: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1528 "configure"
+#line 2696 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -1532,7 +2700,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1536: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2704: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -1549,7 +2717,7 @@ rm -f conftest*
 if test $ac_cv_header_stdc = yes; then
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 1553 "configure"
+#line 2721 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -1567,7 +2735,7 @@ fi
 if test $ac_cv_header_stdc = yes; then
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 1571 "configure"
+#line 2739 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -1588,7 +2756,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 1592 "configure"
+#line 2760 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -1599,7 +2767,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:1603: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -1623,12 +2791,12 @@ EOF
 fi
 
 echo $ac_n "checking for mode_t""... $ac_c" 1>&6
-echo "configure:1627: checking for mode_t" >&5
+echo "configure:2795: checking for mode_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1632 "configure"
+#line 2800 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1656,12 +2824,12 @@ EOF
 fi
 
 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:1660: checking for pid_t" >&5
+echo "configure:2828: checking for pid_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1665 "configure"
+#line 2833 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1689,12 +2857,12 @@ EOF
 fi
 
 echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:1693: checking for size_t" >&5
+echo "configure:2861: checking for size_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1698 "configure"
+#line 2866 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -1722,12 +2890,12 @@ EOF
 fi
 
 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:1726: checking for uid_t in sys/types.h" >&5
+echo "configure:2894: checking for uid_t in sys/types.h" >&5
 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1731 "configure"
+#line 2899 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 EOF
@@ -1764,17 +2932,17 @@ for ac_hdr in sys/time.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1768: checking for $ac_hdr" >&5
+echo "configure:2936: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1773 "configure"
+#line 2941 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1778: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2946: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -1801,12 +2969,12 @@ fi
 done
 
 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:1805: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:2973: checking whether time.h and sys/time.h may both be included" >&5
 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1810 "configure"
+#line 2978 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/time.h>
@@ -1815,7 +2983,7 @@ int main() {
 struct tm *tp;
 ; return 0; }
 EOF
-if { (eval echo configure:1819: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2987: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_time=yes
 else
@@ -1836,6 +3004,38 @@ EOF
 fi
 
 
+#-------------------------------------------
+#     In OS/390 struct pwd has no pw_gecos field
+#-------------------------------------------
+
+echo $ac_n "checking pw_gecos in struct pwd""... $ac_c" 1>&6
+echo "configure:3013: checking pw_gecos in struct pwd" >&5
+cat > conftest.$ac_ext <<EOF
+#line 3015 "configure"
+#include "confdefs.h"
+#include <pwd.h>
+int main() {
+struct passwd pwd; pwd.pw_gecos;
+; return 0; }
+EOF
+if { (eval echo configure:3022: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  tk_ok=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  tk_ok=no
+fi
+rm -f conftest*
+echo "$ac_t""$tk_ok" 1>&6
+if test $tk_ok = yes; then
+    cat >> confdefs.h <<\EOF
+#define HAVE_PW_GECOS 1
+EOF
+
+fi
+
 #--------------------------------------------------------------------
 #      Locate the X11 header files and the X11 library archive.  Try
 #      the ac_path_x macro first, but if it doesn't find the X stuff
@@ -1845,12 +3045,13 @@ fi
 #      no include files, so double-check its result just to be safe.
 #--------------------------------------------------------------------
 
-# If we find X, set shell vars x_includes and x_libraries to the
+
+    # If we find X, set shell vars x_includes and x_libraries to the
 # paths, otherwise set no_x=yes.
 # Uses ac_ vars as temps to allow command line to override cache and checks.
 # --without-x overrides everything else, but does not touch the cache.
 echo $ac_n "checking for X""... $ac_c" 1>&6
-echo "configure:1854: checking for X" >&5
+echo "configure:3055: checking for X" >&5
 
 # Check whether --with-x or --without-x was given.
 if test "${with_x+set}" = set; then
@@ -1912,12 +3113,12 @@ if test "$ac_x_includes" = NO; then
 
   # First, try using that file with no special directory specified.
 cat > conftest.$ac_ext <<EOF
-#line 1916 "configure"
+#line 3117 "configure"
 #include "confdefs.h"
 #include <$x_direct_test_include>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1921: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3122: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -1986,14 +3187,14 @@ if test "$ac_x_libraries" = NO; then
   ac_save_LIBS="$LIBS"
   LIBS="-l$x_direct_test_library $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 1990 "configure"
+#line 3191 "configure"
 #include "confdefs.h"
 
 int main() {
 ${x_direct_test_function}()
 ; return 0; }
 EOF
-if { (eval echo configure:1997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   LIBS="$ac_save_LIBS"
 # We can link X programs with no special library path.
@@ -2079,16 +3280,16 @@ else
   echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
 fi
 
-not_really_there=""
-if test "$no_x" = ""; then
-    if test "$x_includes" = ""; then
-       cat > conftest.$ac_ext <<EOF
-#line 2087 "configure"
+    not_really_there=""
+    if test "$no_x" = ""; then
+       if test "$x_includes" = ""; then
+           cat > conftest.$ac_ext <<EOF
+#line 3288 "configure"
 #include "confdefs.h"
 #include <X11/XIntrinsic.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2092: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3293: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -2100,23 +3301,23 @@ else
   not_really_there="yes"
 fi
 rm -f conftest*
-    else
-       if test ! -r $x_includes/X11/Intrinsic.h; then
-           not_really_there="yes"
+       else
+           if test ! -r $x_includes/X11/Intrinsic.h; then
+               not_really_there="yes"
+           fi
        fi
     fi
-fi
-if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then
-    echo $ac_n "checking for X11 header files""... $ac_c" 1>&6
-echo "configure:2112: checking for X11 header files" >&5
-    XINCLUDES="# no special path needed"
-    cat > conftest.$ac_ext <<EOF
-#line 2115 "configure"
+    if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then
+       echo $ac_n "checking for X11 header files""... $ac_c" 1>&6
+echo "configure:3313: checking for X11 header files" >&5
+       XINCLUDES="# no special path needed"
+       cat > conftest.$ac_ext <<EOF
+#line 3316 "configure"
 #include "confdefs.h"
 #include <X11/Intrinsic.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2120: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3321: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -2128,51 +3329,51 @@ else
   XINCLUDES="nope"
 fi
 rm -f conftest*
+       if test "$XINCLUDES" = nope; then
+           dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include"
+           for i in $dirs ; do
+               if test -r $i/X11/Intrinsic.h; then
+                   echo "$ac_t""$i" 1>&6
+                   XINCLUDES=" -I$i"
+                   break
+               fi
+           done
+       fi
+    else
+       if test "$x_includes" != ""; then
+           XINCLUDES=-I$x_includes
+       else
+           XINCLUDES="# no special path needed"
+       fi
+    fi
     if test "$XINCLUDES" = nope; then
-        dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include"
-        for i in $dirs ; do
-           if test -r $i/X11/Intrinsic.h; then
+       echo "$ac_t""couldn't find any!" 1>&6
+       XINCLUDES="# no include files found"
+    fi
+
+    if test "$no_x" = yes; then
+       echo $ac_n "checking for X11 libraries""... $ac_c" 1>&6
+echo "configure:3357: checking for X11 libraries" >&5
+       XLIBSW=nope
+       dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
+       for i in $dirs ; do
+           if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
                echo "$ac_t""$i" 1>&6
-               XINCLUDES=" -I$i"
+               XLIBSW="-L$i -lX11"
+               x_libraries="$i"
                break
            fi
-        done
-    fi
-else
-    if test "$x_includes" != ""; then
-       XINCLUDES=-I$x_includes
+       done
     else
-       XINCLUDES="# no special path needed"
-    fi
-fi
-if test "$XINCLUDES" = nope; then
-    echo "$ac_t""couldn't find any!" 1>&6
-    XINCLUDES="# no include files found"
-fi
-
-if test "$no_x" = yes; then
-    echo $ac_n "checking for X11 libraries""... $ac_c" 1>&6
-echo "configure:2156: checking for X11 libraries" >&5
-    XLIBSW=nope
-    dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
-    for i in $dirs ; do
-       if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
-           echo "$ac_t""$i" 1>&6
-           XLIBSW="-L$i -lX11"
-           x_libraries="$i"
-           break
+       if test "$x_libraries" = ""; then
+           XLIBSW=-lX11
+       else
+           XLIBSW="-L$x_libraries -lX11"
        fi
-    done
-else
-    if test "$x_libraries" = ""; then
-       XLIBSW=-lX11
-    else
-       XLIBSW="-L$x_libraries -lX11"
     fi
-fi
-if test "$XLIBSW" = nope ; then
-    echo $ac_n "checking for XCreateWindow in -lXwindow""... $ac_c" 1>&6
-echo "configure:2176: checking for XCreateWindow in -lXwindow" >&5
+    if test "$XLIBSW" = nope ; then
+       echo $ac_n "checking for XCreateWindow in -lXwindow""... $ac_c" 1>&6
+echo "configure:3377: checking for XCreateWindow in -lXwindow" >&5
 ac_lib_var=`echo Xwindow'_'XCreateWindow | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2180,7 +3381,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lXwindow  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2184 "configure"
+#line 3385 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -2191,7 +3392,7 @@ int main() {
 XCreateWindow()
 ; return 0; }
 EOF
-if { (eval echo configure:2195: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3396: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2211,11 +3412,12 @@ else
   echo "$ac_t""no" 1>&6
 fi
 
-fi
-if test "$XLIBSW" = nope ; then
-    echo "$ac_t""couldn't find any!  Using -lX11." 1>&6
-    XLIBSW=-lX11
-fi
+    fi
+    if test "$XLIBSW" = nope ; then
+       echo "$ac_t""couldn't find any!  Using -lX11." 1>&6
+       XLIBSW=-lX11
+    fi
+
 
 #--------------------------------------------------------------------
 #      Various manipulations on the search path used at runtime to
@@ -2243,12 +3445,6 @@ fi
 # variable LIB_RUNTIME_DIR.
 
 eval "TK_CC_SEARCH_FLAGS=\"$TCL_LD_SEARCH_FLAGS\""
-TK_LD_SEARCH_FLAGS=`echo ${TK_CC_SEARCH_FLAGS} |sed -e "s|-Wl,||g" -e "s|,| |g"`
-
-# CYGNUS LOCAL: Don't hack TK_LD_SEARCH_FLAGS if SHLIB_LD is gcc.
-case "${SHLIB_LD}" in
-  *gcc*) TK_LD_SEARCH_FLAGS="${TK_CC_SEARCH_FLAGS}" ;;
-esac
 
 #
 # CYGNUS LOCAL:  statically link on Solaris, HPUX & SunOS so that
@@ -2299,11 +3495,8 @@ esac
            fi
            ;;
 #
-# gdb linked statically w/ SunOS or HPUX, but not hpux11 wide
+# gdb linked statically w/ SunOS or HPUX
 #
-       hppa*64*-hp-hpux*)
-           ;;
-
         m68k-hp-hpux*|hppa*-hp-hpux*|sparc-sun-sunos*)
             if test "x$x_libraries" != "x" ;
             then
@@ -2322,6 +3515,18 @@ esac
 #
 # END CYGNUS LOCAL
 
+# The following case handles the differences between linking with "ld"
+# and the compiler
+
+case $SHLIB_LD in
+    *ld*)
+      TK_LD_SEARCH_FLAGS=`echo ${TK_CC_SEARCH_FLAGS} |sed -e "s|-Wl,||g" -e "s|,| |g"`
+      ;;
+    *)
+      TK_LD_SEARCH_FLAGS="${TK_CC_SEARCH_FLAGS}"
+      ;;
+esac
+
 #--------------------------------------------------------------------
 #      Check for the existence of various libraries.  The order here
 #      is important, so that then end up in the right order in the
@@ -2341,7 +3546,7 @@ esac
 #--------------------------------------------------------------------
 
 echo $ac_n "checking for main in -lXbsd""... $ac_c" 1>&6
-echo "configure:2345: checking for main in -lXbsd" >&5
+echo "configure:3550: checking for main in -lXbsd" >&5
 ac_lib_var=`echo Xbsd'_'main | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2349,14 +3554,14 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lXbsd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2353 "configure"
+#line 3558 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:2360: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3565: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2380,7 +3585,7 @@ fi
 # CYGNUS LOCAL: Store any socket library(ies) in the cache, and don't
 # mess up the cache values of the functions we check for.
 echo $ac_n "checking for socket libraries""... $ac_c" 1>&6
-echo "configure:2384: checking for socket libraries" >&5
+echo "configure:3589: checking for socket libraries" >&5
 if eval "test \"`echo '$''{'tcl_cv_lib_sockets'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2388,12 +3593,12 @@ else
   tk_checkBoth=0
   unset ac_cv_func_connect
   echo $ac_n "checking for connect""... $ac_c" 1>&6
-echo "configure:2392: checking for connect" >&5
+echo "configure:3597: checking for connect" >&5
 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2397 "configure"
+#line 3602 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char connect(); below.  */
@@ -2416,7 +3621,7 @@ connect();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_connect=yes"
 else
@@ -2439,7 +3644,7 @@ fi
   if test "$tk_checkSocket" = 1; then
       unset ac_cv_func_connect
       echo $ac_n "checking for main in -lsocket""... $ac_c" 1>&6
-echo "configure:2443: checking for main in -lsocket" >&5
+echo "configure:3648: checking for main in -lsocket" >&5
 ac_lib_var=`echo socket'_'main | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2447,14 +3652,14 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2451 "configure"
+#line 3656 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:2458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3663: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2481,12 +3686,12 @@ fi
       LIBS="$LIBS -lsocket -lnsl"
       unset ac_cv_func_accept
       echo $ac_n "checking for accept""... $ac_c" 1>&6
-echo "configure:2485: checking for accept" >&5
+echo "configure:3690: checking for accept" >&5
 if eval "test \"`echo '$''{'ac_cv_func_accept'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2490 "configure"
+#line 3695 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char accept(); below.  */
@@ -2509,7 +3714,7 @@ accept();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2513: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3718: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_accept=yes"
 else
@@ -2536,12 +3741,12 @@ fi
   tk_oldLibs=$LIBS
   LIBS="$LIBS $tk_cv_lib_sockets"
   echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
-echo "configure:2540: checking for gethostbyname" >&5
+echo "configure:3745: checking for gethostbyname" >&5
 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2545 "configure"
+#line 3750 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char gethostbyname(); below.  */
@@ -2564,7 +3769,7 @@ gethostbyname();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2568: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_gethostbyname=yes"
 else
@@ -2582,7 +3787,7 @@ if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for main in -lnsl""... $ac_c" 1>&6
-echo "configure:2586: checking for main in -lnsl" >&5
+echo "configure:3791: checking for main in -lnsl" >&5
 ac_lib_var=`echo nsl'_'main | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2590,14 +3795,14 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2594 "configure"
+#line 3799 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:2601: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3806: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2627,6 +3832,10 @@ fi
 echo "$ac_t""$tcl_cv_lib_sockets" 1>&6
 test -z "$tcl_cv_lib_sockets" || LIBS="$LIBS $tcl_cv_lib_sockets"
 
+# Add the threads support libraries
+
+LIBS="$LIBS$THREADS_LIBS"
+
 #--------------------------------------------------------------------
 # One more check related to the X libraries.  The standard releases
 # of Ultrix don't support the "xauth" mechanism, so send won't work
@@ -2640,13 +3849,13 @@ test -z "$tcl_cv_lib_sockets" || LIBS="$LIBS $tcl_cv_lib_sockets"
 
 if test -d /usr/include/mit ; then
     echo $ac_n "checking MIT X libraries""... $ac_c" 1>&6
-echo "configure:2644: checking MIT X libraries" >&5
+echo "configure:3853: checking MIT X libraries" >&5
     tk_oldCFlags=$CFLAGS
     CFLAGS="$CFLAGS -I/usr/include/mit"
     tk_oldLibs=$LIBS
     LIBS="$LIBS -lX11-mit"
     cat > conftest.$ac_ext <<EOF
-#line 2650 "configure"
+#line 3859 "configure"
 #include "confdefs.h"
 
        #include <X11/Xlib.h>
@@ -2657,7 +3866,7 @@ int main() {
     
 ; return 0; }
 EOF
-if { (eval echo configure:2661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3870: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   
        echo "$ac_t""yes" 1>&6
@@ -2684,12 +3893,12 @@ fi
 
 MATH_LIBS=""
 echo $ac_n "checking for sin""... $ac_c" 1>&6
-echo "configure:2688: checking for sin" >&5
+echo "configure:3897: checking for sin" >&5
 if eval "test \"`echo '$''{'ac_cv_func_sin'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2693 "configure"
+#line 3902 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char sin(); below.  */
@@ -2712,7 +3921,7 @@ sin();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2716: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_sin=yes"
 else
@@ -2733,7 +3942,7 @@ MATH_LIBS="-lm"
 fi
 
 echo $ac_n "checking for main in -lieee""... $ac_c" 1>&6
-echo "configure:2737: checking for main in -lieee" >&5
+echo "configure:3946: checking for main in -lieee" >&5
 ac_lib_var=`echo ieee'_'main | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2741,14 +3950,14 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lieee  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2745 "configure"
+#line 3954 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:2752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3961: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2775,14 +3984,14 @@ fi
 #--------------------------------------------------------------------
 
 echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6
-echo "configure:2779: checking whether char is unsigned" >&5
+echo "configure:3988: checking whether char is unsigned" >&5
 if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   if test "$GCC" = yes; then
   # GCC predefines this symbol on systems where it applies.
 cat > conftest.$ac_ext <<EOF
-#line 2786 "configure"
+#line 3995 "configure"
 #include "confdefs.h"
 #ifdef __CHAR_UNSIGNED__
   yes
@@ -2804,7 +4013,7 @@ if test "$cross_compiling" = yes; then
     { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
 else
   cat > conftest.$ac_ext <<EOF
-#line 2808 "configure"
+#line 4017 "configure"
 #include "confdefs.h"
 /* volatile prevents gcc2 from optimizing the test away on sparcs.  */
 #if !defined(__STDC__) || __STDC__ != 1
@@ -2814,7 +4023,7 @@ main() {
   volatile char c = 255; exit(c < 0);
 }
 EOF
-if { (eval echo configure:2818: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4027: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_char_unsigned=yes
 else
@@ -2845,13 +4054,14 @@ fi
 #      "fixstrtod" (provided by Tcl) that corrects the error.
 #--------------------------------------------------------------------
 
-echo $ac_n "checking for strtod""... $ac_c" 1>&6
-echo "configure:2850: checking for strtod" >&5
+
+    echo $ac_n "checking for strtod""... $ac_c" 1>&6
+echo "configure:4060: checking for strtod" >&5
 if eval "test \"`echo '$''{'ac_cv_func_strtod'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2855 "configure"
+#line 4065 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char strtod(); below.  */
@@ -2874,7 +4084,7 @@ strtod();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2878: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4088: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_strtod=yes"
 else
 
 if eval "test \"`echo '$ac_cv_func_'strtod`\" = yes"; then
   echo "$ac_t""yes" 1>&6
-  tk_strtod=1
+  tcl_strtod=1
 else
   echo "$ac_t""no" 1>&6
-tk_strtod=0
+tcl_strtod=0
 fi
 
-if test "$tk_strtod" = 1; then
-    echo $ac_n "checking for Solaris 2.4 strtod bug""... $ac_c" 1>&6
-echo "configure:2900: checking for Solaris 2.4 strtod bug" >&5
-    if test "$cross_compiling" = yes; then
-  tk_ok=0
+    if test "$tcl_strtod" = 1; then
+       echo $ac_n "checking for Solaris2.4/Tru64 strtod bugs""... $ac_c" 1>&6
+echo "configure:4110: checking for Solaris2.4/Tru64 strtod bugs" >&5
+       if test "$cross_compiling" = yes; then
+  tcl_ok=0
 else
   cat > conftest.$ac_ext <<EOF
-#line 2905 "configure"
+#line 4115 "configure"
 #include "confdefs.h"
 
-       extern double strtod();
-       int main()
-       {
-           char *string = "NaN";
-           char *term;
-           strtod(string, &term);
-           if ((term != string) && (term[-1] == 0)) {
-               exit(1);
+           extern double strtod();
+           int main()
+           {
+               char *string = "NaN", *spaceString = " ";
+               char *term;
+               double value;
+               value = strtod(string, &term);
+               if ((term != string) && (term[-1] == 0)) {
+                   exit(1);
+               }
+               value = strtod(spaceString, &term);
+               if (term == (spaceString+1)) {
+                   exit(1);
+               }
+               exit(0);
            }
-           exit(0);
-       }
 EOF
-if { (eval echo configure:2920: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
-  tk_ok=1
+  tcl_ok=1
 else
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
   rm -fr conftest*
-  tk_ok=0
+  tcl_ok=0
 fi
 rm -fr conftest*
 fi
 
-    if test "$tk_ok" = 1; then
-       echo "$ac_t""ok" 1>&6
-    else
-       echo "$ac_t""buggy" 1>&6
-       cat >> confdefs.h <<\EOF
+       if test "$tcl_ok" = 1; then
+           echo "$ac_t""ok" 1>&6
+       else
+           echo "$ac_t""buggy" 1>&6
+           LIBOBJS="$LIBOBJS fixstrtod.o"
+           cat >> confdefs.h <<\EOF
 #define strtod fixstrtod
 EOF
 
+       fi
     fi
-fi
+
 
 #--------------------------------------------------------------------
 #      The statements below define a collection of symbols related to
 #      building libtk as a shared library instead of a static library.
 #--------------------------------------------------------------------
 
-# Check whether --enable-shared or --disable-shared was given.
+
+    echo $ac_n "checking how to build libraries""... $ac_c" 1>&6
+echo "configure:4167: checking how to build libraries" >&5
+    # Check whether --enable-shared or --disable-shared was given.
 if test "${enable_shared+set}" = set; then
   enableval="$enable_shared"
-  ok=$enableval
+  tcl_ok=$enableval
 else
-  ok=no
+  tcl_ok=no
 fi
 
 
-# CYGNUS LOCAL: on machines where static linking of libX11 is important,
-# it is also important to build a static libtk.
-if test -n "$suppress_enable_shared"; then
-   ok=no
-fi
-# END CYGNUS LOCAL
+    if test "${enable_shared+set}" = set; then
+       enableval="$enable_shared"
+       tcl_ok=$enableval
+    else
+       tcl_ok=no
+    fi
+
+    if test "$tcl_ok" = "yes" ; then
+       echo "$ac_t""shared" 1>&6
+       SHARED_BUILD=1
+    else
+       echo "$ac_t""static" 1>&6
+       SHARED_BUILD=0
+       cat >> confdefs.h <<\EOF
+#define STATIC_BUILD 1
+EOF
+
+    fi
 
-TK_SHARED_LIB_FILE=
-TK_UNSHARED_LIB_FILE=
-if test "$ok" = "yes" -a "${SHLIB_SUFFIX}" != ""; then
-    TK_SHARED_BUILD=1
+
+eval eval "TK_SHARED_LIB_SUFFIX=${SHARED_LIB_SUFFIX}"
+eval eval "TK_UNSHARED_LIB_SUFFIX=${UNSHARED_LIB_SUFFIX}"
+
+if test "${SHARED_BUILD}" = "1" -a "${SHLIB_SUFFIX}" != ""; then
     TK_SHLIB_CFLAGS="${SHLIB_CFLAGS}"
-    eval "TK_LIB_FILE=libtk${TCL_SHARED_LIB_SUFFIX}"
-    TK_SHARED_LIB_FILE="$TK_LIB_FILE"
-    MAKE_LIB="\${SHLIB_LD} -o ${TK_LIB_FILE} \${OBJS} \$(TK_LD_SEARCH_FLAGS) ${SHLIB_LD_LIBS}"
+    
+  libname=tk
+  suffix=${TK_SHARED_LIB_SUFFIX}
+
+  case "${host}" in
+    *windows32* | *mingw32* | *cygwin*)
+      eval "long_libname=\"${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+    ;;
+    *)
+      eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+    ;;
+  esac
+
+  eval "long_libname=${long_libname}"
+
+  # Trick to replace DBGX with TCL_DBGX
+  DBGX='${TCL_DBGX}'
+  eval "long_libname=${long_libname}"
+
+  TK_LIB_FILE=$long_libname
+
+    MAKE_LIB="\${SHLIB_LD} -o \${TK_LIB_FILE} \${OBJS} \$(TK_LD_SEARCH_FLAGS) ${TCL_STUB_LIB_SPEC} \${LIBS}"
     RANLIB=":"
+
+#    TCL_STUB_FLAGS="-DUSE_TCL_STUBS"
+    TCL_STUB_FLAGS=""
 else
-    TK_SHARED_BUILD=0
     TK_SHLIB_CFLAGS=""
-    eval "TK_LIB_FILE=libtk${TCL_UNSHARED_LIB_SUFFIX}"
-    TK_UNSHARED_LIB_FILE="$TK_LIB_FILE"
-    MAKE_LIB="ar cr ${TK_LIB_FILE} \${OBJS}"
-fi
+    
+  libname=tk
+  suffix=${TK_UNSHARED_LIB_SUFFIX}
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        eval "long_libname=\"${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+      else
+        eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+      fi
+    ;;
+    *)
+      eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+    ;;
+  esac
 
-TK_BUILD_INCLUDES="-I`cd $srcdir/../generic; pwd`"
+  eval "long_libname=${long_libname}"
+
+  # Trick to replace DBGX with TCL_DBGX
+  DBGX='${TCL_DBGX}'
+  eval "long_libname=${long_libname}"
+
+  TK_LIB_FILE=$long_libname
+
+    MAKE_LIB="\${STLIB_LD} \${TK_LIB_FILE} \${OBJS}"
+
+    TCL_STUB_FLAGS=""
+fi
 
 # Note:  in the following variable, it's important to use the absolute
 # path name of the Tcl directory rather than "..":  this is because
 # AIX remembers this path and will attempt to use it at run-time to look
 # up the Tcl library.
 
-if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
-    TK_BUILD_LIB_SPEC="-L`pwd` -ltk${VERSION}"
-    TK_LIB_FLAG="-ltk${VERSION}\${TK_DBGX}"
+if test "$SHARED_BUILD" = 0 -o $TCL_NEEDS_EXP_FILE = 0; then
+    
+  libname=tk
+  version=$TK_VERSION
+
+  if test "$TCL_LIB_SUFFIX" = "" ; then
+    { echo "configure: error: The TCL_LIB_SUFFIX variable is not defined" 1>&2; exit 1; }
+  fi
+
+  # If the . character is not allowed in lib name, remove it from version
+  if test "${TCL_LIB_VERSIONS_OK}" != "ok"; then
+        version=`echo $version | tr -d .`
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        eval "short_libname=\"${TCL_VENDOR_PREFIX}${libname}${version}${TCL_LIB_SUFFIX}\""
+      else
+        short_libname="-l${TCL_VENDOR_PREFIX}${libname}${version}${TCL_DBGX}"
+      fi
+    ;;
+    *)
+      short_libname="-l${TCL_VENDOR_PREFIX}${libname}${version}\${TCL_DBGX}"
+    ;;
+  esac
+
+  TK_LIB_FLAG=$short_libname
+
+    
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        
+  val="`pwd`/${TK_LIB_FLAG}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_BUILD_LIB_SPEC" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_BUILD_LIB_SPEC=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_BUILD_LIB_SPEC="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_BUILD_LIB_SPEC=$val
+    ;;
+  esac
+
+      else
+        
+  val=`pwd`
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable dirname" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        dirname=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        dirname="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      dirname=$val
+    ;;
+  esac
+
+        TK_BUILD_LIB_SPEC="-L${dirname} ${TK_LIB_FLAG}"
+      fi
+    ;;
+    *)
+      TK_BUILD_LIB_SPEC="-L`pwd` ${TK_LIB_FLAG}"
+    ;;
+  esac
+
+    
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        
+  val="${exec_prefix}/lib/${TK_LIB_FLAG}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_LIB_SPEC" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_LIB_SPEC=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_LIB_SPEC="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_LIB_SPEC=$val
+    ;;
+  esac
+
+      else
+        
+  val=${exec_prefix}/lib
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable dirname" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        dirname=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        dirname="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      dirname=$val
+    ;;
+  esac
+
+        TK_LIB_SPEC="-L${dirname} ${TK_LIB_FLAG}"
+      fi
+    ;;
+    *)
+      TK_LIB_SPEC="-L${exec_prefix}/lib ${TK_LIB_FLAG}"
+    ;;
+  esac
+
+    TK_BUILD_EXP_FILE=""
+    TK_EXP_FILE=""
 else
-    TK_BUILD_LIB_SPEC="-L`pwd` -ltk`echo ${VERSION} | tr -d .`"
-    TK_LIB_FLAG="-ltk`echo ${VERSION} | tr -d .`\${TK_DBGX}"
+    TK_BUILD_EXP_FILE="lib.exp"
+    eval "TK_EXP_FILE=libtk${TCL_EXPORT_FILE_SUFFIX}"
+    
+    TK_BUILD_LIB_SPEC="-bI:`pwd`/${TK_BUILD_EXP_FILE}"
+    TK_LIB_SPEC="-bI:${exec_prefix}/lib/${TK_EXP_FILE}"
 fi
+TK_SHARED_BUILD=${SHARED_BUILD}
+
+TK_BUILD_INCLUDES="-I`cd $srcdir/../generic; pwd`"
+
+#--------------------------------------------------------------------
+# The statements below define various symbols relating to creating
+# the stub'd version of the Tk library
+#
+# For now, linking to Tcl stubs is not supported with Tk. It causes
+# too many problems with linking.  When Tk is a fully loadable 
+# extension, linking the the Tcl stubs will be supported.
+#--------------------------------------------------------------------
+
+
+  libname=tkstub
+  suffix=${TK_UNSHARED_LIB_SUFFIX}
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        eval "long_libname=\"${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+      else
+        eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+      fi
+    ;;
+    *)
+      eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+    ;;
+  esac
+
+  eval "long_libname=${long_libname}"
+
+  # Trick to replace DBGX with TCL_DBGX
+  DBGX='${TCL_DBGX}'
+  eval "long_libname=${long_libname}"
+
+  TK_STUB_LIB_FILE=$long_libname
+
+
+MAKE_STUB_LIB="\${STLIB_LD} \${STUB_LIB_FILE} \${STUB_LIB_OBJS}"
+
+
+  libname=tkstub
+  version=${TK_VERSION}
+
+  if test "$TCL_LIB_SUFFIX" = "" ; then
+    { echo "configure: error: The TCL_LIB_SUFFIX variable is not defined" 1>&2; exit 1; }
+  fi
+
+  # If the . character is not allowed in lib name, remove it from version
+  if test "${TCL_LIB_VERSIONS_OK}" != "ok"; then
+        version=`echo $version | tr -d .`
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        eval "short_libname=\"${TCL_VENDOR_PREFIX}${libname}${version}${TCL_LIB_SUFFIX}\""
+      else
+        short_libname="-l${TCL_VENDOR_PREFIX}${libname}${version}${TCL_DBGX}"
+      fi
+    ;;
+    *)
+      short_libname="-l${TCL_VENDOR_PREFIX}${libname}${version}\${TCL_DBGX}"
+    ;;
+  esac
+
+  TK_STUB_LIB_FLAG=$short_libname
+
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        
+  val="`pwd`/${TK_STUB_LIB_FLAG}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_BUILD_STUB_LIB_SPEC" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_BUILD_STUB_LIB_SPEC=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_BUILD_STUB_LIB_SPEC="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_BUILD_STUB_LIB_SPEC=$val
+    ;;
+  esac
+
+      else
+        
+  val=`pwd`
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable dirname" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        dirname=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        dirname="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      dirname=$val
+    ;;
+  esac
+
+        TK_BUILD_STUB_LIB_SPEC="-L${dirname} ${TK_STUB_LIB_FLAG}"
+      fi
+    ;;
+    *)
+      TK_BUILD_STUB_LIB_SPEC="-L`pwd` ${TK_STUB_LIB_FLAG}"
+    ;;
+  esac
+
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        
+  val="${exec_prefix}/lib/${TK_STUB_LIB_FLAG}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_STUB_LIB_SPEC" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_STUB_LIB_SPEC=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_STUB_LIB_SPEC="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_STUB_LIB_SPEC=$val
+    ;;
+  esac
+
+      else
+        
+  val=${exec_prefix}/lib
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable dirname" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        dirname=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        dirname="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      dirname=$val
+    ;;
+  esac
+
+        TK_STUB_LIB_SPEC="-L${dirname} ${TK_STUB_LIB_FLAG}"
+      fi
+    ;;
+    *)
+      TK_STUB_LIB_SPEC="-L${exec_prefix}/lib ${TK_STUB_LIB_FLAG}"
+    ;;
+  esac
+
+
+
+  
+  val="`pwd`/${TK_STUB_LIB_FILE}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_BUILD_STUB_LIB_PATH" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_BUILD_STUB_LIB_PATH=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_BUILD_STUB_LIB_PATH="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_BUILD_STUB_LIB_PATH=$val
+    ;;
+  esac
+
+
+
+  
+  val="`pwd`/${TK_STUB_LIB_FILE}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_STUB_LIB_PATH" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_STUB_LIB_PATH=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_STUB_LIB_PATH="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_STUB_LIB_PATH=$val
+    ;;
+  esac
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
 
-TK_LIB_FULL_PATH="`pwd`/${TK_LIB_FILE}"
 
 
 
@@ -3143,7 +4896,6 @@ do
 done
 
 ac_given_srcdir=$srcdir
-ac_given_INSTALL="$INSTALL"
 
 trap 'rm -fr `echo "Makefile tkConfig.sh" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
 EOF
@@ -3177,57 +4929,67 @@ s%@includedir@%$includedir%g
 s%@oldincludedir@%$oldincludedir%g
 s%@infodir@%$infodir%g
 s%@mandir@%$mandir%g
-s%@host@%$host%g
-s%@host_alias@%$host_alias%g
-s%@host_cpu@%$host_cpu%g
-s%@host_vendor@%$host_vendor%g
-s%@host_os@%$host_os%g
-s%@target@%$target%g
-s%@target_alias@%$target_alias%g
-s%@target_cpu@%$target_cpu%g
-s%@target_vendor@%$target_vendor%g
-s%@target_os@%$target_os%g
-s%@build@%$build%g
-s%@build_alias@%$build_alias%g
-s%@build_cpu@%$build_cpu%g
-s%@build_vendor@%$build_vendor%g
-s%@build_os@%$build_os%g
-s%@CC@%$CC%g
-s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
-s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
-s%@INSTALL_DATA@%$INSTALL_DATA%g
 s%@RANLIB@%$RANLIB%g
+s%@CC@%$CC%g
 s%@CPP@%$CPP%g
+s%@TCL_BIN_DIR@%$TCL_BIN_DIR%g
+s%@TCL_SRC_DIR@%$TCL_SRC_DIR%g
+s%@TCL_LIB_FILE@%$TCL_LIB_FILE%g
+s%@AR@%$AR%g
+s%@TCL_LIB_SUFFIX@%$TCL_LIB_SUFFIX%g
 s%@DL_LIBS@%$DL_LIBS%g
-s%@LD_FLAGS@%$LD_FLAGS%g
+s%@CFLAGS_DEBUG@%$CFLAGS_DEBUG%g
+s%@CFLAGS_OPTIMIZE@%$CFLAGS_OPTIMIZE%g
+s%@CFLAGS_WARNING@%$CFLAGS_WARNING%g
+s%@TK_STUB_LIB_FILE@%$TK_STUB_LIB_FILE%g
+s%@TK_STUB_LIB_FLAG@%$TK_STUB_LIB_FLAG%g
+s%@TK_BUILD_STUB_LIB_SPEC@%$TK_BUILD_STUB_LIB_SPEC%g
+s%@TK_STUB_LIB_SPEC@%$TK_STUB_LIB_SPEC%g
+s%@TK_BUILD_STUB_LIB_PATH@%$TK_BUILD_STUB_LIB_PATH%g
+s%@TK_STUB_LIB_PATH@%$TK_STUB_LIB_PATH%g
+s%@MAKE_STUB_LIB@%$MAKE_STUB_LIB%g
+s%@TK_STUB_FLAGS@%$TK_STUB_FLAGS%g
+s%@TK_BUILD_EXP_FILE@%$TK_BUILD_EXP_FILE%g
+s%@TK_EXP_FILE@%$TK_EXP_FILE%g
+s%@TCL_STUB_FLAGS@%$TCL_STUB_FLAGS%g
+s%@CFLAGS_DEFAULT@%$CFLAGS_DEFAULT%g
+s%@LDFLAGS_DEFAULT@%$LDFLAGS_DEFAULT%g
+s%@LDFLAGS_DEBUG@%$LDFLAGS_DEBUG%g
+s%@LDFLAGS_OPTIMIZE@%$LDFLAGS_OPTIMIZE%g
+s%@TK_DBGX@%$TK_DBGX%g
+s%@EXTRA_CFLAGS@%$EXTRA_CFLAGS%g
 s%@MATH_LIBS@%$MATH_LIBS%g
 s%@MAKE_LIB@%$MAKE_LIB%g
 s%@SHLIB_CFLAGS@%$SHLIB_CFLAGS%g
+s%@TK_SHLIB_CFLAGS@%$TK_SHLIB_CFLAGS%g
+s%@STLIB_LD@%$STLIB_LD%g
 s%@SHLIB_LD@%$SHLIB_LD%g
 s%@SHLIB_LD_LIBS@%$SHLIB_LD_LIBS%g
 s%@SHLIB_SUFFIX@%$SHLIB_SUFFIX%g
 s%@SHLIB_VERSION@%$SHLIB_VERSION%g
-s%@TCL_BIN_DIR@%$TCL_BIN_DIR%g
+s%@TCL_LIB_FULL_PATH@%$TCL_LIB_FULL_PATH%g
+s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g
+s%@TCL_LIB_FLAG@%$TCL_LIB_FLAG%g
+s%@TCL_BUILD_STUB_LIB_SPEC@%$TCL_BUILD_STUB_LIB_SPEC%g
 s%@TCL_BUILD_LIB_SPEC@%$TCL_BUILD_LIB_SPEC%g
-s%@TCL_SRC_DIR@%$TCL_SRC_DIR%g
+s%@TCL_DBGX@%$TCL_DBGX%g
 s%@TCL_VERSION@%$TCL_VERSION%g
-s%@TK_BUILD_INCLUDES@%$TK_BUILD_INCLUDES%g
 s%@TK_BUILD_LIB_SPEC@%$TK_BUILD_LIB_SPEC%g
+s%@TK_LIB_FULL_PATH@%$TK_LIB_FULL_PATH%g
 s%@TK_CC_SEARCH_FLAGS@%$TK_CC_SEARCH_FLAGS%g
 s%@TK_LD_SEARCH_FLAGS@%$TK_LD_SEARCH_FLAGS%g
-s%@TK_LIB_FULL_PATH@%$TK_LIB_FULL_PATH%g
 s%@TK_LIB_FILE@%$TK_LIB_FILE%g
 s%@TK_LIB_FLAG@%$TK_LIB_FLAG%g
 s%@TK_LIB_SPEC@%$TK_LIB_SPEC%g
 s%@TK_MAJOR_VERSION@%$TK_MAJOR_VERSION%g
 s%@TK_MINOR_VERSION@%$TK_MINOR_VERSION%g
 s%@TK_PATCH_LEVEL@%$TK_PATCH_LEVEL%g
-s%@TK_SHLIB_CFLAGS@%$TK_SHLIB_CFLAGS%g
 s%@TK_SRC_DIR@%$TK_SRC_DIR%g
 s%@TK_VERSION@%$TK_VERSION%g
 s%@XINCLUDES@%$XINCLUDES%g
 s%@XLIBSW@%$XLIBSW%g
 s%@TK_SHARED_BUILD@%$TK_SHARED_BUILD%g
+s%@TK_BUILD_INCLUDES@%$TK_BUILD_INCLUDES%g
 s%@TCL_SHARED_LIB_SUFFIX@%$TCL_SHARED_LIB_SUFFIX%g
 s%@TCL_UNSHARED_LIB_SUFFIX@%$TCL_UNSHARED_LIB_SUFFIX%g
 s%@TK_SHARED_LIB_FILE@%$TK_SHARED_LIB_FILE%g
@@ -3240,7 +5002,7 @@ cat >> $CONFIG_STATUS <<\EOF
 
 # Split the substitutions into bite-sized pieces for seds with
 # small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
+ac_max_sed_cmds=60 # Maximum number of lines to put in a sed script.
 ac_file=1 # Number of current file.
 ac_beg=1 # First line for current file.
 ac_end=$ac_max_sed_cmds # Line after last line for current file.
@@ -3308,10 +5070,6 @@ for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
     top_srcdir="$ac_dots$ac_given_srcdir" ;;
   esac
 
-  case "$ac_given_INSTALL" in
-  [/$]*) INSTALL="$ac_given_INSTALL" ;;
-  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
-  esac
 
   echo creating "$ac_file"
   rm -f "$ac_file"
@@ -3327,7 +5085,6 @@ for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
 s%@configure_input@%$configure_input%g
 s%@srcdir@%$srcdir%g
 s%@top_srcdir@%$top_srcdir%g
-s%@INSTALL@%$INSTALL%g
 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
 fi; done
 rm -f conftest.s*
@@ -3344,3 +5101,4 @@ chmod +x $CONFIG_STATUS
 rm -fr confdefs* $ac_clean_files
 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
 
+
index 60d0b30..1413149 100755 (executable)
@@ -1,26 +1,20 @@
-! /bin/bash -norc
+#! /bin/bash -norc
 dnl    This file is an input file used by the GNU "autoconf" program to
 dnl    generate the file "configure", which is run during Tk installation
 dnl    to configure the system for the local environment.
+# RCS: @(#) $Id$
 
 # CYGNUS LOCAL, autoconf 2.5 or higher to get --bindir et al
 AC_PREREQ(2.5)
 # END CYGNUS LOCAL
 
 AC_INIT(../generic/tk.h)
-# SCCS: @(#) configure.in 1.90 97/11/20 12:45:45
+# RCS: @(#) $Id$
 
-# CYGNUS LOCAL tromey - find config.guess/config.sub in our tree
-AC_CONFIG_AUX_DIR($srcdir/../..)
-AC_CANONICAL_SYSTEM
-AC_PROG_CC
-AC_PROG_INSTALL
-# END CYGNUS LOCAL
-
-TK_VERSION=8.0
+TK_VERSION=8.3
 TK_MAJOR_VERSION=8
-TK_MINOR_VERSION=0
-TK_PATCH_LEVEL=".4"
+TK_MINOR_VERSION=3
+TK_PATCH_LEVEL=".2"
 VERSION=${TK_VERSION}
 
 if test "${prefix}" = "NONE"; then
@@ -29,74 +23,94 @@ fi
 if test "${exec_prefix}" = "NONE"; then
     exec_prefix=$prefix
 fi
-TK_SRC_DIR=`cd $srcdir/..; pwd`
+# Make sure srcdir is fully qualified!
+srcdir=`cd $srcdir ; pwd`
+TCL_TOOL_PATH(TK_SRC_DIR, "`cd $srcdir/..; pwd`")
 
 AC_PROG_RANLIB
-AC_ARG_ENABLE(gcc, [  --enable-gcc            allow use of gcc if available],
-    [tk_ok=$enableval], [tkl_ok=no])
-if test "$tk_ok" = "yes"; then
-    AC_PROG_CC
-else
-    CC=${CC-cc}
-AC_SUBST(CC)
-fi
+AC_PROG_CC
+
 AC_HAVE_HEADERS(unistd.h limits.h)
 
-# set the warning flags depending on whether or not we are using gcc
-if test "${GCC}" = "yes" ; then
-    # leave -Wimplicit-int out, the X libs generate so many of these warnings
-    # that they obscure everything else.
+#------------------------------------------------------------------------
+# Threads support
+#------------------------------------------------------------------------
 
-    CFLAGS_WARNING="-Wall -Wconversion -Wno-implicit-int"
-else
-    CFLAGS_WARNING=""
+SC_ENABLE_THREADS
+
+#------------------------------------------------------------------------------
+# If we're using GCC, see if the compiler understands -pipe.  If so, use it.
+# It makes compiling go faster.  (This is only a performance feature.)
+#------------------------------------------------------------------------------
+
+if test -z "$no_pipe"; then
+if test -n "$GCC"; then
+  AC_MSG_CHECKING([if the compiler understands -pipe])
+  OLDCC="$CC"  
+  CC="$CC -pipe"
+  AC_TRY_COMPILE(,,
+    AC_MSG_RESULT(yes),
+    CC="$OLDCC"
+    AC_MSG_RESULT(no))
+fi  
 fi
 
 #--------------------------------------------------------------------
-#      See if there was a command-line option for where Tcl is;  if
-#      not, assume that its top-level directory is a sibling of ours.
+# Find and load the tclConfig.sh file
 #--------------------------------------------------------------------
 
-AC_ARG_WITH(tcl, [  --with-tcl=DIR          use Tcl 8.0 binaries from DIR],
-       TCL_BIN_DIR=$withval, TCL_BIN_DIR=`cd ../../tcl/unix; pwd`)
-if test -z "$TCL_BIN_DIR"; then
-    AC_MSG_ERROR(couldn't find Tcl build directory in ../../tcl/unix)
-fi
-if test ! -d $TCL_BIN_DIR; then
-    AC_MSG_ERROR(Tcl directory $TCL_BIN_DIR doesn't exist)
-fi
-if test ! -f $TCL_BIN_DIR/Makefile; then
-    AC_MSG_ERROR(There's no Makefile in $TCL_BIN_DIR;  perhaps you didn't specify the Tcl *build* directory (not the toplevel Tcl directory) or you forgot to configure Tcl?)
-fi
+SC_PATH_TCLCONFIG
+SC_LOAD_TCLCONFIG
 
 #--------------------------------------------------------------------
-#      Read in configuration information generated by Tcl for shared
-#      libraries, and arrange for it to be substituted into our
-#      Makefile.
+# Recompute the necessary flags to run the compiler
 #--------------------------------------------------------------------
 
-file=$TCL_BIN_DIR/tclConfig.sh
-. $file
-SHLIB_CFLAGS=$TCL_SHLIB_CFLAGS
-SHLIB_LD=$TCL_SHLIB_LD
-SHLIB_LD_LIBS=$TCL_SHLIB_LD_LIBS
-SHLIB_SUFFIX=$TCL_SHLIB_SUFFIX
-SHLIB_VERSION=$TCL_SHLIB_VERSION
-DL_LIBS=$TCL_DL_LIBS
-LD_FLAGS=$TCL_LD_FLAGS
+SC_CONFIG_CFLAGS
+
+SC_ENABLE_SYMBOLS
 
 LIB_RUNTIME_DIR='${LIB_RUNTIME_DIR}'
 
+TK_DBGX=${DBGX}
+
+#------------------------------------------------------------------------
 # If Tcl and Tk are installed in different places, adjust the library
 # search path to reflect this.
+#------------------------------------------------------------------------
 
 if test "$TCL_EXEC_PREFIX" != "$exec_prefix"; then
-    LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${TCL_EXEC_PREFIX}"
+    LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${TCL_EXEC_PREFIX}/lib"
 fi
 
 #--------------------------------------------------------------------
-#      Supply a substitute for stdlib.h if it doesn't define strtol,
-#      strtoul, or strtod (which it doesn't in some versions of SunOS).
+# On a few very rare systems, all of the libm.a stuff is
+# already in libc.a.  Set compiler flags accordingly.
+# Also, Linux requires the "ieee" library for math to work
+# right (and it must appear before "-lm").
+#--------------------------------------------------------------------
+
+AC_CHECK_FUNC(sin, MATH_LIBS="", MATH_LIBS="-lm")
+AC_CHECK_LIB(ieee, main, [MATH_LIBS="-lieee $MATH_LIBS"])
+
+#--------------------------------------------------------------------
+# On AIX systems, libbsd.a has to be linked in to support
+# non-blocking file IO.  This library has to be linked in after
+# the MATH_LIBS or it breaks the pow() function.  The way to
+# insure proper sequencing, is to add it to the tail of MATH_LIBS.
+# This library also supplies gettimeofday.
+#--------------------------------------------------------------------
+libbsd=no
+if test "`uname -s`" = "AIX" ; then
+    AC_CHECK_LIB(bsd, gettimeofday, libbsd=yes)
+    if test $libbsd = yes; then
+       MATH_LIBS="$MATH_LIBS -lbsd"
+    fi
+fi
+
+#--------------------------------------------------------------------
+# Supply a substitute for stdlib.h if it doesn't define strtol,
+# strtoul, or strtod (which it doesn't in some versions of SunOS).
 #--------------------------------------------------------------------
 
 AC_MSG_CHECKING(stdlib.h)
@@ -109,13 +123,13 @@ fi
 AC_MSG_RESULT($tk_ok)
 
 #--------------------------------------------------------------------
-#      Include sys/select.h if it exists and if it supplies things
-#      that appear to be useful and aren't already in sys/types.h.
-#      This appears to be true only on the RS/6000 under AIX.  Some
-#      systems like OSF/1 have a sys/select.h that's of no use, and
-#      other systems like SCO UNIX have a sys/select.h that's
-#      pernicious.  If "fd_set" isn't defined anywhere then set a
-#      special flag.
+# Include sys/select.h if it exists and if it supplies things
+# that appear to be useful and aren't already in sys/types.h.
+# This appears to be true only on the RS/6000 under AIX.  Some
+# systems like OSF/1 have a sys/select.h that's of no use, and
+# other systems like SCO UNIX have a sys/select.h that's
+# pernicious.  If "fd_set" isn't defined anywhere then set a
+# special flag.
 #--------------------------------------------------------------------
 
 AC_MSG_CHECKING([fd_set and sys/select])
@@ -133,14 +147,14 @@ if test $tk_ok = no; then
 fi
 
 #--------------------------------------------------------------------
-#      Check for various typedefs and provide substitutes if
-#      they don't exist.
+# Check for various typedefs and provide substitutes if
+# they don't exist.
 #--------------------------------------------------------------------
 
-AC_MODE_T
-AC_PID_T
-AC_SIZE_T
-AC_UID_T
+AC_TYPE_MODE_T
+AC_TYPE_PID_T
+AC_TYPE_SIZE_T
+AC_TYPE_UID_T
 
 #------------------------------------------------------------------------------
 #       Find out about time handling differences.
@@ -149,6 +163,18 @@ AC_UID_T
 AC_CHECK_HEADERS(sys/time.h)
 AC_HEADER_TIME
 
+#-------------------------------------------
+#     In OS/390 struct pwd has no pw_gecos field
+#-------------------------------------------
+
+AC_MSG_CHECKING([pw_gecos in struct pwd])
+AC_TRY_COMPILE([#include <pwd.h>],
+      [struct passwd pwd; pwd.pw_gecos;], tk_ok=yes, tk_ok=no)
+AC_MSG_RESULT($tk_ok)
+if test $tk_ok = yes; then
+    AC_DEFINE(HAVE_PW_GECOS)
+fi
+
 #--------------------------------------------------------------------
 #      Locate the X11 header files and the X11 library archive.  Try
 #      the ac_path_x macro first, but if it doesn't find the X stuff
@@ -158,69 +184,7 @@ AC_HEADER_TIME
 #      no include files, so double-check its result just to be safe.
 #--------------------------------------------------------------------
 
-AC_PATH_X
-not_really_there=""
-if test "$no_x" = ""; then
-    if test "$x_includes" = ""; then
-       AC_TRY_CPP([#include <X11/XIntrinsic.h>], , not_really_there="yes")
-    else
-       if test ! -r $x_includes/X11/Intrinsic.h; then
-           not_really_there="yes"
-       fi
-    fi
-fi
-if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then
-    AC_MSG_CHECKING(for X11 header files)
-    XINCLUDES="# no special path needed"
-    AC_TRY_CPP([#include <X11/Intrinsic.h>], , XINCLUDES="nope")
-    if test "$XINCLUDES" = nope; then
-        dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include"
-        for i in $dirs ; do
-           if test -r $i/X11/Intrinsic.h; then
-               AC_MSG_RESULT($i)
-               XINCLUDES=" -I$i"
-               break
-           fi
-        done
-    fi
-else
-    if test "$x_includes" != ""; then
-       XINCLUDES=-I$x_includes
-    else
-       XINCLUDES="# no special path needed"
-    fi
-fi
-if test "$XINCLUDES" = nope; then
-    AC_MSG_RESULT(couldn't find any!)
-    XINCLUDES="# no include files found"
-fi
-
-if test "$no_x" = yes; then
-    AC_MSG_CHECKING(for X11 libraries)
-    XLIBSW=nope
-    dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
-    for i in $dirs ; do
-       if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
-           AC_MSG_RESULT($i)
-           XLIBSW="-L$i -lX11"
-           x_libraries="$i"
-           break
-       fi
-    done
-else
-    if test "$x_libraries" = ""; then
-       XLIBSW=-lX11
-    else
-       XLIBSW="-L$x_libraries -lX11"
-    fi
-fi
-if test "$XLIBSW" = nope ; then
-    AC_CHECK_LIB(Xwindow, XCreateWindow, XLIBSW=-lXwindow)
-fi
-if test "$XLIBSW" = nope ; then
-    AC_MSG_RESULT(couldn't find any!  Using -lX11.)
-    XLIBSW=-lX11
-fi
+SC_PATH_X
 
 #--------------------------------------------------------------------
 #      Various manipulations on the search path used at runtime to
@@ -248,12 +212,6 @@ fi
 # variable LIB_RUNTIME_DIR.
 
 eval "TK_CC_SEARCH_FLAGS=\"$TCL_LD_SEARCH_FLAGS\""
-TK_LD_SEARCH_FLAGS=`echo ${TK_CC_SEARCH_FLAGS} |sed -e "s|-Wl,||g" -e "s|,| |g"`
-
-# CYGNUS LOCAL: Don't hack TK_LD_SEARCH_FLAGS if SHLIB_LD is gcc.
-case "${SHLIB_LD}" in
-  *gcc*) TK_LD_SEARCH_FLAGS="${TK_CC_SEARCH_FLAGS}" ;;
-esac
 
 #
 # CYGNUS LOCAL:  statically link on Solaris, HPUX & SunOS so that
@@ -304,11 +262,8 @@ esac
            fi
            ;;
 #
-# gdb linked statically w/ SunOS or HPUX, but not hpux11 wide
+# gdb linked statically w/ SunOS or HPUX
 #
-       hppa*64*-hp-hpux*)
-           ;;
-
         m68k-hp-hpux*|hppa*-hp-hpux*|sparc-sun-sunos*)
             if test "x$x_libraries" != "x" ;
             then
@@ -327,6 +282,18 @@ esac
 #
 # END CYGNUS LOCAL
 
+# The following case handles the differences between linking with "ld"
+# and the compiler
+
+case $SHLIB_LD in
+    *ld*)
+      TK_LD_SEARCH_FLAGS=`echo ${TK_CC_SEARCH_FLAGS} |sed -e "s|-Wl,||g" -e "s|,| |g"`
+      ;;
+    *)
+      TK_LD_SEARCH_FLAGS="${TK_CC_SEARCH_FLAGS}"
+      ;;
+esac
+
 #--------------------------------------------------------------------
 #      Check for the existence of various libraries.  The order here
 #      is important, so that then end up in the right order in the
@@ -380,6 +347,10 @@ AC_CACHE_CHECK([for socket libraries], tcl_cv_lib_sockets,
 ])
 test -z "$tcl_cv_lib_sockets" || LIBS="$LIBS $tcl_cv_lib_sockets"
 
+# Add the threads support libraries
+
+LIBS="$LIBS$THREADS_LIBS"
+
 #--------------------------------------------------------------------
 # One more check related to the X libraries.  The standard releases
 # of Ultrix don't support the "xauth" mechanism, so send won't work
@@ -435,113 +406,141 @@ AC_C_CHAR_UNSIGNED
 #      "fixstrtod" (provided by Tcl) that corrects the error.
 #--------------------------------------------------------------------
 
-AC_CHECK_FUNC(strtod, tk_strtod=1, tk_strtod=0)
-if test "$tk_strtod" = 1; then
-    AC_MSG_CHECKING([for Solaris 2.4 strtod bug])
-    AC_TRY_RUN([
-       extern double strtod();
-       int main()
-       {
-           char *string = "NaN";
-           char *term;
-           strtod(string, &term);
-           if ((term != string) && (term[-1] == 0)) {
-               exit(1);
-           }
-           exit(0);
-       }], tk_ok=1, tk_ok=0, tk_ok=0)
-    if test "$tk_ok" = 1; then
-       AC_MSG_RESULT(ok)
-    else
-       AC_MSG_RESULT(buggy)
-       AC_DEFINE(strtod, fixstrtod)
-    fi
-fi
+SC_BUGGY_STRTOD
 
 #--------------------------------------------------------------------
 #      The statements below define a collection of symbols related to
 #      building libtk as a shared library instead of a static library.
 #--------------------------------------------------------------------
 
-AC_ARG_ENABLE(shared,
-    [  --enable-shared         build libtk as a shared library],
-    [ok=$enableval], [ok=no])
+SC_ENABLE_SHARED
 
-# CYGNUS LOCAL: on machines where static linking of libX11 is important,
-# it is also important to build a static libtk.
-if test -n "$suppress_enable_shared"; then
-   ok=no
-fi
-# END CYGNUS LOCAL
+eval eval "TK_SHARED_LIB_SUFFIX=${SHARED_LIB_SUFFIX}"
+eval eval "TK_UNSHARED_LIB_SUFFIX=${UNSHARED_LIB_SUFFIX}"
 
-TK_SHARED_LIB_FILE=
-TK_UNSHARED_LIB_FILE=
-if test "$ok" = "yes" -a "${SHLIB_SUFFIX}" != ""; then
-    TK_SHARED_BUILD=1
+if test "${SHARED_BUILD}" = "1" -a "${SHLIB_SUFFIX}" != ""; then
     TK_SHLIB_CFLAGS="${SHLIB_CFLAGS}"
-    eval "TK_LIB_FILE=libtk${TCL_SHARED_LIB_SUFFIX}"
-    TK_SHARED_LIB_FILE="$TK_LIB_FILE"
-    MAKE_LIB="\${SHLIB_LD} -o ${TK_LIB_FILE} \${OBJS} \$(TK_LD_SEARCH_FLAGS) ${SHLIB_LD_LIBS}"
+    TCL_TOOL_SHARED_LIB_LONGNAME(TK_LIB_FILE, tk, ${TK_SHARED_LIB_SUFFIX})
+    MAKE_LIB="\${SHLIB_LD} -o \${TK_LIB_FILE} \${OBJS} \$(TK_LD_SEARCH_FLAGS) ${TCL_STUB_LIB_SPEC} \${LIBS}"
     RANLIB=":"
+
+#    TCL_STUB_FLAGS="-DUSE_TCL_STUBS"
+    TCL_STUB_FLAGS=""
 else
-    TK_SHARED_BUILD=0
     TK_SHLIB_CFLAGS=""
-    eval "TK_LIB_FILE=libtk${TCL_UNSHARED_LIB_SUFFIX}"
-    TK_UNSHARED_LIB_FILE="$TK_LIB_FILE"
-    MAKE_LIB="ar cr ${TK_LIB_FILE} \${OBJS}"
-fi
+    TCL_TOOL_STATIC_LIB_LONGNAME(TK_LIB_FILE, tk, ${TK_UNSHARED_LIB_SUFFIX})
+    MAKE_LIB="\${STLIB_LD} \${TK_LIB_FILE} \${OBJS}"
 
-dnl CYGNUS LOCAL
-TK_BUILD_INCLUDES="-I`cd $srcdir/../generic; pwd`"
-dnl END CYGNUS LOCAL
+    TCL_STUB_FLAGS=""
+fi
 
 # Note:  in the following variable, it's important to use the absolute
 # path name of the Tcl directory rather than "..":  this is because
 # AIX remembers this path and will attempt to use it at run-time to look
 # up the Tcl library.
 
-if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
-    TK_BUILD_LIB_SPEC="-L`pwd` -ltk${VERSION}"
-    TK_LIB_FLAG="-ltk${VERSION}\${TK_DBGX}"
+if test "$SHARED_BUILD" = 0 -o $TCL_NEEDS_EXP_FILE = 0; then
+    TCL_TOOL_LIB_SHORTNAME(TK_LIB_FLAG, tk, $TK_VERSION)
+    TCL_TOOL_LIB_SPEC(TK_BUILD_LIB_SPEC, `pwd`, ${TK_LIB_FLAG})
+    TCL_TOOL_LIB_SPEC(TK_LIB_SPEC, ${exec_prefix}/lib, ${TK_LIB_FLAG})
+    TK_BUILD_EXP_FILE=""
+    TK_EXP_FILE=""
 else
-    TK_BUILD_LIB_SPEC="-L`pwd` -ltk`echo ${VERSION} | tr -d .`"
-    TK_LIB_FLAG="-ltk`echo ${VERSION} | tr -d .`\${TK_DBGX}"
+    TK_BUILD_EXP_FILE="lib.exp"
+    eval "TK_EXP_FILE=libtk${TCL_EXPORT_FILE_SUFFIX}"
+    
+    TK_BUILD_LIB_SPEC="-bI:`pwd`/${TK_BUILD_EXP_FILE}"
+    TK_LIB_SPEC="-bI:${exec_prefix}/lib/${TK_EXP_FILE}"
 fi
+TK_SHARED_BUILD=${SHARED_BUILD}
+
+dnl CYGNUS LOCAL
+TK_BUILD_INCLUDES="-I`cd $srcdir/../generic; pwd`"
+dnl END CYGNUS LOCAL
 
-TK_LIB_FULL_PATH="`pwd`/${TK_LIB_FILE}"
+#--------------------------------------------------------------------
+# The statements below define various symbols relating to creating
+# the stub'd version of the Tk library
+#
+# For now, linking to Tcl stubs is not supported with Tk. It causes
+# too many problems with linking.  When Tk is a fully loadable 
+# extension, linking the the Tcl stubs will be supported.
+#--------------------------------------------------------------------
 
+TCL_TOOL_STATIC_LIB_LONGNAME(TK_STUB_LIB_FILE, tkstub, ${TK_UNSHARED_LIB_SUFFIX})
+
+MAKE_STUB_LIB="\${STLIB_LD} \${STUB_LIB_FILE} \${STUB_LIB_OBJS}"
+
+TCL_TOOL_LIB_SHORTNAME(TK_STUB_LIB_FLAG, tkstub, ${TK_VERSION})
+TCL_TOOL_LIB_SPEC(TK_BUILD_STUB_LIB_SPEC, `pwd`, ${TK_STUB_LIB_FLAG})
+TCL_TOOL_LIB_SPEC(TK_STUB_LIB_SPEC, ${exec_prefix}/lib, ${TK_STUB_LIB_FLAG})
+
+TCL_TOOL_LIB_PATH(TK_BUILD_STUB_LIB_PATH, `pwd`, ${TK_STUB_LIB_FILE})
+TCL_TOOL_LIB_PATH(TK_STUB_LIB_PATH, `pwd`, ${TK_STUB_LIB_FILE})
+
+AC_SUBST(TK_STUB_LIB_FILE)
+AC_SUBST(TK_STUB_LIB_FLAG)
+AC_SUBST(TK_BUILD_STUB_LIB_SPEC)
+AC_SUBST(TK_STUB_LIB_SPEC)
+AC_SUBST(TK_BUILD_STUB_LIB_PATH)
+AC_SUBST(TK_STUB_LIB_PATH)
+AC_SUBST(MAKE_STUB_LIB)
+AC_SUBST(TK_STUB_FLAGS)
+AC_SUBST(TK_BUILD_EXP_FILE)
+AC_SUBST(TK_EXP_FILE)
+
+AC_SUBST(TCL_STUB_FLAGS)
+AC_SUBST(TK_BUILD_EXP_FILE)
+AC_SUBST(TK_EXP_FILE)
+
+AC_SUBST(CFLAGS_DEFAULT)
+AC_SUBST(CFLAGS_DEBUG)
+AC_SUBST(CFLAGS_OPTIMIZE)
+AC_SUBST(LDFLAGS_DEFAULT)
+AC_SUBST(LDFLAGS_DEBUG)
+AC_SUBST(LDFLAGS_OPTIMIZE)
+AC_SUBST(TK_DBGX)
 AC_SUBST(DL_LIBS)
-AC_SUBST(LD_FLAGS)
+AC_SUBST(EXTRA_CFLAGS)
 AC_SUBST(MATH_LIBS)
+AC_SUBST(AR)
+AC_SUBST(RANLIB)
 AC_SUBST(MAKE_LIB)
 AC_SUBST(SHLIB_CFLAGS)
+AC_SUBST(TK_SHLIB_CFLAGS)
+AC_SUBST(STLIB_LD)
 AC_SUBST(SHLIB_LD)
 AC_SUBST(SHLIB_LD_LIBS)
 AC_SUBST(SHLIB_SUFFIX)
 AC_SUBST(SHLIB_VERSION)
 AC_SUBST(TCL_BIN_DIR)
+AC_SUBST(TCL_LIB_FULL_PATH)
+AC_SUBST(TCL_LIB_SPEC)
+AC_SUBST(TCL_LIB_FLAG)
+AC_SUBST(TCL_BUILD_STUB_LIB_SPEC)
 AC_SUBST(TCL_BUILD_LIB_SPEC)
+AC_SUBST(TCL_DBGX)
+AC_SUBST(TCL_LIB_FLAG)
 AC_SUBST(TCL_SRC_DIR)
 AC_SUBST(TCL_VERSION)
-dnl CYGNUS LOCAL
-AC_SUBST(TK_BUILD_INCLUDES)
-dnl END CYGNUS LOCAL
 AC_SUBST(TK_BUILD_LIB_SPEC)
+AC_SUBST(TK_LIB_FULL_PATH)
 AC_SUBST(TK_CC_SEARCH_FLAGS)
 AC_SUBST(TK_LD_SEARCH_FLAGS)
-AC_SUBST(TK_LIB_FULL_PATH)
 AC_SUBST(TK_LIB_FILE)
 AC_SUBST(TK_LIB_FLAG)
 AC_SUBST(TK_LIB_SPEC)
 AC_SUBST(TK_MAJOR_VERSION)
 AC_SUBST(TK_MINOR_VERSION)
 AC_SUBST(TK_PATCH_LEVEL)
-AC_SUBST(TK_SHLIB_CFLAGS)
 AC_SUBST(TK_SRC_DIR)
 AC_SUBST(TK_VERSION)
 AC_SUBST(XINCLUDES)
 AC_SUBST(XLIBSW)
 AC_SUBST(TK_SHARED_BUILD)
+dnl CYGNUS LOCAL
+AC_SUBST(TK_BUILD_INCLUDES)
+dnl END CYGNUS LOCAL
 # CYGNUS LOCAL
 # Need more variables to keep shared/static linking separate.
 AC_SUBST(TCL_SHARED_LIB_SUFFIX)
@@ -551,3 +550,4 @@ AC_SUBST(TK_UNSHARED_LIB_FILE)
 # END CYGNUS LOCAL
 
 AC_OUTPUT(Makefile tkConfig.sh)
+
index a07fbd9..7af644e 100644 (file)
-# Visual C++ 2.x and 4.0 makefile
+# This file is a Makefile for Tk.  If it has the name "Makefile.in"
+# then it is a template for a Makefile;  to generate the actual Makefile,
+# run "./configure", which is a configuration script generated by the
+# "autoconf" program (constructs like "@foo@" will get replaced in the
+# actual Makefile.
 #
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-# 
-# Copyright (c) 1995-1996 Sun Microsystems, Inc.
-# SCCS: @(#) makefile.vc 1.63 97/08/13 13:33:32
-
-# Does not depend on the presence of any environment variables in
-# order to compile tcl; all needed information is derived from 
-# location of the compiler directories.
-
-# This file is CYGNUS LOCAL.  It is a copy of makefile.vc from the
-# standard tk distribution, modified to work with cygwin and an
-# autoconf configure script.  I have chosen to minimize the number of
-# changes, so the comments continue to refer to Visual C++ and the
-# like.  This should make it easier to merge in a new version if that
-# is necessary.
-
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-srcdir = @srcdir@
-VPATH = $(srcdir):$(srcdir)/../xlib:$(srcdir)/../generic:$(srcdir)/../unix:$(srcdir)/../win/rc
-libdir=@libdir@
-bindir=@bindir@
-includedir=@includedir@
-mandir=@mandir@
-datadir=@datadir@
-host_alias=@host_alias@
-
-INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_DATA = @INSTALL_DATA@
-
-CC = @CC@
-CFLAGS = @CFLAGS@
-NM = @NM@
-AS = @AS@
-LD = @LD@
-DLLTOOL = @DLLTOOL@
-WINDRES = @WINDRES@
-
-OBJEXT=@OBJEXT@
-
-DLL_LDFLAGS = @DLL_LDFLAGS@
-DLL_LDLIBS = @DLL_LDLIBS@
-
-# Current Tk version;  used in various names.
-
-DIRVERSION = @TK_VERSION@
+# RCS: @(#) $Id$
+
+TCLVERSION             = @TCL_VERSION@
+VERSION                        = @TK_VERSION@
+
+#----------------------------------------------------------------
+# Things you can change to personalize the Makefile for your own
+# site (you can make these changes in either Makefile.in or
+# Makefile, but changes to Makefile will get lost if you re-run
+# the configuration script).
+#----------------------------------------------------------------
+
+# Default top-level directories in which to install architecture-
+# specific files (exec_prefix) and machine-independent files such
+# as scripts (prefix).  The values specified here may be overridden
+# at configure-time with the --exec-prefix and --prefix options
+# to the "configure" script.
+
+prefix                 = @prefix@
+exec_prefix            = @exec_prefix@
+bindir                 = @bindir@
+libdir                 = @libdir@
+includedir             = @includedir@
+mandir                 = @mandir@
 
 # The following definition can be set to non-null for special systems
 # like AFS with replication.  It allows the pathnames used for installation
 # to be different than those used for actually reference files at
 # run-time.  INSTALL_ROOT is prepended to $prefix and $exec_prefix
 # when installing files.
-INSTALL_ROOT =
+INSTALL_ROOT           =
 
-# Directory from which applications will reference the library of Tcl
+# Directory from which applications will reference the library of Tk
 # scripts (note: you can set the TK_LIBRARY environment variable at
-# run-time to override the compiled-in location):
-TK_LIBRARY =           $(datadir)/tk$(DIRVERSION)
+# run-time to override this value):
+TK_LIBRARY             = @datadir@/tk$(VERSION)
 
-# Path name to use when installing library scripts:
-SCRIPT_INSTALL_DIR =   $(INSTALL_ROOT)$(TK_LIBRARY)
+# Path to use at runtime to refer to LIB_INSTALL_DIR:
+LIB_RUNTIME_DIR                = $(libdir)
+
+# Directory in which to install the program wish:
+BIN_INSTALL_DIR                = $(INSTALL_ROOT)$(bindir)
 
 # Directory in which to install the .a or .so binary for the Tk library:
-LIB_INSTALL_DIR =      $(INSTALL_ROOT)$(libdir)
+LIB_INSTALL_DIR                = $(INSTALL_ROOT)$(libdir)
 
-# Directory in which to install the program wish:
-BIN_INSTALL_DIR =      $(INSTALL_ROOT)$(bindir)
+# Path name to use when installing library scripts:
+SCRIPT_INSTALL_DIR     = $(INSTALL_ROOT)$(TK_LIBRARY)
 
 # Directory in which to install the include file tk.h:
-INCLUDE_INSTALL_DIR =  $(INSTALL_ROOT)$(includedir)
+INCLUDE_INSTALL_DIR    = $(INSTALL_ROOT)$(includedir)
+
+# Top-level directory for manual entries:
+MAN_INSTALL_DIR                = $(INSTALL_ROOT)$(mandir)
 
-# Directory in which to install the X11 header files.  These files are
-# not machine independent, so they should not go in includedir.
-X11_INCLUDE_INSTALL_DIR = $(INSTALL_ROOT)$(includedir)/X11
+# Directory in which to install manual entry for wish:
+MAN1_INSTALL_DIR       = $(MAN_INSTALL_DIR)/man1
+
+# Directory in which to install manual entries for Tk's C library
+# procedures:
+MAN3_INSTALL_DIR       = $(MAN_INSTALL_DIR)/man3
+
+# Directory in which to install manual entries for the built-in
+# Tk commands:
+MANN_INSTALL_DIR       = $(MAN_INSTALL_DIR)/mann
+
+# Libraries built with optimization switches have this additional extension
+TK_DBGX                        = @TK_DBGX@
+
+# The directory containing the Tcl source and header files.
+TCL_SRC_DIR            = @TCL_SRC_DIR@
+
+# The directory containing the Tcl library archive file appropriate
+# for this version of Tk:
+TCL_BIN_DIR            = @TCL_BIN_DIR@
+
+# The directory containing the Tcl sources and headers appropriate
+# for this version of Tk ("srcdir" will be replaced or has already
+# been replaced by the configure script):
+TCL_GENERIC_DIR        = @TCL_SRC_DIR@/generic
+
+# This program converts from POSIX to Windows native paths.
+CYGPATH                        = @CYGPATH@
+
+# The name of the Tcl library.
+TCL_LIB_SPEC     = @TCL_BUILD_LIB_SPEC@
+TCL_STUB_LIB_SPEC = @TCL_BUILD_STUB_LIB_SPEC@
+
+SRC_DIR                        = @srcdir@
+ROOT_DIR               = $(SRC_DIR)/..
+WIN_DIR                        = $(SRC_DIR)
+UNIX_DIR               = $(SRC_DIR)/../unix
+GENERIC_DIR            = $(SRC_DIR)/../generic
+BITMAP_DIR             = $(ROOT_DIR)/bitmaps
+XLIB_DIR               = $(ROOT_DIR)/xlib
+RC_DIR                 = $(WIN_DIR)/rc
+
+ROOT_DIR_NATIVE                = $(shell $(CYGPATH) '$(ROOT_DIR)')
+WIN_DIR_NATIVE         = $(shell $(CYGPATH) '$(WIN_DIR)')
+GENERIC_DIR_NATIVE     = $(shell $(CYGPATH) '$(GENERIC_DIR)')
+BITMAP_DIR_NATIVE      = $(shell $(CYGPATH) '$(ROOT_DIR)/bitmaps')
+XLIB_DIR_NATIVE                = $(shell $(CYGPATH) '$(ROOT_DIR)/xlib')
+TCL_GENERIC_NATIVE     = $(shell $(CYGPATH) '$(TCL_GENERIC_DIR)')
+TCL_SRC_DIR_NATIVE      = $(shell $(CYGPATH) '$(TCL_SRC_DIR)')
+TCL_BIN_DIR_NATIVE      = $(shell $(CYGPATH) '$(TCL_BIN_DIR)')
+RC_DIR_NATIVE          = $(shell $(CYGPATH) '$(RC_DIR)')
+
+DLLSUFFIX              = @DLLSUFFIX@
+LIBSUFFIX              = @LIBSUFFIX@
+EXESUFFIX              = @EXESUFFIX@
+
+TK_STUB_LIB_FILE       = @TK_STUB_LIB_FILE@
+TK_LIB_FILE            = @TK_LIB_FILE@
+TK_DLL_FILE            = @TK_DLL_FILE@
+
+SHARED_LIBRARIES       = $(TK_DLL_FILE) $(TK_STUB_LIB_FILE)
+STATIC_LIBRARIES       = $(TK_LIB_FILE)
+
+WISH_RES               = @WISH_RES@
+TK_RES                 = @TK_RES@
+
+WISH                   = wish$(VER)${EXESUFFIX}
+TKTEST                 = tktest${EXEEXT}
+CAT32                  = cat32$(EXEEXT)
+MAN2TCL                        = man2tcl$(EXEEXT)
+
+@SET_MAKE@
+
+# Setting the VPATH variable to a list of paths will cause the 
+# makefile to look into these paths when resolving .c to .obj
+# dependencies.
+
+VPATH = $(GENERIC_DIR):$(WIN_DIR):$(UNIX_DIR):$(XLIB_DIR):$(RC_DIR)
+
+# warning flags
+CFLAGS_WARNING = @CFLAGS_WARNING@
+
+# The default switches for optimization or debugging
+CFLAGS_DEBUG    = @CFLAGS_DEBUG@
+CFLAGS_OPTIMIZE        = @CFLAGS_OPTIMIZE@
+
+# The default switches for optimization or debugging
+LDFLAGS_DEBUG    = @LDFLAGS_DEBUG@
+LDFLAGS_OPTIMIZE = @LDFLAGS_OPTIMIZE@
+
+# To change the compiler switches, for example to change from optimization to
+# debugging symbols, change the following line:
+#CFLAGS                = $(CFLAGS_DEBUG)
+#CFLAGS                = $(CFLAGS_OPTIMIZE)
+#CFLAGS                = $(CFLAGS_DEBUG) $(CFLAGS_OPTIMIZE)
+CFLAGS         = @CFLAGS@ @CFLAGS_DEFAULT@
+
+# Special compiler flags to use when building man2tcl on Windows.
+MAN2TCLFLAGS   = @MAN2TCLFLAGS@
+
+AR             = @AR@
+RANLIB         = @RANLIB@
+CC             = @CC@
+RC             = @RC@
+RES            = @RES@
+AC_FLAGS       = @EXTRA_CFLAGS@ @DEFS@
+CPPFLAGS       = @CPPFLAGS@
+LDFLAGS                = @LDFLAGS@ @LDFLAGS_DEFAULT@
+LDFLAGS_CONSOLE        = @LDFLAGS_CONSOLE@
+LDFLAGS_WINDOW = @LDFLAGS_WINDOW@
+EXEEXT         = @EXEEXT@
+OBJEXT         = @OBJEXT@
+LIBS_GUI       = @LIBS_GUI@
+STLIB_LD       = @STLIB_LD@
+SHLIB_LD       = @SHLIB_LD@
+SHLIB_CFLAGS   = @SHLIB_CFLAGS@
+SHLIB_LD_LIBS  = @SHLIB_LD_LIBS@ $(TCL_STUB_LIB_SPEC) $(LIBS_GUI)
+SHLIB_SUFFIX   = @SHLIB_SUFFIX@
+VER            = @TK_MAJOR_VERSION@@TK_MINOR_VERSION@
+DOTVER         = @TK_MAJOR_VERSION@.@TK_MINOR_VERSION@
+LIBS           = @LIBS@ $(LIBS_GUI)
+RMDIR          = rm -rf
+MKDIR          = mkdir -p
+SHELL          = @SHELL@
+RM             = rm -f
+COPY           = cp
+
+# FIXME: Add a "make shell SCRIPT=foo.tcl" argument
+# so that a shell can easily be run from the build dir.
+TCLSH_PROG     = $(TCL_BIN_DIR)/tclsh$(VER)
+
+CC_SWITCHES = ${CFLAGS} ${CFLAGS_WARNING} ${SHLIB_CFLAGS} \
+-I"${GENERIC_DIR_NATIVE}" -I"${WIN_DIR_NATIVE}" \
+-I"${XLIB_DIR_NATIVE}" -I"${BITMAP_DIR_NATIVE}" \
+ -I"${TCL_GENERIC_NATIVE}" ${AC_FLAGS}
+
+CC_OBJNAME = @CC_OBJNAME@
+CC_EXENAME = @CC_EXENAME@
+
+STUB_CC_SWITCHES       = ${CC_SWITCHES} -DUSE_TCL_STUBS
+CON_CC_SWITCHES                = ${CC_SWITCHES} -DCONSOLE
+
+# Tk used to let the configure script choose which program to use
+# for installing, but there are just too many different versions of
+# "install" around;  better to use the install-sh script that comes
+# with the distribution, which is slower but guaranteed to work.
+
+INSTALL                = cp
+INSTALL_PROGRAM = ${INSTALL}
+INSTALL_DATA   = ${INSTALL}
+
+WISH_OBJS = \
+       winMain.$(OBJEXT)
+
+TCLTEST_OBJS = \
+       ${TCL_BIN_DIR}/tclThreadTest.$(OBJEXT)
+
+TCLTEST_OBJS_NATIVE = \
+       "${TCL_BIN_DIR_NATIVE}/tclThreadTest.$(OBJEXT)"
+
+TKTEST_OBJS = \
+       $(TCLTEST_OBJS) \
+       testMain.$(OBJEXT) \
+       tkSquare.$(OBJEXT) \
+       tkTest.$(OBJEXT) \
+       tkWinTest.$(OBJEXT)
+
+TKTEST_OBJS_NATIVE = \
+       $(TCLTEST_OBJS_NATIVE) \
+       testMain.$(OBJEXT) \
+       tkSquare.$(OBJEXT) \
+       tkTest.$(OBJEXT) \
+       tkWinTest.$(OBJEXT)
+
+XLIB_OBJS = \
+       xcolors.$(OBJEXT) \
+       xdraw.$(OBJEXT) \
+       xgc.$(OBJEXT) \
+       ximage.$(OBJEXT) \
+       xutil.$(OBJEXT)
+
+TK_OBJS = \
+       tkConsole.$(OBJEXT) \
+       tkUnixMenubu.$(OBJEXT) \
+       tkUnixScale.$(OBJEXT) \
+       $(XLIB_OBJS) \
+       tkWin3d.$(OBJEXT) \
+       tkWin32Dll.$(OBJEXT) \
+       tkWinButton.$(OBJEXT) \
+       tkWinClipboard.$(OBJEXT) \
+       tkWinColor.$(OBJEXT) \
+       tkWinConfig.$(OBJEXT) \
+       tkWinCursor.$(OBJEXT) \
+       tkWinDialog.$(OBJEXT) \
+       tkWinDraw.$(OBJEXT) \
+       tkWinEmbed.$(OBJEXT) \
+       tkWinFont.$(OBJEXT) \
+       tkWinImage.$(OBJEXT) \
+       tkWinInit.$(OBJEXT) \
+       tkWinKey.$(OBJEXT) \
+       tkWinMenu.$(OBJEXT) \
+       tkWinPixmap.$(OBJEXT) \
+       tkWinPointer.$(OBJEXT) \
+       tkWinRegion.$(OBJEXT) \
+       tkWinScrlbr.$(OBJEXT) \
+       tkWinSend.$(OBJEXT) \
+       tkWinWindow.$(OBJEXT) \
+       tkWinWm.$(OBJEXT) \
+       tkWinX.$(OBJEXT) \
+       stubs.$(OBJEXT) \
+       tk3d.$(OBJEXT) \
+       tkArgv.$(OBJEXT) \
+       tkAtom.$(OBJEXT) \
+       tkBind.$(OBJEXT) \
+       tkBitmap.$(OBJEXT) \
+       tkButton.$(OBJEXT) \
+       tkCanvArc.$(OBJEXT) \
+       tkCanvBmap.$(OBJEXT) \
+       tkCanvImg.$(OBJEXT) \
+       tkCanvLine.$(OBJEXT) \
+       tkCanvPoly.$(OBJEXT) \
+       tkCanvPs.$(OBJEXT) \
+       tkCanvText.$(OBJEXT) \
+       tkCanvUtil.$(OBJEXT) \
+       tkCanvWind.$(OBJEXT) \
+       tkCanvas.$(OBJEXT) \
+       tkClipboard.$(OBJEXT) \
+       tkCmds.$(OBJEXT) \
+       tkColor.$(OBJEXT) \
+       tkConfig.$(OBJEXT) \
+       tkCursor.$(OBJEXT) \
+       tkEntry.$(OBJEXT) \
+       tkError.$(OBJEXT) \
+       tkEvent.$(OBJEXT) \
+       tkFileFilter.$(OBJEXT) \
+       tkFocus.$(OBJEXT) \
+       tkFont.$(OBJEXT) \
+       tkFrame.$(OBJEXT) \
+       tkGC.$(OBJEXT) \
+       tkGeometry.$(OBJEXT) \
+       tkGet.$(OBJEXT) \
+       tkGrab.$(OBJEXT) \
+       tkGrid.$(OBJEXT) \
+       tkImage.$(OBJEXT) \
+       tkImgBmap.$(OBJEXT) \
+       tkImgGIF.$(OBJEXT) \
+       tkImgPPM.$(OBJEXT) \
+       tkImgPhoto.$(OBJEXT) \
+       tkImgUtil.$(OBJEXT) \
+       tkListbox.$(OBJEXT) \
+       tkMacWinMenu.$(OBJEXT) \
+       tkMain.$(OBJEXT) \
+       tkMenu.$(OBJEXT) \
+       tkMenubutton.$(OBJEXT) \
+       tkMenuDraw.$(OBJEXT) \
+       tkMessage.$(OBJEXT) \
+       tkObj.$(OBJEXT) \
+       tkOldConfig.$(OBJEXT) \
+       tkOption.$(OBJEXT) \
+       tkPack.$(OBJEXT) \
+       tkPlace.$(OBJEXT) \
+       tkPointer.$(OBJEXT) \
+       tkRectOval.$(OBJEXT) \
+       tkScale.$(OBJEXT) \
+       tkScrollbar.$(OBJEXT) \
+       tkSelect.$(OBJEXT) \
+       tkText.$(OBJEXT) \
+       tkTextBTree.$(OBJEXT) \
+       tkTextDisp.$(OBJEXT) \
+       tkTextImage.$(OBJEXT) \
+       tkTextIndex.$(OBJEXT) \
+       tkTextMark.$(OBJEXT) \
+       tkTextTag.$(OBJEXT) \
+       tkTextWind.$(OBJEXT) \
+       tkTrig.$(OBJEXT) \
+       tkUtil.$(OBJEXT) \
+       tkVisual.$(OBJEXT) \
+       tkStubInit.$(OBJEXT) \
+       tkStubLib.$(OBJEXT) \
+       tkWindow.$(OBJEXT)
+
+STUB_OBJS = \
+       tkStubLib.$(OBJEXT) \
+       tkStubImg.$(OBJEXT)
+
+TCL_DOCS = "$(TCL_SRC_DIR_NATIVE)"/doc/*.[13n]
+TK_DOCS = "$(ROOT_DIR_NATIVE)"/doc/*.[13n]
+CORE_DOCS = $(TCL_DOCS) $(TK_DOCS)
 
 DEMOPROGS = browse hello ixset rmt rolodex square tcolor timer widget
 
-#
-# Project directories
-#
-# ROOT    = top of source tree
-#
-# TMPDIR  = location where .obj files should be stored during build
-#
-# TOOLS32 = location of VC++ 32-bit development tools. Note that the
-#          VC++ 2.0 header files are broken, so you need to use the
-#          ones that come with the developer network CD's, or later
-#          versions of VC++.
-#
-# TCLDIR = location of top of Tcl source heirarchy
-#
+# Main targets.  The default target -- all -- builds the binaries, 
+# performs any post processing on libraries or documents.
+
+all: binaries libraries doc
+
+binaries: @LIBRARIES@ $(WISH)
+
+libraries:
+
+$(ROOT_DIR)/doc/man.macros:
+       $(INSTALL_DATA) @TCL_SRC_DIR@/doc/man.macros $(ROOT_DIR)/doc/man.macros
 
-ROOT   = $(srcdir)/..
-TMPDIR = .
-TOOLS32        = c:\msdev
-TCLDIR = $(srcdir)/../../tcl
-
-# Set this to the appropriate value of /MACHINE: for your platform
-MACHINE        = IX86
-
-# Comment the following line to compile with symbols
-NODEBUG=1
-
-# uncomment the following two lines to compile with TCL_MEM_DEBUG
-#DEBUGDEFINES  =-DTCL_MEM_DEBUG
-
-######################################################################
-# Do not modify below this line
-######################################################################
-
-VERSION = 80
-
-TCLDLL = cygtcl$(VERSION).dll
-TCLLIB = libtcl$(VERSION).a
-TCLPLUGINDLL = cygtcl$(VERSION)p.dll
-TCLPLUGINLIB = libtcl$(VERSION)p.a
-TKDLL = cygtk$(VERSION).dll
-TKLIB = libtk$(VERSION).a
-TKPLUGINDLL = cygtk$(VERSION)p.dll
-TKPLUGINLIB = libtk$(VERSION)p.a
-
-WISH = cygwish$(VERSION).exe
-WISHP = cygwishp$(VERSION).exe
-TKTEST = tktest.exe
-DUMPEXTS = $(TMPDIR)/dumpexts.exe
-
-WISHOBJS = \
-       $(TMPDIR)/tkConsole.$(OBJEXT) \
-       $(TMPDIR)/winMain.$(OBJEXT)
-
-TKTESTOBJS = \
-       $(TMPDIR)/tkConsole.$(OBJEXT) \
-       $(TMPDIR)/tkTest.$(OBJEXT) \
-       $(TMPDIR)/tkSquare.$(OBJEXT) \
-       $(TMPDIR)/testMain.$(OBJEXT)
-
-XLIBOBJS = \
-       $(TMPDIR)/xcolors.$(OBJEXT) \
-       $(TMPDIR)/xdraw.$(OBJEXT) \
-       $(TMPDIR)/xgc.$(OBJEXT) \
-       $(TMPDIR)/ximage.$(OBJEXT) \
-       $(TMPDIR)/xutil.$(OBJEXT)
-
-TKOBJS = \
-       $(TMPDIR)/tkUnixMenubu.$(OBJEXT) \
-       $(TMPDIR)/tkUnixScale.$(OBJEXT) \
-       $(XLIBOBJS) \
-       $(TMPDIR)/tkWin3d.$(OBJEXT) \
-       $(TMPDIR)/tkWin32Dll.$(OBJEXT) \
-       $(TMPDIR)/tkWinButton.$(OBJEXT) \
-       $(TMPDIR)/tkWinClipboard.$(OBJEXT) \
-       $(TMPDIR)/tkWinColor.$(OBJEXT) \
-       $(TMPDIR)/tkWinCursor.$(OBJEXT) \
-       $(TMPDIR)/tkWinDialog.$(OBJEXT) \
-       $(TMPDIR)/tkWinDraw.$(OBJEXT) \
-       $(TMPDIR)/tkWinEmbed.$(OBJEXT) \
-       $(TMPDIR)/tkWinFont.$(OBJEXT) \
-       $(TMPDIR)/tkWinImage.$(OBJEXT) \
-       $(TMPDIR)/tkWinInit.$(OBJEXT) \
-       $(TMPDIR)/tkWinKey.$(OBJEXT) \
-       $(TMPDIR)/tkWinMenu.$(OBJEXT) \
-       $(TMPDIR)/tkWinPixmap.$(OBJEXT) \
-       $(TMPDIR)/tkWinPointer.$(OBJEXT) \
-       $(TMPDIR)/tkWinRegion.$(OBJEXT) \
-       $(TMPDIR)/tkWinScrlbr.$(OBJEXT) \
-       $(TMPDIR)/tkWinSend.$(OBJEXT) \
-       $(TMPDIR)/tkWinWindow.$(OBJEXT) \
-       $(TMPDIR)/tkWinWm.$(OBJEXT) \
-       $(TMPDIR)/tkWinX.$(OBJEXT) \
-       $(TMPDIR)/stubs.$(OBJEXT) \
-       $(TMPDIR)/tk3d.$(OBJEXT) \
-       $(TMPDIR)/tkArgv.$(OBJEXT) \
-       $(TMPDIR)/tkAtom.$(OBJEXT) \
-       $(TMPDIR)/tkBind.$(OBJEXT) \
-       $(TMPDIR)/tkBitmap.$(OBJEXT) \
-       $(TMPDIR)/tkButton.$(OBJEXT) \
-       $(TMPDIR)/tkCanvArc.$(OBJEXT) \
-       $(TMPDIR)/tkCanvBmap.$(OBJEXT) \
-       $(TMPDIR)/tkCanvImg.$(OBJEXT) \
-       $(TMPDIR)/tkCanvLine.$(OBJEXT) \
-       $(TMPDIR)/tkCanvPoly.$(OBJEXT) \
-       $(TMPDIR)/tkCanvPs.$(OBJEXT) \
-       $(TMPDIR)/tkCanvText.$(OBJEXT) \
-       $(TMPDIR)/tkCanvUtil.$(OBJEXT) \
-       $(TMPDIR)/tkCanvWind.$(OBJEXT) \
-       $(TMPDIR)/tkCanvas.$(OBJEXT) \
-       $(TMPDIR)/tkClipboard.$(OBJEXT) \
-       $(TMPDIR)/tkCmds.$(OBJEXT) \
-       $(TMPDIR)/tkColor.$(OBJEXT) \
-       $(TMPDIR)/tkConfig.$(OBJEXT) \
-       $(TMPDIR)/tkCursor.$(OBJEXT) \
-       $(TMPDIR)/tkEntry.$(OBJEXT) \
-       $(TMPDIR)/tkError.$(OBJEXT) \
-       $(TMPDIR)/tkEvent.$(OBJEXT) \
-       $(TMPDIR)/tkFileFilter.$(OBJEXT) \
-       $(TMPDIR)/tkFocus.$(OBJEXT) \
-       $(TMPDIR)/tkFont.$(OBJEXT) \
-       $(TMPDIR)/tkFrame.$(OBJEXT) \
-       $(TMPDIR)/tkGC.$(OBJEXT) \
-       $(TMPDIR)/tkGeometry.$(OBJEXT) \
-       $(TMPDIR)/tkGet.$(OBJEXT) \
-       $(TMPDIR)/tkGrab.$(OBJEXT) \
-       $(TMPDIR)/tkGrid.$(OBJEXT) \
-       $(TMPDIR)/tkImage.$(OBJEXT) \
-       $(TMPDIR)/tkImgBmap.$(OBJEXT) \
-       $(TMPDIR)/tkImgGIF.$(OBJEXT) \
-       $(TMPDIR)/tkImgPPM.$(OBJEXT) \
-       $(TMPDIR)/tkImgPhoto.$(OBJEXT) \
-       $(TMPDIR)/tkImgUtil.$(OBJEXT) \
-       $(TMPDIR)/tkListbox.$(OBJEXT) \
-       $(TMPDIR)/tkMacWinMenu.$(OBJEXT) \
-       $(TMPDIR)/tkMain.$(OBJEXT) \
-       $(TMPDIR)/tkMenu.$(OBJEXT) \
-       $(TMPDIR)/tkMenubutton.$(OBJEXT) \
-       $(TMPDIR)/tkMenuDraw.$(OBJEXT) \
-       $(TMPDIR)/tkMessage.$(OBJEXT) \
-       $(TMPDIR)/tkOption.$(OBJEXT) \
-       $(TMPDIR)/tkPack.$(OBJEXT) \
-       $(TMPDIR)/tkPlace.$(OBJEXT) \
-       $(TMPDIR)/tkPointer.$(OBJEXT) \
-       $(TMPDIR)/tkRectOval.$(OBJEXT) \
-       $(TMPDIR)/tkScale.$(OBJEXT) \
-       $(TMPDIR)/tkScrollbar.$(OBJEXT) \
-       $(TMPDIR)/tkSelect.$(OBJEXT) \
-       $(TMPDIR)/tkText.$(OBJEXT) \
-       $(TMPDIR)/tkTextBTree.$(OBJEXT) \
-       $(TMPDIR)/tkTextDisp.$(OBJEXT) \
-       $(TMPDIR)/tkTextImage.$(OBJEXT) \
-       $(TMPDIR)/tkTextIndex.$(OBJEXT) \
-       $(TMPDIR)/tkTextMark.$(OBJEXT) \
-       $(TMPDIR)/tkTextTag.$(OBJEXT) \
-       $(TMPDIR)/tkTextWind.$(OBJEXT) \
-       $(TMPDIR)/tkTrig.$(OBJEXT) \
-       $(TMPDIR)/tkUtil.$(OBJEXT) \
-       $(TMPDIR)/tkVisual.$(OBJEXT) \
-       $(TMPDIR)/tkWindow.$(OBJEXT)
-
-cc32           = $(TOOLS32)\bin\cl.exe
-link32         = $(TOOLS32)\bin\link.exe
-rc32           = $(TOOLS32)\bin\rc.exe
-include32      = -I$(TOOLS32)\include
-
-WINDIR          = $(ROOT)/win
-GENERICDIR     = $(ROOT)/generic
-XLIBDIR                = $(ROOT)/xlib
-BITMAPDIR      = $(ROOT)/bitmaps
-TCLLIBDIR       = ../../tcl/win
-RCDIR          = $(WINDIR)/rc
-
-TK_INCLUDES    = -I$(WINDIR) -I$(GENERICDIR) -I$(BITMAPDIR) -I$(XLIBDIR) \
-                       -I$(TCLDIR)/generic
-TK_DEFINES     = $(DEBUGDEFINES)
-
-TK_CFLAGS      = $(cdebug) $(cflags) $(cvarsdll) \
-                       $(TK_INCLUDES) $(TK_DEFINES) $(CFLAGS)
-
-######################################################################
-# Link flags
-######################################################################
-
-#!IFDEF NODEBUG
-#ldebug = /RELEASE
-#!ELSE
-#ldebug = -debug:full -debugtype:cv
-#!ENDIF
-
-# declarations common to all linker options
-# lcommon = /NODEFAULTLIB /RELEASE /NOLOGO
-
-# declarations for use on Intel i386, i486, and Pentium systems
-#!IF "$(MACHINE)" == "IX86"
-#DLLENTRY = @12
-#lflags   = $(lcommon) -align:0x1000 /MACHINE:$(MACHINE)
-#!ELSE
-#lflags   = $(lcommon) /MACHINE:$(MACHINE)
-#!ENDIF
-
-ifeq ($(OBJEXT),obj)
-
-lcommon = /NODEFAULTLIB /RELEASE /NOLOGO
-lflags   = $(lcommon) -align:0x1000 /MACHINE:$(MACHINE)
-conlflags = $(lflags)  -subsystem:console -entry:mainCRTStartup
-guilflags = $(lflags) -subsystem:windows -entry:WinMainCRTStartup
-dlllflags = $(lflags) -entry:_DllMainCRTStartup@12 -dll
-
-else
-
-conlflags = $(lflags) -Wl,--subsystem,console -mwindows
-guilflags = $(lflags) -mwindows
-dlllflags = $(lflags)
-
-endif
-
-#!IF "$(MACHINE)" == "PPC"
-#libc = libc.lib
-#libcdll = crtdll.lib
-#!ELSE
-#libc = libc.lib oldnames.lib
-#libcdll = msvcrt.lib oldnames.lib
-#!ENDIF
-
-ifeq ($(OBJEXT),o)
-
-baselibs   = -lkernel32 $(optlibs) -ladvapi32
-winlibs    = $(baselibs) -luser32 -lgdi32 -lcomdlg32 -lwinspool
-
-else
-
-baselibs   = kernel32.lib $(optlibs) advapi32.lib
-winlibs    = $(baselibs) user32.lib gdi32.lib comdlg32.lib winspool.lib
-libcdll    = msvcrt.lib oldnames.lib
-
-endif
-
-guilibs           = $(libc) $(winlibs)
-
-guilibsdll = $(libcdll) $(winlibs)
-
-######################################################################
-# Compile flags
-######################################################################
-
-#!IFDEF NODEBUG
-#cdebug = -Ox
-#!ELSE
-#cdebug = -Z7 -Od -WX
-#!ENDIF
-
-# declarations common to all compiler options
-#ccommon = -c -W3 -nologo -YX
-
-#!IF "$(MACHINE)" == "IX86"
-#cflags = $(ccommon) -D_X86_=1
-#!ELSE
-#!IF "$(MACHINE)" == "MIPS"
-#cflags = $(ccommon) -D_MIPS_=1
-#!ELSE
-#!IF "$(MACHINE)" == "PPC"
-#cflags = $(ccommon) -D_PPC_=1
-#!ELSE
-#!IF "$(MACHINE)" == "ALPHA"
-#cflags = $(ccommon) -D_ALPHA_=1
-#!ENDIF
-#!ENDIF
-#!ENDIF
-#!ENDIF
+doc: $(ROOT_DIR)/doc/man.macros
 
-cvars      = -DWIN32 -D_WIN32
-cvarsmt    = $(cvars) -D_MT
-cvarsdll   = $(cvarsmt) -D_DLL
+winhelp: $(TCL_SRC_DIR_NATIVE)/tools/man2help.tcl $(MAN2TCL)
+       TCL_LIBRARY="$(TCL_SRC_DIR_NATIVE)/library"; export TCL_LIBRARY; \
+       TK_LIBRARY="$(ROOT_DIR_NATIVE)/library"; export TK_LIBRARY; \
+       PATH="$(PATH):$(TCL_BIN_DIR)"; export PATH; \
+       $(TCLSH_PROG) "$(TCL_SRC_DIR_NATIVE)"/tools/man2help.tcl tcl "$(VER)" $(CORE_DOCS)
+       $(COPY) "$(TCL_BIN_DIR)"/tcl.hpj ./
+       hcw /c /e tcl.hpj
+       $(COPY) ./tcl$(VER).cnt ./TCL$(VER).HLP "$(TCL_SRC_DIR_NATIVE)"/tools/
 
-CON_CFLAGS     = $(cdebug) $(cflags) $(cvars) $(include32) -DCONSOLE
+$(MAN2TCL): $(TCL_SRC_DIR_NATIVE)/tools/man2tcl.c
+       $(CC) $(CFLAGS_OPTIMIZE) $(MAN2TCLFLAGS) -o $(MAN2TCL) "$(TCL_SRC_DIR_NATIVE)"/tools/man2tcl.c
 
-######################################################################
-# Project specific targets
-######################################################################
-
-all:    $(TKDLL) $(TKLIB) $(WISH)
-test:  $(TKTEST)
-plugin:        $(TKPLUGINDLL) $(WISHP)
-
-install: install-binaries install-libraries install-demos
+test: binaries $(TKTEST)
+       @TCL_LIBRARY="$(TCL_SRC_DIR_NATIVE)/library"; export TCL_LIBRARY; \
+       TK_LIBRARY="$(ROOT_DIR_NATIVE)/library"; export TK_LIBRARY; \
+       PATH="$(PATH):$(TCL_BIN_DIR)"; export PATH; \
+       ./$(TKTEST) "$(ROOT_DIR_NATIVE)/tests/all.tcl" $(TESTFLAGS) \
+       | ./$(CAT32)
 
-install-binaries: $(TKDLL) $(TKLIB) $(WISH)
+runtest: tktest
+       @TCL_LIBRARY="$(TCL_SRC_DIR_NATIVE)/library"; export TCL_LIBRARY; \
+       TK_LIBRARY="$(ROOT_DIR_NATIVE)/library"; export TK_LIBRARY; \
+       PATH="$(PATH):$(TCL_BIN_DIR)"; export PATH; \
+       ./$(TKTEST) 
+
+install: all install-binaries install-libraries install-doc install-demos
+
+install-binaries:
        @for i in $(LIB_INSTALL_DIR) $(BIN_INSTALL_DIR) ; \
            do \
            if [ ! -d $$i ] ; then \
                echo "Making directory $$i"; \
-               mkdir $$i; \
+               $(MKDIR) $$i; \
                chmod 755 $$i; \
                else true; \
                fi; \
            done;
-       @echo "Installing $(TKLIB)"
-       @$(INSTALL_DATA) $(TKLIB) $(LIB_INSTALL_DIR)/$(TKLIB)
-       @chmod 555 $(LIB_INSTALL_DIR)/$(TKLIB)
-       @echo "Installing wish"
+       @echo "Installing $(TK_LIB_FILE) to $(LIB_INSTALL_DIR)/"
+       @$(INSTALL_DATA) $(TK_LIB_FILE) $(LIB_INSTALL_DIR)/$(TK_LIB_FILE)
+       @echo "Installing $(WISH) as $(BIN_INSTALL_DIR)/wish$(VERSION)"
        @$(INSTALL_PROGRAM) $(WISH) $(BIN_INSTALL_DIR)/$(WISH)
-       @echo "Installing tkConfig.sh"
-       @$(INSTALL_DATA) ../unix/tkConfig.sh $(LIB_INSTALL_DIR)/tkConfig.sh
+       @echo "Installing tkConfig.sh to $(LIB_INSTALL_DIR)/"
+       @$(INSTALL_DATA) tkConfig.sh $(LIB_INSTALL_DIR)/tkConfig.sh
+       @if test "$(DLLSUFFIX)" != "" ; then \
+           echo "Installing $(TK_DLL_FILE) to $(LIB_INSTALL_DIR)/" ; \
+           $(INSTALL_PROGRAM) $(TK_DLL_FILE) \
+               $(BIN_INSTALL_DIR)/$(TK_DLL_FILE) ; \
+       fi
+       @if test "$(TK_STUB_LIB_FILE)" != "" ; then \
+           if [ -f $(TK_STUB_LIB_FILE) ]; then \
+               echo "Installing $(TK_STUB_LIB_FILE) to $(LIB_INSTALL_DIR)/"; \
+               $(INSTALL_DATA) $(TK_STUB_LIB_FILE) \
+                        $(LIB_INSTALL_DIR)/$(TK_STUB_LIB_FILE); \
+           fi; \
+        fi
 
 install-libraries:
-       @echo "Installing DLL"
-       @$(INSTALL_DATA) $(TKDLL) $(BIN_INSTALL_DIR)/$(TKDLL)
-       @for i in $(INSTALL_ROOT)@datadir@ $(INCLUDE_INSTALL_DIR) \
-               $(SCRIPT_INSTALL_DIR) $(INSTALL_ROOT)@exec_prefix@ \
-               $(INSTALL_ROOT)@exec_prefix@/@host_alias@ \
-               $(INSTALL_ROOT)@exec_prefix@/@host_alias@/include \
-               $(X11_INCLUDE_INSTALL_DIR) ; \
+       @for i in $(INSTALL_ROOT)$(prefix)/lib \
+               $(INCLUDE_INSTALL_DIR) $(INCLUDE_INSTALL_DIR)/X11 \
+               $(SCRIPT_INSTALL_DIR) $(SCRIPT_INSTALL_DIR)/images; \
            do \
            if [ ! -d $$i ] ; then \
                echo "Making directory $$i"; \
-               mkdir $$i; \
+               $(MKDIR) $$i; \
                chmod 755 $$i; \
                else true; \
                fi; \
            done;
-       @echo "Installing tk.h"
-       @$(INSTALL_DATA) $(GENERICDIR)/tk.h $(INCLUDE_INSTALL_DIR)/tk.h
-       for i in $(XLIBDIR)/X11/*.h; \
+       @echo "Installing header files";
+       @for i in $(GENERIC_DIR)/tk.h $(GENERIC_DIR)/tkDecls.h \
+               $(GENERIC_DIR)/tkIntXlibDecls.h ; \
            do \
-           echo "Installing $$i"; \
-           $(INSTALL_DATA) $$i $(X11_INCLUDE_INSTALL_DIR); \
+           $(INSTALL_DATA) $$i $(INCLUDE_INSTALL_DIR); \
            done;
-       for i in $(ROOT)/library/*.tcl $(ROOT)/library/tclIndex $(ROOT)/library/prolog.ps $(ROOT)/unix/tkAppInit.c; \
+       @for i in $(XLIB_DIR)/X11/*.h; \
            do \
-           echo "Installing $$i"; \
-           $(INSTALL_DATA) $$i $(SCRIPT_INSTALL_DIR); \
+           $(INSTALL_DATA) $$i $(INCLUDE_INSTALL_DIR)/X11; \
            done;
-
-install-minimal:
-       @echo "Installing DLL"
-       @$(INSTALL_DATA) $(TKDLL) $(BIN_INSTALL_DIR)/$(TKDLL)
-       @for i in $(INSTALL_ROOT)@datadir@ $(SCRIPT_INSTALL_DIR) ; \
+       @echo "Installing library files to $(SCRIPT_INSTALL_DIR)";
+       @for i in $(ROOT_DIR)/library/*.tcl $(GENERIC_DIR)/prolog.ps \
+               $(ROOT_DIR)/library/tclIndex $(UNIX_DIR)/tkAppInit.c; \
            do \
-           if [ ! -d $$i ] ; then \
-               echo "Making directory $$i"; \
-               mkdir $$i; \
-               chmod 755 $$i; \
-               else true; \
-               fi; \
+           $(INSTALL_DATA) $$i $(SCRIPT_INSTALL_DIR); \
            done;
-       for i in $(ROOT)/library/*.tcl $(ROOT)/library/tclIndex $(ROOT)/library/prolog.ps; \
+       @echo "Installing library images directory";
+       @for i in $(ROOT_DIR)/library/images/*; \
            do \
-           echo "Installing $$i"; \
-           $(INSTALL_DATA) $$i $(SCRIPT_INSTALL_DIR); \
+           if [ -f $$i ] ; then \
+               $(INSTALL_DATA) $$i $(SCRIPT_INSTALL_DIR)/images; \
+           fi; \
            done;
 
 install-demos:
-       @for i in $(INSTALL_ROOT)@datadir@ $(SCRIPT_INSTALL_DIR) \
+       @for i in $(INSTALL_ROOT)$(prefix)/lib $(SCRIPT_INSTALL_DIR) \
                $(SCRIPT_INSTALL_DIR)/demos \
                $(SCRIPT_INSTALL_DIR)/demos/images ; \
            do \
            if [ ! -d $$i ] ; then \
                echo "Making directory $$i"; \
-               mkdir $$i; \
+               $(MKDIR) $$i; \
                chmod 755 $$i; \
                else true; \
                fi; \
            done;
-       @for i in $(ROOT)/library/demos/*; \
+       @echo "Installing demos to $(SCRIPT_INSTALL_DIR)/demos/";
+       @for i in $(ROOT_DIR)/library/demos/*; \
            do \
            if [ -f $$i ] ; then \
-               echo "Installing $$i"; \
-               sed -e '3 s|exec wish|exec $(WISH)|' \
+               sed -e '3 s|exec $(WISH)|exec $(WISH)|' \
                        $$i > $(SCRIPT_INSTALL_DIR)/demos/`basename $$i`; \
            fi; \
            done;
@@ -454,199 +480,114 @@ install-demos:
            do \
            chmod 755 $(SCRIPT_INSTALL_DIR)/demos/$$i; \
            done;
-       @for i in $(ROOT)/library/demos/images/*; \
+       @echo "Installing demo images";
+       @for i in $(ROOT_DIR)/library/demos/images/*; \
            do \
            if [ -f $$i ] ; then \
-               echo "Installing $$i"; \
                $(INSTALL_DATA) $$i $(SCRIPT_INSTALL_DIR)/demos/images; \
                fi; \
            done;
 
-ifeq ($(OBJEXT),o)
+install-doc:
 
-$(TKDLL): $(TKOBJS) tkres.$(OBJEXT) tkcyg.def
-       $(CC) -s $(DLL_LDFLAGS) -Wl,--base-file,tk.base -o $(TKDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66300000
-       $(DLLTOOL) --as=$(AS) --dllname $(TKDLL) --def $(TMPDIR)/tkcyg.def --base-file tk.base --output-exp tk.exp
-       $(CC) -s $(DLL_LDFLAGS) -Wl,--base-file,tk.base tk.exp -o $(TKDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66300000
-       $(DLLTOOL) --as=$(AS) --dllname $(TKDLL) --def $(TMPDIR)/tkcyg.def --base-file tk.base --output-exp tk.exp
-       $(CC) $(DLL_LDFLAGS) tk.exp -o $(TKDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66300000
 
-else
+$(WISH): $(TK_LIB_FILE) $(WISH_OBJS) $(WISH_RES)
+       $(CC) $(CFLAGS) $(WISH_OBJS) $(TCL_LIB_SPEC) $(TK_LIB_FILE) $(LIBS) \
+       $(WISH_RES) $(CC_EXENAME) $(LDFLAGS_WINDOW)
 
-$(TKDLL): $(TKOBJS) tkres.$(OBJEXT) tkcyg.def
-       link $(ldebug) $(dlllflags) -def:tkcyg.def \
-               -out:$@ tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) \
-               $(guilibsdll) $(TKOBJS)
-       mv cygtk80.lib libtk80.a
-endif
+tktest : $(TKTEST)
 
-ifeq ($(OBJEXT),o)
+$(TKTEST): $(TK_LIB_FILE) $(TKTEST_OBJS) $(WISH_RES) $(CAT32)
+       $(CC) $(CFLAGS) $(TKTEST_OBJS_NATIVE) $(TCL_LIB_SPEC) \
+       $(TK_LIB_FILE) $(LIBS) \
+       $(WISH_RES) $(CC_EXENAME) $(LDFLAGS_WINDOW)
 
-$(TKLIB): $(TMPDIR)/tkcyg.def
-       $(DLLTOOL) --as=$(AS) --dllname $(TKDLL) --def $(TMPDIR)/tkcyg.def --output-lib $(TKLIB)
+cat32.${OBJEXT}: $(TCL_SRC_DIR)/win/cat.c
+       $(CC) -c $(CC_SWITCHES) @DEPARG@ $(CC_OBJNAME)
 
-else
+$(CAT32): cat32.${OBJEXT}
+       $(CC) $(CFLAGS) cat32.$(OBJEXT) $(CC_EXENAME) $(LDFLAGS_CONSOLE)
 
-$(TKLIB): $(TKDLL)
+# WISH_RES 
+$(RC_DIR)/wish_static.rc : $(RC_DIR)/wish.rc $(RC_DIR)/tk_base.rc
+       cat $(RC_DIR)/wish.rc $(RC_DIR)/tk_base.rc > $(RC_DIR)/wish_static.rc
 
-endif
+wish_static.$(RES) : $(RC_DIR)/wish_static.rc
+       $(RC) @RC_OUT@ $@ @RC_TYPE@ @RC_INCLUDE@ "$(GENERIC_DIR_NATIVE)" @RC_INCLUDE@ "$(TCL_GENERIC_NATIVE)" @RC_INCLUDE@ "$(RC_DIR_NATIVE)" @DEPARG@
 
-$(TKPLUGINLIB): $(TMPDIR)/plugin.def
-       $(DLLTOOL) --as=$(AS) --dllname $(TKPLUGINDLL) --def $(TMPDIR)/plugin.def --output-lib $(TKPLUGINLIB)
 
-$(TKPLUGINDLL): $(TKOBJS) tkres.$(OBJEXT) $(TMPDIR)/plugin.def
-       $(CC) $(DLL_LDFLAGS) -Wl,--base-file,tkplugin.base -o $(TKPLUGINDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66800000
-       $(DLLTOOL) --as=$(AS) --dllname $(TKPLUGINDLL) --def $(TMPDIR)/plugin.def --base-file tkplugin.base --output-exp tk.exp
-       $(CC) $(DLL_LDFLAGS) -Wl,--base-file,tkplugin.base tk.exp -o $(TKPLUGINDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66800000
-       $(DLLTOOL) --as=$(AS) --dllname $(TKPLUGINDLL) --def $(TMPDIR)/plugin.def --base-file tkplugin.base --output-exp tk.exp
-       $(CC) $(DLL_LDFLAGS) tk.exp -o $(TKPLUGINDLL) $(TKOBJS) tkres.$(OBJEXT) $(TCLLIBDIR)/$(TCLLIB) $(DLL_LDLIBS) -mwindows -Wl,-e,_DllMain@12 -Wl,--image-base,0x66800000
+# TK_RES
+$(RC_DIR)/tk_dll.rc : $(RC_DIR)/tk.rc $(RC_DIR)/tk_base.rc
+       cat $(RC_DIR)/tk.rc $(RC_DIR)/tk_base.rc > $(RC_DIR)/tk_dll.rc
 
-ifeq ($(OBJEXT),o)
+tk_dll.$(RES) : $(RC_DIR)/tk_dll.rc
+       $(RC) @RC_OUT@ $@ @RC_TYPE@ @RC_INCLUDE@ "$(GENERIC_DIR_NATIVE)" @RC_INCLUDE@ "$(TCL_GENERIC_NATIVE)" @RC_INCLUDE@ "$(RC_DIR_NATIVE)" @DEPARG@
 
-$(WISH): $(WISHOBJS) wishres.$(OBJEXT) $(TKLIB)
-       $(CC) $(ldebug) $(guilflags) $(WISHOBJS) wishres.$(OBJEXT) -o $@ \
-               $(TKLIB) $(TCLLIBDIR)/$(TCLLIB) $(guilibsdll)
+# The following targets are configured by autoconf to generate either
+# a shared library or static library
 
-else
+${TK_STUB_LIB_FILE}: ${STUB_OBJS}
+       @$(RM) ${TK_STUB_LIB_FILE}
+       @MAKE_LIB@ ${STUB_OBJS}
+       @POST_MAKE_LIB@
 
-$(WISH): $(WISHOBJS) wishres.$(OBJEXT) $(TKLIB)
-       link $(ldebug) $(guilflags) $(WISHOBJS) wishres.$(OBJEXT) -OUT:$@ \
-               $(TKLIB) $(TCLLIBDIR)/$(TCLLIB) $(guilibsdll)
-endif
+${TK_DLL_FILE}: ${TK_OBJS} $(TK_RES)
+       @$(RM) ${TK_DLL_FILE}
+       @MAKE_DLL@ ${TK_OBJS} $(TK_RES) $(SHLIB_LD_LIBS)
 
-$(WISHP): $(WISHOBJS) $(TKPLUGINLIB) wishres.$(OBJEXT)
-       $(CC) $(ldebug) $(guilflags) $(WISHOBJS) wishres.$(OBJEXT) -o $@ \
-               $(TKPLUGINLIB) $(TCLLIBDIR)/$(TCLPLUGINLIB) $(guilibsdll)
+${GNU_TK_LIB_FILE}: ${TK_DLL_FILE}
 
-$(TKTEST): $(TKTESTOBJS) wishres.$(OBJEXT) $(TKLIB)
-       $(CC) $(ldebug) $(guilflags) $(TKTESTOBJS) wishres.$(OBJEXT) -o $@ \
-               $(TKLIB) $(TCLLIBDIR)/$(TCLLIB) $(guilibsdll)
+${MSVC_TK_LIB_FILE}: ${TK_OBJS}
+       @$(RM) ${TK_LIB_FILE}
+       @MAKE_LIB@ ${TK_OBJS}
+       @POST_MAKE_LIB@
 
-ifeq ($(OBJEXT),o)
-tkcyg.def: $(TKOBJS)
-       echo 'EXPORTS' > tmp.def
-       for o in $(TKOBJS); do \
-         $(NM) --extern-only --defined-only $$o | sed -e 's/[^ ]* [^ ]* //' -e 's/^_//' | fgrep -v DllEntryPoint | fgrep -v DllMain | fgrep -v impure_ptr >> tmp.def; \
-       done
-       mv tmp.def $(TMPDIR)/tkcyg.def
+# Special case object file targets
 
-plugin.def: $(TKOBJS)
-       echo 'EXPORTS' > tmp.def
-       for o in $(TKOBJS); do \
-         $(NM) --extern-only --defined-only $$o | sed -e 's/[^ ]* [^ ]* //' -e 's/^_//' | fgrep -v DllEntryPoint | fgrep -v DllMain | fgrep -v impure_ptr >> tmp.def; \
-       done
-       mv tmp.def $(TMPDIR)/plugin.def
+winMain.$(OBJEXT): winMain.c
+       $(CC) -c $(CC_SWITCHES) @DEPARG@ $(CC_OBJNAME)
 
-else
+testMain.$(OBJEXT): winMain.c
+       $(CC) -c $(CC_SWITCHES) @DEPARG@ -DTK_TEST $(CC_OBJNAME)
 
-# Source-Navigator need the extra Symbols.
+tkTest.$(OBJEXT): tkTest.c
+       $(CC) -c $(CC_SWITCHES) @DEPARG@ $(CC_OBJNAME)
 
-tkcyg.def: $(TKOBJS) $(DUMPEXTS)
-       $(DUMPEXTS) -o tkcyg.def $(TKDLL) $(TKOBJS)
-       echo "  tkWindowType" >> tkcyg.def
-       echo "  tkArcType" >> tkcyg.def
-       echo "  tkBitmapType" >> tkcyg.def
-       echo "  tkOvalType" >> tkcyg.def
-       echo "  tkImageType" >> tkcyg.def
-       echo "  tkPolygonType" >> tkcyg.def
-       echo "  tkLineType" >> tkcyg.def
-       echo "  tkTextType" >> tkcyg.def
-       echo "  tkRectangleType" >> tkcyg.def
-       echo "  tkTextCharType" >> tkcyg.def
+tkWinTest.$(OBJEXT): tkWinTest.c
+       $(CC) -c $(CC_SWITCHES) @DEPARG@ $(CC_OBJNAME)
 
-plugin.def: $(TKOBJS) $(DUMPEXTS)
-       $(DUMPEXTS) -o tkcyg.def $(TKDLL) $(TKOBJS) 
+tkSquare.$(OBJEXT): tkSquare.c
+       $(CC) -c $(CC_SWITCHES) @DEPARG@ $(CC_OBJNAME)
 
+tclThreadTest.$(OBJEXT): $(TCL_BIN_DIR)/tclThreadTest.$(OBJEXT)
 
-$(DUMPEXTS): $(TCLDIR)/win/winDumpExts.c
-       $(CC) $(TCLDIR)/win/winDumpExts.c user32.lib -link -OUT:$(DUMPEXTS)
+# Add the object extension to the implicit rules.  By default .obj is not
+# automatically added.
 
-endif
+.SUFFIXES: .${OBJEXT}
+.SUFFIXES: .$(RES)
+.SUFFIXES: .rc
 
-#$(DUMPEXTS): $(TCLDIR)\win\winDumpExts.c
-#      $(cc32) $(CON_CFLAGS) -Fo$(TMPDIR)\ $?
-#      set LIB=$(TOOLS32)\lib
-#      $(link32) $(ldebug) $(conlflags) $(guilibs) -out:$@ \
-#              $(TMPDIR)\winDumpExts.$(OBJEXT)bj 
+# Implicit rule for all object files that will end up in the Tcl library
 
-#
-# Special case object file targets
-#
+.c.$(OBJEXT):
+       $(CC) -c $(STUB_CC_SWITCHES) -DBUILD_tk @DEPARG@ $(CC_OBJNAME)
 
-$(TMPDIR)/testMain.$(OBJEXT): $(ROOT)/win/winMain.c
-       $(CC) -c $(TK_CFLAGS) -DTK_TEST -o $@ $?
+.rc.$(RES):
+       $(RC) @RC_OUT@ $@ @RC_TYPE@ @RC_INCLUDE@ "$(GENERIC_DIR_NATIVE)" @RC_INCLUDE@ "$(TCL_GENERIC_NATIVE)" @RC_INCLUDE@ "$(RC_DIR_NATIVE)" @DEPARG@
 
-#
-# Implicit rules
-#
-.SUFFIXES: .S .c .o .obj .s
-.c.$(OBJEXT):
-       $(CC) -c $(TK_CFLAGS) $<
-
-ifeq ($(OBJEXT),o)
-
-tkres.$(OBJEXT): $(ROOT)/win/rc/tk.rc
-       $(WINDRES) --include $(ROOT)/win/rc --include $(ROOT)/generic --define VS_VERSION_INFO=1 $(ROOT)/win/rc/tk.rc tkres.$(OBJEXT)
-
-wishres.$(OBJEXT): $(ROOT)/win/rc/wish.rc
-       $(WINDRES) --include $(ROOT)/win/rc --include $(ROOT)/generic --define VS_VERSION_INFO=1 $(ROOT)/win/rc/wish.rc wishres.$(OBJEXT)
-
-else
-
-tkres.$(OBJEXT): $(ROOT)/win/rc/tk.rc
-       rc -i$(ROOT)/win/rc -i$(ROOT)/generic -dVS_VERSION_INFO=1 -fotkres.$(OBJEXT) $(ROOT)/win/rc/tk.rc 
-
-wishres.$(OBJEXT): $(ROOT)/win/rc/wish.rc
-       rc -i$(ROOT)/win/rc -i$(ROOT)/generic -dVS_VERSION_INFO=1 -fowishres.$(OBJEXT) $(ROOT)/win/rc/wish.rc 
-
-endif
-
-#{$(ROOT)\win\rc}.rc{$(TMPDIR)}.res:
-#      $(rc32) -fo $@ -r -i $(ROOT)\generic $<
-
-clean:
-       rm -f *.exp *.a *.dll *.exe $(TMPDIR)/*.$(OBJEXT) *.res *.def
-       rm -f tk.base tkplugin.base
-
-# dependencies
-
-$(TMPDIR)/tk.res: \
-    $(RCDIR)/buttons.bmp \
-    $(RCDIR)/cursor*.cur \
-    $(RCDIR)/tk.ico
-
-$(GENERICDIR)/default.h: $(WINDIR)/tkWinDefault.h
-$(GENERICDIR)/tkButton.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkCanvas.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkEntry.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkFrame.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkListbox.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkMenu.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkMenubutton.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkMessage.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkScale.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkScrollbar.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkText.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkTextIndex.c: $(GENERICDIR)/default.h
-$(GENERICDIR)/tkTextTag.c: $(GENERICDIR)/default.h
-
-$(GENERICDIR)/tkText.c: $(GENERICDIR)/tkText.h
-$(GENERICDIR)/tkTextBTree.c: $(GENERICDIR)/tkText.h
-$(GENERICDIR)/tkTextDisp.c: $(GENERICDIR)/tkText.h
-$(GENERICDIR)/tkTextDisp.c: $(GENERICDIR)/tkText.h
-$(GENERICDIR)/tkTextImage.c: $(GENERICDIR)/tkText.h
-$(GENERICDIR)/tkTextIndex.c: $(GENERICDIR)/tkText.h
-$(GENERICDIR)/tkTextMark.c: $(GENERICDIR)/tkText.h
-$(GENERICDIR)/tkTextTag.c: $(GENERICDIR)/tkText.h
-$(GENERICDIR)/tkTextWind.c: $(GENERICDIR)/tkText.h
-
-$(GENERICDIR)/tkMacWinMenu.c: $(GENERICDIR)/tkMenu.h
-$(GENERICDIR)/tkMenu.c: $(GENERICDIR)/tkMenu.h
-$(GENERICDIR)/tkMenuDraw.c: $(GENERICDIR)/tkMenu.h
-$(WINDIR)/tkWinMenu.c: $(GENERICDIR)/tkMenu.h
-
-Makefile: $(WINDIR)/Makefile.in config.status
-       $(SHELL) config.status
-
-config.status: $(WINDIR)/configure
-       ./config.status --recheck
+depend:
+
+cleanhelp:
+       $(RM) *.hlp *.cnt *.hpj *.GID *.rtf man2tcl${EXEEXT}
+
+clean: cleanhelp
+       $(RM) *.lib *.a *.exp *.dll *.$(RES) *.${OBJEXT} *~ \#* TAGS a.out
+       $(RM) $(WISH) $(TKTEST) $(CAT32)
+       $(RM) *.pch *.ilk *.pdb
+
+distclean: clean
+       $(RM) Makefile config.status config.cache config.log tkConfig.sh
+
+Makefile: $(SRC_DIR)/Makefile.in
+       ./config.status
index 20cf223..8670d1e 100755 (executable)
@@ -1,7 +1,7 @@
 #! /bin/sh
 
 # Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.12.2 
+# Generated automatically using autoconf version 2.13 
 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
 #
 # This configure script is free software; the Free Software Foundation
@@ -12,7 +12,13 @@ ac_help=
 ac_default_prefix=/usr/local
 # Any additions from configure.in:
 ac_help="$ac_help
-  --with-tcl=DIR          use Tcl 8.0 binaries from DIR"
+  --enable-threads        build with threads"
+ac_help="$ac_help
+  --enable-shared         build and link with shared libraries [--enable-shared]"
+ac_help="$ac_help
+  --enable-symbols        build with debugging symbols [--disable-symbols]"
+ac_help="$ac_help
+  --with-tcl=DIR          use Tcl 8.3 binaries from DIR"
 
 # Initialize some variables set by options.
 # The variables have the same names as the options, with
@@ -30,6 +36,7 @@ program_suffix=NONE
 program_transform_name=s,x,x,
 silent=
 site=
+sitefile=
 srcdir=
 target=NONE
 verbose=
@@ -144,6 +151,7 @@ Configuration:
   --help                  print this message
   --no-create             do not create output files
   --quiet, --silent       do not print \`checking...' messages
+  --site-file=FILE        use FILE as the site file
   --version               print the version of autoconf that created configure
 Directory and file names:
   --prefix=PREFIX         install architecture-independent files in PREFIX
@@ -314,6 +322,11 @@ EOF
   -site=* | --site=* | --sit=*)
     site="$ac_optarg" ;;
 
+  -site-file | --site-file | --site-fil | --site-fi | --site-f)
+    ac_prev=sitefile ;;
+  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
+    sitefile="$ac_optarg" ;;
+
   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
     ac_prev=srcdir ;;
   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -335,7 +348,7 @@ EOF
     verbose=yes ;;
 
   -version | --version | --versio | --versi | --vers)
-    echo "configure generated by autoconf version 2.12.2"
+    echo "configure generated by autoconf version 2.13"
     exit 0 ;;
 
   -with-* | --with-*)
@@ -479,12 +492,16 @@ fi
 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
 
 # Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
-  if test "x$prefix" != xNONE; then
-    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-  else
-    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+if test -z "$sitefile"; then
+  if test -z "$CONFIG_SITE"; then
+    if test "x$prefix" != xNONE; then
+      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+    else
+      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+    fi
   fi
+else
+  CONFIG_SITE="$sitefile"
 fi
 for ac_site_file in $CONFIG_SITE; do
   if test -r "$ac_site_file"; then
@@ -524,6 +541,12 @@ fi
 
 
 
+TK_VERSION=8.3
+TK_MAJOR_VERSION=8
+TK_MINOR_VERSION=3
+TK_PATCH_LEVEL=".2"
+VER=$TK_MAJOR_VERSION$TK_MINOR_VERSION
+
 if test "${prefix}" = "NONE"; then
     prefix=/usr/local
 fi
@@ -531,57 +554,14 @@ if test "${exec_prefix}" = "NONE"; then
     exec_prefix=$prefix
 fi
 
-ac_aux_dir=
-for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
-  if test -f $ac_dir/install-sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f $ac_dir/install.sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
-
-# Make sure we can run config.sub.
-if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
-else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:561: checking host system type" >&5
-
-host_alias=$host
-case "$host_alias" in
-NONE)
-  case $nonopt in
-  NONE)
-    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
-    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
-    fi ;;
-  *) host_alias=$nonopt ;;
-  esac ;;
-esac
-
-host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
-host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$host" 1>&6
-
+#------------------------------------------------------------------------
+# Standard compiler checks
+#------------------------------------------------------------------------
 
 # Extract the first word of "gcc", so it can be a program name with args.
 set dummy gcc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:585: checking for $ac_word" >&5
+echo "configure:565: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -589,7 +569,8 @@ else
   ac_cv_prog_CC="$CC" # Let the user override the test.
 else
   IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  for ac_dir in $PATH; do
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
     test -z "$ac_dir" && ac_dir=.
     if test -f $ac_dir/$ac_word; then
       ac_cv_prog_CC="gcc"
@@ -610,7 +591,7 @@ if test -z "$CC"; then
   # Extract the first word of "cc", so it can be a program name with args.
 set dummy cc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:614: checking for $ac_word" >&5
+echo "configure:595: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -619,7 +600,8 @@ else
 else
   IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
   ac_prog_rejected=no
-  for ac_dir in $PATH; do
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
     test -z "$ac_dir" && ac_dir=.
     if test -f $ac_dir/$ac_word; then
       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
@@ -660,7 +642,7 @@ fi
       # Extract the first word of "cl", so it can be a program name with args.
 set dummy cl; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:664: checking for $ac_word" >&5
+echo "configure:646: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -668,7 +650,8 @@ else
   ac_cv_prog_CC="$CC" # Let the user override the test.
 else
   IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
-  for ac_dir in $PATH; do
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
     test -z "$ac_dir" && ac_dir=.
     if test -f $ac_dir/$ac_word; then
       ac_cv_prog_CC="cl"
@@ -691,7 +674,7 @@ fi
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:695: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:678: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -700,12 +683,14 @@ ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
 cross_compiling=$ac_cv_prog_cc_cross
 
-cat > conftest.$ac_ext <<EOF
-#line 705 "configure"
+cat > conftest.$ac_ext << EOF
+
+#line 689 "configure"
 #include "confdefs.h"
+
 main(){return(0);}
 EOF
-if { (eval echo configure:709: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   ac_cv_prog_cc_works=yes
   # If we can't run a trivial program, we are probably using a cross compiler.
   if (./conftest; exit) 2>/dev/null; then
@@ -719,18 +704,24 @@ else
   ac_cv_prog_cc_works=no
 fi
 rm -fr conftest*
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
 
 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
 if test $ac_cv_prog_cc_works = no; then
   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
 fi
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:729: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:720: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
 cross_compiling=$ac_cv_prog_cc_cross
 
 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:734: checking whether we are using GNU C" >&5
+echo "configure:725: checking whether we are using GNU C" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -739,7 +730,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:743: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:734: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
   ac_cv_prog_gcc=yes
 else
   ac_cv_prog_gcc=no
@@ -758,7 +749,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
 ac_save_CFLAGS="$CFLAGS"
 CFLAGS=
 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:762: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:753: checking whether ${CC-cc} accepts -g" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -789,169 +780,1608 @@ else
   fi
 fi
 
-echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:794: checking for object suffix" >&5
-if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  rm -f conftest*
-echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:800: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  for ac_file in conftest.*; do
-    case $ac_file in
-    *.c) ;;
-    *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
-    esac
-  done
-else
-  { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
+
+ac_aux_dir=
+for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
+  if test -f $ac_dir/install-sh; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install-sh -c"
+    break
+  elif test -f $ac_dir/install.sh; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install.sh -c"
+    break
+  fi
+done
+if test -z "$ac_aux_dir"; then
+  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
 fi
-rm -f conftest*
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
+# Make sure we can run config.sub.
+if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
+else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
 fi
 
-echo "$ac_t""$ac_cv_objext" 1>&6
-OBJEXT=$ac_cv_objext
-ac_objext=$ac_cv_objext
+echo $ac_n "checking host system type""... $ac_c" 1>&6
+echo "configure:811: checking host system type" >&5
+
+host_alias=$host
+case "$host_alias" in
+NONE)
+  case $nonopt in
+  NONE)
+    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
+    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
+    fi ;;
+  *) host_alias=$nonopt ;;
+  esac ;;
+esac
 
-NM=${NM-nm}
+host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
+host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$host" 1>&6
 
-AS=${AS-as}
+echo $ac_n "checking build system type""... $ac_c" 1>&6
+echo "configure:832: checking build system type" >&5
 
-LD=${LD-ld}
+build_alias=$build
+case "$build_alias" in
+NONE)
+  case $nonopt in
+  NONE) build_alias=$host_alias ;;
+  *) build_alias=$nonopt ;;
+  esac ;;
+esac
 
-DLLTOOL=${DLLTOOL-dlltool}
+build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
+build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$build" 1>&6
 
-WINDRES=${WINDRES-windres}
+if test $host != $build; then
+  ac_tool_prefix=${host_alias}-
+else
+  ac_tool_prefix=
+fi
 
-# Find a good install program.  We prefer a C program (faster),
-# so one script is as good as another.  But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# ./install, which can be erroneously created by make from ./install.sh.
-echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:839: checking for a BSD compatible install" >&5
-if test -z "$INSTALL"; then
-if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
+# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
+set dummy ${ac_tool_prefix}ar; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:858: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-    IFS="${IFS=        }"; ac_save_IFS="$IFS"; IFS=":"
-  for ac_dir in $PATH; do
-    # Account for people who put trailing slashes in PATH elements.
-    case "$ac_dir/" in
-    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
-    *)
-      # OSF1 and SCO ODT 3.0 have their own names for install.
-      # Don't use installbsd from OSF since it installs stuff as root
-      # by default.
-      for ac_prog in ginstall scoinst install; do
-        if test -f $ac_dir/$ac_prog; then
-         if test $ac_prog = install &&
-            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
-           # AIX install.  It has an incompatible calling convention.
-           :
-         else
-           ac_cv_path_install="$ac_dir/$ac_prog -c"
-           break 2
-         fi
-       fi
-      done
-      ;;
-    esac
+  if test -n "$AR"; then
+  ac_cv_prog_AR="$AR" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_AR="${ac_tool_prefix}ar"
+      break
+    fi
   done
-  IFS="$ac_save_IFS"
-
+  IFS="$ac_save_ifs"
 fi
-  if test "${ac_cv_path_install+set}" = set; then
-    INSTALL="$ac_cv_path_install"
-  else
-    # As a last resort, use the slow shell script.  We don't cache a
-    # path for INSTALL within a source directory, because that will
-    # break other packages using the cache if that directory is
-    # removed, or if the path is relative.
-    INSTALL="$ac_install_sh"
-  fi
 fi
-echo "$ac_t""$INSTALL" 1>&6
+AR="$ac_cv_prog_AR"
+if test -n "$AR"; then
+  echo "$ac_t""$AR" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
 
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
 
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+if test -z "$ac_cv_prog_AR"; then
+if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "ar", so it can be a program name with args.
+set dummy ar; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:890: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$AR"; then
+  ac_cv_prog_AR="$AR" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_AR="ar"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_prog_AR" && ac_cv_prog_AR=":"
+fi
+fi
+AR="$ac_cv_prog_AR"
+if test -n "$AR"; then
+  echo "$ac_t""$AR" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
 
+else
+  AR=":"
+fi
+fi
 
-# needed for the subtle differences between cygwin and mingw32
-case "${host}" in
-*-*-cygwin*)
-       DLL_LDLIBS=-lcygwin
-       DLL_LDFLAGS='-nostartfiles -Wl,--dll'
-       ;;
-*-*-mingw32*)
-       DLL_LDLIBS=
-       DLL_LDFLAGS='-mdll'
-       ;;
-esac
+# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
+set dummy ${ac_tool_prefix}ranlib; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:925: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$RANLIB"; then
+  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+fi
+fi
+RANLIB="$ac_cv_prog_RANLIB"
+if test -n "$RANLIB"; then
+  echo "$ac_t""$RANLIB" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
 
 
+if test -z "$ac_cv_prog_RANLIB"; then
+if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "ranlib", so it can be a program name with args.
+set dummy ranlib; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:957: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$RANLIB"; then
+  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_RANLIB="ranlib"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
+fi
+fi
+RANLIB="$ac_cv_prog_RANLIB"
+if test -n "$RANLIB"; then
+  echo "$ac_t""$RANLIB" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
 
+else
+  RANLIB=":"
+fi
+fi
 
+# Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
+set dummy ${ac_tool_prefix}windres; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:992: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_RC'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$RC"; then
+  ac_cv_prog_RC="$RC" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_RC="${ac_tool_prefix}windres"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+fi
+fi
+RC="$ac_cv_prog_RC"
+if test -n "$RC"; then
+  echo "$ac_t""$RC" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
 
-# The following stuff is just for tkConfig.sh, not for Makefile. 
 
-# Check whether --with-tcl or --without-tcl was given.
-if test "${with_tcl+set}" = set; then
-  withval="$with_tcl"
-  TCL_BIN_DIR=$withval
+if test -z "$ac_cv_prog_RC"; then
+if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "windres", so it can be a program name with args.
+set dummy windres; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1024: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_RC'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$RC"; then
+  ac_cv_prog_RC="$RC" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_RC="windres"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_prog_RC" && ac_cv_prog_RC=":"
+fi
+fi
+RC="$ac_cv_prog_RC"
+if test -n "$RC"; then
+  echo "$ac_t""$RC" 1>&6
 else
-  TCL_BIN_DIR=`cd ../../tcl/unix; pwd`
+  echo "$ac_t""no" 1>&6
 fi
 
-if test ! -d $TCL_BIN_DIR; then
-    { echo "configure: error: Tcl directory $TCL_BIN_DIR doesn't exist" 1>&2; exit 1; }
+else
+  RC=":"
 fi
-if test ! -f $TCL_BIN_DIR/tclConfig.sh; then
-    { echo "configure: error: There's no tclConfig.sh in $TCL_BIN_DIR;  perhaps you didn't specify the Tcl *build* directory (not the toplevel Tcl directory) or you forgot to configure Tcl?" 1>&2; exit 1; }
 fi
 
-file=$TCL_BIN_DIR/tclConfig.sh
-. $file
-SHLIB_CFLAGS=$TCL_SHLIB_CFLAGS
-SHLIB_LD=$TCL_SHLIB_LD
-SHLIB_LD_LIBS=$TCL_SHLIB_LD_LIBS
-SHLIB_SUFFIX=$TCL_SHLIB_SUFFIX
-SHLIB_VERSION=$TCL_SHLIB_VERSION
-DL_LIBS=$TCL_DL_LIBS
-LD_FLAGS=$TCL_LD_FLAGS
-TK_LD_SEARCH_FLAGS=$TCL_LD_SEARCH_FLAGS
 
-LIBOBJS=
+#--------------------------------------------------------------------
+# Checks to see if the make progeam sets the $MAKE variable.
+#--------------------------------------------------------------------
+
+echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
+echo "configure:1062: checking whether ${MAKE-make} sets \${MAKE}" >&5
+set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftestmake <<\EOF
+all:
+       @echo 'ac_maketemp="${MAKE}"'
+EOF
+# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
+if test -n "$ac_maketemp"; then
+  eval ac_cv_prog_make_${ac_make}_set=yes
+else
+  eval ac_cv_prog_make_${ac_make}_set=no
+fi
+rm -f conftestmake
+fi
+if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  SET_MAKE=
+else
+  echo "$ac_t""no" 1>&6
+  SET_MAKE="MAKE=${MAKE-make}"
+fi
+
+
+#--------------------------------------------------------------------
+# These two macros perform additinal compiler test.
+#--------------------------------------------------------------------
+
+echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
+echo "configure:1094: checking for Cygwin environment" >&5
+if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1099 "configure"
+#include "confdefs.h"
+
+int main() {
+
+#ifndef __CYGWIN__
+#define __CYGWIN__ __CYGWIN32__
+#endif
+return __CYGWIN__;
+; return 0; }
+EOF
+if { (eval echo configure:1110: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_cygwin=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_cygwin=no
+fi
+rm -f conftest*
+rm -f conftest*
+fi
+
+echo "$ac_t""$ac_cv_cygwin" 1>&6
+CYGWIN=
+test "$ac_cv_cygwin" = yes && CYGWIN=yes
+
+#--------------------------------------------------------------------
+# Determines the correct binary file extension (.o, .obj, .exe etc.)
+#--------------------------------------------------------------------
+
+echo $ac_n "checking for object suffix""... $ac_c" 1>&6
+echo "configure:1132: checking for object suffix" >&5
+if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  rm -f conftest*
+echo 'int i = 1;' > conftest.$ac_ext
+if { (eval echo configure:1138: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  for ac_file in conftest.*; do
+    case $ac_file in
+    *.c) ;;
+    *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
+    esac
+  done
+else
+  { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
+fi
+rm -f conftest*
+fi
+
+echo "$ac_t""$ac_cv_objext" 1>&6
+OBJEXT=$ac_cv_objext
+ac_objext=$ac_cv_objext
+
+echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
+echo "configure:1156: checking for mingw32 environment" >&5
+if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1161 "configure"
+#include "confdefs.h"
+
+int main() {
+return __MINGW32__;
+; return 0; }
+EOF
+if { (eval echo configure:1168: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_mingw32=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_mingw32=no
+fi
+rm -f conftest*
+rm -f conftest*
+fi
+
+echo "$ac_t""$ac_cv_mingw32" 1>&6
+MINGW32=
+test "$ac_cv_mingw32" = yes && MINGW32=yes
+
+
+echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
+echo "configure:1187: checking for executable suffix" >&5
+if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
+  ac_cv_exeext=.exe
+else
+  rm -f conftest*
+  echo 'int main () { return 0; }' > conftest.$ac_ext
+  ac_cv_exeext=
+  if { (eval echo configure:1197: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+    for file in conftest.*; do
+      case $file in
+      *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+      *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
+      esac
+    done
+  else
+    { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
+  fi
+  rm -f conftest*
+  test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
+fi
+fi
+
+EXEEXT=""
+test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
+echo "$ac_t""${ac_cv_exeext}" 1>&6
+ac_exeext=$EXEEXT
+
+
+#--------------------------------------------------------------------
+# Check whether --enable-threads or --disable-threads was given.
+#--------------------------------------------------------------------
+
+
+    echo $ac_n "checking for building with threads""... $ac_c" 1>&6
+echo "configure:1224: checking for building with threads" >&5
+    # Check whether --enable-threads or --disable-threads was given.
+if test "${enable_threads+set}" = set; then
+  enableval="$enable_threads"
+  tcl_ok=$enableval
+else
+  tcl_ok=no
+fi
+
+
+    if test "$tcl_ok" = "yes"; then
+       echo "$ac_t""yes" 1>&6
+       TCL_THREADS=1
+       cat >> confdefs.h <<\EOF
+#define TCL_THREADS 1
+EOF
+
+    else
+       TCL_THREADS=0
+       echo "$ac_t""no (default)" 1>&6
+    fi
+
+
+#--------------------------------------------------------------------
+# The statements below define a collection of symbols related to
+# building libtk as a shared library instead of a static library.
+#--------------------------------------------------------------------
+
+
+    echo $ac_n "checking how to build libraries""... $ac_c" 1>&6
+echo "configure:1254: checking how to build libraries" >&5
+    # Check whether --enable-shared or --disable-shared was given.
+if test "${enable_shared+set}" = set; then
+  enableval="$enable_shared"
+  tcl_ok=$enableval
+else
+  tcl_ok=yes
+fi
+
+
+    if test "${enable_shared+set}" = set; then
+       enableval="$enable_shared"
+       tcl_ok=$enableval
+    else
+       tcl_ok=yes
+    fi
+
+    if test "$tcl_ok" = "yes" ; then
+       echo "$ac_t""shared" 1>&6
+       SHARED_BUILD=1
+    else
+       echo "$ac_t""static" 1>&6
+       SHARED_BUILD=0
+       cat >> confdefs.h <<\EOF
+#define STATIC_BUILD 1
+EOF
+
+    fi
+
+
+#--------------------------------------------------------------------
+# The statements below define a collection of compile flags.  This 
+# macro depends on the value of SHARED_BUILD, and should be called
+# after SC_ENABLE_SHARED checks the configure switches.
+#--------------------------------------------------------------------
+
+
+    TCL_LIB_VERSIONS_OK=nodots
+
+    # Extract the first word of "cygpath", so it can be a program name with args.
+set dummy cygpath; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1296: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CYGPATH'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$CYGPATH"; then
+  ac_cv_prog_CYGPATH="$CYGPATH" # Let the user override the test.
+else
+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_CYGPATH="cygpath -w"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_prog_CYGPATH" && ac_cv_prog_CYGPATH="echo"
+fi
+fi
+CYGPATH="$ac_cv_prog_CYGPATH"
+if test -n "$CYGPATH"; then
+  echo "$ac_t""$CYGPATH" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+
+    # Check for a bug in gcc's windres that causes the
+    # compile to fail when a Windows native path is
+    # passed into windres. The mingw toolchain requires
+    # Windows native paths while Cygwin should work
+    # with both. Avoid the bug by passing a POSIX
+    # path when using the Cygwin toolchain.
+
+    if test "$GCC" = "yes" && test "$CYGPATH" != "echo" ; then
+        conftest=/tmp/conftest.rc
+        echo "STRINGTABLE BEGIN" > $conftest
+        echo "101 \"name\"" >> $conftest
+        echo "END" >> $conftest
+
+        echo $ac_n "checking for Windows native path bug in windres""... $ac_c" 1>&6
+echo "configure:1338: checking for Windows native path bug in windres" >&5
+        cyg_conftest=`$CYGPATH $conftest`
+        if { ac_try='$RC -o conftest.res.o $cyg_conftest'; { (eval echo configure:1340: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } ; then
+            echo "$ac_t""no" 1>&6
+        else
+            echo "$ac_t""yes" 1>&6
+            CYGPATH=echo
+        fi
+        conftest=
+        cyg_conftest=
+    fi
+
+    if test "$CYGPATH" = "echo" || test "$ac_cv_cygwin" = "yes"; then
+        DEPARG='"$<"'
+    else
+        DEPARG='"$(shell $(CYGPATH) $<)"'
+    fi
+
+    VENDORPREFIX=""
+
+    # set various compiler flags depending on whether we are using gcc or cl
+
+    echo $ac_n "checking compiler flags""... $ac_c" 1>&6
+echo "configure:1361: checking compiler flags" >&5
+    if test "${GCC}" = "yes" ; then
+
+       # CYGNUS LOCAL
+       VENDORPREFIX="cyg"
+
+       SHLIB_LD=""
+       SHLIB_LD_LIBS=""
+       LIBS=""
+       LIBS_GUI="-lgdi32 -lcomdlg32"
+       STLIB_LD="${AR} cr"
+       RC_OUT=-o
+       RC_TYPE=
+       RC_INCLUDE=--include
+       RES=res.o
+       MAKE_LIB="\${STLIB_LD} \$@"
+       POST_MAKE_LIB="\${RANLIB} \$@"
+       MAKE_EXE="\${CC} -o \$@"
+       LIBPREFIX="lib${VENDORPREFIX}"
+
+       if test "${SHARED_BUILD}" = "0" ; then
+           # static
+            echo "$ac_t""using static flags" 1>&6
+           runtime=
+           MAKE_DLL="echo "
+           LIBSUFFIX="s\${DBGX}.a"
+           LIBRARIES="\${STATIC_LIBRARIES}"
+           EXESUFFIX="s\${DBGX}.exe"
+           DLLSUFFIX=""
+       else
+           # dynamic
+            echo "$ac_t""using shared flags" 1>&6
+
+           # ad-hoc check to see if CC supports -shared.
+           if "${CC}" -shared 2>&1 | egrep ': -shared not supported' >/dev/null; then
+               { echo "configure: error: ${CC} does not support the -shared option.
+               You will need to upgrade to a newer version of the toolchain." 1>&2; exit 1; }
+           fi
+
+           runtime=
+           # Link with gcc since ld does not link to default libs like
+           # -luser32 and -lmsvcrt. We also need to add CFLAGS so important
+           # flags like -mno-cygwin get passed in to CC.
+           SHLIB_LD='${CC} -shared ${CFLAGS}'
+           # Add SHLIB_LD_LIBS to the Make rule, not here.
+           MAKE_DLL="\${SHLIB_LD} \$(LDFLAGS) -o \$@ ${extra_ldflags} \
+               -Wl,--out-implib,\$(patsubst %.dll,lib%.a,\$@)"
+
+           LIBSUFFIX="\${DBGX}.a"
+           DLLSUFFIX="\${DBGX}.dll"
+           EXESUFFIX="\${DBGX}.exe"
+           LIBRARIES="\${SHARED_LIBRARIES}"
+       fi
+
+       CFLAGS_DEBUG=-g
+       CFLAGS_OPTIMIZE=-O
+       CFLAGS_WARNING="-Wall -Wconversion"
+       LDFLAGS_DEBUG=
+       LDFLAGS_OPTIMIZE=
+
+       # Specify the CC output file names based on the target name
+       CC_OBJNAME="-o \$@"
+       CC_EXENAME="-o \$@"
+
+       # Specify linker flags depending on the type of app being 
+       # built -- Console vs. Window.
+       #
+       # We need to pass -e _WinMain@16 so that ld will use
+       # WinMain() instead of main() as the entry point. We can't
+       # use autoconf to check for this case since it would need
+       # to run an executable and that does not work when
+       # cross compiling. Remove this -e workaround once we
+       # require a gcc that does not have this bug.
+       LDFLAGS_CONSOLE="-mconsole ${extra_ldflags}"
+       LDFLAGS_WINDOW="-mwindows -e _WinMain@16 ${extra_ldflags}"
+    else
+       # CYGNUS LOCAL
+       VENDORPREFIX="sn"
+
+       SHLIB_LD="link -dll -nologo"
+       SHLIB_LD_LIBS="user32.lib advapi32.lib"
+       LIBS="user32.lib advapi32.lib"
+       LIBS_GUI="gdi32.lib comdlg32.lib"
+       STLIB_LD="lib -nologo"
+       RC="rc"
+       RC_OUT=-fo
+       RC_TYPE=-r
+       RC_INCLUDE=-i
+       RES=res
+       MAKE_LIB="\${STLIB_LD} -out:\$@"
+       POST_MAKE_LIB=
+       MAKE_EXE="\${CC} -Fe\$@"
+       LIBPREFIX=${VENDORPREFIX}
+
+       if test "${SHARED_BUILD}" = "0" ; then
+           # static
+            echo "$ac_t""using static flags" 1>&6
+           runtime=-MT
+           MAKE_DLL="echo "
+           LIBSUFFIX="s\${DBGX}.lib"
+           LIBRARIES="\${STATIC_LIBRARIES}"
+           EXESUFFIX="s\${DBGX}.exe"
+           DLLSUFFIX=""
+       else
+           # dynamic
+            echo "$ac_t""using shared flags" 1>&6
+           runtime=-MD
+           # Add SHLIB_LD_LIBS to the Make rule, not here.
+           MAKE_DLL="\${SHLIB_LD} \$(LDFLAGS) -out:\$@"
+           LIBSUFFIX="\${DBGX}.lib"
+           DLLSUFFIX="\${DBGX}.dll"
+           EXESUFFIX="\${DBGX}.exe"
+           LIBRARIES="\${SHARED_LIBRARIES}"
+       fi
+
+       EXTRA_CFLAGS="-YX"
+       CFLAGS_DEBUG="-nologo -Z7 -Od -WX ${runtime}d"
+#      CFLAGS_OPTIMIZE="-nologo -O2 -Gs -GD ${runtime}"
+       CFLAGS_OPTIMIZE="-nologo -Oti -Gs -GD ${runtime}"
+       CFLAGS_WARNING="-W3"
+       LDFLAGS_DEBUG="-debug:full -debugtype:cv"
+       LDFLAGS_OPTIMIZE="-release"
+
+       # Specify the CC output file names based on the target name
+       CC_OBJNAME="-Fo\$@"
+       CC_EXENAME="-Fe\"\$(shell \$(CYGPATH) '\$@')\""
+
+       # Specify linker flags depending on the type of app being 
+       # built -- Console vs. Window.
+       LDFLAGS_CONSOLE="-link -subsystem:console"
+       LDFLAGS_WINDOW="-link -subsystem:windows"
+    fi
+
+    # TCL_LIB_SUFFIX is defined here and in tclConfig.sh so that macros
+    # can use a single variable name for both Tcl and extensions.
+    TCL_LIB_SUFFIX=$LIBSUFFIX
+
+
+#--------------------------------------------------------------------
+# man2tcl needs this so that it can use errno.h
+#--------------------------------------------------------------------
+
+echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
+echo "configure:1504: checking how to run the C preprocessor" >&5
+# On Suns, sometimes $CPP names a directory.
+if test -n "$CPP" && test -d "$CPP"; then
+  CPP=
+fi
+if test -z "$CPP"; then
+if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+    # This must be in double quotes, not single quotes, because CPP may get
+  # substituted into the Makefile and "${CC-cc}" will confuse make.
+  CPP="${CC-cc} -E"
+  # On the NeXT, cc -E runs the code through the compiler's parser,
+  # not just through cpp.
+  cat > conftest.$ac_ext <<EOF
+#line 1519 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1525: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP="${CC-cc} -E -traditional-cpp"
+  cat > conftest.$ac_ext <<EOF
+#line 1536 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1542: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP="${CC-cc} -nologo -E"
+  cat > conftest.$ac_ext <<EOF
+#line 1553 "configure"
+#include "confdefs.h"
+#include <assert.h>
+Syntax Error
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1559: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  :
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  CPP=/lib/cpp
+fi
+rm -f conftest*
+fi
+rm -f conftest*
+fi
+rm -f conftest*
+  ac_cv_prog_CPP="$CPP"
+fi
+  CPP="$ac_cv_prog_CPP"
+else
+  ac_cv_prog_CPP="$CPP"
+fi
+echo "$ac_t""$CPP" 1>&6
+
+ac_safe=`echo "errno.h" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for errno.h""... $ac_c" 1>&6
+echo "configure:1585: checking for errno.h" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 1590 "configure"
+#include "confdefs.h"
+#include <errno.h>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1595: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=yes"
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  :
+else
+  echo "$ac_t""no" 1>&6
+MAN2TCLFLAGS="-DNO_ERRNO_H"
+fi
+
+
+
+#--------------------------------------------------------------------
+# Set the default compiler switches based on the --enable-symbols 
+# option.  This macro depends on C flags, and should be called
+# after SC_CONFIG_CFLAGS macro is called.
+#--------------------------------------------------------------------
+
+
+    echo $ac_n "checking for build with symbols""... $ac_c" 1>&6
+echo "configure:1627: checking for build with symbols" >&5
+    # Check whether --enable-symbols or --disable-symbols was given.
+if test "${enable_symbols+set}" = set; then
+  enableval="$enable_symbols"
+  tcl_ok=$enableval
+else
+  tcl_ok=no
+fi
+
+
+    if test "$tcl_ok" = "yes"; then
+       CFLAGS_DEFAULT='$(CFLAGS_DEBUG)'
+       LDFLAGS_DEFAULT='$(LDFLAGS_DEBUG)'
+       DBGX=d
+       echo "$ac_t""yes" 1>&6
+    else
+       CFLAGS_DEFAULT='$(CFLAGS_OPTIMIZE)'
+       LDFLAGS_DEFAULT='$(LDFLAGS_OPTIMIZE)'
+       DBGX=""
+       echo "$ac_t""no" 1>&6
+    fi
+
+
+TK_DBGX=${DBGX}
+
+#--------------------------------------------------------------------
+# Locate and source the tclConfig.sh file.
+#--------------------------------------------------------------------
+
+
+    echo $ac_n "checking the location of tclConfig.sh""... $ac_c" 1>&6
+echo "configure:1658: checking the location of tclConfig.sh" >&5
+
+# CYGNUS LOCAL
+    if test -d ../../tcl8.1/win;  then
+       TCL_BIN_DIR_DEFAULT=../../tcl8.1/win
+    else
+       TCL_BIN_DIR_DEFAULT=../../tcl/win
+    fi
+# END CYGNUS LOCAL
+    
+    # Check whether --with-tcl or --without-tcl was given.
+if test "${with_tcl+set}" = set; then
+  withval="$with_tcl"
+  TCL_BIN_DIR=$withval
+else
+  TCL_BIN_DIR=`cd $TCL_BIN_DIR_DEFAULT; pwd`
+fi
+
+    if test ! -d $TCL_BIN_DIR; then
+       { echo "configure: error: Tcl directory $TCL_BIN_DIR does not exist" 1>&2; exit 1; }
+    fi
+    if test ! -f $TCL_BIN_DIR/tclConfig.sh; then
+       { echo "configure: error: There is no tclConfig.sh in $TCL_BIN_DIR:  perhaps you did not specify the Tcl *build* directory (not the toplevel Tcl directory) or you forgot to configure Tcl?" 1>&2; exit 1; }
+    fi
+    echo "$ac_t""$TCL_BIN_DIR/tclConfig.sh" 1>&6
+
+
+    echo $ac_n "checking for existence of $TCL_BIN_DIR/tclConfig.sh""... $ac_c" 1>&6
+echo "configure:1686: checking for existence of $TCL_BIN_DIR/tclConfig.sh" >&5
+
+    if test -f "$TCL_BIN_DIR/tclConfig.sh" ; then
+        echo "$ac_t""loading" 1>&6
+       . $TCL_BIN_DIR/tclConfig.sh
+    else
+        echo "$ac_t""file not found" 1>&6
+    fi
+
+    # The eval is required to do the TCL_DBGX substitution in the
+    # TCL_LIB_FILE variable.
+
+    eval TCL_LIB_FILE=${TCL_LIB_FILE}
+    eval TCL_LIB_FLAG=${TCL_LIB_FLAG}
+
+    
+    
+    
+
+
+#------------------------------------------------------------------------
+# tkConfig.sh refers to this by a different name
+#------------------------------------------------------------------------
+
+TK_SHARED_BUILD=${SHARED_BUILD}
+
+#--------------------------------------------------------------------
+# Perform final evaluations of variables with possible substitutions.
+#--------------------------------------------------------------------
+
+NODOT_VERSION=${VER}
+
+TK_SHARED_LIB_SUFFIX="\${NODOT_VERSION}${DLLSUFFIX}"
+TK_UNSHARED_LIB_SUFFIX="\${NODOT_VERSION}${LIBSUFFIX}"
+TK_EXPORT_FILE_SUFFIX="\${NODOT_VERSION}${LIBSUFFIX}"
+
+
+  val="`cd $srcdir/..; pwd`"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_SRC_DIR" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_SRC_DIR=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_SRC_DIR="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_SRC_DIR=$val
+    ;;
+  esac
+
+
+
+  libname=tk
+  suffix=${TK_SHARED_LIB_SUFFIX}
+
+  case "${host}" in
+    *windows32* | *mingw32* | *cygwin*)
+      eval "long_libname=\"${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+    ;;
+    *)
+      eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+    ;;
+  esac
+
+  eval "long_libname=${long_libname}"
+
+  # Trick to replace DBGX with TCL_DBGX
+  DBGX='${TCL_DBGX}'
+  eval "long_libname=${long_libname}"
+
+  TK_DLL_FILE=$long_libname
+
+
+  libname=tk
+  suffix=${TK_UNSHARED_LIB_SUFFIX}
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        eval "long_libname=\"${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+      else
+        eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+      fi
+    ;;
+    *)
+      eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+    ;;
+  esac
+
+  eval "long_libname=${long_libname}"
+
+  # Trick to replace DBGX with TCL_DBGX
+  DBGX='${TCL_DBGX}'
+  eval "long_libname=${long_libname}"
+
+  TK_LIB_FILE=$long_libname
+
+
+  libname=tkstub
+  suffix=${TK_UNSHARED_LIB_SUFFIX}
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        eval "long_libname=\"${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+      else
+        eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+      fi
+    ;;
+    *)
+      eval "long_libname=\"lib${TCL_VENDOR_PREFIX}${libname}${suffix}\""
+    ;;
+  esac
+
+  eval "long_libname=${long_libname}"
+
+  # Trick to replace DBGX with TCL_DBGX
+  DBGX='${TCL_DBGX}'
+  eval "long_libname=${long_libname}"
+
+  TK_STUB_LIB_FILE=$long_libname
+
+
+if test "$GCC" = "yes"; then
+    GNU_TK_LIB_FILE=${TK_LIB_FILE}
+    MSVC_TK_LIB_FILE=
+else
+    GNU_TK_LIB_FILE=
+    MSVC_TK_LIB_FILE=${TK_LIB_FILE}
+fi
+
+
+  libname=tkstub
+  version=${TK_VERSION}
+
+  if test "$TCL_LIB_SUFFIX" = "" ; then
+    { echo "configure: error: The TCL_LIB_SUFFIX variable is not defined" 1>&2; exit 1; }
+  fi
+
+  # If the . character is not allowed in lib name, remove it from version
+  if test "${TCL_LIB_VERSIONS_OK}" != "ok"; then
+        version=`echo $version | tr -d .`
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        eval "short_libname=\"${TCL_VENDOR_PREFIX}${libname}${version}${TCL_LIB_SUFFIX}\""
+      else
+        short_libname="-l${TCL_VENDOR_PREFIX}${libname}${version}${TCL_DBGX}"
+      fi
+    ;;
+    *)
+      short_libname="-l${TCL_VENDOR_PREFIX}${libname}${version}\${TCL_DBGX}"
+    ;;
+  esac
+
+  TK_STUB_LIB_FLAG=$short_libname
+
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        
+  val="`pwd`/${TK_STUB_LIB_FLAG}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_BUILD_STUB_LIB_SPEC" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_BUILD_STUB_LIB_SPEC=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_BUILD_STUB_LIB_SPEC="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_BUILD_STUB_LIB_SPEC=$val
+    ;;
+  esac
+
+      else
+        
+  val=`pwd`
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable dirname" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        dirname=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        dirname="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      dirname=$val
+    ;;
+  esac
+
+        TK_BUILD_STUB_LIB_SPEC="-L${dirname} ${TK_STUB_LIB_FLAG}"
+      fi
+    ;;
+    *)
+      TK_BUILD_STUB_LIB_SPEC="-L`pwd` ${TK_STUB_LIB_FLAG}"
+    ;;
+  esac
+
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        
+  val="${exec_prefix}/lib/${TK_STUB_LIB_FLAG}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_STUB_LIB_SPEC" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_STUB_LIB_SPEC=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_STUB_LIB_SPEC="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_STUB_LIB_SPEC=$val
+    ;;
+  esac
+
+      else
+        
+  val=${exec_prefix}/lib
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable dirname" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        dirname=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        dirname="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      dirname=$val
+    ;;
+  esac
+
+        TK_STUB_LIB_SPEC="-L${dirname} ${TK_STUB_LIB_FLAG}"
+      fi
+    ;;
+    *)
+      TK_STUB_LIB_SPEC="-L${exec_prefix}/lib ${TK_STUB_LIB_FLAG}"
+    ;;
+  esac
+
+
+
+  
+  val="`pwd`/${TK_STUB_LIB_FILE}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_BUILD_STUB_LIB_PATH" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_BUILD_STUB_LIB_PATH=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_BUILD_STUB_LIB_PATH="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_BUILD_STUB_LIB_PATH=$val
+    ;;
+  esac
+
+
+
+  
+  val="${exec_prefix}/lib/${TK_STUB_LIB_FILE}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_STUB_LIB_PATH" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_STUB_LIB_PATH=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_STUB_LIB_PATH="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_STUB_LIB_PATH=$val
+    ;;
+  esac
+
+
+
+eval "DLLSUFFIX=${DLLSUFFIX}"
+eval "LIBPREFIX=${LIBPREFIX}"
+eval "LIBSUFFIX=${LIBSUFFIX}"
+eval "EXESUFFIX=${EXESUFFIX}"
+
+
+  libname=tk
+  version=$TK_VERSION
+
+  if test "$TCL_LIB_SUFFIX" = "" ; then
+    { echo "configure: error: The TCL_LIB_SUFFIX variable is not defined" 1>&2; exit 1; }
+  fi
+
+  # If the . character is not allowed in lib name, remove it from version
+  if test "${TCL_LIB_VERSIONS_OK}" != "ok"; then
+        version=`echo $version | tr -d .`
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        eval "short_libname=\"${TCL_VENDOR_PREFIX}${libname}${version}${TCL_LIB_SUFFIX}\""
+      else
+        short_libname="-l${TCL_VENDOR_PREFIX}${libname}${version}${TCL_DBGX}"
+      fi
+    ;;
+    *)
+      short_libname="-l${TCL_VENDOR_PREFIX}${libname}${version}\${TCL_DBGX}"
+    ;;
+  esac
+
+  TK_LIB_FLAG=$short_libname
+
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        
+  val="`pwd`/${TK_LIB_FLAG}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_BUILD_LIB_SPEC" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_BUILD_LIB_SPEC=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_BUILD_LIB_SPEC="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_BUILD_LIB_SPEC=$val
+    ;;
+  esac
+
+      else
+        
+  val=`pwd`
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable dirname" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        dirname=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        dirname="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      dirname=$val
+    ;;
+  esac
+
+        TK_BUILD_LIB_SPEC="-L${dirname} ${TK_LIB_FLAG}"
+      fi
+    ;;
+    *)
+      TK_BUILD_LIB_SPEC="-L`pwd` ${TK_LIB_FLAG}"
+    ;;
+  esac
+
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "$GCC" != yes; then
+        
+  val="${exec_prefix}/lib/${TK_LIB_FLAG}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_LIB_SPEC" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_LIB_SPEC=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_LIB_SPEC="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_LIB_SPEC=$val
+    ;;
+  esac
+
+      else
+        
+  val=${exec_prefix}/lib
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable dirname" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        dirname=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        dirname="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      dirname=$val
+    ;;
+  esac
+
+        TK_LIB_SPEC="-L${dirname} ${TK_LIB_FLAG}"
+      fi
+    ;;
+    *)
+      TK_LIB_SPEC="-L${exec_prefix}/lib ${TK_LIB_FLAG}"
+    ;;
+  esac
+
+
+  
+  val="`pwd`/${TK_LIB_FILE}"
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable TK_LIB_FULL_PATH" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        TK_LIB_FULL_PATH=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        TK_LIB_FULL_PATH="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      TK_LIB_FULL_PATH=$val
+    ;;
+  esac
+
+
+
+if test "$SHARED_BUILD" = 0 -o $TCL_NEEDS_EXP_FILE = 0; then
+    WISH_RES=wish_static.${RES}
+    TK_RES=
+else
+    WISH_RES=wish_static.${RES}
+    TK_RES=tk_dll.${RES}
+fi
+TK_SHARED_BUILD=${SHARED_BUILD}
+
+CFG_TK_SHARED_LIB_SUFFIX=${TK_SHARED_LIB_SUFFIX}
+CFG_TK_UNSHARED_LIB_SUFFIX=${TK_UNSHARED_LIB_SUFFIX}
+CFG_TK_EXPORT_FILE_SUFFIX=${TK_EXPORT_FILE_SUFFIX}
+
+# Add X include path, it must be in a format
+# like -I"C:/Dir" and not -I"C:\Dir" or VC++ will puke.
+
+  val=$srcdir/../xlib
+
+  if test "$val" = "" ; then
+    { echo "configure: error: Empty value for variable XINCLUDES" 1>&2; exit 1; }
+  fi
+
+  case "${host}" in
+    *windows32* | *mingw32*)
+      if test "${CYGPATH}" = ""; then
+        { echo "configure: error: CYGPATH variable is not defined." 1>&2; exit 1; }
+      elif test "${CYGPATH}" = "echo"; then
+        # No cygpath when cross compiling
+        XINCLUDES=$val
+      else
+        # store literal argument text in a variable
+        val=$val
+        # Convert Cygwin to Windows path (/tmp/foo -> C:\Tmp\foo)
+        val="`${CYGPATH} $val`"
+        # Convert path like C:\Tmp\foo to C:/Tmp/foo
+        XINCLUDES="`echo $val | sed -e s#\\\\\\\\#/#g`"
+      fi
+    ;;
+    *)
+      # Default to a no-op under Unix or Cygwin gcc
+      XINCLUDES=$val
+    ;;
+  esac
+
+XINCLUDES="-I\"${XINCLUDES}\""
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
 
-TK_VERSION=8.0
-TK_MAJOR_VERSION=8
-TK_MINOR_VERSION=0
-TK_PATCH_LEVEL=p2
-VERSION=${TK_VERSION}
 
-MATH_LIBS=-lm
-LIBOBJS=
 
-TK_SHLIB_CFLAGS=""
-eval "TK_LIB_FILE=libtk${TCL_UNSHARED_LIB_SUFFIX}"
 
-TK_UNSHARED_LIB_FILE="$TK_LIB_FILE"
-TK_SRC_DIR=`cd $srcdir/..; pwd`
 
-XINCLUDES="-I`cd $srcdir/../xlib; pwd`"
-XLIBSW=
-TK_BUILD_INCLUDES="-I`cd $srcdir/../generic; pwd` -I`cd $srcdir/../xlib; pwd`"
-TK_BUILD_LIB_SPEC="-L`pwd` -ltk`echo ${VERSION} | tr -d .`"
-TK_LIB_SPEC="-L${exec_prefix}/lib -ltk`echo ${VERSION} | tr -d .`"
 
 
 
@@ -991,7 +2421,7 @@ EOF
 # Ultrix sh set writes to stderr and can't be redirected directly,
 # and sets the high bit in the cache file unless we assign to the vars.
 (set) 2>&1 |
-  case `(ac_space=' '; set) 2>&1 | grep ac_space` in
+  case `(ac_space=' '; set | grep ac_space) 2>&1` in
   *ac_space=\ *)
     # `set' does not quote correctly, so add quotes (double-quote substitution
     # turns \\\\ into \\, and sed turns \\ into \).
@@ -1070,7 +2500,7 @@ do
     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
-    echo "$CONFIG_STATUS generated by autoconf version 2.12.2"
+    echo "$CONFIG_STATUS generated by autoconf version 2.13"
     exit 0 ;;
   -help | --help | --hel | --he | --h)
     echo "\$ac_cs_usage"; exit 0 ;;
@@ -1079,9 +2509,8 @@ do
 done
 
 ac_given_srcdir=$srcdir
-ac_given_INSTALL="$INSTALL"
 
-trap 'rm -fr `echo "Makefile ../unix/tkConfig.sh" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+trap 'rm -fr `echo "Makefile tkConfig.sh" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
 EOF
 cat >> $CONFIG_STATUS <<EOF
 
@@ -1094,6 +2523,7 @@ s%@SHELL@%$SHELL%g
 s%@CFLAGS@%$CFLAGS%g
 s%@CPPFLAGS@%$CPPFLAGS%g
 s%@CXXFLAGS@%$CXXFLAGS%g
+s%@FFLAGS@%$FFLAGS%g
 s%@DEFS@%$DEFS%g
 s%@LDFLAGS@%$LDFLAGS%g
 s%@LIBS@%$LIBS%g
@@ -1112,38 +2542,100 @@ s%@includedir@%$includedir%g
 s%@oldincludedir@%$oldincludedir%g
 s%@infodir@%$infodir%g
 s%@mandir@%$mandir%g
+s%@CC@%$CC%g
 s%@host@%$host%g
 s%@host_alias@%$host_alias%g
 s%@host_cpu@%$host_cpu%g
 s%@host_vendor@%$host_vendor%g
 s%@host_os@%$host_os%g
-s%@CC@%$CC%g
+s%@build@%$build%g
+s%@build_alias@%$build_alias%g
+s%@build_cpu@%$build_cpu%g
+s%@build_vendor@%$build_vendor%g
+s%@build_os@%$build_os%g
+s%@AR@%$AR%g
+s%@RANLIB@%$RANLIB%g
+s%@RC@%$RC%g
+s%@SET_MAKE@%$SET_MAKE%g
 s%@OBJEXT@%$OBJEXT%g
-s%@NM@%$NM%g
-s%@AS@%$AS%g
-s%@LD@%$LD%g
-s%@DLLTOOL@%$DLLTOOL%g
-s%@WINDRES@%$WINDRES%g
-s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
-s%@INSTALL_DATA@%$INSTALL_DATA%g
-s%@TCL_ALLOC_OBJ@%$TCL_ALLOC_OBJ%g
-s%@DLL_LDFLAGS@%$DLL_LDFLAGS%g
-s%@DLL_LDLIBS@%$DLL_LDLIBS%g
-s%@LIBOBJS@%$LIBOBJS%g
-s%@DL_LIBS@%$DL_LIBS%g
-s%@LD_FLAGS@%$LD_FLAGS%g
-s%@MATH_LIBS@%$MATH_LIBS%g
-s%@TK_BUILD_INCLUDES@%$TK_BUILD_INCLUDES%g
-s%@TK_BUILD_LIB_SPEC@%$TK_BUILD_LIB_SPEC%g
-s%@TK_LIB_FILE@%$TK_LIB_FILE%g
-s%@TK_LIB_SPEC@%$TK_LIB_SPEC%g
+s%@EXEEXT@%$EXEEXT%g
+s%@CYGPATH@%$CYGPATH%g
+s%@CPP@%$CPP%g
+s%@MAN2TCLFLAGS@%$MAN2TCLFLAGS%g
+s%@TCL_BIN_DIR@%$TCL_BIN_DIR%g
+s%@TCL_SRC_DIR@%$TCL_SRC_DIR%g
+s%@TCL_LIB_FILE@%$TCL_LIB_FILE%g
+s%@TK_VERSION@%$TK_VERSION%g
 s%@TK_MAJOR_VERSION@%$TK_MAJOR_VERSION%g
 s%@TK_MINOR_VERSION@%$TK_MINOR_VERSION%g
 s%@TK_PATCH_LEVEL@%$TK_PATCH_LEVEL%g
+s%@TK_DBGX@%$TK_DBGX%g
+s%@TK_LIB_FILE@%$TK_LIB_FILE%g
+s%@GNU_TK_LIB_FILE@%$GNU_TK_LIB_FILE%g
+s%@MSVC_TK_LIB_FILE@%$MSVC_TK_LIB_FILE%g
+s%@TK_DLL_FILE@%$TK_DLL_FILE%g
+s%@TK_LIB_FLAG@%$TK_LIB_FLAG%g
+s%@TK_STUB_LIB_FILE@%$TK_STUB_LIB_FILE%g
+s%@TK_STUB_LIB_FLAG@%$TK_STUB_LIB_FLAG%g
+s%@TK_STUB_LIB_SPEC@%$TK_STUB_LIB_SPEC%g
+s%@TK_STUB_LIB_PATH@%$TK_STUB_LIB_PATH%g
+s%@TK_BUILD_STUB_LIB_SPEC@%$TK_BUILD_STUB_LIB_SPEC%g
+s%@TK_BUILD_STUB_LIB_PATH@%$TK_BUILD_STUB_LIB_PATH%g
 s%@TK_SRC_DIR@%$TK_SRC_DIR%g
-s%@TK_VERSION@%$TK_VERSION%g
+s%@TK_BIN_DIR@%$TK_BIN_DIR%g
+s%@TK_BUILD_LIB_SPEC@%$TK_BUILD_LIB_SPEC%g
+s%@TK_LIB_SPEC@%$TK_LIB_SPEC%g
+s%@TK_LIB_FULL_PATH@%$TK_LIB_FULL_PATH%g
+s%@TK_SHARED_BUILD@%$TK_SHARED_BUILD%g
+s%@WISH_RES@%$WISH_RES%g
+s%@TK_RES@%$TK_RES%g
+s%@TCL_VERSION@%$TCL_VERSION%g
+s%@TCL_MAJOR_VERSION@%$TCL_MAJOR_VERSION%g
+s%@TCL_MINOR_VERSION@%$TCL_MINOR_VERSION%g
+s%@TCL_PATCH_LEVEL@%$TCL_PATCH_LEVEL%g
+s%@TCL_DLL_FILE@%$TCL_DLL_FILE%g
+s%@TCL_STUB_LIB_FILE@%$TCL_STUB_LIB_FILE%g
+s%@TCL_STUB_LIB_FLAG@%$TCL_STUB_LIB_FLAG%g
+s%@TCL_BUILD_LIB_SPEC@%$TCL_BUILD_LIB_SPEC%g
+s%@TCL_BUILD_STUB_LIB_SPEC@%$TCL_BUILD_STUB_LIB_SPEC%g
+s%@TCL_DBGX@%$TCL_DBGX%g
+s%@CFG_TK_SHARED_LIB_SUFFIX@%$CFG_TK_SHARED_LIB_SUFFIX%g
+s%@CFG_TK_UNSHARED_LIB_SUFFIX@%$CFG_TK_UNSHARED_LIB_SUFFIX%g
+s%@CFG_TK_EXPORT_FILE_SUFFIX@%$CFG_TK_EXPORT_FILE_SUFFIX%g
+s%@DEPARG@%$DEPARG%g
+s%@CFLAGS_DEFAULT@%$CFLAGS_DEFAULT%g
+s%@CFLAGS_DEBUG@%$CFLAGS_DEBUG%g
+s%@CFLAGS_OPTIMIZE@%$CFLAGS_OPTIMIZE%g
+s%@CFLAGS_WARNING@%$CFLAGS_WARNING%g
+s%@EXTRA_CFLAGS@%$EXTRA_CFLAGS%g
+s%@STLIB_LD@%$STLIB_LD%g
+s%@SHLIB_LD@%$SHLIB_LD%g
+s%@SHLIB_LD_LIBS@%$SHLIB_LD_LIBS%g
+s%@SHLIB_CFLAGS@%$SHLIB_CFLAGS%g
+s%@SHLIB_SUFFIX@%$SHLIB_SUFFIX%g
+s%@CC_OBJNAME@%$CC_OBJNAME%g
+s%@CC_EXENAME@%$CC_EXENAME%g
+s%@LDFLAGS_DEFAULT@%$LDFLAGS_DEFAULT%g
+s%@LDFLAGS_DEBUG@%$LDFLAGS_DEBUG%g
+s%@LDFLAGS_OPTIMIZE@%$LDFLAGS_OPTIMIZE%g
+s%@LDFLAGS_CONSOLE@%$LDFLAGS_CONSOLE%g
+s%@LDFLAGS_WINDOW@%$LDFLAGS_WINDOW%g
+s%@RC_OUT@%$RC_OUT%g
+s%@RC_TYPE@%$RC_TYPE%g
+s%@RC_INCLUDE@%$RC_INCLUDE%g
+s%@RES@%$RES%g
+s%@LIBS_GUI@%$LIBS_GUI%g
+s%@DLLSUFFIX@%$DLLSUFFIX%g
+s%@LIBPREFIX@%$LIBPREFIX%g
+s%@LIBSUFFIX@%$LIBSUFFIX%g
+s%@EXESUFFIX@%$EXESUFFIX%g
+s%@LIBRARIES@%$LIBRARIES%g
+s%@MAKE_LIB@%$MAKE_LIB%g
+s%@POST_MAKE_LIB@%$POST_MAKE_LIB%g
+s%@MAKE_DLL@%$MAKE_DLL%g
+s%@MAKE_EXE@%$MAKE_EXE%g
+s%@TK_XINCLUDES@%$TK_XINCLUDES%g
 s%@XINCLUDES@%$XINCLUDES%g
-s%@XLIBSW@%$XLIBSW%g
 
 CEOF
 EOF
@@ -1152,7 +2644,7 @@ cat >> $CONFIG_STATUS <<\EOF
 
 # Split the substitutions into bite-sized pieces for seds with
 # small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
+ac_max_sed_cmds=60 # Maximum number of lines to put in a sed script.
 ac_file=1 # Number of current file.
 ac_beg=1 # First line for current file.
 ac_end=$ac_max_sed_cmds # Line after last line for current file.
@@ -1185,7 +2677,7 @@ EOF
 
 cat >> $CONFIG_STATUS <<EOF
 
-CONFIG_FILES=\${CONFIG_FILES-"Makefile ../unix/tkConfig.sh"}
+CONFIG_FILES=\${CONFIG_FILES-"Makefile tkConfig.sh"}
 EOF
 cat >> $CONFIG_STATUS <<\EOF
 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
@@ -1220,10 +2712,6 @@ for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
     top_srcdir="$ac_dots$ac_given_srcdir" ;;
   esac
 
-  case "$ac_given_INSTALL" in
-  [/$]*) INSTALL="$ac_given_INSTALL" ;;
-  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
-  esac
 
   echo creating "$ac_file"
   rm -f "$ac_file"
@@ -1239,7 +2727,6 @@ for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
 s%@configure_input@%$configure_input%g
 s%@srcdir@%$srcdir%g
 s%@top_srcdir@%$top_srcdir%g
-s%@INSTALL@%$INSTALL%g
 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
 fi; done
 rm -f conftest.s*