Questions tagged [google-nativeclient]

Native Client (NaCl) and Portable Native Client (PNaCl) are open-source technologies for executing compiled code in a browser sandbox. PNaCl is portable and preferred but has a few limitations. Questions about the tool chain and SDK for Native Client as well as questions concerning behaviors of the resulting applications should use this tag. Questions involving HTML and JavaScript components used with Native Client may need those tags as well or instead.

The Native Client (NaCl) and Portable Native Client (PNaCl) open-source technologies are designed to run operating system independent, native compiled code securely inside browsers by containing the compiled code in a sandbox. The result is to provide the raw speed needed for browser based applications to compete with traditional software like 3D games, video editing, and other applications. Native Client gives languages like C and C++ the same level of portability and safety that JavaScript provides on the web today.

There are two versions of Native Client: Native Client using the native code of a specific target hardware and Portable Native Client using a portable hardware independent code. The Portable Native Client code is translated to Native Client code for the current hardware at the time it is executed in the sandbox.

Portable Native Client is preferred since one executable can run on multiple hardware while Native Client requires multiple hardware specific versions. However Portable Native Client does have a few limitations and Native Code may be required for a specific application.

A complete application is expected to use Native Client (PNaCl or NaCl) with HTML along with any needed JavaScript and CSS styles (JavaScript and CSS may be included in the HTML file or as separate files). An embed tag with a type of application/x-pnacl for Portable Native Client or application/x-nacl for Native Client is used in an HTML file specifying the application's manifest file to download and start the Native Client application.

Applications may be published through the Chrome Web Store.

From the SDK download page.

Platforms

Native Client supports several operating systems, including Windows, Linux, OSX, and ChromeOS. It supports several architectures including on x86-32, x86-64, ARM, and MIPS.

446 questions
25
votes
2 answers

Does CEF3 support NaCl?

Has anyone had success in enabling NaCl/PNaCl support in the CEF3 (Chromium Embedded Framework)? I find that Chrome (34) can run the PNaCl samples on this page fine, but the cefclient distributed at cefbuilds.com (Windows, 1916 branch) does…
holtavolt
  • 4,378
  • 1
  • 26
  • 40
20
votes
4 answers

Can Native Client (NaCl) programs be written in languages other than C or C++?

Would it be possible to write a native client application in Python or Go that could then run in the browser?
Alexis
  • 23,545
  • 19
  • 104
  • 143
17
votes
1 answer

Adding NaCl in an Chrome Extension

My question is quite simple, I tried to create a chrome extension that calls a NaCl module. My button and different files seem to be ok, and my quite simple code in C++ returns a PostMessage hello World. But, when I try it, it doesn't work. Are…
Nicolalalas
  • 323
  • 2
  • 8
15
votes
4 answers

Can I run Google's Native Client outside of the browser?

Is it possible to run Google NaCl outside of the browser as a process sandbox?
Rafał Sobota
  • 1,468
  • 1
  • 17
  • 32
13
votes
0 answers

Google Native Client, sending binary data from NACL to the frontend

How do I send binary data, e.g. mp3/mp4 data back to the frontend ? I know there are two ways of doing it: utilizing the sandbox filesystem provided by NACL and get the url at the frontend; passing the data through the PostMessage() using…
JJin
  • 327
  • 4
  • 14
11
votes
2 answers

Run compiled files on Google Native Client

How to run compiled files directly using Google Native Client (PNaCl)? It tried checking their documentation. It said that - Native Client is a sandbox for running compiled C and C++ code in the browser efficiently and securely, independent of the…
Arulx Z
  • 193
  • 1
  • 13
11
votes
1 answer

Make tag fill the whole window and resize with it
I have a NaCl plugin for Chrome that I'd like to fill the whole window with. HTML is like this:
whywhat
  • 113
  • 1
  • 1
  • 5
10
votes
4 answers

NaCl OpenGL example

Now that nacl is about to be on by default in chrome I'd like to try writing an opengl game. It seems that this is possible because there is a working quake port, but I can't find any documentation about this. Does anyone have a minimal example?…
Timmmm
  • 88,195
  • 71
  • 364
  • 509
10
votes
5 answers

Does a Qt application work in Google Native Client?

I'm not familiar with Qt or with Google Native Client. Is it possible for a TRIVIAL Qt console application to be ported to Google Native Client? I understand that some work would be involved. But the question is, how much if it's even possible?
JP Richardson
  • 38,609
  • 36
  • 119
  • 151
10
votes
2 answers

odd compiled code

I've compiled some Qt code with google's nacl compiler, but the ncval validator does not grok it. One example among many: src/corelib/animation/qabstractanimation.cpp:165 Here's the relevant code: #define Q_GLOBAL_STATIC(TYPE, NAME) …
user1095108
  • 14,119
  • 9
  • 58
  • 116
9
votes
1 answer

Why is my program so slow?

Someone decided to do a quick test to see how native client compared to javascript in terms of speed. They did that by running 10 000 000 sqrt calculations and measuring the time it took. The result with javascript: 0.096 seconds, and with NaCl:…
gman
  • 100,619
  • 31
  • 269
  • 393
9
votes
1 answer

Building a Framework With Qt, and Wt, or NaCl?

I am contemplating designing a framework to allow for one C++ code base to become a desktop application and a web app for most major platforms (Mac OS, Windows, Linux, and possibly Android). I have decided Qt would be best for desktop builds,…
8
votes
3 answers

Are there any examples of compiling C# code using Mono so that the exe can run with Google's native client support?

I have found a press release that states that Mono now support compilation for native client. It's unclear whether this is only available from the separate github mono fork, or as part of the standard distribution. I've built the forked mono…
Jeff Thompson
  • 2,662
  • 2
  • 18
  • 17
7
votes
1 answer

Can chrome native client do anything that javascript cannot do?

I am confused about the utility of native client in Chrome other than say using the language of your choice and running faster. Can one accomplish anything in native client that you cannot do in javascript? By anything, I mean functionality, not a…
software engineer
  • 271
  • 1
  • 4
  • 15
7
votes
1 answer

What is NaCl Socket API?

I've found it at chrome://flags/ but I don't really know what is this. I searched on the web a lot, but I haven't found anything.
Danny Fox
  • 38,659
  • 28
  • 68
  • 94
1
2 3
29 30