Using Visual Studio .Net to develop Glast code
We have the capability to develop software with Microsoft's newest C++
compiler, vc7. This is a much more compliant compiler, and has a much improved
STL library.
In addition, the IDE is much improved.
The steps to install it are:
- Get Visual Studio .Net, minimally with the C++ compiler.
- You should be running at least CMT v1r12p20021129, with Glast patches to
write vs.net files. (The "version" output in the CMT status window should be:
v1r12p20021129-vsnet. )
- Change your PATH environment variable to allow "devenv.exe" to run. On
most systems, this means adding
C:\Program Files\Microsoft Visual Studio
.NET\Common7\IDE
Test by typing "devenv" at the command prompt: it should bring up the
IDE.
- Get vcmt v17 That is, vcmt.wsf 1.111 and cmt.wsc 1.46 or later. The latter must be
"registered" as usual. When you start vcmt, the debug button
on the new "vsnet" row should be
enabled, and selected, if all the above is set properly. Note that you can
also select Debug and Release, on the msdev row, which then uses vc6, as before,
if it is installed. After selecting a
different environment,
you must "setup" packages before building or running applications.
Note that most libraries built with vc6 will link OK. One exception is
Geant4.
Now the "start" button runs devenv, the name of the executable for vs.net. As
before, the workspace has all projects in the selected package, and the static
or shared libraries from all dependent packages. A difference is that in
order to clean or rebuild a package alone, and not affect the dependent libs,
you must select an alternate configuration, Debug_norecurse from the "Solution
configurations" pull-down menu.
This prevents vs.net from operating on any but the selected project. It also
makes builds go faster.
Vsnet 2003
This was a minor update for the .Net development system, except for the C++
compiler, which is a major change. Implications for us are
- It is necessary to use a patched version of Gaudi v12r0; the old Gaudi can
not be patched to compile, I think.
- One must patch and recompile g4
- One must recompile CLHEP
- You need a more recent version of vcmt, v18, that recognizes the existence
of this new compiler. It assigns tags "VC8" or "VC8debug".
All the code changes needed for Glast software have been made.
As of this writing
07/31/2003, these
changes have been made and tested on my laptop, but have not yet been made
available. Help would be appreciated.
Last update: (T. Burnett)
07/31/2003 13:32 -0700