Sign in to follow this  
TheOther

Automating Visual Studio build processes

Recommended Posts

Hey everyone, I'm currently building/maintaining an LGPL project which is compatible with VS6.0/.NET 2003 and soon-to-be .NET 2005 and most likely Dev-CPP (so GCC). I currently have a stupid little batch script which goes into each IDE folder, runs the vcvars32, then cd's into my project folders and runs nmake; which then builds my .lib/.dll files. It's clunky and ugly and I'm hoping there's a really easy system to accomplish this. Is there a GUI tool of some kind that will help me out? Is it worth building an ANT script to do this? In the "beginner's forum" @Kwisatz mentioned using autotools which is what the SDL maintainers use...(as far as he knew). What does everyone else do here? (Or are they sane enough to just limit themselves to one IDE *grin*) thanks in advance!

Share this post


Link to post
Share on other sites
I hope I'm not stating the obvious... You can run Visual Studio from the command line (or a batch file) and compile an entire solution or specific projects. You don't need to use nmake.

For example:
    devenv /build /projectconfig Release C:\...\solution.sln
devenv /build /project "project|Win32" /projectconfig Debug C:\...\solution.sln

Share this post


Link to post
Share on other sites
I once put together a build system that'd build 50 executables (16 and 32-bit), a half-dozen DLL's, collapse the palettes of a few hundred BMP files to 256 colors, and compress and build installers for all of 'em. . .in six languages. Close to a thousand build-targets.

And it was all done with batch files. It worked just fine when I wrote it eight years ago, and it'd work today with only a couple of changes to build-paths.

Elegance is overrated. Go with what works.

Share this post


Link to post
Share on other sites
@Konfusious: Thanks I'll give that a shot.

@Arild: Thanks I'll try that one out as well.

@gregs: Sorry but I need it to handle more than just .NET 2003 solutions.

@JohnBolton: Thanks for that tip John. I was always so used to nmake that I didn't realize you could throw command line params to DevEnv.exe like that.
Of course I'll have to add new command lines if I use GCC, but I'd have to do that anyways.

I don't mind the simple/rudimentary approach of batch files either. I was just seeing if there was "a better way" to approach this problem.

Thanks everyone, I'll be busy tonight checking these out..

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this