You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: pages/terra/SRPM.mdx
+9-9Lines changed: 9 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ import { Callout } from "nextra/components";
9
9
10
10
We provide SPRM macros to ease packaging and better integrate into our workflow. Please use these macros when possible when contributing to Terra.
11
11
12
-
These are provided in the `anda-srpm-macros` package. If you use them, make sure to add `anda-srpm-macros` as a `BuildRequires:` in the spec file.
12
+
These are provided in the `anda-srpm-macros` package. If you use them, make sure to add `anda-srpm-macros` as a `BuildRequires:{:rpmspec}` in the spec file.
13
13
14
14
You may need to refer to the [miscellaneous packaging guidelines](./policy#miscellaneous-packaging-guidelines) for non-macro related Terra guidelines.
15
15
@@ -222,7 +222,7 @@ OR:
222
222
The above would create a `LICENSE.modules` file which can then be packaged using `%license LICENSE.modules`.
223
223
224
224
#### %npm_license_summary
225
-
Outputs a summary of the bundled licenses. Useful for determining what to put in the `License:` section for Node modules.
225
+
Outputs a summary of the bundled licenses. Useful for determining what to put in the `License:{:rpmspec}` section for Node modules.
226
226
227
227
Expands to: `%{__npm_license_checker} --summary`
228
228
@@ -453,7 +453,7 @@ These macros assist with the general packaging of applications that use [Electro
453
453
### %electronmeta
454
454
Set up all basic requirements including build macros for building an Electron app.
455
455
456
-
Does <u>not</u> install the JavaScript package managers used for builds (e.g., `nodejs-npm`, `bun`, `pnpm`, `yarnpkg`, `yarnpkg-berry`). These must still be specified in the `BuildRequires:` manually.
456
+
Does <u>not</u> install the JavaScript package managers used for builds (e.g., `nodejs-npm`, `bun`, `pnpm`, `yarnpkg`, `yarnpkg-berry`). These must still be specified in the `BuildRequires:{:rpmspec}` manually.
457
457
458
458
Available flags:
459
459
-`-a` will pull in additional build dependencies often needed particularly when building with NPM.
@@ -474,19 +474,19 @@ Rundown of what all `%electronmeta` does:
474
474
- Defines `%__requires_excludes` based on architecture to prevent Electron projects' cross-platform builds from causing false dependency positives from RPM.
475
475
- Sets `%debug_package` to `%{nil}` to prevent stripping of bundled libraries and/or build failures due to not enough data to strip.
476
476
- Sets the build and runtime dependencies.
477
-
- Sets the `ExclusiveArch` field to only the architectures Electron supports.
477
+
- Sets the `ExclusiveArch:{:rpmspec}` field to only the architectures Electron supports.
478
478
- Defines a `%bcond` for whether or not Electron is bundled for other macros.
479
479
- Defines the bundled dependencies as bundled. NOTE: This only defines Electron's bundled dependencies, not any Node modules the app may also bundle.
480
480
481
481
This ensures packagers do not need to manually set these for every Electron app's spec, hopefully eliminating depsolver problems and helping reduce common build issues.
482
482
483
483
Like other meta macros (e.g., `%forgemeta` from Fedora), you MUST be mindful of where in the spec this macro should be placed.
484
-
- MUST always come after `Name:` is defined and before the `%prep` section.
485
-
- SHOULD come before the `License:` field if using [`%{electron_license}`](#electron_license).
484
+
- MUST always come after `Name:{:rpmspec}` is defined and before the `%prep` section.
485
+
- SHOULD come before the `License:{:rpmspec}` field if using [`%{electron_license}`](#electron_license).
486
486
- MAY need to come before the sources if an upstream provides sources named after the Electron architecture.
487
487
- MAY be used under preambles but before `%prep` if not using `%{electron_license}`.
488
488
489
-
The safest location is under `Name:` and above other preambles. When in doubt, place the macro here.
489
+
The safest location is under `Name:{:rpmspec}` and above other preambles. When in doubt, place the macro here.
490
490
491
491
Example usage:
492
492
```rpmspec
@@ -511,9 +511,9 @@ However, at this time Terra only supports x86_64, AArch64, and 32-bit x86.
511
511
### %electron_license
512
512
The license for bundled Electron.
513
513
NOT set by default in `%electronmeta` because you cannot set the license field twice.
514
-
MAY be used in combination with manually adding the other relevant licenses (if this is done, a proper license tag would be `License: XXX-x.x AND %{electron_license}`.
514
+
MAY be used in combination with manually adding the other relevant licenses (if this is done, a proper license tag would be `License: XXX-x.x AND %{electron_license}{:rpmspec}`.
515
515
516
-
[`%electronmeta`](#electronmeta) SHOULD be used BEFORE the `License:` preamble but AFTER `Name:` if using this macro.
516
+
[`%electronmeta`](#electronmeta) SHOULD be used BEFORE the `License:{:rpmspec}` preamble but AFTER `Name:` if using this macro.
517
517
518
518
### Electron Build Macros
519
519
These are macros used to build Electron apps using JavaScript package managers and builders such as [Electron Builder](https://www.electron.build), [Electron Forge](https://www.electronforge.io), and [Electron Vite](https://electron-vite.github.io).
0 commit comments