views:

95

answers:

2

Hey folks,

I've tried to compile an application with Directx. But this causes an PRJ0030 error for $(). How can I escape critical characters like (,) or blanks. Refering to the cmd I've used ^ but it does not help.

Kind regards, Gerrit

A: 

cmd.exe unfortunately isn't a proper shell like bash, and parsing the command line is up to each individual program. I can't speak for devenv.exe but a common convention is to surround troublesome strings with double quotes (").

Hugh Allen
I've tried to use the quotes like this:[...]AdditionalLibraryDirectories=""$(DIRECTX_ROOT)\Lib\x86""[...]But it does not seem to work. Also double quotes in the variable does not help.
Esco
+1  A: 
AdditionalLibraryDirectories=""$(DIRECTX_ROOT)\Lib\x86""

&quot should not be there. $(DIRECTX_ROOT) requires the macro to be set in a project property sheet. You are better off spelling it out:

AdditionalLibraryDirectories="c:\blah\dx9\Lib\x86"
Hans Passant
Unfortunately I need to do it this way, cause we would like to set the path with enviroment variables. Without the it gives me this compiler line:/I "C:\Program Files (x86)\Microsoft DirectX SDK (March 2009)"\IncludeBut the same error occurs.
Esco
Looks about right. There is however a mis-placed double-quote there, before the \Include. Check the environment variable value. You've also mysteriously switched for Lib to Include.
Hans Passant
Esco
@Esco: I'm kinda lost right now with copy/paste errors and quotes in random places. Open the Buildlog.htm file and copy the cl.exe command line you see there into your question so we know what it *really* looks like.
Hans Passant