Compiling EiffelStudio

Revision as of 13:24, 10 April 2006 by Doenniu (Talk | contribs) (Installing EiffelStudio)

Installing EiffelStudio

To compile EiffelStudio, you need an already working EiffelStudio compiler on your machine. The current source tree requires at least version 5.7 of EiffelStudio. You can download it from This version still requires a registration (we missed to remove the registration cluster while compiling). You need to activate EiffelStudio (see below), because in some cases the compiler won't work correctly if not activated.

If you are a student of the Software Architecture course, you should have received a key by mail. If you are a regular ETH student, please contact Bernd Schoeller. Anybody else, please contact Eiffel Software stating your platform - you will receive back a Username and a numeric "CD-Key" comprising five groups of five digits, separated by hyphens.

There is a file in your distribution called INSTALL.readme that refers you to instructions in docs/installation/index.html, however this file is not present in the 5.7 pre-release (for Linux at least). Hopefully someone who knows how it's supposed to work will streamline the delivery and instructions, but the following worked for me under Linux:

Set the ISE_EIFFEL environment variable to the directory in which you unpacked EiffelStudio. This will normally be a filesystem path ending in /Eiffel57.

Set the ISE_PLATFORM environment variable to your platform (e.g. 'linux-x86'). The documentation refers to platforms such as 'linux-glibc' and 'linux-glibc2.1' but these seem to be obsolete and 'linux-x86' worked for me.

From the Eiffel57 directory, type ./register and copy your Username and the five 5-digit groups of your license key to the corresponding fields. When you get it right, the "Register" button becomes active and you can click it.

From the same directory, type ./make_install then (assuming you want to precompile the EiffelBase and Vision2 libraries) enter "Y" to each prompt. The system will chug away for a minute or two precompiling everything, whilst printing lots of output including a few C warnings that can probably be ignored.

Make sure your PATH environment variable includes the 'bin' directory (for example ...Eiffel57/studio/spec/linux-x86/bin) then type 'estudio'. Although you have registered EiffelStudio, you must now activate it by going to

Here you must choose a version number. There is no "5.7" option, but "5.6" worked for me. This leads to a screen where you copy in your Username and Registration Key, and receive an Activation Key. The web page claims that you can just copy and paste this into the first text box in the EiffelStudio activation dialog, but this didn't work for me and I had to copy each 5-digit numeric group into the corresponding text box. When you get it right, the "activate" box becomes enabled and you can click it, after which EiffelStudio will start up and offer to create a new application for you.

Extracting source code

Checking out from SVN

Define the EIFFEL_SRC environment variable. Usually we use the XXdev convention where XX is the version number from the current developped version of the compiler.

Make sure that ISE_EIFFEL, ISE_PLATFORM and ISE_C_COMPILER (on windows only) are properly defined

Perform the following checkout procedures:


svn co %SVNURL%/trunk/Src -N 57dev
svn co %SVNURL%/trunk/Src/bench/C 57dev/C
svn co %SVNURL%/trunk/Src/bench/Eiffel 57dev/Eiffel
svn co %SVNURL%/trunk/Src/common 57dev/Eiffel/common
svn co %SVNURL%/trunk/Delivery -N 57dev/Delivery
svn co %SVNURL%/trunk/free_add_ons 57dev/free_add_ons

cd 57dev
svn up C_library
svn up dotnet
svn up library
svn up
svn up tools


export SVNURL=
svn co $SVNURL/trunk/Src -N 57dev
svn co $SVNURL/trunk/Src/bench/C 57dev/C
svn co $SVNURL/trunk/Src/bench/Eiffel 57dev/Eiffel
svn co $SVNURL/trunk/Src/common 57dev/Eiffel/common
svn co $SVNURL/trunk/Delivery -N 57dev/Delivery
svn co $SVNURL/trunk/free_add_ons 57dev/free_add_ons

cd 57dev
svn up C_library
svn up dotnet
svn up library
svn up
svn up tools

Installing gobo

You have to unzip the gobo distribution from $EIFFEL_SRC/free_add_ons/gobo/gobo_34_win.tgz and extract it into $EIFFEL_SRC/library.

Please make sure to use the version provided or the very latest version from CVS. All other versions (including the official 3.4 release) will not work because of name clashes in the UC_STRING class between GOBO and EiffelStudio.

