环境:win7 32位,vs2013 英文版

问题:使用vs2013编译webkit-r174650版本,公司电脑编译失败,自己电脑编译成功,新装一个虚拟机win7也能编译成功。公司电脑报错:

9>------ 已启动生成:  项目: JavaScriptCore, 配置: Debug Win32 ------
9>  /usr/bin/perl
9>  svn: E155007: '/home/Administrator/WebKit-r174650/Source/JavaScriptCore/JavaScriptCore.vcxproj' is not a working copy
9>  Use of uninitialized value $SVN_REVISION in scalar chomp at C:\cygwin\home\administrator\webkit-r174650\WebKitLibraries\win\tools\scripts\auto-version.pl line 86.
9>  Use of uninitialized value $SVN_REVISION in concatenation (.) or string at C:\cygwin\home\administrator\webkit-r174650\WebKitLibraries\win\tools\scripts\auto-version.pl line 90.
9>  Assembling C:\cygwin\home\administrator\webkit-r174650\WebKitBuild\Debug\obj32\JavaScriptCore\DerivedSources\LowLevelInterpreterWin.asm...
9>  Assembling ..\jit\JITStubsMSVC64.asm...
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: 命令“REM Do not edit from the Visual Studio IDE! Customize via a JavaScriptCorePreLink.cmd file.
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: if not exist "C:\cygwin\home\Administrator\WebKit-r174650\Source\JavaScriptCore\JavaScriptCore.vcxproj\JavaScriptCorePreLink.cmd" exit /b
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073:
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set CONFIGURATIONBUILDDIR=C:\cygwin\home\administrator\webkit-r174650\WebKitBuild\Debug
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set CONFIGURATIONNAME=Debug
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set INPUTDIR=
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set INPUTFILENAME=
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set INPUTPATH=
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set INTDIR=C:\cygwin\home\administrator\webkit-r174650\WebKitBuild\Debug\obj32\JavaScriptCore\
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set OUTDIR=C:\cygwin\home\administrator\webkit-r174650\WebKitBuild\Debug\bin32\
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set PLATFORMARCHITECTURE=32
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set PLATFORMNAME=Win32
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set PROJECTDIR=C:\cygwin\home\Administrator\WebKit-r174650\Source\JavaScriptCore\JavaScriptCore.vcxproj\
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set PROJECTFILENAME=JavaScriptCore.vcxproj
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set PROJECTNAME=JavaScriptCore
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set PROJECTPATH=C:\cygwin\home\Administrator\WebKit-r174650\Source\JavaScriptCore\JavaScriptCore.vcxproj\JavaScriptCore.vcxproj
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set SOLUTIONDIR=C:\cygwin\home\Administrator\WebKit-r174650\Source\WebKit\WebKit.vcxproj\
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set SOLUTIONFILENAME=WebKit.sln
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set SOLUTIONNAME=WebKit
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set SOLUTIONPATH=C:\cygwin\home\Administrator\WebKit-r174650\Source\WebKit\WebKit.vcxproj\WebKit.sln
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set TARGETDIR=C:\cygwin\home\administrator\webkit-r174650\WebKitBuild\Debug\bin32\
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set TARGETEXT=.dll
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set TARGETFILENAME=JavaScriptCore.dll
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set TARGETPATH=C:\cygwin\home\administrator\webkit-r174650\WebKitBuild\Debug\bin32\JavaScriptCore.dll
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set DEBUGSUFFIX=
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: set WEBKIT_LIBRARIES=C:\cygwin\home\administrator\webkit-r174650\WebKitLibraries\win
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073:
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: REM If any of the above variables didn't exist previously and
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: REM were set to an empty string, set will set the errorlevel to 1,
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: REM which will cause the project-specific script to think the build
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: REM has failed. This cmd /c call will clear the errorlevel.
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: cmd /c
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073:
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: "C:\cygwin\home\Administrator\WebKit-r174650\Source\JavaScriptCore\JavaScriptCore.vcxproj\JavaScriptCorePreLink.cmd"
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073:
9>C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets(127,5): error MSB3073: :VCEnd”已退出,代码为 1。

解决:用记事本打开JavaScriptCorePreLink.cmd,然后填写echo do thing,主要就是让JavaScriptCorePreLink.cmd非0kb

原因:操作系统有问题(我从网上新装的操作系统就可以编辑空bat文件),右键任何0kb的.bat,.cmd文件,点击编辑/打开/打印都报参数错误。这个原因导致vs无法正确运行空的JavaScriptCorePreLink.cmd


Logo

华为开发者空间,是为全球开发者打造的专属开发空间,汇聚了华为优质开发资源及工具,致力于让每一位开发者拥有一台云主机,基于华为根生态开发、创新。

更多推荐