我从 Microsoft,但我不知道如何开始。
我有一个 VS 项目和一个包含注册表项的文件。没有包含 makefile,也没有任何关于如何构建的说明。
我正在尝试将 G++ 编译器与 MinGW 一起使用。用例是简单的 http 身份验证。我在 Linux 上使用我的 pam-http 项目 进行了此工作。
- 我如何编译一个简单的凭据提供程序?
- 有提供构建脚本/makefiles 的教程吗?
我非常愿意尽可能使用 FOSS,因此 MinGW 和g++,而且我在 Windows 上编译的经验很少(几年前我在工作中使用过 VS)。最终我想在 cURL 中链接,但是一旦我构建了一些东西我就可以弄清楚。
注意:
我找到了这些,但我正在寻找使用 g++ 的构建脚本:
我分享
编辑:
我在 MinGW 的网站上发现 this 说可以链接到 MS VC 创建的 DLL。
我不想使用 Visual Studio。我更喜欢一个不受特定构建工具(如 ANT 或 make)约束的命令行编译工具。
I found some examples from Microsoft, but I'm not sure how to get started.
I have what appears to be a VS project and a file with Registry entries. There are no makefiles included and not really any instructions on how to build.
I am trying to use the G++ compiler with MinGW. The use case is simple http authentication. I have this working on Linux with my pam-http project.
- How do I go about compiling a simple Credential Provider?
- Are there any tutorials that give build scripts/makefiles?
I would very much prefer to use FOSS where possible, hence MinGW and g++, and I have little experience with compiling on Windows (I used VS at a job several years ago). Ultimately I'd like to link in cURL, but I can figure that out once I get something built.
Note:
I found these, but I'm looking for build scripts using g++:
I share kberson's sentiments.
EDIT:
I found this on MinGW's website that says linking against MS VC created DLLs is possible.
I do not want to use Visual Studio. I'd prefer a command-line compile tool that isn't tied down to a specific build tool (like ANT or make).
发布评论
评论(1)
如果您使用 Visual Studio Express C++(然后移植到 G++),编译示例凭据提供程序将变得更加容易。您可能还需要安装 Windows SDK
MSVC++ 附带命令行构建工具。因此,要构建 Windows 7 的自定义凭据提供程序,首先提取将文件放入目录中。然后安装 MSVC - 使用开始菜单上的快捷方式 Visual Studio 命令提示符 (2010) 打开命令提示符并键入
或构建发布配置 Win32
请参阅 MSBuild (Visual C++) 概述, MSBuild 命令行参考 和 在命令行上构建
这些凭据提供程序是使用 COM 构建的 - 的一部分OLE2 - 这是 Microsoft 组件对象模型。 可以在不使用 MSVC 的情况下构建可互操作的组件,但需要做更多的工作。因此,一开始我会使用 MSVC 进行开发,因为所有示例都可以开箱即用,然后我会移植到 G++,因为会出现问题,而且通常更容易从工作系统开始,因为它规则解决 COM 绑定中的问题。
要了解 COM,阅读COM 的技术基础会有所帮助。 。
To compile the example credential providers will be considerably easier if you use Visual Studio Express C++ (and then port to G++). You may also need to install the Windowns SDK
MSVC++ comes with command line building tools. So to build the custom credential provider for Windows 7 firstly extract the files into a directory. Then Install MSVC - use the shortcut on the start menu Visual Studio Command Prompt (2010) to open a command prompt and type
or to build the release configuration Win32
Refer to MSBuild (Visual C++) Overview, MSBuild Command Line Reference and Building on the Command Line
These credential providers are built using COM - part of OLE2 - which is the Microsoft Component Object Model. It is possible to build interoperable components without using MSVC but more work. So to get started I'd develop using MSVC simply because all of the examples will work out of the box and then I'd port across to G++ as there will be issues and it is usually easier to start from a working system as it rules out problems in the COM bindings.
To understand COM it helps to read the Technical foundation of COM.