lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Dear Luaners,

I'm new in the group (and to Lua). Thats why at first a great
 "hello" to all!
 ... and always some problems:

I want to build "tklua" for Win3.1 (+Win32s) - but something is wrong :-(

My configuration is:
- real DOS 6.20   (or sometimes NT4.0)
- DJGPP 2.95.2    (gcc.exe)
- RSXNTDJ 1.5.1   (gccw32.exe)
- xlibemu         (based on X11R5)
- tcltk-8.0p2-minw32.zip (there are libtcl80.a, libtk80.a and both dll's)
- lua 3.1
- tolua 3.0
  ...and I have tested to build it with:
- tklua 2.0, tklua 2.1, tklua 2.11 and tklua 2.12

but it didn't work! Well - I'm a pascal programmer and doesn't realy
understand "C". (This is the reason why I hope to use tklua.)

The first I have made was to "make all" but always at lua there comes
an error "-1" from "make.exe". So I have written me a "build.bat" that
makes for all subdirs:
 cd subdir
 make all
 cd ..

This works on Lua, Luac and on ToLua. I have tested the new exe's with a
"hello world" and tryed to build tklua in the same manner (with build.bat).
Here is a part of my log file:

----------------------------------------- 
make.exe[1]: Entering directory `i:/lua31/tklua/src/lib'
make.exe[1]: `../../lib/libtklua.a' is up to date.
make.exe[1]: Leaving directory `i:/lua31/tklua/src/lib'
----------------------------------------- 
make.exe[1]: Entering directory `i:/lua31/tklua/src/bin'
gcc -o ../../bin/tklua tkluamain.o -L../../lib -L/lua31/lua/lib -L/lua31/tolua/lib -L/tcl/lib -L/xlib/lib -L/usr/local/lib -L/usr/local/gllua/lib -ltk80 -ltcl80 -ltklua -ltolua -llualib -llua -lX11 -lm
../../lib/libtklua.a(tklua.o)(.text+0x9e):tklua.c: undefined reference to `Tcl_Eval'

(23 lines of this kind)

../../lib/libtklua.a(tklua.o)(.text+0x212e):tklua.c: undefined reference to `Tk_NameToWindow'
collect2: ld returned 1 exit status
make.exe[1]: *** [../../bin/tklua] Error 1
make.exe[1]: Leaving directory `i:/lua31/tklua/src/bin'
make.exe: *** [basic] Error 2
----------------------------------------- 

At the end there is a "tklua.o" in the ./SRC/LIB directory but nothing 
in ./BIN . The "undefined references" (log file) points to:

Tcl_CancelIdleCall
Tcl_CreateCommand
Tcl_CreateInterp
Tcl_DeleteTimerHandler
Tcl_DoWhenIdle
Tcl_Eval
Tcl_Free
Tcl_GetVar
Tcl_Init
Tcl_SplitList
Tk_Init
Tk_MainWindow
Tk_NameToWindow

My qeustions are:
1. What's wrong?
2. should I use a different compiler?   (using DOS!)
3. is this the rigth tcltk-pack?        (need "libXXX.a" format = COFF ???)
 3a. where can I get the rigth *.h and lib*.a for tcltk 8.0p2 ?
4. why doesn't "make" work on the main-makefile but on all sub makefile's ?
 4a. should I use a different version of "make.exe" ?
5. is there anywere a tklua version for Lua 4.0 ?
6. may I use the originaly "tkbnd.c" in ./SRC/LIB or have I build a new one?
7. In my new builded "tkbnd.c" are these lines:
   --- snipp ---
   [
   <tk.lua>
   ]
   --- snapp ---
   what does it mean? Have tolua didn't work correctly or is it for 
   unix only? My gcc.exe reports then a parser error before '['.
8. Are there anybody using tklua with Win3x(+Win32s) ?
9. Is it a problem for (To)Lua if DOS has cutted a file name to 8+3 chars
   for ex.: tkluamain.c to tkluamai.c ?
10. Will it be a problem for tklua to load and show (quickly) a 24bit-picture
   with about 20-40 MB ?

I hope some of you will take the time to answer my questions - thanks!
... and sorry for my bad english.

best regards
Torsten Kildal (germany)
--
why use windows - if you have a door?