Recent

Author Topic: [ANN] PasBuild v1.7.0 Released  (Read 947 times)

Graeme

  • Hero Member
  • *****
  • Posts: 1526
    • Graeme on the web
[ANN] PasBuild v1.7.0 Released
« on: March 29, 2026, 03:19:58 am »
Hi everyone,

PasBuild v1.7.0 has been released.

PasBuild is a Maven-inspired build automation tool for Free
Pascal projects. It provides convention-based project structure,
dependency management, multi-module builds, resource filtering,
and packaging.

Homepage:
  https://github.com/graemeg/pasbuild

Quick Start Guide:
   https://github.com/graemeg/PasBuild/blob/master/docs/quick-start-guide.adoc


Overview For This Release
-------------------------

PasBuild v1.7.0 introduces an external plugin system, a
resolve command for IDE and tooling integration, and
activeByDefault module control. Several bug fixes improve
multi-module test builds, unit discovery for non-standard
source layouts, and resource processing output.


New Features
------------

External Plugin System

  PasBuild now supports external plugins: standalone
  executables that extend the build lifecycle with custom
  goals. Plugins are named pasbuild-<goal> and discovered
  in the project's plugins/ directory, ~/.pasbuild/plugins/,
  or anywhere on PATH.

  Plugins declare which build phase they run after via a
  --pasbuild-phase flag and receive project context through
  environment variables and the resolve command. Unknown
  goals are automatically deferred for plugin resolution
  before reporting an error.

  An example plugin (shell and Pascal implementations) is
  included under extras/plugins/hello-world/.

  Example usage:

    pasbuild hello       # runs pasbuild-hello plugin
    pasbuild --help      # lists discovered plugins


Resolve Command (IDE/Tooling Integration)

  The new resolve command outputs the fully resolved build
  configuration as JSON to stdout, without compiling. This
  includes unit paths, include paths, defines, compiler
  options, dependencies, and the complete compiler command
  line.

  It supports single-module projects, multi-module
  aggregators (outputs all modules), and per-module
  selection with -m.

  Example usage:

    pasbuild resolve           # single module
    pasbuild resolve           # aggregator: all modules
    pasbuild resolve -m core   # specific module

  Use cases include IDE integration, plugin development,
  CI tooling, and debugging build configuration issues.


activeByDefault Module Attribute

  Modules listed in an aggregator's <modules> section can
  now specify activeByDefault="false" to be excluded from
  normal builds. This is useful for example projects or
  optional modules in large multi-module repositories.

  Two mechanisms override this attribute:

  - The --all CLI flag forces all modules to build
    regardless of their activeByDefault setting (useful
    for CI and nightly builds).
  - Explicitly selecting a module with -m also overrides
    the attribute.

  Example:

    <modules>
      <module>core</module>
      <module activeByDefault="false">examples</module>
    </modules>


Bug Fixes
---------

Multi-Line Unit Declarations in Bootstrap Generator

  Units where the 'unit' keyword and the unit name appear
  on separate lines (common in some FPC codebases such as
  aggpas units in fpGUI) were not being discovered by the
  bootstrap generator. ParseUnitName now tracks a
  UnitKeyFound flag to handle the name appearing on the
  next non-empty line.

  Thanks to Andrew Haines for reporting this issue.


Test Goals Skip Gracefully When No Test Directory Exists

  Modules without a src/test/pascal/ directory previously
  caused the entire reactor build to fail. Test-compile
  and test now log an informational message and return
  success, matching Maven behaviour where a module with
  no test sources reports SUCCESS in the reactor summary.


Test-Compile Routed Through Reactor for Multi-Module Builds

  The test-compile goal was missing from both the
  multi-module dispatch and the reactor goal-to-command
  mapping. This caused test-compile with -m to run against
  the aggregator directory instead of the selected module,
  failing with "Source directory not found".


Module Dependency Paths Included in Test-Compile

  Test compilation failed when test units referenced units
  from module dependencies because BuildTestCompilerCommand
  omitted ResolvedModulePaths. The same -Fu loop from the
  compile command is now applied to test-compile.


Conditional Unit Paths Resolved Relative to Source Directory

  Conditional paths from <unitPaths> were added as -Fu
  flags without prepending the base source directory,
  producing incorrect compiler arguments in auto-scan
  mode. Paths are now resolved relative to the configured
  source directory.


XML Escaping in Init-Generated project.xml

  User input containing <, >, or & characters (e.g. an
  author field with an email address in angle brackets)
  produced invalid XML. All user-provided values are now
  escaped with XML entities before being written.

  Thanks to Frank Fischer for reporting this issue.


