ERights Home download / 0-8-4 
Back to: E 0.8.4: Installing on Windows x On to: E 0.8.4: Installing on Unix/Linux

Building E 0.8.4
on Windows


Installing a Development Environment

See the Dependencies section for information on obtaining appropriate version of a JDK and the Cygwin environment.

The E Source Distribution

For Windows users, we recommend downloading the zip of E source distribution.

Compilation Notes

There are still some deprecated methods used in this release. You can safely ignore these warnings for now.

Building from Makefiles

The file e/src/jsrc/Makefile defines a macro-variable named COMPILE in a line like:

COMPILE=$(WCOMPILE)

To the right, it either ways WCOMPILE or JCOMPILE. As explained in the preceeding comment, WCOMPILE causes the build to use the compiler that comes with Symantec Visual Cafe when Cafe is installed at "D:/VisualCafe". Needless to say, this is not a very portable assumption. Change this to JCOMPILE in order to build in a portable manner. However, on my machine this hits a very mysterious problem documented in that Makefile comment. If you have different luck, whether or not you succeed, please let me know.

To build the release, cd to the e/src directory and type make.

Building in a Java IDE

The good news is that E itself is a pure Java program. Besides the installer (setup.bat,setup.pif) and the command-line drivers (e.bat,e.pif and elmer.bat,elmer.pif), you can happily develop E using a Java-only development environment, such as Symantec's Visual Cafe. For concreteness, and because it's what I use, I'll explain how to build a Cafe project for E, but user's of other development environments should easily see how to do likewise in their system. But first, you need to go to "e/src/jsrc" and run "make setup" to initialize "e/classes". This does require the Cygwin environment.

To start with, create a "New Project". For a project type, select "Empty Project" since we don't want it generating new source files for us. Select "Project Options". Under the "Project" tab, deselect "Enable RAD for New Files" since this is needless overhead for us. The "Project Type" should be "Application - A program that requires a java.exe to run". We know of no reason why "Win32 - A standalone executable program" shouldn't work, but when we run the resulting executable we get an Out of Memory error. If you have different luck, please let me know.

For the "Main Class" enter "org.erights.e.elang.interp.Interp" -- the class whose main() is the top of the E interpreter. For command like arguments, put "d:\e\src\esrc\scripts\elmer.e". Elmer is a good way to test each new build of E.

On the "Compiler" tab, we recommend deselecting "Show command line", but salt to taste.

On the "Directories" tab, for "Show directories for", first select "Input class files". This is where you enter the equivalent of the CLASSPATH. Assuming you installed the E source tree at "d:\e\src", you should enter...

...these directories for these reasons
d:\e\src\esrc
For the *.emaker files
d:\e\classes
Where compiled java & resources (icons) go
d:\e\src\bin\jars\ALG_0-1-1.jar
d:\e\src\bin\jars\IJCE_0-1-1.jar
d:\e\src\bin\jars\SPT_0-1-1.jar
The Cryptix files. These cannot be unpacked into \e\classes, but must instead be included by name.
d:\e\src\bin\jars\swingall-1.0.3.jar
If your IDE doesn't already have an adequate Swing, download swingall-1.0.3.jar, and place it at this location. Note that this swing is included in the E 0.8.4 binary distribution.

 

For "Output files", "Output directory", enter "d:\e\classes". This is where Cafe's compiler will place the *.class files.

Now we need to suck all the e\src\jsrc\*.java files into the project. It should work to set the "Source files" to d:\e\src\jsrc, but it doesn't. Poking around all the menus, it seems impossible to do this automatically, but Jay Fenton discovered a trick. Go to the "Search" menu, select "Find in Files". Go to the "Name and Location" tab. In the "Find what:" enter "package" or any other string that all Java source files are guaranteed to contain. "In files of type:" should be "*.java". Select the "In folder:" radio button and fill in "d:\e\src\jsrc". Be sure "Search subfolders" is checked. The other options don't matter. Click "Find" and wait awhile while the "Find in Files" window lists all out *.java files.

Once this is done, go to the "Find in Files" window and right click to bring up a menu. Select "Add All to Project" and wait even longer. Once this is done, be sure to save your project to avoid losing all this work. (Exiting and re-entering Cafe is a foolproof technique.)

Finally, on the "Project" menu, select "Run in Debugger". Hopefully, after everything successfully compiles, you'll see an Elmer window. You are now running Elmer under the Cafe debugger. Have fun!

 
Unless stated otherwise, all text on this page which is either unattributed or by Mark S. Miller is hereby placed in the public domain.
ERights Home  
Prev x Next
Download    FAQ    API    Mail Archive    Donate

report bug (including invalid html)

Golden Key Campaign Blue Ribbon Campaign