I've successfully build lyx with the IDE, but it's only a IDE
for the build process, debugging does not work, and before each
program start it does a complete scons run which takes too long,
so there are no advantages to use the ide instead the command line.

Cite from scons user list:

SCons generates the .sln and .vcproj files for me. These files can be
loaded by the visual studio ide. Then I click Build Project for example
and visual studio will start scons which then invokes the compiler, linker
and does all the rest. It's pretty much the same as the old workflow,
except that scons now drives the compilation process. Of course I also get
a lot of enhancements like installing files etc. A drawback is that msvs
doesn't provide intellisense for me anymore.
Of course you can also use SCons without generating the .sln and .vcproj
files. In this case you'd run the SConstruct from the command line (or
from a simple batch script). It will invoke the ms compiler again.
All in all I really like SCons + MSVS way better than the standard MSVS
toolkit.

Does MSVS pick up the compiler errors in the same way, i.e. to make it
easy to move to the source line?  Presumably, it just parses stdout and
stderr?

Yes, an example output looks like this:

------ Build started: Project: DCGeometry, Configuration: debug Win32
------

Performing Makefile project actions
Starting SCons
scons: Reading SConscript files ...
Reading Z:\DCSDK\Makefiles\Sources\Renderer.py
... shortened here ....
scons: done reading SConscript files.
scons: Building targets ...
cl /nologo /TP /EHsc /Gm /GR /W3 /Wp64 /Zc:forScope /wd4251 /RTC1 /RTCc
/RTCs /RTCu /MDd /Zi /DDEBUG /D_DEBUG /DDC_TRACK_MEMORY /DPLATFORM_WIN32
/DWIN32   ....... shortened switches here ........
DCSkeletalAnimation.cpp
Z:\DCSDK\Sources\Geometry\DynamicMesh\DCSkeletalAnimation.h(31) : warning
C4114: same type qualifier used more than once
Z:\DCSDK\Sources\Geometry\DynamicMesh\DCSkeletalAnimation.cpp(245) :
warning C4018: '<' : signed/unsigned mismatch

So I can click just on the first line as usual and I am taken directly to
line 31 in the header. The warnings/errors also appear in the Task List as
usual. The only thing changes is that you see the scons output + command
to invoke the compiler. Maybe you can even customize/disable that.


So I guess debug is not supported after all. (Maybe someone can try to
set a breakpoint and run.)

As of slow starting, under command line, one can use the rebuild
option to rebuild only one module and scons starts almost instantly
(fast_start also helps here), All static library proejcts work in this
way but the lyx project will scan all changes for all modules. In
either cases, the configure part should not be run.

If cmake can do better in this area, this is a legitimate reason for
it to go into svn. (Question: does cmake handle moc file generation
etc?)  I will finish this msvs project patch and announce the
completion of scons msvc support (untill scons provides some new msvc
support.).


Cheers,
Bo

Reply via email to