本文主要是记录一个C++编译错误的解决方案,具体错误请看本文标题。

这个错误主要是由Managed C++的增量编译导致的,这是VS 2008的一个bug,在VS 2010已经修复,我使用的正式2010所以直接简单做一下Clean然后再Rebuild就可以了。如果你用的是VS 2008,请参考以下解决方案:

  1. 禁用增量编译。 In the project properties, under Configuration Properties > General, set "Enable Managed Incremental Build" to No.
  2. 给待编译的项目制定一个具体的版本。比如将 
    [assembly:AssemblyVersionAttribute("1.0.*")];

    替换为

    [assembly:AssemblyVersionAttribute("1.0.0.1")];

参考:

  • StackOverflow关于这个问题的解答:http://stackoverflow.com/questions/810827/lnk2022-metadata-operation-failed-driving-me-insane
  • 微软的bug页面:https://connect.microsoft.com/VisualStudio/feedback/details/442615/managed-incremental-build-doesnt-work-if-change-to-dependent-project-was-insignificant

error LNK2022: metadata operation failed (801311D6) : Differing number of methods in duplicated types的更多相关文章

  1. 【openstack报错】【metadata问题】‘http://169.254.169.254/2009-04-04/meta-data/instance-id’ failed : url error [[Errno 111] Connection refused]

    [时间]2014年2月25日 [平台]ubuntu 12.04.3 openstack havana  with nova-network in multi-host [日志]实例启动时输出的日志内容 ...

  2. Error: ORA-16501: the Data Guard broker operation failed ORA-16625: cannot reach database

    在备库上建配置文件 DGMGRL> create configuration 'sharkdbbork' as primary database is 'sharkdb' connect ide ...

  3. composer在update时提示file could not be downloaded: SSL operation failed with code 1. OpenSSL Error messages: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO

    在开发的时候,需要把依赖的服务更新到最新,然后 手动composer update一下,提示如下: failed) Update failed (The "e "https://a ...

  4. 使用PHPMailer 中的报错解决 "Connection failed. Error #2: stream_socket_client(): SSL operation failed with code 1. OpenSSL Error messages:"

    PHPMailer项目地址:https://github.com/PHPMailer/PHPMailer 项目中用到PHPMailer,使用过程中报错:"Connection failed. ...

  5. 【MYSQL用户创建报错】ERROR 1396 (HY000): Operation CREATE USER failed for 'user1'@'%'

    原文参考自:http://blog.csdn.net/u011575570/article/details/51438841 1.创建用户的时候报错ERROR 1396 (HY000): Operat ...

  6. hive 报错FAILED: Error in metadata: java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.metastore.HiveMetaStoreClient FAILED: Execu

    使用hive一段时间以后,今天在使用的时候突然报错,如下: hive> show databases;FAILED: Error in metadata: java.lang.RuntimeEx ...

  7. mysql-创建用户报错ERROR 1396 (HY000): Operation CREATE USER failed for 'XXXX'@'XXXX'(转载)

    创建用户: create user ‘test’@’%’ identified by ‘test’; 显示ERROR 1396 (HY000): Operation CREATE USER faile ...

  8. mysql-创建用户报错ERROR 1396 (HY000): Operation CREATE USER failed for 'root'@'localhost'

    创建用户: create user ‘test’@’%’ identified by ‘test’; 显示ERROR 1396 (HY000): Operation CREATE USER faile ...

  9. mysql-创建用户报错ERROR 1396 (HY000): Operation CREATE USER failed for 'XXXX'@'XXXX'

    创建用户: create user 'test'@'%' identified by 'test'; 显示ERROR 1396 (HY000): Operation CREATE USER faile ...

随机推荐

  1. j2ee性能调优之最小化资源压力测试法则

    前面看到有人讲j2ee的性能调优,虽然这块不是自己的专长,但是猪养多了,也忍不住跳出来说几句. 虽然几乎每本讲性能调优的书籍开篇都会提,没必要的情况下就不要做调优,但是我个人还是认为,所有系统在上线前 ...

  2. NOI模拟题1 Problem A: sub

    题面 Sample Input 5 7 2 -1 -3 1 1 1 2 1 3 3 4 3 5 2 1 3 0 2 1 2 1 2 1 1 -3 2 Sample Output 2 4 5 2 HIN ...

  3. Spring MVC通过Pageable对象和PageableDefault注解获取分页信息(MongoDB通过Pageable来操作分页)

    说明:Pageable同时也能用于操作MongoDB的分页. PageableSpring Data库中定义的一个接口,该接口是所有分页相关信息的一个抽象,通过该接口,我们可以得到和分页相关所有信息( ...

  4. Sort Detail Data Block Example - Oracle Forms

    Example is given below to sort detail data block data (toggle asc or desc) with push buttons used as ...

  5. cocos2dx 2.x新建项目

    举例: cocos2d-x-2.2.6/tools/project-creator 进入 这个文件夹 chmod 777 project-cereator.py ./create_project.py ...

  6. 2017.3.14 activiti实战--第二十章--REST服务

    学习资料:<Activiti实战> 第二十章 REST服务 20.1 通信协议概述 略. 20.2 REST API概述 资源分类 资源基础URI 说明 Deployments manag ...

  7. Octave入门基础

    Octave入门基础 一.简单介绍 1.1 Octave是什么? Octave是一款用于数值计算和画图的开源软件.和Matlab一样,Octave 尤其精于矩阵运算:求解联立方程组.计算矩阵特征值和特 ...

  8. 原生JavaScript技巧大收集100个

    原生JavaScript技巧大收集 1.原生JavaScript实现字符串长度截取function cutstr(str, len) { var temp; var icount = 0; var p ...

  9. 如何把VBS转换为EXE文件

    如下所示,我想要做一个把360网速测试剥离开来的绿色版,有一个TestSpeed.bat命令,双击之后去执行了360AppLoader.exe,并且会调用netmon文件夹的NetSpeed.dll文 ...

  10. 微信小程序-使用腾讯Wxpage

    微信小程序想要更快的速度吗? 满足你 https://github.com/tvfe/wxpage#-c%E5%AE%9A%E4%B9%89 使用超简单(导入wxpage.js,最后使用对象名:P): ...