寻找 .winmd 路径的静态库
Static library looking for path of .winmd
我有一个 C++ 库,它可以在 windows 运行 时间环境中使用它。
我想将它用作静态库。我以这种方式配置并构建了它 successfully.I 还能够将它的项目引用添加到我的使用中。
但是当我尝试构建我将要使用它的项目时 - 我遇到了构建错误:
pch.cpp : fatal error C1192: #using failed on 'D:..\mylib\mylib.winmd'
为什么要查找 .winmd 文件?它生成 .lib 文件。我在这里做错了什么?
我必须在我的 .cxproj 文件中添加以下项目,以制作静态库,并将其作为 .lib 文件添加到我的 UWP
<Keyword>StaticLibrary</Keyword>
<AppContainerApplication>true</AppContainerApplication>
<ApplicationType>Windows Store</ApplicationType>
<WindowsTargetPlatformVersion>10.0.14393.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformMinVersion>10.0.10586.0
</WindowsTargetPlatformMinVersion>
<ApplicationTypeRevision>10.0</ApplicationTypeRevision>
<Link>
<SubSystem>Console</SubSystem>
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
</Link>
我有一个 C++ 库,它可以在 windows 运行 时间环境中使用它。
我想将它用作静态库。我以这种方式配置并构建了它 successfully.I 还能够将它的项目引用添加到我的使用中。
但是当我尝试构建我将要使用它的项目时 - 我遇到了构建错误:
pch.cpp : fatal error C1192: #using failed on 'D:..\mylib\mylib.winmd'
为什么要查找 .winmd 文件?它生成 .lib 文件。我在这里做错了什么?
我必须在我的 .cxproj 文件中添加以下项目,以制作静态库,并将其作为 .lib 文件添加到我的 UWP
<Keyword>StaticLibrary</Keyword>
<AppContainerApplication>true</AppContainerApplication>
<ApplicationType>Windows Store</ApplicationType>
<WindowsTargetPlatformVersion>10.0.14393.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformMinVersion>10.0.10586.0
</WindowsTargetPlatformMinVersion>
<ApplicationTypeRevision>10.0</ApplicationTypeRevision>
<Link>
<SubSystem>Console</SubSystem>
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
<GenerateWindowsMetadata>false</GenerateWindowsMetadata>
</Link>