NetworkManager/contrib
Thomas Haller 60c70e2fd2
contrib/rpm: support default options for debug,test in generated spec file
"build_clean.sh" (and "build.sh") scripts can both create a source
tarball (via `make dist`/`make distcheck`), an SRPM (and a spec file),
or build RPMs from the SRPM.

Note that the generated spec file has various options, like

    %bcond_without nmtui
    %bcond_without debug
    %bcond_without test

When building an RPM from the SRPM, you can specify the "--with" or
"--without" option for rpmbuild. This is also what the "-w" / "-W" options
for "build_clean.sh" do.

However, the SRPM still has the intrinsic defaults, and if you later
build an RPM from it, you would have to pass "--with" / "--without"
to rpmbuild.

Often that is not conveniently possible, for example, when you build the
SRPM in koji.

Extend the scripts so that also the defaults for "-w debug" and "-w
test" can be specified when generating the SRPM. You can do that with
the new options "--default-for-{debug,test}" to "build_clean.sh".

Alternatively, it suffices to specify the previously supported
"-w" / "-W" options. That way, we will pass those options to rpmbuild,
but also set them as defaults in the generate spec file. The new
options "--default-for-{debug,test}" are only needed if you want
the default in the spec file to be different then what you use
when creating the SRPM.

(cherry picked from commit a3f2cee0e6)
2021-01-07 09:17:09 +01:00
..
art/logo artwork: introduce NetworkManager stickers 2019-09-30 17:36:59 +02:00
debian build/debian: install mobile-broadband-provider-info 2019-09-11 14:54:34 +02:00
editors contrib: add emacs config for hacking on NM 2015-08-11 13:42:26 -04:00
fedora contrib/rpm: support default options for debug,test in generated spec file 2021-01-07 09:17:09 +01:00
scripts contrib: add "nm-code-format-container.sh" to reformat working directory in container 2020-09-29 13:37:58 +02:00