Clone this repo:
  1. 3acb1ef Sanitize CJBig2_SymbolDict's memory usage. by Lei Zhang · 14 hours ago chromium/2532 master
  2. fd751f2 Parallelize by Lei Zhang · 14 hours ago
  3. 848a13b Pass IJS_Runtime, not IJS_Context, to native object constructors. by Tom Sepez · 15 hours ago
  4. f1c7136 Allow compiling PDFium without V8. by Tom Sepez · 15 hours ago
  5. c9952e6 Fix a bad refactoring error from commit 8a9ce57. by Lei Zhang · 18 hours ago

Building PDFium


Get the chromium depot tools via the instructions at (this provides the gclient utilty needed below).

Also install Python, Subversion, and Git and make sure they’re in your path.

Optionally, you may want to install the Ninja build system (recommended) rather than using your platform-specific build system.

Get the code

mkdir pdfium
cd pdfium
gclient config --name . --unmanaged
gclient sync

Generate the build files

Now we use the GYP library to generate the build files.

At this point, you have two options. The first option is to use the Ninja build system. This is the default as of mid-September, 2015. Previously, the second option was the default. Most PDFium developers use Ninja, as does our continuous build system.

On Windows: build\gyp_pdfium For all other platforms: build/gyp_pdfium

The second option is to generate platform-specific build files, i.e. Makefiles on Linux, sln files on Windows, and xcodeproj files on Mac. To do so, set the GYP_GENERATORS environment variable appropriately (e.g. “make”, “msvs”, or “xcode”) before running the above command.

Building the code

If you used Ninja, you can build the sample program by: ninja -C out/Debug pdfium_test You can build the entire product (which includes a few unit tests) by: ninja -C out/Debug

If you’re not using Ninja, then building is platform-specific.

On Linux: make pdfium_test

On Mac, open build/all.xcodeproj

On Windows, open build\all.sln

Running the sample program

The pdfium_test program supports reading, parsing, and rasterizing the pages of a .pdf file to .ppm or .png output image files (windows supports two other formats). For example: out/Debug/pdfium_test --ppm path/to/myfile.pdf


The current health of the source tree can be found at


There is a branch for a forthcoming feature called XFA that you can get by following the steps above, then: git checkout origin/xfa build/gyp_pdfium ninja -C out/Debug