Installing VVE

Linux

Linux installation is, for now, only from source. You will need:

First, you have to compile the QGLViewer provided (it is slightly modified from the original). It is compiled using qmake, a readme is provided by the QGLViewer development team. You will want to install QGLViewer in your system.

Note:
To simplify the following explanation, I will refer to the VVE source directory using ~vve and the VVE build directory using ~vve_build. You will replace these by whatever directory you chose.

To install VVE, create a build directory outside the VVE source directory. Then, go inside ~vve_build and launch the command: ccmake ~vve

Configure a first time by pressing the 'c' key.

You will see a lot of options. If everything is installed in your system (including QGLViewer), the only options you will want to set are:

If QGLViewer is not installed in your system but locally, set QGLVIEWER_DIR to the directory containing the QGLViewer directory (which contains the header files) and QGLVIEWER_LIBRARY_DIR to the directory containing libQGLViewer.so.

Now, reconfigure by pressing 'c' and, if everything is setup correctly, you will be able to generate the makefiles by pressing 'g'.

ccmake will exit by itself, leaving you into your build directory. From then, simply type:

$ make -j2
$ su
# make install

Note:
The $ and # signs indicate respectively the user and root prompt, you should not type them.

Now, setup a VVEDIR environment variable to whatever directory you installed VVE in and make sure $VVEDIR/bin is in the $PATH and $VVEDIR/lib in $LD_LIBRARY_PATH (or in the system library lookup paths).

You are setup and can compile/run VVE models in VLab (and even outside).

Windows

From binary distribution

To install VVE on windows (using LStudio) you will first need to install MinGW32 with g++-4.2 and Qt 4.3 for MingW32. The binary archive provides you with all the needed software.

  1. Install MinGW using the installer
  2. Unpack the content of mingw_update.zip into the install directory of MinGW (by default C:\mingw)
  3. Install Qt 4.3 for MinGW
  4. Unpack Lstudio.exe.zip into your LStudio bin directory (this operation will replace your LStudio.exe, you might want to save it first).
  5. Unpack vve.zip into C:\ (or any other directory, but C:\ is recommended)
  6. Copy vveinterpreter.exe and QGLViewer2.dll (found in the bin directory of VVE) into the bin directory of LStudio
  7. Setup your environment variables:
    • VVEDIR should contain the installation directory of VVE (by default C:\VVE)
    • QMAKESPEC must be set to win32-g++
    • Q4DIR should contain the installation directory of Qt (by default C:\Qt\4.3)
    • Make sure Q4DIR%\bin, Q4DIR%\lib and C:\mingw\bin (or wherever the bin directory of MinGW is) are in your PATH environment variable

You are setup and can compile/run VVE models in LStudio.

From source

To install from source, start by the steps 1 to 4 and 7 of the binary installation. In addition, you will need to install cmake for windows. You can download it at http://www.cmake.org

Note:
During this process, I will assume you want to install VVE into C:\VVE. If this is not the case, change the directories accordingly.

The first project to compile is QGLViewer. It is compiled using qmake. Once it is compile, install it into C:\VVE. At the end, you should have QGLViewer.dll in C:\VVE\lib and a QGLViewer directory into C:\VVE\include. Next, copy QGLViewer.dll into the bin directory of LStudio.

Then, launch CMake. Select the source directory of VVE and a build directory outside the source directory. Validate and select a MinGW project in the list of project types CMake propose. The variable to setup are:

Click the configure button, then the OK button. The window should disappear without error message. Next, launch a window command prompt and change the directory for your build directory. If your build directory is C:\vve_build, then type:

$ cd C:\\vve_build
$ c:
$ mingw32-make
$ mingw32-make install
Note:
the $ sign indicate the prompt, you should not type it

At last, copy the vveinterpreter.exe file into your LStudio bin directory.

You are setup and can compile/run VVE models in LStudio.

Post-installation specific to L-Studio ATE

L-Studio ATE comes with its own version of MinGW. However, the version it comes with is too old to run VVE. Also, when L-Studio launches any command (i.e. to run or compile) it completely override the PATH the user set up and points to its own MINGW. You should prevent it by editing the file L-studio-VERSION\lpfg\bin\mingw.bat and replace its content by:

IF "%MINGW%" == "" set MINGW=%LPFGPATH%\MinGW
set PATH=%PATH%;%MINGW%\bin
set MINGWMAKE=%MINGW%\bin\mingw32-make
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Generated on Fri May 31 15:37:54 2013 for VVE by  doxygen 1.6.3