GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • PMD Source Code Analyzer Project
  • Nav
  • Download
  • GitHub
  • Edit on GitHub

This view

  • Original page
  • New address

GeezerVison is showing docs.pmd-code.org — Building PMD from source | PMD Source Code Analyzer

 
  • PMD 7.30.0
  • Release date: 27-November-2026
  • About
    • Home
    • Release notes
    • Getting help
    • Release policies
    • Support lifecycle
    • Security
  • User Documentation
    • Migration Guide for PMD 7
    • Installation and basic CLI usage
    • Making rulesets
    • Configuring rules
    • Best practices
    • Suppressing warnings
    • Incremental analysis
    • PMD CLI reference
    • PMD Report formats
    • 3rd party rulesets
    • Signed Releases
    • CPD reference
      • Copy-paste detection
      • CPD Report formats
    • Extending PMD
      • Introduction to writing rules
      • Your first rule
      • XPath rules
      • Java rules
      • Rule designer reference
      • Defining rule properties
      • Rule guidelines
      • Testing your rules
      • Creating (XML) dump of the AST
    • Tools / Integrations
      • Maven PMD Plugin
      • Gradle
      • Ant
      • PMD Java API
      • bld PMD Extension
      • CI integrations
      • IDE Plugins
      • Other Tools / Integrations
  • Rule Reference
    • Apex Rules
      • Index
      • Best Practices
      • Code Style
      • Design
      • Documentation
      • Error Prone
      • Performance
      • Security
    • HTML Rules
      • Index
      • Best Practices
    • Java Rules
      • Index
      • Best Practices
      • Code Style
      • Design
      • Documentation
      • Error Prone
      • Multithreading
      • Performance
      • Security
    • Java Server Pages Rules
      • Index
      • Best Practices
      • Code Style
      • Design
      • Error Prone
      • Security
    • JavaScript Rules
      • Index
      • Best Practices
      • Code Style
      • Error Prone
      • Performance
    • Kotlin Rules
      • Index
      • Best Practices
      • Error Prone
    • Maven POM Rules
      • Index
      • Error Prone
    • Modelica Rules
      • Index
      • Best Practices
    • PLSQL Rules
      • Index
      • Best Practices
      • Code Style
      • Design
      • Error Prone
    • Salesforce Visualforce Rules
      • Index
      • Security
    • Scala Rules
      • Index
    • Swift Rules
      • Index
      • Best Practices
      • Error Prone
    • Velocity Template Language (VTL) Rules
      • Index
      • Best Practices
      • Design
      • Error Prone
    • WSDL Rules
      • Index
    • XML Rules
      • Index
      • Best Practices
      • Error Prone
    • XSL Rules
      • Index
      • Code Style
      • Performance
  • Language-Specific Documentation
    • Overview
    • Language configuration
    • Apex
    • C/C++
    • C#
    • CSS
    • Coco
    • Dart
    • Fortran
    • Gherkin
    • Go
    • HTML
    • Java
    • JavaScript / TypeScript
    • JSP
    • Julia
    • Kotlin
    • Lua
    • Matlab
    • Modelica
    • Objective-C
    • Perl
    • PHP
    • PLSQL
    • Python
    • Ruby
    • Rust
    • Scala
    • Swift
    • T-SQL
    • Visualforce
    • Velocity Template Language (VTL)
    • XML and XML dialects
  • Developer Documentation
    • Contributing
      • Contributing
      • Developer resources
      • Newcomers' Guide
      • Writing documentation
    • Building PMD
      • General Info
      • Building PMD from source
      • Building PMD with IntelliJ IDEA
      • Building PMD with Eclipse IDE
      • Building PMD with VS Code IDE
      • Building PMD with Netbeans IDE
    • Roadmap
    • GitHub Actions Workflows
    • How PMD works
    • Logging
    • Pmdtester
    • Rule Deprecation Policy
    • Major contributions
      • Rule Guidelines
      • Adding a new dialect
      • Adding a new language (JavaCC)
      • Adding a new language (ANTLR)
      • Adding a new CPD language
    • Experimental features
      • List of experimental Features
  • Project documentation
    • Trivia about PMD
      • PMD in the press
      • Products & books related to PMD
      • Similar projects
      • What does 'PMD' mean?
    • Logo
    • FAQ
    • License
    • Credits
    • Old Release Notes
      • Release Notes PMD 7.x
      • Detailed Release Notes PMD 7.0.0
      • Release Notes PMD 6.x
      • Release Notes PMD 5.x
      • Release Notes PMD 4.x and earlier
    • Decisions
    • Project management
      • Infrastructure
      • Release process
      • Merging pull requests
      • Main Landing page

Building PMD from source

Table of Contents

Compiling PMD

Note

You will need 21 to build PMD, even though running PMD only requires Java 8.

You’ll need to either check out the source code or download the latest source release. Assuming you’ve got the latest source release, unzip it to a directory:

