[Slackbuilds-users] Setting options (was: FFmpeg update)

Christoph Willing chris.willing at iinet.net.au
Fri May 29 06:44:58 UTC 2015

On 29/05/15 07:15, Christoph Willing wrote:
> On 29/05/15 05:57, David Spencer wrote:
>> At the risk of further bikeshedding, isn't it best to just keep your
>> choice of options somewhere? e.g. in the sbopkg queuefile, or in the
>> sbopkg saved .options file?
> That's only good for sbopkg users.

So what about non-sbopkg users - myself, in particular? A better 
solution would be one that is not specific to a particular build 
framework. I've had an idea about it which I'll outline here and ask for 
any comments - its _not_ a proposal for any change at SBo.

As well as the SBo git master branch, I already have a local 'spbuilder' 
branch of it in which I keep any variations that I happen to want. In 
particular, for the packages I use, each .info file has an extra PREREQS 
field which contains any packages that I want beyond those already 
mentioned in the REQUIRES field. The PREREQS field also has $REQUIRES in 
it; therefore my personal build tool can use the PREREQS field to load 
up both the standard packages as well as my preferred extra packages.

Using that same idea, of adding to the local version of the .info file, 
why not add an OPTIONS field? Probably better might be OPTIONS_ON and 
OPTIONS_OFF fields e.g.
which the build tool would use to set options in the environment when it 
runs the SlackBuild.

Is it preferable to edit the .info file (rather than the .SlackBuild)? 
Well, I think it is preferable for two reasons. Firstly because the 
.info file is not executed and any additional fields in it should be 
completely transparent to any build system that doesn't know about the 
additions. Secondly because periodic merges from master _usually_ cause 
no conflicts when any local changes consist of additions at the end of a 
file (as would be the case here). On the other hand, changes in the 
middle of a file (like resetting various options from 'no' to 'yes' in 
the .SlackBuild file itself) are more likely to result in merge 
conflicts that need to be resolved.

Its just an idea at the moment. I'd welcome any comments (is it an 
inherently _bad_ idea?) before modifying my build tool to accommodate it.


More information about the SlackBuilds-users mailing list