linking to tk84.lib fails 
Author Message
 linking to tk84.lib fails

Tk 8.4a1 Bug:  Generated by Ajuba's bug entry form at
        http://www.*-*-*.com/
Responses to this post are encouraged.
------

Submitted by:  Don Porter
OperatingSystem:  Windows 95
Synopsis:  linking to tk84.lib fails

ReproducibleScript:
/* FILE: test.c
 */
#include <tcl.h>
#include <tk.h>

int
Tcl_AppInit(Tcl_Interp *interp)
{
    if (Tcl_Init(interp) != TCL_OK) {
        return TCL_ERROR;
    }
    if (Tk_Init(interp) != TCL_OK) {
        return TCL_ERROR;
    }
    Tcl_StaticPackage(interp, "Tk", Tk_Init, Tk_SafeInit);

    return TCL_OK;

Quote:
}

int main(int argc, char **argv)
{
  // Turn over control to the Tk library.
  Tk_Main(argc, argv, Tcl_AppInit);

  // Make picky compilers happy.
  return 0;

Quote:
}

ObservedBehavior:
C:> cl /nologo /c /IC:/PROGRA~1/TCL/include /Fotest.obj test.c
test.c

C:> link /nologo test.obj C:/PROGRA~1/TCL/lib/tk84.lib C:/PROGRA~1/TCL/lib/tcl84.lib /OUT:test.exe
C:/PROGRA~1/TCL/lib/tk84.lib: fatal error LNK1106: invalid file or disk full: cannot seek to 0x393f800d

DesiredBehavior:
I should be able to statically link
my C apps to tk84.lib.

Comments:
    The disk is not full.

    cl == Microsoft(R) 32-Bit Optimizing Compiler Version 11.00.7022 for
    80x86

    The same sequence of operation succeeds with Tcl/Tk 8.3.1.



Sun, 24 Nov 2002 03:00:00 GMT  
 linking to tk84.lib fails
Hi Don,

I don't think tk84.dll is a static library.  It's a import lib, i believe:

C:\>lib /list c:/progra~1/tcl/lib/tcl84.lib
Microsoft (R) Library Manager Version 5.12.8181
Copyright (C) Microsoft Corp 1992-1998. All rights reserved.

tcl84.dll
tcl84.dll
tcl84.dll
tcl84.dll
 ....

There's a way to make a static library for Tk.  Jan Nijtmans made some patches
for it.  I'm not sure if they're in the core, though.
--
* David Gravereaux *
Tomahawk Software Group



Sun, 24 Nov 2002 03:00:00 GMT  
 linking to tk84.lib fails

Quote:
> I don't think tk84.dll is a static library.  It's a import lib, i believe:

OK, I'm willing to be educated in the ways of Windows.

However, the exact same procedures have been effective with Tk releases
from 4.2 through 8.3.1 on the same OS with the same compiler and linker,
so something has changed in the new Tk 8.4a1 release.  What?

--
| Don Porter          Mathematical and Computational Sciences Division |

| http://math.nist.gov/~DPorter/                                  NIST |
|______________________________________________________________________|



Sun, 24 Nov 2002 03:00:00 GMT  
 linking to tk84.lib fails
Yes, something is wrong with the windows distribution.
Same problem under 98SE...

George

Quote:

> Tk 8.4a1 Bug:  Generated by Ajuba's bug entry form at
>         http://www.ajubasolutions.com/support/bugForm.html
> Responses to this post are encouraged.
> ------

> Submitted by:  Don Porter
> OperatingSystem:  Windows 95
> Synopsis:  linking to tk84.lib fails

> ReproducibleScript:
> /* FILE: test.c
>  */
> #include <tcl.h>
> #include <tk.h>

> int
> Tcl_AppInit(Tcl_Interp *interp)
> {
>     if (Tcl_Init(interp) != TCL_OK) {
>         return TCL_ERROR;
>     }
>     if (Tk_Init(interp) != TCL_OK) {
>         return TCL_ERROR;
>     }
>     Tcl_StaticPackage(interp, "Tk", Tk_Init, Tk_SafeInit);

>     return TCL_OK;
> }

> int main(int argc, char **argv)
> {
>   // Turn over control to the Tk library.
>   Tk_Main(argc, argv, Tcl_AppInit);

>   // Make picky compilers happy.
>   return 0;
> }

> ObservedBehavior:
> C:> cl /nologo /c /IC:/PROGRA~1/TCL/include /Fotest.obj test.c
> test.c

> C:> link /nologo test.obj C:/PROGRA~1/TCL/lib/tk84.lib C:/PROGRA~1/TCL/lib/tcl84.lib /OUT:test.exe
> C:/PROGRA~1/TCL/lib/tk84.lib: fatal error LNK1106: invalid file or disk full: cannot seek to 0x393f800d

> DesiredBehavior:
> I should be able to statically link
> my C apps to tk84.lib.

> Comments:
>     The disk is not full.

>     cl == Microsoft(R) 32-Bit Optimizing Compiler Version 11.00.7022 for
>     80x86

>     The same sequence of operation succeeds with Tcl/Tk 8.3.1.



Mon, 25 Nov 2002 03:00:00 GMT  
 linking to tk84.lib fails

Quote:


>> I don't think tk84.dll is a static library.  It's a import lib, i believe:

>OK, I'm willing to be educated in the ways of Windows.

Whoop..  My mistake.  I got lost in the wording.  lib/tk84.lib in the install
is an import library, and a static library is something different.

Quote:
>However, the exact same procedures have been effective with Tk releases
>from 4.2 through 8.3.1 on the same OS with the same compiler and linker,
>so something has changed in the new Tk 8.4a1 release.  What?

Here's a bad guess...  I can't confirm it unless someone asks the config crew...

Microsoft has a different linker that makes compressed import libraries that
came with the platform SDK (and I think MSVC++ 6).

http://msdn.microsoft.com/library/default.asp?URL=/library/devprods/v...

I don't know if my guess is correct.  If the Ajuba config crew is using the
newer linker, I think they should add /LINK50COMPAT to the link commandline for
the 5.0 format in the distribution.

*disclaimer: I'm guessing..*
--
David Gravereaux



Mon, 25 Nov 2002 03:00:00 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. how to statically link against tcl84.lib, tk84.lib, tclx84.lib?

2. The latest Tcl85 failed to load extensions that were linked to the tcl85 and tk85.lib

3. Linking sqldedev.lib, desktopenginedeploy.lib to my app: unsupported recordtype 21

4. Static vs Shared: Linking tcl83s.lib vs tcl83.lib

5. Statically Linking tcl.lib and tk.lib into a standalone .exe file

6. Reimplementing Lib/codeop.py in C fails...

7. make lib.info fails in 1.4 ?

8. Static Lib still failing

9. shared lib problems on SunOS: build ok, load fails

10. Loading tk84.dll dynamically (on Windows boxes)

11. compile tk84 on windows, X11 needed?

12. If someone is interested: Win32 build of tcl/tk84 from todays cvs available

 

 
Powered by phpBB® Forum Software