OLD | NEW |
1 .. _devcycle-building: | 1 .. _devcycle-building: |
2 | 2 |
3 ######## | 3 ######## |
4 Building | 4 Building |
5 ######## | 5 ######## |
6 | 6 |
7 .. contents:: Table Of Contents | 7 .. contents:: Table Of Contents |
8 :local: | 8 :local: |
9 :backlinks: none | 9 :backlinks: none |
10 :depth: 2 | 10 :depth: 2 |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 The PNaCl toolchain contains modified versions of the tools in the | 131 The PNaCl toolchain contains modified versions of the tools in the |
132 LLVM toolchain, as well as linkers and other tools from binutils. | 132 LLVM toolchain, as well as linkers and other tools from binutils. |
133 To determine which version of LLVM or binutils the tools are based upon, | 133 To determine which version of LLVM or binutils the tools are based upon, |
134 run the tool with the ``--version`` command line flag. These tools | 134 run the tool with the ``--version`` command line flag. These tools |
135 are used to compile and link applications into **.pexe** files. The toolchain | 135 are used to compile and link applications into **.pexe** files. The toolchain |
136 also contains a tool to translate a **pexe** file into a | 136 also contains a tool to translate a **pexe** file into a |
137 architecture-specific **.nexe** (e.g., for debugging purposes). | 137 architecture-specific **.nexe** (e.g., for debugging purposes). |
138 | 138 |
139 Some of the useful tools include: | 139 Some of the useful tools include: |
140 | 140 |
141 pnacl-abicheck | 141 ``pnacl-abicheck`` |
142 Checks that the **pexe** follows the PNaCl ABI rules. | 142 Checks that the **pexe** follows the PNaCl ABI rules. |
143 pnacl-ar | 143 ``pnacl-ar`` |
144 Creates archives (i.e., static libraries) | 144 Creates archives (i.e., static libraries) |
145 pnacl-clang | 145 ``pnacl-bcdis`` |
| 146 Object dumper for PNaCl bitcode files. |
| 147 ``pnacl-clang`` |
146 C compiler and compiler driver | 148 C compiler and compiler driver |
147 pnacl-clang++ | 149 ``pnacl-clang++`` |
148 C++ compiler and compiler driver | 150 C++ compiler and compiler driver |
149 pnacl-compress | 151 ``pnacl-compress`` |
150 Compresses a finalized **pexe** file for deployment. | 152 Compresses a finalized **pexe** file for deployment. |
151 pnacl-dis | 153 ``pnacl-dis`` |
152 Disassembler for both **pexe** files and **nexe** files | 154 Disassembler for both **pexe** files and **nexe** files |
153 pnacl-finalize | 155 ``pnacl-finalize`` |
154 Finalizes **pexe** files for deployment | 156 Finalizes **pexe** files for deployment |
155 pnacl-ld | 157 ``pnacl-ld`` |
156 Bitcode linker | 158 Bitcode linker |
157 pnacl-nm | 159 ``pnacl-nm`` |
158 Lists symbols in bitcode files, native code, and libraries | 160 Lists symbols in bitcode files, native code, and libraries |
159 pnacl-ranlib | 161 ``pnacl-ranlib`` |
160 Generates a symbol table for archives (i.e., static libraries) | 162 Generates a symbol table for archives (i.e., static libraries) |
161 pnacl-translate | 163 ``pnacl-translate`` |
162 Translates a **pexe** to a native architecture, outside of the browser | 164 Translates a **pexe** to a native architecture, outside of the browser |
163 | 165 |
164 For the full list of tools, see the | 166 For the full list of tools, see the |
165 ``pepper_<version>/toolchain/<platform>_pnacl/bin`` directory. | 167 ``pepper_<version>/toolchain/<platform>_pnacl/bin`` directory. |
166 | 168 |
167 Using the PNaCl tools to compile, link, debug, and deploy | 169 Using the PNaCl tools to compile, link, debug, and deploy |
168 ========================================================= | 170 ========================================================= |
169 | 171 |
170 To build an application with the PNaCl SDK toolchain, you must compile | 172 To build an application with the PNaCl SDK toolchain, you must compile |
171 your code, link it, test and debug it, and then deploy it. This section goes | 173 your code, link it, test and debug it, and then deploy it. This section goes |
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
359 deployment (via ``pnacl-finalize``). Alternatively, you can apply this step as | 361 deployment (via ``pnacl-finalize``). Alternatively, you can apply this step as |
360 part of the finalizing step by adding the ``--compress`` flag to the | 362 part of the finalizing step by adding the ``--compress`` flag to the |
361 ``pnacl-finalize`` command line. | 363 ``pnacl-finalize`` command line. |
362 | 364 |
363 This compression step doesn't replace the gzip compression performed web servers | 365 This compression step doesn't replace the gzip compression performed web servers |
364 configured for HTTP compression: both compressions are complementary. You'll | 366 configured for HTTP compression: both compressions are complementary. You'll |
365 want to configure your web server to gzip **pexe** files: the gzipped version of | 367 want to configure your web server to gzip **pexe** files: the gzipped version of |
366 a compressed **pexe** file is smaller than the corresponding uncompressed | 368 a compressed **pexe** file is smaller than the corresponding uncompressed |
367 **pexe** file by 7.5% to 10%. | 369 **pexe** file by 7.5% to 10%. |
368 | 370 |
| 371 .. _pnacl-bcdis: |
| 372 |
| 373 Object dumping of PNaCl bitcode files |
| 374 ===================================== |
| 375 |
| 376 Sometimes you may be interesting in the contents of a PNaCl bitcode file. The |
| 377 tool ``pnacl-bcdis`` object dumps the contents of a PNaCl bitcode file. For a |
| 378 description of the output produced by this tool, see |
| 379 :doc:`/reference/pnacl-bitcode-manual`. |
| 380 |
| 381 .. naclcode:: |
| 382 :prettyprint: 0 |
| 383 |
| 384 nacl_sdk/pepper_<version>/toolchain/win_pnacl/bin/pnacl-bcdis \ |
| 385 hello_world.final.pexe |
| 386 |
| 387 The output is the corresponding contents of the given **pexe**. |
| 388 |
369 The GNU-based toolchains | 389 The GNU-based toolchains |
370 ======================== | 390 ======================== |
371 | 391 |
372 Besides the PNaCl toolchain, the Native Client SDK also includes modified | 392 Besides the PNaCl toolchain, the Native Client SDK also includes modified |
373 versions of the tools in the standard GNU toolchain, including the GCC | 393 versions of the tools in the standard GNU toolchain, including the GCC |
374 compilers and the linkers and other tools from binutils. These tools only | 394 compilers and the linkers and other tools from binutils. These tools only |
375 support building **nexe** files. Run the tool with the ``--version`` | 395 support building **nexe** files. Run the tool with the ``--version`` |
376 command line flag to determine the current version of the tools. | 396 command line flag to determine the current version of the tools. |
377 | 397 |
378 Each tool in the toolchain is prefixed with the name of the target | 398 Each tool in the toolchain is prefixed with the name of the target |
(...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
694 Function foo has disallowed type: i128 (i128) | 714 Function foo has disallowed type: i128 (i128) |
695 LLVM ERROR: PNaCl ABI verification failed | 715 LLVM ERROR: PNaCl ABI verification failed |
696 | 716 |
697 When faced with a PNaCl ABI verification error, check the list of features | 717 When faced with a PNaCl ABI verification error, check the list of features |
698 that are :ref:`not supported by PNaCl <when-to-use-nacl>`. | 718 that are :ref:`not supported by PNaCl <when-to-use-nacl>`. |
699 If the problem you face is not listed as restricted, | 719 If the problem you face is not listed as restricted, |
700 :ref:`let us know <help>`! | 720 :ref:`let us know <help>`! |
701 | 721 |
702 .. _glibc: http://www.gnu.org/software/libc/ | 722 .. _glibc: http://www.gnu.org/software/libc/ |
703 .. _newlib: http://sourceware.org/newlib/ | 723 .. _newlib: http://sourceware.org/newlib/ |
OLD | NEW |