c++ - 无法在 VS2015 中禁用单个 C 文件的预编译头文件

标签 c++ c visual-studio visual-studio-2015 precompiled-headers

我正在尝试为我的项目的 C 文件禁用预编译头文件,因为 VS2015 给我这个错误(为便于阅读而换行):

..\..\..\..\Lib\freetype2\src\autofit\autofit.c : fatal error C1853: 
  'Y:\obj\TwoNav_PC_15\headers\CompeTwoNav.pch' precompiled header file 
  is from a previous version of the compiler, or the precompiled header 
  is C++ and you are using it from C (or vice versa)

在查看如何操作时,我找到了 this post , 但是当我尝试在我的 Visual Studio 2015 Professional 中执行此操作时,我看不到所引用的选项。

编辑:这是我尝试选择属性的方式:

enter image description here

这张图片是我在选择文件属性时看到的:

File Properties dialogbox

最佳答案

我找到了一个变通方法来显示我需要的正确工具...我把它留在这里作为答案,以防其他人遇到这个问题。

它不会通过单击文件 -> 属性 出现,但在单击项目 -> 属性 时出现所以,一旦打开,我选择了文件 autofit.c从 TreeView 中,最后我可以从这个单个文件中禁用预编译头文件!

enter image description here

关于c++ - 无法在 VS2015 中禁用单个 C 文件的预编译头文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40267915/

相关文章:

c - 用于检测两个后/前增量运算符的静态分析器

c - 将字符串的内容解析为子字符串

c++ - Visual Studio 中的 "multi-processor compilation"有什么缺点吗?

visual-studio - MSVC 相当于 '__builtin_return_address'

.net - 托管对象,为什么不会(^)。编译?

C++ 错误 : no matching function for call to 'std::vector<int>::swap(std::vector<int>)'

c++ - 如何使用 re2 获取部分匹配项的数量

c++ - C++中的C代码不兼容参数错误

c++ - 未找到符号,应在平面命名空间 ObjC++ 中

无法读取所有字符串