Re: Command line compiler

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Wow! You really enjoy misery! (I'm an old Unix programmer, and nothing has made me
happier than never again having to look at a makefile. And I used to be the Wizard of
Makefiles--people would come to me to get their makefile problems fixed...)

You can always just call cl.exe; that's all the IDE does anyway. Back pre-VS, I used to
write makefiles and call cl from the makefile rules.

Note that you must have the appropirate directory in your search path to make this work;
otherwise, the necessary DLLs may not be findable. When you install VS, it usually gives
you an option of creating a little .bat file that contains all the necessary SET options,
which in the pre-vs days, I would invoke as part of my "build" sequence.

You will also need to make sure your INCLUDE= and LIB= paths are set. It has been about
15 years since I've had to look at makefiles, so I'm not up on all the details any longer.
I used to write programs that generated makefiles (one called "makemake", which my client,
who lived in Hawaii, would pronounce "mocky-mocky")

The mspdb71.dll should definitely be installed, and I found it in my installation. It is
not, however, in the bin directory. I set the compilation up by setting the following
directories to the PATH variable:

c:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE;c:\program files\Microsoft
Visual Studio .NET 2003\Vc7\bin

Note the Common7 directory must be added. When I ran the cl command from the command
line, it worked fine, except that I didn't have all the options set right in the command
line so I got a lot of errors about missing command line options, but it actually tried to
compile my .cpp file.
joe


On 1 Jun 2006 17:36:31 +0200, Peter Jay Salzman <p@xxxxxxxxx> wrote:

Hi all,

I'm a GNU/Linux developer trying to get comfortable with developing on the
Microsoft platform. At work I have Visual Studio 2003 version 7.1.3088.

I would like to use a command line compiler, my own Makefile, and my own
editor to develop software. I would like to forego the IDE completely.

I've read that there's a command line VC++ compiler called cl.exe, and even
found it sitting on my hard drive:

C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7\bin\cl.exe

However, when I try to run the command line compiler (just typed "cl.exe"), I
get a pop-up window with the error message:

This application has failed to start because mspdb71.dll was not
found. Re-installing the application may fix this problem.

I did a quick search and can't find that dll.

Can someone post simple instructions on how I can get up and running with the
command line version of a visual C++ compiler?

Thanks,
Pete
Joseph M. Newcomer [MVP]
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
.



Relevant Pages

  • Re: How to build the regex datablade
    ... >> * Now I'm trying to build it for IDS version PQR using C compiler ABC ... There is an all-purpose makefile included, ... I suggest trying without 'b' on the command line. ... Is 'server' defined ...
    (comp.databases.informix)
  • How to debug in windows ??!!
    ... We have a project which compiles well on Visual Studio for Windows. ... Studio as it uses a very complex makefile with lex/yacc files etc (I ... So we have made some changes in the library to get the VS cl compiler ...
    (microsoft.public.vsnet.debugging)
  • Re: Codewarrior compiler command line???
    ... duplicate the command line for compile and link by telling it what ... IDE project options you are selecting. ... Far better would be to build the whole project from a makefile, ... now almost all development tools use Eclipse as their IDE ...
    (comp.arch.embedded)
  • Re: Free LAPACK for Intel Fortran 8 on Windows?
    ... The compiler we're using is Intel Visual Fortran on Windows, which means using it via the Visual Studio interface. ... I know that one can easily download a copy of LAPACK and the reference BLAS implementation from Netlib. ... The Netlib version is designed to be built with a makefile, and it looks like it would be rather a distinct pain to set things up to compile it through Visual Studio instead. ...
    (comp.lang.fortran)
  • Re: why these statements in a general latex makefile
    ... >>(BTW, just out of curiosity, do you even realize what the touch command ... The same way as you took it as an insult, ... > In the context of the Makefile: grep fills .btmp.new with references to ...
    (comp.text.tex)