[Xcircuit-dev] Small xcircuit patch...
Brought to you by:
rtedwards
From: Ulrich G. <gru...@zk...> - 2005-08-25 20:16:06
|
Hi, I had to install xcircuit on a Windows XP system, using Xming as a standalone X server. Everything worked fine, except some smaller annoyances, which are partially related to Windows and partially not. Therefore my small patches may be useful for Linux/Unix users, too. What was patched: 1. xcircuit relies internally on "/" (slash) to be the path separator character. This caused some problems with "\" (backslash) in Windows filenames. The fix: I extended the function xc_tilde_expand() from files.c to replace all occurences of "\" by "/". xc_tilde_expand() is called to clean up user-specified filenames and was therefore a good candidate for the modification. 2. All spice netlists are originally written to the directory xcircuit was started from. If xcircuit is started by a GUI, this will always be your home directory (please correct me if I am wrong). I'd like better to find the spice netlists in the same directory where the .ps file is located. Therefore I made a small patch to netlist.c in order to prepend the path of the current page before writing the spice netlist file. Now the .spc and .fspc netlists are written into the directory of the current page and can be found beside the .ps file. Any conflict with the original concept? Both patches can be seen from the attached diff output (diff -u). Maybe you want to include them into coming releases. The patches are based on the xcircuit 3.3.31 source which I downloaded from the xcircuit website (xcircuit-3.3.31.tgz). There is a file files.c.new in the tarball, which seems not to be used currently. However, the above changes of xc_tilde_expand() can also be applied to files.c.new. What was not patched: 3. xcircuit cannot handle filenames having whitespace in them. Such names occur seldom under Linux/Unix (but they do), but more frequently under Windows. It seems to me that spaces in filenames sometimes do have a special meaning to xcircuit, therefore I left my fingers off. However, I assume that it should be easy to make xcircuit work with filenames containing whitespace as well. If you can give me some hints, I would try to fix this, too. If you are interested in Xming: Xming is based on Cygwin, but you don't have to install the complete Cygwin suite; see http://wiki.freedesktop.org/wiki/Xming. Runs very nice. Xming might be an update information for the Windows section of the xcircuit website (http://xcircuit.ece.jhu.edu/windows.html). If useful, I can also provide an updated precompiled Windows package (zip file) containing the current xcircuit, because Holger Vogt's zip file is an xcircuit 2.2.0 from december 2000. Thanks for your work on xcircuit! Best regards, Ulrich -- ZKOM GmbH Dr. Ulrich Gruenebaum E-Mail: gru...@zk... Phone: +49/(0)231/9700-337 Fax: +49/(0)231/9700-399 |