Resource Processing Output Respects Verbose Flag

  The per-file "Copied:" and "Filtered:" log lines during
  resource processing could produce excessive output for
  projects with many resource files. These lines now
  require the -v flag. The verbose flag is also propagated
  from parent commands to their dependencies.


Changes
-------

CLI Refactoring

  Build goals and certain arguments are now refactored
  and better separated in code logic.


Quiet Mode for Resolve Output

  The resolve command suppresses all [INFO] log lines to
  ensure only machine-consumable JSON appears on stdout.


Test Suite
----------

  63 new test cases added in this release:
  Total test count: 209 (up from 146 in v1.6.0)


PasBuild is free software released under the BSD-3-Clause
license.


Regards,
  - Graeme -
--
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

valdir.marcos

  • Hero Member
  • *****
  • Posts: 1266
Re: [ANN] PasBuild v1.7.0 Released
« Reply #1 on: March 30, 2026, 04:32:37 am »
Simply because the task is not easy to describe, ...
I have understood that some MacOS related commits should be merged and then FPC 3.2.4 is ready for release.
If the commits are known, it should be easy to explain. "Merge commits xxx, yyy, zzz and solve merge conflicts."
Are the commits known? I assume somebody knows.

The thing is that fpk, who is the release manager for 3.2.4 had said that the fixes branch is frozen (around 1 1/2 years ago) and hadn't yet said that it is free for merges again. Which is why marcov and I have refrained from doing further merges including the fixes for macOS, which yes, are known.

The reason for the delay is reportedly the lack of manpower.  It looks like A.I could manage doing the work involved in releasing the next version of FPC.  If producing a C compiler comes at a cost of $20,000, the cost of an FPC release should be a very small fraction of that which I believe the community as a whole would likely be willing to occasionally shoulder.    Built into the above is the presumption that the amount of work involved in an FPC release is significantly less than what's required to produce a C compiler and also that it is a lot simpler.

The issues we are talking about are issues one doesn't need to use AI for. That's just unnecessary overkill.
For deciding which commits are necessary to be merged a human is required and will always be required, because as soon as we bow to that AI non-sense part of the core devs (including me) will leave the project. I have absolutely no love for AI assisted coding and I don't want to be bother by it in a project I do for enjoyment.
What we instead need is better automation for building, like Jenkins which we indirectly have through alb42 (who mainly tests the Amiga-like platforms, but also some other platforms). If we can get that to automatically generate full releases instead of simply snapshots then that already makes things easier for us.
The issues we have can be solved using normal, deterministic ways, one doesn't need to resort to stochastic parrots.



Jenkins
Build great things at any scale
The leading open source automation server, Jenkins provides hundreds of plugins to support building, deploying and automating any project.
https://www.jenkins.io


Jenkins is an open source automation server. It helps automate the parts of software development related to building, testing, and deploying, facilitating continuous integration, and continuous delivery. It is a server-based system that runs in servlet containers such as Apache Tomcat, or by default as a stand-alone web-application in co-bundled Eclipse Jetty. It supports version control tools, including AccuRev, CVS, Subversion, Git, Mercurial, Perforce, ClearCase, and RTC, and can execute Apache Ant, Apache Maven, and sbt based projects as well as arbitrary shell scripts and Windows batch commands.
https://en.wikipedia.org/wiki/Jenkins_(software)


@Graeme
Respecting the differences between Jenkins and PasBuild, is it possible to use PasBuild to build the entire Free Pascal Compiler (FPC) from sources (trunk/main, fixes, stable, etc)?

Graeme

  • Hero Member
  • *****
  • Posts: 1526
    • Graeme on the web
Re: [ANN] PasBuild v1.7.0 Released
« Reply #2 on: March 30, 2026, 01:40:59 pm »
Respecting the differences between Jenkins and PasBuild, is it possible to use PasBuild to build the entire Free Pascal Compiler (FPC) from sources (trunk/main, fixes, stable, etc)?

Jenkins and PasBuild have very different target audiences. But honestly, I have no idea. Would be an interesting experiment though. And with the new plug-in support in PasBuild, I guess anything is possible now.

I don't fully understand the build system of FPC, and after numerous attempts to try and understand fpmake itself, for my own personal use, I eventually gave up. That was primarily the reason I created PasBuild in the first place - fpmake was too hard to use, and too much of a manual process.
--
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

 

TinyPortal © 2005-2018