[tom@hal building]$ ls -l
total 5716
-rw-rw-r--    1 tom      tom       5837216 Jul 17 13:09 pmd-src-7.30.0.zip
[tom@hal building]$ unzip -q pmd-src-7.30.0.zip
[tom@hal building]$

Now cd down into the pmd directory:

[tom@hal building]$ cd pmd-src-7.30.0
[tom@hal pmd-src-7.30.0]$ ls -l | grep pom.xml
-rw-rw-r--    1 tom      tom          36482 14\. Nov 17:36 pom.xml
[tom@hal pmd-src-7.30.0]$

That’s the project configuration for maven… let’s compile!

[tom@hal pmd-src-7.30.0]$ ./mvnw clean verify
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] PMD
[INFO] PMD Core
...
... after a few minutes ...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for PMD 7.30.0:
[INFO] 
[INFO] PMD ................................................ SUCCESS [ 31.653 s]
[INFO] PMD Core ........................................... SUCCESS [01:10 min]
[INFO] PMD Test Schema .................................... SUCCESS [  5.408 s]
[INFO] PMD Ant Integration ................................ SUCCESS [  9.623 s]
[INFO] PMD Test Framework ................................. SUCCESS [  7.571 s]
[INFO] PMD language module testing utilities .............. SUCCESS [ 30.390 s]
[INFO] PMD Apex ........................................... SUCCESS [ 56.152 s]
[INFO] PMD Coco ........................................... SUCCESS [01:18 min]
[INFO] PMD C++ ............................................ SUCCESS [ 11.274 s]
[INFO] PMD C# ............................................. SUCCESS [ 16.891 s]
[INFO] PMD Dart ........................................... SUCCESS [  9.317 s]
[INFO] PMD Fortran ........................................ SUCCESS [  6.105 s]
[INFO] PMD Gherkin ........................................ SUCCESS [ 16.105 s]
[INFO] PMD Go ............................................. SUCCESS [  8.768 s]
[INFO] PMD Groovy ......................................... SUCCESS [  9.565 s]
[INFO] PMD HTML ........................................... SUCCESS [  8.741 s]
[INFO] PMD Java ........................................... SUCCESS [03:17 min]
[INFO] PMD JavaScript ..................................... SUCCESS [ 25.659 s]
[INFO] PMD JSP ............................................ SUCCESS [ 17.373 s]
[INFO] PMD Julia .......................................... SUCCESS [ 26.660 s]
[INFO] PMD Kotlin ......................................... SUCCESS [ 41.748 s]
[INFO] PMD Lua ............................................ SUCCESS [ 18.991 s]
[INFO] PMD Matlab ......................................... SUCCESS [ 14.886 s]
[INFO] PMD Modelica ....................................... SUCCESS [ 30.926 s]
[INFO] PMD Objective-C .................................... SUCCESS [  9.005 s]
[INFO] PMD Perl ........................................... SUCCESS [  5.979 s]
[INFO] PMD PHP ............................................ SUCCESS [  6.914 s]
[INFO] PMD PL/SQL ......................................... SUCCESS [02:14 min]
[INFO] PMD Python ......................................... SUCCESS [  6.971 s]
[INFO] PMD Ruby ........................................... SUCCESS [  5.493 s]
[INFO] PMD Rust ........................................... SUCCESS [  7.290 s]
[INFO] PMD Scala Common Source and Settings ............... SUCCESS [  1.874 s]
[INFO] PMD Scala for Scala 2.13 ........................... SUCCESS [ 24.269 s]
[INFO] PMD Swift .......................................... SUCCESS [ 23.196 s]
[INFO] PMD TSql ........................................... SUCCESS [  7.145 s]
[INFO] PMD Visualforce .................................... SUCCESS [ 12.353 s]
[INFO] PMD Velocity Template Language (VTL) ............... SUCCESS [ 10.073 s]
[INFO] PMD XML and XSL .................................... SUCCESS [  7.855 s]
[INFO] PMD Languages Dependencies ......................... SUCCESS [  2.878 s]
[INFO] PMD Documentation Generator (internal) ............. SUCCESS [ 10.902 s]
[INFO] PMD Scala for Scala 2.12 ........................... SUCCESS [ 21.131 s]
[INFO] PMD CLI ............................................ SUCCESS [ 11.246 s]
[INFO] PMD Distribution Packages .......................... SUCCESS [ 11.457 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  17:52 min
[INFO] Finished at: 2025-01-09T15:49:59+01:00
[INFO] ------------------------------------------------------------------------

[tom@hal pmd-src-7.30.0]$

Now the source and binary distribution zip files can be found in the folder pmd-dist/target.

Notes:

  • The rules that have already been written are specified in the src/main/resources/category/ directories of the specific languages, e.g. pmd-java/src/main/resources/category. They’re also in the jar file that’s included with both the source and binary distributions.
Tags: devdocs
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.