| OLD | NEW |
| 1 {{+bindTo:partials.standard_nacl_article}} | 1 {{+bindTo:partials.standard_nacl_article}} |
| 2 | 2 |
| 3 <section id="c-tutorial-getting-started-part-2"> | 3 <section id="c-tutorial-getting-started-part-2"> |
| 4 <span id="tutorial2"></span><h1 id="c-tutorial-getting-started-part-2"><span id=
"tutorial2"></span>C++ Tutorial: Getting Started (Part 2)</h1> | 4 <span id="tutorial2"></span><h1 id="c-tutorial-getting-started-part-2"><span id=
"tutorial2"></span>C++ Tutorial: Getting Started (Part 2)</h1> |
| 5 <div class="contents local" id="contents" style="display: none"> | 5 <div class="contents local" id="contents" style="display: none"> |
| 6 <ul class="small-gap"> | 6 <ul class="small-gap"> |
| 7 <li><a class="reference internal" href="#overview" id="id1">Overview</a></li> | 7 <li><a class="reference internal" href="#overview" id="id1">Overview</a></li> |
| 8 <li><p class="first"><a class="reference internal" href="#using-the-native-clien
t-sdk-build-system" id="id2">Using the Native Client SDK build system</a></p> | 8 <li><p class="first"><a class="reference internal" href="#using-the-native-clien
t-sdk-build-system" id="id2">Using the Native Client SDK build system</a></p> |
| 9 <ul class="small-gap"> | 9 <ul class="small-gap"> |
| 10 <li><a class="reference internal" href="#simplifying-the-makefile" id="id3">Simp
lifying the Makefile</a></li> | 10 <li><a class="reference internal" href="#simplifying-the-makefile" id="id3">Simp
lifying the Makefile</a></li> |
| (...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 245 <pre class="prettyprint"> | 245 <pre class="prettyprint"> |
| 246 <body data-name="part2" | 246 <body data-name="part2" |
| 247 data-tools="newlib glibc pnacl" | 247 data-tools="newlib glibc pnacl" |
| 248 data-configs="Debug Release" | 248 data-configs="Debug Release" |
| 249 data-path="{tc}/{config}"> | 249 data-path="{tc}/{config}"> |
| 250 ... | 250 ... |
| 251 </pre> | 251 </pre> |
| 252 <p><code>common.js</code> will read these data attributes to allow you to load t
he same | 252 <p><code>common.js</code> will read these data attributes to allow you to load t
he same |
| 253 example with different toolchains by changing the URL’s <a class="referenc
e external" href="http://en.wikipedia.org/wiki/Query_string">query string</a>. F
or example, you can load the | 253 example with different toolchains by changing the URL’s <a class="referenc
e external" href="http://en.wikipedia.org/wiki/Query_string">query string</a>. F
or example, you can load the |
| 254 glibc Debug version of this example by navigating to | 254 glibc Debug version of this example by navigating to |
| 255 <code>index.html?tc=glibc&config=Debug</code>.</p> | 255 <code>index.html?tc=glibc&config=Debug</code>. Path URI’s such as <co
de>../</code>, for example |
| 256 do not work for either the data-path parameter or its corresponding query |
| 257 string.</p> |
| 256 <p>Next, we remove the <code>embed</code> element that is described in HTML. Thi
s will be | 258 <p>Next, we remove the <code>embed</code> element that is described in HTML. Thi
s will be |
| 257 automatically added for us by <code>common.js</code>, based on the current | 259 automatically added for us by <code>common.js</code>, based on the current |
| 258 toolchain/configuration combination:</p> | 260 toolchain/configuration combination:</p> |
| 259 <pre class="prettyprint"> | 261 <pre class="prettyprint"> |
| 260 <!-- | 262 <!-- |
| 261 Just as in part1, the <embed> element will be wrapped inside the <div&g
t; | 263 Just as in part1, the <embed> element will be wrapped inside the <div&g
t; |
| 262 element with the id "listener". In part1, the embed was specified in H
TML, | 264 element with the id "listener". In part1, the embed was specified in H
TML, |
| 263 here the common.js module creates a new <embed> element and adds it to the | 265 here the common.js module creates a new <embed> element and adds it to the |
| 264 <div> for us. | 266 <div> for us. |
| 265 --> | 267 --> |
| (...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 419 // This function is called by common.js when a message is received from the | 421 // This function is called by common.js when a message is received from the |
| 420 // NaCl module. | 422 // NaCl module. |
| 421 function handleMessage(message) { | 423 function handleMessage(message) { |
| 422 var logEl = document.getElementById('log'); | 424 var logEl = document.getElementById('log'); |
| 423 logEl.textContent += message.data; | 425 logEl.textContent += message.data; |
| 424 } | 426 } |
| 425 </pre> | 427 </pre> |
| 426 </section> | 428 </section> |
| 427 | 429 |
| 428 {{/partials.standard_nacl_article}} | 430 {{/partials.standard_nacl_article}} |
| OLD | NEW |