msbuild,Build failed with Error MSB3073 exited with code 1

1、 接手以前的老项目,因为项目比较大,所以用Developer Command Prompt 的msbuild命令编译比较快一些,常用命令如下

      devenv /?             帮助

      ms build xx.sln    编译全部解决方案                             

     1)      打开Developer Command Prompt for VS2013,(开始\visual studio2013\visual studio tools\Developer Command Prompt for VS2013)

              注意要以管理员身份打开

     2)      进入项目sln所在路径,如路径为C:\zxc\04 Retirement Studio\Solutions       

              输入cd C:\zxc\04 Retirement Studio\Solutions 回车    

     3)      输入msbuild + 解决方案名称,回车开始编译  

              输入:msbuild RetirementStudio.sln会车         

     4)如有错误会以红色提示,warning以黄色提示。

2、 在编译过程中报错。(主项目为RetirementStudio,其中报错的为子项目Common)

 

VS2013打开项目 在项目里面直接编译(rebuild)也报错

Error      1              The command "copy Mercer.RetirementStudio.Business.DataAcquisition.SSIS.Common.dll "C:\zxc\04 Retirement Studio\Solutions\Source\DataAcquisition\Business\SSIS\Common\..\RefBak\"" exited with code 1.                Common (Business\DataAcquisition\SSIS\Common)

 

3、 查看Common项目属性发现在Build Events中有如下设置:

copy $(TargetFileName) "$(ProjectDir)..\RefBak\"

猜测可能是输出文件路径不存在导致的错误,在项目Common.csproj的上一级目录

C:\zxc\04 Retirement Studio\Solutions\Source\DataAcquisition\Business\SSIS

下新建文件夹RefBak,重新编译即可通过

 

转载于:https://www.cnblogs.com/xiaochun126/p/4961773.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值