Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!brutus.cs.uiuc.edu!wuarchive!texbell!sugar!karl From: karl@sugar.hackercorp.com (Karl Lehenbauer) Newsgroups: comp.sys.amiga.tech Subject: Re: Tcl - Tool command language Message-ID: <5262@sugar.hackercorp.com> Date: 8 Mar 90 01:57:42 GMT References: <5213@sugar.hackercorp.com> <5231@sugar.hackercorp.com> <48f6cbee.db93@edsel.engin.umich.edu> <5237@sugar.hackercorp.com> <23217@usc.edu> Reply-To: karl@sugar.hackercorp.com (Karl Lehenbauer) Organization: Sugar Land Unix - Houston Lines: 32 In article <23217@usc.edu> papa@pollux.usc.edu (Marco Papa) writes: >One drawback I see at the moment of Tcl vs. Arexx on the Amiga is that the >former one is not made into a .library. >Are you guys at hackercorp working on a Tcl library? Yes. Manx 5.0 greatly simplifies the creation of libraries. You create a .fd file and the mapfd program, which comes with 5.0, generates the amicall pragmas for the library. You use the -qp compiler option to generate the function prototypes. Then a bit of monkey business and magic (a sample shared library, with source, that actually compiles and works is included in 5.0) and you have a shared library. I have done almost all of the work necessary to make Tcl and my Tcla Amiga extension for interprocess communications, windows, menus, gadgets, fonts, drawing and event loop handling into a shared library. This mainly involved moving all global data into ClientData structures associated with the Tcla extensions. Fortunately, vanilla Tcl keeps all of its data in or subordinate to Tcl_Interp data structures, so Tcl itself requires hardly any diddling to make it work within a shared lib. I haven't finished the job because I like calling printf and such when I'm debugging, and doing so from a shared library introduces some difficulties. I may have to have the user of the shared library pass pointers to some functions up to the shared library, that the library can then call the user-specified functions when it needs to, functions like write and panic. -- -- uunet!sugar!karl "As long as there is a legion of superheros, all else -- can surely be made right." -- Sensor Girl -- Usenet access: (713) 438-5018