[Spice-devel] Spice QXL Driver does not work for Windows 7

John A. Sullivan III jsullivan at opensourcedevel.com
Tue Jul 19 14:06:56 PDT 2011


On Tue, 2011-07-19 at 12:48 +0200, Mario wrote: 
> Alon,
> 
> first of all thanks a lot for your quick reply. Theoretical my Windows 
> Instance should also load unsigned drivers as I enabled the Test Mode of 
> Windows 7.
> 
> However to make it a bit more clear please let me describe step by step 
> what I´ve done so far:
> 
> 1st) I was looking for any old instance of qxl on my system:
> - delete all qxldd.dll files in %SystemRoot% or deeper
> - delete all qxl.sys files in %SystemRoot% or deeper
> - delete all qxl installations in the DriverStore by executing "pnputil 
> -d oem##.inf"
> - remove the qxl service in the system registry
> - reboot ;-)
> 
> 2nd) Grab all the sources:
> - mkdir c:\qxl # and cd into it
> - git clone git://git.freedesktop.org/git/spice/win32/qxl
> - git clone git://git.freedesktop.org/git/spice/spice-protocol
> - mkdir qxl\include\spice
> - xcopy spice-protocol\spice qxl\include\
> 
> 3rd) Compile qxl:
> - start free x86 Build Environment of WinDDK Verson 7600.16385.1 
> (latest)
> - set SPICE_COMMON_DIR=C:\qxl\qxl\include\spice
> - cd c:\qxl\qxl
> - build -cZg
> Output:
> BUILD: Compile and Link for x86
> BUILD: Start time: Tue Jul 19 12:00:14 2011
> BUILD: Examining c:\qxl\qxl directory tree for files to compile.
> BUILD: Compiling and Linking c:\qxl\qxl\display directory
> Configuring OACR for 'root:x86fre' - <OACR on>
> Compiling resources - display\driver.rc
> Compiling - display\driver.c
> Compiling - display\rop.c
> Compiling - display\res.c
> Compiling - display\text.c
> Compiling - display\pointer.c
> Compiling - display\brush.c
> Compiling - display\mspace.c
> Compiling - display\quic.c
> Compiling - display\surface.c
> Compiling - display\generating code...
> Linking Executable - display\display\objfre_win7_x86\i386\qxldd.dll
> BUILD: Compiling and Linking c:\qxl\qxl\miniport directory
> Compiling resources - miniport\qxl.rc
> Compiling - miniport\qxl.c
> Compiling - miniport\wdmhelper.c
> Compiling - miniport\generating code...
> Linking Executable - miniport\miniport\objfre_win7_x86\i386\qxl.sys
> BUILD: Finish time: Tue Jul 19 12:00:19 2011
> BUILD: Done
> 
>      17 files compiled
>      2 executables built
> 
> 3rd) Create a driver package:
> - mkdir driver
> - xcopy miniport\objfre_win7_x86\i386\qxl.sys driver
> - xcopy miniport\qxl.inf driver
> - xcopy display\objfre_win7_x86\i386\qxldd.dll driver
> - cd driver
> - Makecert -r -pe -n "CN=CertForWDK" -ss "Cert" mccert.cer
> - Inf2cat.exe /driver:c:\qxl\qxl\driver\ /os:7_x86
> - signtool sign /a /v /s "Cert" /n "CertForWDK" qxl.cat
> - signtool sign /a /v /s "Cert" /n "CertForWDK" qxl.sys
> - signtool sign /a /v /s "Cert" /n "CertForWDK" qxldd.dll
> 
> 4th) Switch on the Windows Test Mode:
> - bcdedit.exe -set TESTSIGNING ON
> 
> Now I installed the driver using the Windows Device Manager and did a 
> reboot.
> 
> But as a result the driver still cannot start :(
> 
> The files are both present as they are listed in the Device Manager. 
> And even if there is a message that the driver has not been signed the 
> files in system32 and system32\drivers are signed (rightclicking the 
> properties and 'Properties').
> 
> Any idea?
> 
> Thanks a lot.
> 
> Mario
> 
> 
> On Mon, 18 Jul 2011 23:09:45 +0300, Alon Levy wrote:
> >
> > Looks like it isn't signed and windows doesn't like that. Try signing 
> > it.
> > Also, not sure how you installed it, but maybe try choosing all the 
> > manual
> > paths in the device-manager upate driver wizard.
> >
<snip>
Strange - one of our very talented engineers had a similar problem using
the DDK.  He followed the instructions but it just didn't work.  It did
work when we used the SDK.  I do not know if that is simply coincidence
but here are our internal notes:

I was finally able to get them to work.  Here is what I did under both
W7 and W2K8:
Download and install the WinQual toolkit:
https://winqual.microsoft.com/member/SubmissionWizard/controls/WinqualSubmissionTool.msi
This is to obtain Inf2Cat.exe
Download and install the MS SDK:
http://www.microsoft.com/downloads/en/details.aspx?FamilyID=6b6c21d2-2006-4afa-9702-529fa782d63b
This is for Makecert.exe and signtool.exe
Go to the SDK Bin directory and run:
Makecert -r -pe -n "CN=TestCertForQXL" -ss "QXLTestCert" C:\qxldriver
\qxlcert.cer  (all one line)

Go to the WinQual directory and run:
Inf2cat.exe /driver:C:\qxldriver\ /os:7_X64

Return to the SDK Bin directory and run:
signtool sign /a /v /s "QXLTestCert" /n "TestCertForQXL" c:\qxldriver
\qxl.cat
signtool sign /a /v /s "QXLTestCert" /n "TestCertForQXL" c:\qxldriver
\qxl.sys
signtool sign /a /v /s "QXLTestCert" /n "TestCertForQXL" c:\qxldriver
\qxldd.dll
bcdedit.exe -set TESTSIGNING ON

Go to the Device Manager, choose the QXL Video Driver and update it
pointing specifically to the new, signed driver.  This assumes we are
updating.  I suppose we would simply install the driver when prompted
for new hardware if this was the first attempt.  It appears we can
simply copy the driver directory to W2K8 and install the same way.



More information about the Spice-devel mailing list