[Rpm-maint] [rpm-software-management/rpm] Add a man page for rpm macro processor (PR #3781)

Michal Domonkos notifications at github.com
Fri Jun 13 14:44:59 UTC 2025


@dmnks commented on this pull request.



> +RPM has a powerful built-in macro processor. The primary uses of macros
+are configuration and other utility functions for RPM itself,
+and as a packaging aid in spec files.
+
+In addition to simple text substitution, the macro processor supports
+the following facilities:
+- function-like parametric macros with options and arguments processing
+  and locally scoped automatic and user-defined macros
+- various built-in primitives for string processing and OS interaction
+- shell expansion
+- expression expansion
+- embedded Lua expansion
+
+The macro definition syntax is:
+
+	_NAME_[([_OPTIONS_])] _BODY_

I wonder if this hairy definition could be simplified by leaving out the square brackets immediately around `OPTIONS`? As in:

```
_NAME_[(_OPTIONS_)] _BODY_
```

I suppose they're currently there because you can legally define a macro as `foo()` (i.e. without any options). But is that actually something that's useful by itself?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/3781#pullrequestreview-2925089334
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/pull/3781/review/2925089334 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20250613/6ada569d/attachment.htm>


More information about the Rpm-maint mailing list