Using Electric 1-5: Windows Installation

Chapter I: INTRODUCTION

| ## 5: Windows Installation |

Electric runs under Windows 95/98, Windows NT 4.0, or Windows 2000. The system compiles with Visual C++ 5.0 or later (Visual C++ 6.0 project files are included).

The Electric distribution is a single file in UNIX "tar" format, GNU-zipped. This can be extracted by a number of programs, including "WinZip" (see http://www.gzip.org for more information). To install Electric, follow this procedure:

- Extract the contents of the "tar" file. When using WinZip, make sure that the "TAR File Smart CR/LF Conversion" box is checked in the "Configuration..." dialog of the "Options" menu. Once extracted, you will have a top-level directory called electric-VERSION with four subdirectories: src, lib, examples, and html.
- There are a number of binary-format files that have been text-encoded into the file \src\graph\graphpc.uue. Use "WinZip" to extract the files into the same directory (there should be 5 cursor files that end in .cur and 2 icon files that end in .ico).
- Run Visual C++ and open the workspace file Electric.dsw (both it and the associated file Electric.dsp are in the top level, alongside the src directory). If you have trouble with these files (or are using Visual C++ 5.0), use the MAKE file Electric.mak. Compile Electric. This will create a new directory in the top level called Debug, which will contain all of the object files.
- Inside of the Debug directory, you will find the executable file Electric. Move this file out of the Debug directory and place it in the top-level directory. Double-click the Electric executable to run the system.

Here are some detail on the Electric distribution:

- The src directory contains the source code. It is hierarchically organized by function.
- The html directory contains one subdirectory, manual, which is this manual in HTML format. To see the document, point your browser to the file index.html inside of the manual directory.
- The examples directory has some demo files.
- Since the TCL and LISP language extensions are not distributed as part of the GNU download, users who wish to add this facility must acquire the sources separately. Use the same procedure to extract the language extension file (which will also be a GNU-zipped tar file). Extract it into the same location as the main source distribution and it will add the necessary files to the source tree. Then use the file ElectricLang.dsw to build Electric with the language extension. The resulting executable will be in the DebugLang directory.
- To add the Java language extension, you must follow these steps:
  - Download the Java Development Kit (JDK) from http://java.sun.com. Install it. The standard location is C:\jdk1.3, and this path will be used here. If you install it elsewhere, adjust these instructions accordingly.
  - Use the "System" Control Panel, click on the "Environment" tab, and under "System variables", select "Path". In the "Value:" area, add this string to the end:
    ;C:\jdk1.3\jre\bin\classic;C:\jdk1.3\bin
    You must restart your computer after making this change.
  - In Visual C++, use the "Settings" command of the "Project" menu. Select the "C/C++" tab and the "Preprocessor" category. In the "Preprocessor definitions" area, add this to the end:
    ,FORCEJAVA=1
    In the "Additional include directories" area, add this to the end:
    C:\jdk1.3\include,C:\jdk1.3\include\win32
    Select the "Link" tab and the "General" category. In the "Object/library modules" area, enter this:
    jvm.lib
    Select the "Link" tab and the "Input" category. In the "Additional library path" area, enter this:
    C:\jdk1.3\lib
- Electric must run on a display that is set to "65536 Colors" or "True Color". Anything less will cause the colors to appear wrong.
- Installation of Electric requires some care. Although Electric will run properly from the directory where it was built, you cannot move the executable to a different location and expect it to work. This is because Electric makes use of a collection of support files. The main support file is called cadrc. In addition, Electric needs to find the lib and html directories. If these support files cannot be found, Electric will not be able to initialize its graphical user interface (just type "-quit" to exit the program if this happens). It is sufficient to move the support files, along with the executable, to a public location. Then make a shortcut to the executable and place that anywhere you like. When the shortcut is run, the directory with the executable will become the current directory, and all of the needed support files will be found.

| Previous |  |  | Table of Contents |  | Next |