Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
P

PDF-Writer

> 编程语言
Open source

High performance library for creating, modiyfing and parsing PDF files in C++

1.0K stars0 likes0 views
WebsiteGitHub

About

High performance library for creating, modiyfing and parsing PDF files in C++

PDF-Writer (PDFHummus)

A fast and free C++ library for creating, parsing and manipulating PDF files and streams.

Documentation | Project Site | NodeJS Wrapper

Prerequisites

  • Compiler: Visual Studio (Windows), GCC/Clang (Linux/macOS)
  • CMake: Download here
  • OpenSSL: Required for PDF2.0 encryption (set PDFHUMMUS_NO_OPENSSL=TRUE to disable)

Project Structure

  • PDFWriter: Main library implementation
  • PDFWriterTesting: Test code for ctest
  • FreeType, LibAesgm, LibJpeg, LibPng, LibTiff, Zlib: Bundled dependencies

Quick Start

bash
# Build
mkdir build && cd build
cmake ..
cmake --build . --config Release

# Test
ctest --test-dir . -C Release

# Install
cmake --install . --prefix ./install --config Release

CMake Options

Option Default Description
PDFHUMMUS_NO_DCT FALSE Exclude DCT decoding support/Detach LibJpeg dependency
PDFHUMMUS_NO_TIFF FALSE Exclude TIFF Images support/Detach LibTiff dependency
PDFHUMMUS_NO_PNG FALSE Exclude PNG Images support/Detatch LibgPng dependency
PDFHUMMUS_NO_OPENSSL FALSE Exclude PDF2.0 encryption/Detach OpenSSL dependency
USE_BUNDLED TRUE Use bundled dependencies
USE_UNBUNDLED_FALLBACK_BUNDLED FALSE Fallback to bundled if system libs not found
BUILD_FUZZING_HARNESS FALSE Enable fuzz testing

Example: cmake .. -DUSE_BUNDLED=FALSE

Using in Your Project

Option 1: CMake FetchContent (Recommended)

cmake
include(FetchContent)
FetchContent_Declare(
  PDFHummus
  GIT_REPOSITORY https://github.com/galkahana/PDF-Writer.git
  GIT_TAG        v4.6.2
  FIND_PACKAGE_ARGS
)
FetchContent_MakeAvailable(PDFHummus)
target_link_libraries(YourTarget PDFHummus::PDFWriter)

Option 2: find_package

cmake
find_package(PDFHummus REQUIRED)
target_link_libraries(YourTarget PDFHummus::PDFWriter)

Option 3: Copy Sources

Simply copy the source folders to your project and include them directly.

Development

Testing

bash
# Run tests
ctest --test-dir build -C Release -j8

# Build and test 
cmake --build build --target pdfWriterCheck --config Release

Test output files: ./build/Testing/Output

VS Code Setup

Install these extensions:

  • C/C++ Extension Pack
  • CMake Tools
  • CMake Test Explorer

Packaging

bash
cd build && cpack .

Development Guidelines

For detailed development guidelines, coding standards, and contribution patterns, see CLAUDE.md. This document contains:

  • Project coding standards and conventions
  • Build commands and configuration options
  • Error handling patterns and best practices
  • Testing guidelines and organizational structure

This documentation is also optimized for AI-assisted development with Claude Code.

Additional Build Instructions

iOS: See build guide

Manual builds: All PDFWriter sources are in the PDFWriter folder. Link against Zlib, LibTiff, LibJpeg, LibPng, FreeType, and OpenSSL.

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

C

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言