[Spice-devel] Problems compiling SPICE Windows client SDK 7.1

Arnon Gilboa agilboa at redhat.com
Mon Jul 4 23:35:04 PDT 2011


Hi John,
See my comments below.
Arnon

John A. Sullivan III wrote:
> Hello, all.  Being a Windows ignoramus, I am having a nightmare of a
> time compiling the Windows client on our Windows 7 build system.  I'll
> recount them for other ignorami and to ask for help for the things I
> could not figure out.
>
> I installed the Windows SDK 7.1 and it installed without compilers
> because we had .net 3.5 installed.  I installed 4.0 and reinstalled the
> SDK and I know had compilers.
>
>   
Currently, the only supported environment for Spice windows client 
compilation is Visual Studio 2008.
To use our precompiled libraries (wspice) use version 9.0.30729.1 SP.
There might be problems with the libs if you use other VS versions.
> The build instructions under Windows say, "The prerequisites are
> available as binaries in one package on the download page." However, I
> did not see such a binary on the download page.
>
> I downloaded spice-0.8.1, spice-protocol-0.8.0, and wspice-x64_20110308.
>   
You have downloaded everything needed for building the client.
In addition you need to have Python (2.7+) & pyparsing installed.
"The prerequisites available as binaries..." is wspice.
> I then did:
>
> setenv /Release /x64 /win7
>
> set REDC_BUILD_DIR=D:\Binaries\x64\Win7
> set SPICE_PROTOCOL_DIR=C:\Users\Administrator\Downloads\spice
> \spice-protocol-0.8.0
> set SPICE_LIBS=C:\Users\Administrator\Downloads\wspice-x64_08032011
>
>   
I would prefer other locations for the files...
but if C:\Users\Administrator\Downloads is fine for you, it's ok for me.
> C:
> cd \Users\Administrator\Downloads\spice\spice-0.8.1\client\windows
> redc.sln
>
> It had no idea of what to do with the file - no association.
>   
VS will open it
> Some Internet research, reading the SDK Release Notes, and a little
> while later and I did:
> msbuild -p:platform=X64 redc.sln
>
> It complained that it could not find vcbuild.exe.
>   
We have never built it with msbuild or vcbuild.exe.
If you want to build using VS from cmd line, use something like:
devenv.exe redc.sln /build "Release|x64"
> Some more research and I found that the 7.1 SDK uses msbuild and that it
> takes a different syntax than vcbuild.  It provides vcupgrade to convert
> the .vcproj files into .vcxproj files but does not convert /sln files.
> devenv does but that is not in the SDK and must be included with the
> full Visual Basic I am guessing.  So, the instructions said to manually
> edit the .sln files to use 2010 instead of 2008 and reference .vcxproj
> files instead of .vcproj files.  So, I ran vcupgrade on redc.vcproj,
> edited redc.sln and tried again.  Same failure message about
> vcbuild.exe.
>
>   
I guess it won't work this way, or it will take too much time to make it 
work.
> I then looked more closely at the .sln file and it looked like it was
> merely specifying the build environment options which are no longer
> necessary with msbuild using the -p:platform= parameter (or so I read)
> so I tried to simply do msbuild -p:platform=X64 redc.vcxproj.  That
> complained about not finding python.  So it looks like python is called
> in generate.bat.  I installed python and it failed again - python was
> not in the path.  So I added it to the path, opened an new SDK shell and
> tried again.  Now I get:
>
> C:\Users\Administrator\Downloads\spice\spice-0.8.1\client\windows>msbuild -p:platform=X64 redc.vcxproj
> Microsoft (R) Build Engine Version 4.0.30319.1
> [Microsoft .NET Framework, Version 4.0.30319.1]
> Copyright (C) Microsoft Corporation 2007. All rights reserved.
>
> Build started 7/4/2011 8:07:48 PM.
> Project "C:\Users\Administrator\Downloads\spice\spice-0.8.1\client\windows\redc.vcxproj" on node 1 (default targets).
> InitializeBuildStatus:
>   Touching "D:\Binaries\x64\Win7\X64\Release\redc.unsuccessfulbuild".
> CustomBuild:
>   Generating demarshaller
>     File "..\..\spice_codegen.py", line 200
>       print "No changes to %s" % dest_file
>                              ^
>   SyntaxError: invalid syntax
>     File "..\..\spice_codegen.py", line 200
>       print "No changes to %s" % dest_file
>                              ^
>   SyntaxError: invalid syntax
> C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppCommon.targets(1
> 51,5): error MSB6006: "cmd.exe" exited with code 1. [C:\Users\Administrator\Dow
> nloads\spice\spice-0.8.1\client\windows\redc.vcxproj]
> Done Building Project "C:\Users\Administrator\Downloads\spice\spice-0.8.1\clien
> t\windows\redc.vcxproj" (default targets) -- FAILED.
>
>
> Build FAILED.
>
> "C:\Users\Administrator\Downloads\spice\spice-0.8.1\client\windows\redc.vcxproj
> " (default target) (1) ->
> (CustomBuild target) ->
>   C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppCommon.targets
> (151,5): error MSB6006: "cmd.exe" exited with code 1. [C:\Users\Administrator\D
> ownloads\spice\spice-0.8.1\client\windows\redc.vcxproj]
>
>     0 Warning(s)
>     1 Error(s)
>
> Time Elapsed 00:00:00.65
>
> I'm assuming the code is correct and I have done something wrong.  How
> do I compile the Windows client in my environment? Thanks - John
>
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/spice-devel
>   



More information about the Spice-devel mailing list