Compiling C libraries

Compiling run-time on Windows

Before being able to compile the run-time, you need to ensure that bash is in your PATH. You can download it from Once done you can do:

configure [win32|win64] [b|m]

The first argument indicated whether you are compiling the run-time for 32 or 64 bits. The second one is to tell which C compiler will be used. For now only `b' (Borland) and `m' (Microsoft) are officially supported. We also informally support `g' (GCC) and `l' (LCC).

On Windows 32 bits to clean up all the generated files you do:

configure clean

On Windows 64 bits, you do:

configure cleand

Compiling run-time on Unix

The command is simply:


This requires that ISE_PLATFORM is properly defined. The `quick_configure' script will look for the file CONFIGS/$ISE_PLATFORM and use it to extract the platform specific information to compile the run-time. If not found then an error will be reported.

Compiling C code from libraries

Here is the list of commands to compile all required C libraries on Windows:

cd $EIFFEL_SRC/library/net/Clib
cd $EIFFEL_SRC/library/vision2/Clib
cd $EIFFEL_SRC/library/wel/Clib

On Unix it is slightly different:

cd $EIFFEL_SRC/library/event/Clib
finish_freezing -library
cd $EIFFEL_SRC/library/net/Clib
finish_freezing -library
cd $EIFFEL_SRC/library/vision2/Clib
finish_freezing -library
cd $EIFFEL_SRC/library/vision2/implementation/gtk/Clib
finish_freezing -library

Compiling C code from C_library

This is only required on Windows to read PNG file. On Unix, this is not required because it is included in GTK+2.4. Simply do the following:

cd $EIFFEL_SRC/C_library/zlib
cd $EIFFEL_SRC/C_library/libpng

Compiling C code from compiler

This is only required on Windows as this C code is a tiny wrapper around the Microsoft C++ API to generate and to debug .NET code.

To compile it, you first need to install the Microsoft .NET SDK. You can download it from their website.

After installing it, you need to update your LIB and INCLUDE environment variable to include the path the lib and include directory of the .NET Framework SDK.

Once properly installed, you can do:

cd $EIFFEL_SRC/Eiffel/library/cli_writer/Clib

Compiling EiffelStudio

Now that we have taken care of the C code compilation we can compile the compiler. There are four ace files in $EIFFEL_SRC/Eiffel/Ace:

  • batch.mswin.ace
  • newbench.mswin.ace
  • batch.unix.ace
  • newbench.linux.ace

The first two are for windows, the last two for unix (even if the last one says `linux').

To compile simply do:

ec -ace <chosen_ace_file> -c_compile

Please note: the 'ec' binary produced by the newbench .ace file contains the full Eiffel compiler, including the batch version. 'estudio' is just a wrapper (available in Src/bench/C/ipc/daemon). So, you need either the one or the other.

Windows specific

At the end of the compilation for the workbench version, the C compilation will fail reporting an undefined reference to `nbref'. This is because the ace file has been built for the finalized version of EiffelStudio not the workbench version. To fix this problem do the following:

copy ec.lnk h

Then edit the file `h' and replace mtcompiler.lib by mtwcompiler.lib. Once this is done you can complete you do:

link @h

In order to update to the new version of metadata consumer tool, follow the instructions described here.

Unix specific

Like the windows version the C compilation, it will fail, but this time for two reasons:

  • nbref
  • linking order causing many errors to be reported

Here is the recommended way, make a copy of the generated Makefile and put it at the same level as your EIFGEN directory. Edit it and replace libmtcompiler.a by libmtwcompiler.a, then search for "$(EXTERNALS) $(EIFLIB)" and replace it by "$(EIFLIB) $(EXTERNALS)". Once this is done, you can do:

make -f ../../Makefile

A little script that does the necessary changes: Place it at the same level as the EIFGEN directory is.

cp EIFGEN/W_code/Makefile .
sed 's/libmtcompiler\.a/libmtwcompiler\.a/g' Makefile > tmp
sed 's/\$(EXTERNALS) \$(EIFLIB)/\$\(EIFLIB\) \$\(EXTERNALS\)/g' tmp > Makefile
cd EIFGEN/W_code
make -f ../../Makefile