如何在Windows中为Google Chrome创建PPAPI插件? [英] How to create a PPAPI plugin for Google Chrome in Windows?

查看:574
本文介绍了如何在Windows中为Google Chrome创建PPAPI插件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是PPAPI开发的新手,已经从此处下载了已经的示例。



然而,即使在浏览文档后,
我无法构建项目。



我有Microsoft Visual Studio 2010,Windows操作系统和Chrome:30.0.1599.65

$ b我知道一旦创建了dll,使用 regsvr32 命令将注册该插件,尽管获取dll,即使有可用的代码,对我来说似乎很难任何帮助建立dll是赞赏。

解决方案

您将从这里开始下载并设置SDK: https://developers.google.com/native-client/sdk/download



此页面将介绍如何构建和运行示例: https://developer.chrome.com/native-client/sdk/examples



此页面介绍如何实际创建自己的插件: https://developer.chrome.com/native-client/devguide/tutorial/ tutorial-part1



然后,您应该阅读整个部分来编写和构造您的应用程序: ht tps://developer.chrome.com/native-client/devguide/coding/application-structure



如果您需要任何第三方库,请务必请在这里查看: https://chromium.googlesource.com/webports



编辑:忘了提到您将要使用与您正在运行的chrome版本相同版本的胡椒api(在本例中为胡椒_30)。此外,您必须使用NaCl工具链(glibc,newlib或pnacl之一);您不能使用Visual C / C ++工具链。我建议现在尝试使用pnacl,因为这是迄今为止最为跨平台版本,但如果遇到麻烦,您可能希望使用newlib工具链,因为它有更好的支持。


I am new to PPAPI development and have downloaded the already examples from here

However, even after coming across the documentation, I am not able to build the project.

I have Microsoft Visual Studio 2010, Windows OS and Chrome:30.0.1599.65

I understand that once a dll is created, using the regsvr32 command will register the plugin, although getting the dll, even with available code, seems tough for me. Any help for building the dll is appreciated.

解决方案

You will want to start here to download the and set up the SDK: https://developers.google.com/native-client/sdk/download

This page will take you through how to build and run the examples: https://developer.chrome.com/native-client/sdk/examples

This page goes over how to actually create your own plugin: https://developer.chrome.com/native-client/devguide/tutorial/tutorial-part1

And then you should read this entire section to code and structure your application: https://developer.chrome.com/native-client/devguide/coding/application-structure

If you need any third party libraries be sure to check here: https://chromium.googlesource.com/webports

Edit: Forgot to mention that you will want to use the same version of the pepper api as the version of chrome you're running (in this case pepper_30). Also, you have to use the NaCl toolchain (one of either glibc, newlib, or pnacl); you can't use the Visual C/C++ toolchains. I recommend trying pnacl now that it is available, as that is by far the most cross platform version, but if you run into trouble, you'll probably want to use the newlib toolchain as it has better support.

这篇关于如何在Windows中为Google Chrome创建PPAPI插件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