Cannot build the Test project for LINQ IQueryable Toolkit (IQToolkit) - Code 9009
I am trying to build the test project for L开发者_StackOverflowINQ IQueryable Toolkit with Visual Studio 2008, but it does not build because it exits with "exited with code 9009".
The source is available at: http://iqtoolkit.codeplex.com/releases/view/40005
How do I fix this?
I built it with Visual Studio 2010, and got error messages that say I am missing System.Data.SQLite
and MySql.Data.MySqlClient
namespaces. So I would first make sure you have the DLL's for those on your computer, and you have added the appropriate references to them to the project.
The complete error message is:
The command "C:\Users\Robert\Downloads\IQToolkit v0.17b\Source\Test\CopyProviders.cmd bin\Debug\ C:\Users\Robert\Downloads\IQToolkit v0.17b\Source\Test\" exited with code 9009.
The file CopyProviders.cmd
in the folder C:\Users\Robert\Downloads\IQToolkit v0.17b\Source\Test\
contains the following:
erase %2%1IQToolkit.Data.*.dll
CALL %2CopyProvider.cmd Access %1 %2
CALL %2CopyProvider.cmd SqlClient %1 %2
CALL %2CopyProvider.cmd SqlServerCe %1 %2
CALL %2CopyProvider.cmd MySqlClient %1 %2
CALL %2CopyProvider.cmd SQLite %1 %2
The CopyProvider.cmd
file contains the following:
if exist %3..\IQToolkit.Data.%1\%2IQToolkit.Data.%1.dll xcopy /C /Y %3..\IQToolkit.Data.%1\%2IQToolkit.Data.%1.dll %3%2
This is all fired off from the Pre-build event command line
, which can be found in the Build Events
portion of the Properties
dialog for the Test
project. It reads as follows:
$(ProjectDir)CopyProviders.cmd $(OutDir) $(ProjectDir)
To get the project to build, you can just remove this line from the Properties dialog, and the project will build just fine.
It seems clear that some file copying takes place during the build process, and that this file copying has something to do with the test process for the IQToolkit. It seems that the IQToolkit output DLL is copied to each of the provider subdirectories. You can probably do this file copying manually, if you want to run the test suite.
In any case, it does appear to be a minor bug. I would let the IQToolkit folks know about it.
Just change the event to:
"$(ProjectDir)CopyProviders.cmd" "$(OutDir)" "$(ProjectDir)"
This can fix this problem.
精彩评论