I have an C++/CLI assembly consisting of approximately 50 source files. The code in this assembly links statically to a number of C++ libraries to do various 'heavy-lifiting' type tasks.
I am using Visual Studio 8 (2005) SP1 to build this assembly.
Building just this assembly (without dependencies, etc) via 'Project Only'->'Rebuild Only' takes about 4.5 minutes on a decent dual-core machine. Below is the abbreviated build output annotated with approximate times:
Compiling...
(file 0)
(file 1)
...
(file N) // About 2 min total to compile all files
Linking... // About 12s
Generating Code // 42s
Finished Generating Code // < 1s
Embedding Manifest // < 1s
Generating Code // 30s
Finished Generating Code
(15 seconds of nothing)
Done
How should I begin debugging why this assembly is taking so long to build? The compile and link times, while not great, are probably about what I'd expect for a project of this size. What concerns me is the fact that I'm seeing two 'Generating Code' steps, each taking much longer than most other projects.
My first guess was that this has to do with the amount of unmanaged code that is linked into the assembly. However, I have several managed applications projects that use just as much native code, and the build times are very reasonable.
Does anyone know what exactly could cause two 'Generating Code' steps that take so long? Is there a project setting I'm missing?