Magic Mailing List |
|
From: R. Timothy Edwards (tim AT stravinsky DOT jhuapl.edu) Date: Thu Oct 03 2002 - 13:27:33 EDT
Dear Thiago, > I've installed magic 7.2 on Linux but when I run it, appears several > warnings, listed below: > > Warning: magic command 'list' use fully-qualified name '::magic::list' > Warning: magic command 'echo' use fully-qualified name '::magic::echo' > Warning: magic command 'dump' use fully-qualified name '::magic::dump' > Warning: magic command 'split' use fully-qualified name '::magic::split' > Warning: magic command 'array' use fully-qualified name '::magic::array' > Warning: magic command 'source' use fully-qualified name '::magic::source' > Warning: magic command 'label' use fully-qualified name '::magic::label' > Warning: magic command 'what' use fully-qualified name '::magic::what' > Warning: magic command 'edit' use fully-qualified name '::magic::edit' > Warning: magic command 'flush' use fully-qualified name '::magic::flush' > Warning: magic command 'send' use fully-qualified name '::magic::send' > Warning: magic command 'grid' use fully-qualified name '::magic::grid' > Warning: magic command 'load' use fully-qualified name '::magic::load' > > Could anybody tell me what's going on?? There are some problems/inconsistencies which crop up when combining magic with the Tcl interpreter. One of the major ones is that they share a number of command names. The worst of these (the most commonly used) are "label" and "load". "edit" crops up when using the TkCon console. The way commands are handled in Tcl is that sets of commands are given their own "namespaces", which are indicated by the double colon ("::"). All commands without the "::" notation are actually just aliases to the "real" command name. So the command "load" is an alias for "::tcl::load". It can be altered to become an alias for "::magic::load", but then any TCL script which uses the command "load" expecting it to be the TCL command, not the magic command, will get an incorrect result. Currently, my non-solution is to make all magic commands available as aliases for their fully qualified names (e.g., "paint" is an alias for "magic::paint") UNLESS there is a conflict with a Tcl command. So, from inside magic, you would use "load tcl_object_file.so" to load a Tcl shared-object library, but you would need to type "::magic::load layout_file.mag" (the two leading colons are unnecessary---a peculiarity of the namespace notation) to load a magic layout file. There are several possible solutions to the command-name overlap problem, but I have not committed to any yet, and I have not worked out the details. It is high on my list of things to do. > Also, I've tried running magic with other techcnology file with the > -T command but it always load with the technology scmos file. I've > already put my new tech file in the folder system. Check the revision number of your source against what is currently posted on my website. There were a couple of revisions (3 and/or 4, I think) where the command-line parsing was broken (it is now on revision 6). That problem shows up with no error or warning messages about the tech file (the command line argument is simply ignored). Regards, Tim
|
|