srpm

Synopsis

Create a source rpm

Description

This command wraps “rpmbuild -bs”, roughly equivalent to:

rpmbuild -bs mypackage.spec

–define “_topdir .” –define “_sourcedir .” –define “_srcrpmdir .” –define “dist .el8”

To include files in the SRPM, the files must be in the current working directory (this depends on the package layout used), and you must reference each file with SourceXXXX: or PatchXXXX: directives in your .spec file.

Arguments

extra_args

Custom arguments that are passed to the ‘rpmbuild’. Use ‘–’ to separate them from other arguments.

Options

-h --help

show this help message and exit

--builddir

Define an alternate builddir

--buildrootdir

Define an alternate buildrootdir

--arch

Prep for a specific arch

--define

Pass custom macros to rpmbuild, may specify multiple times

--md5

Use md5 checksums (for older rpm hosts)

--srpm-mock

Create source rpm in ‘mock’ instead of ‘rpmbuild’

--no-clean -n

Only for --srpm-mock: Do not clean chroot before building package

--no-cleanup-after

Only for --srpm-mock: Do not clean chroot after building if automatic cleanup is enabled

--no-clean-all -N

Only for --srpm-mock: Alias for both --no-clean and --no-cleanup-after