On 01/20/2014 04:24 PM, Björn Persson wrote:
Apparently RPMbuild has a pair of parameters "--with" and "--without"
that can supposedly enable and disable optional features in a package.
Has anyone seen any documentation that explains how those work and how
they interact with a spec file?

I want to be able to easily switch an option between these two states:
· off by default but can be enabled with "--with"
· on by default but can be disabled with "--without"
What's a good way to code that in the spec?

See http://rpm.org/wiki/PackagerDocs/ConditionalBuilds

According to the Packaging Guidelines we're not supposed to use those
parameters when building "the source RPM to be submitted", because they
somehow get "serialized" into the source package. I don't understand
this, because I don't submit any source packages. The source package
gets built on a Koji server when I run "fedpkg build", and I don't know
of a way to pass any options to that process.

I guess you'd be referring to this:
https://fedoraproject.org/wiki/Packaging:Guidelines#Conditional_dependencies

Its a rather complicated way of saying that Fedora packages must have their Fedora defaults for with/without set in the spec, ie rebuilding the package must not require any command-line switches.

        - Panu -

--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel
Fedora Code of Conduct: http://fedoraproject.org/code-of-conduct

Reply via email to